Skip to main content
Graduate
November 7, 2024
Solved

File size larger than flash size

  • November 7, 2024
  • 2 replies
  • 2754 views

Hey everyone I have a qn freejoy.hex is 155kb and my stm32c8t6 is only 64kbs and 128kb how did yall get it flashed

Refer freejoy and freejoy configurator 

It gives me an error file size larger than flash size but other people seems to have workaround any guidence would help a lot

Thanks

    This topic has been closed for replies.
    Best answer by Andrew Neil

    @kalpaknirale wrote:

    Is that how st link utility works ? 


    It's a direct result of the Intel Hex format encoding - It has nothing to do with ST-Link Utility per se.

     

    In the Intel Hex format, each byte of data is encoded as two characters - ie, 2 bytes.

    So that immediately makes the data two times the size.

    Then there's the added overhead of addresses and checksums - so the overall inflation becomes around 2.5 times.

    See the link posted earlier by @mƎALLEm 

     

    #HexSize

    2 replies

    Technical Moderator
    November 7, 2024

    Hello,

    Hex file does not reflect the real size of the application. It contains also the addresses: https://en.wikipedia.org/wiki/Intel_HEX

    If your the generated binary exceeds the Flash size oh the MCU you beed to migrate to a bigger flash size device:

    SofLit_1-1731017308404.png

     

    SofLit_0-1731017268619.png

     

    Graduate
    November 7, 2024

    Yea but the freejoy file size is 155kb 

    Even 128kb will not suffice 

    Technical Moderator
    November 7, 2024

    @kalpaknirale wrote:

    Yea but the freejoy file size is 155kb 

    Even 128kb will not suffice 


    This is the size of the hex file need to convert it to bin format to know the real size of the application. If it exceeds 64kB there is no other solution than migrating to bigger flash size device of 128kB as I explained previously.