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 do I get end of code address?

I am trying to calculate a simple checksum on my code. I am doing something like this:

   unsigned short Index, Checksum = 0;
   unsigned char code * data pCode = 0;

   for( Index = 0; Index < end_of_code; Index++ )
   {
      Checksum += *pCode++;
   }

How can I get the linker to fill in the 'end_of_code' address or the size of the code segment?

Thanks,
Dan

0