A remote debugger consists of a host program running on your PC; which provides the debugger user interface, symbol tables, etc. and a (usually) small monitor program running on the actual target processor. The two programs communicate via RS-232 or some other medium.
"Remote" in this case usually means only a few feet of cable connecting the two devices. The term was coined to distinguish two-computer debugging from the case where the debugger runs on the same computer as the program being debugged.
The target monitor usually implements only a few primitive commands such as memory read and write, register read and write, and execute.
The advantage of this approach is that the target monitor can be kept simple and small, because it doesn't need to contain disassembler tables, ASCII command parsers and the like. Small size also leaves as much of the processor address space as possible for your application program.
The Freescale HCS12 Microcontrollers feature a Background Debug Port (BDM) which allows a Remote Application to control the operation of the target processor. Thjs BDM interface also allows on-chip debugging of code.
The host program can grow as fancy as required, usually without affecting the target program. For example, the DOS and Windows version of NoICE both work with the same target program, even though the Windows version offers many new features.
- The Moitor Program resident on the actual Target Microcontroller uses the following resources:
- Enough FLASH to hold the monitor (about 1024 bytes; smaller than most stand-alone monitors).
- Enough RAM to hold the monitor's data (32 to 256 bytes, depending on the number of processor registers and the desired communications buffer size)
- A UART to communicate with the PC host (or an input bit, an output bit, and the appropriate user-provided bit-banging serial code)
- Enough RAM to hold the program to be downloaded and debugged.
- Special hardware to support single step operation is not required.
- NoICE for Windows uses the same monitors as NoICE for DOS.
|