Table of Contents Previous topic Next topic
Overview->Location in Target Memory->Program Location
The debug monitor is designed to reside on your target system at code address zero and upwards.
For systems where the users code will reside in RAM during the debugging process, the debug monitor will occupy less than 2048 bytes of code space. So for instance on a Dallas DS5000, the debug monitor will fit entirely within the first partition 0000-07FF hex.
For other target systems, the location of the users program might be dictated by the board design and the address range allocated to the RAM chips.
For systems where the users code will reside in ROM or flash memory during the debugging process, the debug monitor will occupy more space. (The reason for this is that the debug monitor cannot make use of modifiable code space in order to efficiently access the values of on-chip SFRs and so the subroutines GetSfr() and SetSfr() are much larger.)
For some flash memory chips, the range of memory occupied by the debug monitor is dictated by the size of the reprogrammable blocks. For instance the Philips P89C51RX2 family of microcontrollers has it's first block of flash memory at 0000-1FFF hex. Since this flash memory can only be erased in blocks, the debug monitor cannot share this block with the users program. The users program must therefore start at address 2000 hex. or above.
Other flash memory chips, such as the Atmel W&M T89C51RD2 are byte reprogrammable. The users program can therefore be located in the memory immediately following the debug monitor.