Teensy OTA using VS2109/Visual Micro and HC-05 BT module

Status
Not open for further replies.

paynterf

Well-known member
Thanks to Paul Stroffregen and Joe Pasquariello's efforts, I have been able to successfully perform OTA updates to a Teensy 3.5 using Visual Studio 2019 Community Edition and the Visual Micro extension as my Arduino IDE, and a BT link from my laptop to a HC-05 module as the OTA link to the Teensy.

I have placed my demo code on my GitHub site - see this link for the Teensy demo sketch, and this link for the C# command-line program I created to automate the process. I also have a very detailed description of the entire development process (including all my failures!) on my blog site here.

Many thanks to Joe for answering all my dumb questions and helping me understand how his wonderful FlasherX update framework does it's magic. I just hope this demo will help others get over the Teensy OTA hump as well.

Note that at present, the BT OTA process appears to be significantly slower than the manual process using Tera Term. I'm not quite sure why, but I suspect I missed something in my command-line program when initializing the serial link. If anyone can figure that out I'd appreciate the help ;-).

Frank
 
Also, I tried speeding up the OTA update by raising the baud rates on both the Serial1 hardware serial interface, and the BT link back to the PC. Doubling the baud rate from 115,200 to 230,400 did not significantly decrease the overall time (about14-15 sec) required to update with a 3100+ line file, so I now suspect that the bottleneck is the line-by-line processing in the Teensy. Joe?

Frank
 
So, I instrumented the 'update_firmware()' function in FlasherX, to see how long it took to process a single line, by timing the processing of a 3133-line .HEX file. The function took 11,729 mSec, or about 3.75 mSec per line. My impression is that this 3.3 mSec/line is a 'fixed cost' for doing OTA updates using FlasherX code. Any thoughts?
 
Status
Not open for further replies.
Back
Top