Zubax / kocherga

Robust platform-agnostic Cyphal/DroneCAN bootloader for deeply embedded systems
https://zubax.com
MIT License
45 stars 10 forks source link

How to embed AppInfo into ROM image #3

Closed chemicstry closed 5 years ago

chemicstry commented 5 years ago

Firstly, thank you for this great library that saved me from writing tons of boilerplate code. I fairly quickly got it running on STM32F103 and can now upload ROM images via UAVCAN.

However, I'm not sure what would be the correct procedure for embedding AppInfo structure into a ROM image. I can initialise it as a global in the code, however I will not be able to calculate CRC and size variables. Is this a job for a custom build tool that would calculate these fields and modify an already built binary? Or am I missing some magic tool that does just that?

Thank you.

pavel-kirienko commented 5 years ago

Thanks @chemicstry ! Fixed in https://github.com/Zubax/kocherga/pull/4

Please review the docs and let me know if anything requires clarification there.

chemicstry commented 5 years ago

I was going to share my own python script that I got working but I see that yours is way better structured. I will test and see if it works.

Thank you for the update!

pavel-kirienko commented 5 years ago

see that yours is way better structured

Thanks, but it is written by Ben Dyer, my modifications are very minor. ;)