2024-05-16 06:15 AM
I need to generate a checksum of data from X address(FLASH) to Y address (FLASH). and write at last 4 bytes of FLASH memory in "xyz" section.
When I say calculate checksum, I mean addition of all given data bytes from X address(FLASH) to Y address (FLASH).
Can we do it at compilation time ?
2024-05-16 10:25 PM
If you write a script (e.g. in Python) which can read your generated ELF or BIN file - sure.
You have to provide this script and add it as a post-compile step.
The compiler itself does not do. But you are free to add this as a step after code generation. And what and how to do: it is only you (therefore you had to write a script post-processing the compile results).