Go Down

Topic: Uploading code to aTmega328 using Bluetooth on software serial  (Read 615 times) previous topic - next topic


I 'm working on an ROV and I' m using RS485 with ROS to  communicate my laptop with the arduino uno on the ROV. My problem is that I want to use hc-05 BT module to upload code to the arduino using software serial, because I can't use hardware serial as ROS uses it. Is that possible or is there a way to get ROS working on software serial?
Thanks in advance!


There is a SOFT_UART option in optiboot for bit banged software UART:
I don't have any experience with it.

You'd need to send a signal to start the bootloader before starting the upload. Usually a hardware reset is done. optiboot is written to jump right to the application after a watchdog reset, but it should be possible to modify it to also run on a watchdog reset.

I know some recent work has been done to enable OTA flashing from the application using the new flash write feature of Optiboot. That requires your sketch to only use 1/2 the flash memory of the Arduino. There's information here, and in the linked thread. Juraj also has an OTA library, but it says it only supports microcontrollers with least 64 kB of flash (your Uno has 32):

there is a way to get ROS working on software serial?
I don't know. What is the problem preventing it from working with software serial?

Go Up