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

overload of xc864 limit?

Hi,

I'm making a program with the xc864 using the keil application but at some point I started to get the followings errors while I tried to program my micro:

" Content mismatch at address 0000H (Flash=EDH Required=02H)
Content mismatch at address 0001H (Flash=B7H Required=0FH)
Content mismatch at address 0002H (Flash=DCH Required=D6H)
Content mismatch at address 0003H (Flash=7FH Required=78H)
... "

I've proved to comment independents parts of the program and the error disapears. So that I think that the problem is that my code is too huge for the micro.

How can I know what makes my code too huge?
There is a way to get more free space for coding?

thanks

Parents
  • The whole point of using functions is that the code is not repeated - a function occupies the same amount of code space whether it is called once or 1000 times!

    The same applies to library functions; eg, printf: if you remove 999 printf calls, and leave only 1 call, then you will still need to have printf in the code.

    Did you actually look at the MAP file, as suggested, to see exactly what is using up all your code space?

    "Looking on the datasheet I've confirmed that the xc864 just have 4k for flash programing, so that I must optmizate the program..."

    Before "oprimising" the program, have you actually considered whether a 4K part has any chance of being sufficient for your requirements?

    At the end of the day, you cannot cram a quart into a pint pot!

Reply
  • The whole point of using functions is that the code is not repeated - a function occupies the same amount of code space whether it is called once or 1000 times!

    The same applies to library functions; eg, printf: if you remove 999 printf calls, and leave only 1 call, then you will still need to have printf in the code.

    Did you actually look at the MAP file, as suggested, to see exactly what is using up all your code space?

    "Looking on the datasheet I've confirmed that the xc864 just have 4k for flash programing, so that I must optmizate the program..."

    Before "oprimising" the program, have you actually considered whether a 4K part has any chance of being sufficient for your requirements?

    At the end of the day, you cannot cram a quart into a pint pot!

Children
No data