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

code memory overshoot ???

if i am using AT89C2051 which has a 2k on-chip code memory, how will i know if my codes have exeeded it? does KEIL automatically pop error? in my application i do not intend using any external code memory & neither is hardware designed for it. what is the way to detect the same (i.e. if i have exeeded the on-chip code memory limit) ???

thank you.

Parents
  • If you specify the starting AND ending address of the CODE space to the linker, you will receive a linker error if you overflow the CODE space. For example:

    *** ERROR L107: ADDRESS SPACE OVERFLOW
        SPACE:   CODE
        SEGMENT: ?PR?MAIN?HELLO
        LENGTH:  000028H

    You can test this with a small program by creating a code array of 2048 bytes. For example:

    code char dummy [2048];

    Jon

Reply
  • If you specify the starting AND ending address of the CODE space to the linker, you will receive a linker error if you overflow the CODE space. For example:

    *** ERROR L107: ADDRESS SPACE OVERFLOW
        SPACE:   CODE
        SEGMENT: ?PR?MAIN?HELLO
        LENGTH:  000028H

    You can test this with a small program by creating a code array of 2048 bytes. For example:

    code char dummy [2048];

    Jon

Children