GithubHelp home page GithubHelp logo

Comments (4)

akospasztor avatar akospasztor commented on July 19, 2024

Hi joa77,

just to clarify: are you referring to the application image, that you would like to flash into the microcontroller with the bootloader? Or the bootloader code itself?

Generally, you need to generate a simple binary output (usually a .bin file) for the application image to be able to flash it with the bootloader (as it currently does not support .hex or any other formats than binary).

Nevertheless, the 140 MB is huge. I have no idea how you could have managed to have an application binary with 140MB. Can you please share some info about your project and how you build it?

Best,
Akos

from stm32-bootloader.

joa77 avatar joa77 commented on July 19, 2024

Thank you for the quick reply.
I am talking about the actual app image here.
The bootloader is only a few kb in size.
Too large bin files seem to be a general problem with ST controllers. Google gives a lot of results after a short query.
For example: https://community.st.com/s/question/0D50X00009XkYIP/bin-file-generated-by-gcc-too-large

It seems to be because Flash and RAM do not form a contiguous memory address area. So the space in between is filled with zero.

By adjusting the linker script, I have now managed to have only the flash area in the .bin file and thus only a few kb in size.

Do I now have to fill the .bin file with zeros at the end, so that it can fill the complete flash, so that the CRC is correct?

from stm32-bootloader.

akospasztor avatar akospasztor commented on July 19, 2024

Yes, you have to adjust your linker configuration to generate the correct binary.

If you want to utilize the CRC feature, you have to fill up the remaining space (except the actual 4-byte CRC value) with 0xFF. If you want to use another CRC method or other CRC configuration, you can edit the verification function here so that it matches with your requirements:

uint8_t Bootloader_VerifyChecksum(void)

from stm32-bootloader.

stale avatar stale commented on July 19, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from stm32-bootloader.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.