Docs say that the response to AT+QFUPL is: +QFUPL: <upload_size>,<checksum>
I’m uploading successfully, but can’t figure out how the module is calculating the checksum.
For example, if I upload my 1187 byte cert, the module reports: +QFUPL: 1187,2d19
but I can’t figure out how it’s calculating 2d19.
I have a question, and I was hoping you could help me.
Would you mind explaining how I can upload a certificate file to the Quectel module using the AT+QFUPL command, with the command being sent from my MCU to the Quectel module?
You send AT+QFUPL="FILENAME",SIZE,TIMEOUT
where: FILENAME is the name of the file you want to use inside the modem’s filesystem - in quotes!!! SIZE is the filesize in bytes TIMEOUT is the # of seconds that the modem should timeout if no data is received
For example: AT+QFUPL="myfile.xyz",1234,10
for a 1234 byte file, saved in the modem as myfile.xyz, with a 10 second timeout
You wait for CONNECT\r\n which means that the modem is ready to rx the data
You send your bytes (expected to be SIZE).
If you send too few, the timeout will occur.
If you send too many, the extra bytes will be ignored and it’ll only save the first SIZE bytes.
The modem responds with +QFUPL: SIZE,CRC\r\n\r\nOK\r\n
For example: +QFUPL: 1234,6e8f\r\n\r\nOK\r\n
The CRC/Checksum algorithm is unknown, Quectel doesn’t publish that.
Because the CRC/Checksum value is unknown, something that I’ve taken to doing is using my self-computed CRC as the file extension, e.g. myfile.AF9C (where AF9C is my CRC value). This allows me to know exactly which version of the file is in the modem by sending AT+QFLST