This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How size of hex file is calculated?

my program size is 14kb (pgm.uvproj) and size of hex file is 25kb.
now my question is how these sizes are calulated?

Thanks in advance

Parents
  • They are not.

    The hex file needs a bit more than two bytes for every byte of the binary program.

    But the binary might contain holes that the hex file need not bother with.

    So while it is common that the hex files are larger than the program size reported by the linker, there are no translation formula.

    In short, the size of the hex file is irrelevant when it comes to the important question: if your program will fit or not in the available processor memory.

Reply
  • They are not.

    The hex file needs a bit more than two bytes for every byte of the binary program.

    But the binary might contain holes that the hex file need not bother with.

    So while it is common that the hex files are larger than the program size reported by the linker, there are no translation formula.

    In short, the size of the hex file is irrelevant when it comes to the important question: if your program will fit or not in the available processor memory.

Children