cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F4: Bootloader: CAN bus

Terry Barnaby
Associate III
Posted on July 14, 2014 at 14:51

I am trying to load firmware over the CAN2 bus using the STM32F4's internal bootloader from a Linux system following the application note AN3154.

In general this is working but I have an issue when writing the data using the WriteMemory command. The STM32 appears to send multiple acknowledgements (0x79) to the 0x04 data commands occasionally. If, on the Linux host, I wait for 100ms before each 0x04 command and flush the CAN bus RX buffer before sending the 0x04 command all is fine, but if I don't flush these spurious acknowledgements things obviously go wrong.

Are there some issues with the STM32 bootloader in CAN bus mode ?

2 REPLIES 2
Terry Barnaby
Associate III
Posted on July 15, 2014 at 12:07

Further to this I have found it works if a delay of about 2ms is added after every WriteData CAN frame has been sent and acknowledgement received. It looks like there is some issue here ...

danielschramm9
Associate II
Posted on October 14, 2014 at 08:05

Hello,

did you have success with your Linux code to flash the stm32 via CAN interface?

Would it be possible that you share your code or launch an open source project from it?

Currently there seems to be no project or reference implementation for this.

(I'm interested for a home automation project, where I need to update several controllers on the bus. This project will also be published as open source / open hardware.

 

Reducing the amount of time invested in the bootloader will help on the other side of the project.)

Thanks a lot,

Daniel