Steps:
1. Generate the bin file and place the bin file in the virtual host directory
2. Make a PHP page block read the bin file, echo out with the ASC character, and mark the length of the tail and the checksum.
3.GPRS protocol stack Connection host path, receive content, content parsing, verification, error saving to backup flash space
4. After all save is done, make a logo in the parameters Flash area, waiting to reboot
5. Do a bootloader, after the boot to detect whether there is a good new version number, if any, overwrite the old version, or directly into the entrance vector.
Because the content of the GPRS transmission HTTP protocol belongs to the short connection, at instruction the situation is many and complex, many need to judge the processing, has the high intensity of work, here the content is temporarily not public. After practical testing, upgrading a dozens of K bin file takes about 5-10 minutes, the middle allows the power-off to re-open without affecting the continuation of the upgrade, the actual work reliability meets the requirements.
Using the HTTP protocol to use ordinary Web site virtual Host + a6c GPRS module for STM32 remote upgrade