Every member of the HC08 microcontroller family is equipped with a basic support for in-system programming and debugging (MON8, for details see datasheet of a HC08 processor). The microcontroller can work in two modes, normal and monitor.
In the monitor mode, the microcontroller can accept couple of commands over the single wire interface. The commands allow to read/write the memory and run a code. In combination with Break module a simple debugging system can be built (for example, ICS boards, P&E Multilink, or various custom designs).
There are few issues that results from the characteristics of the MON8 system:
- To achieve a standard communication speed (19200, 9600, 4800 bauds) a specific oscillator frequency must be used (usually 9.83 or 4.915MHz). Suitable source of processor clock is usually part of the debugging system. The user must set the same clock frequency in the processor component of his project to ensure that the timing of components will be correct. Care must be taken when using PLL and speed modes. Change of the operating frequency of the target processor can result in loss of communication with the target system.
- Some processor models allows to by-pass internal divider-by-2, which effectively doubles the bus clock of the processor. The bypass is selected by logic state of selected input pin (for example, PTC3) during processor reset. The user must set appropriate property in the processor component to reflect actual state of the pin.
- One I/O pin (for example, PTA0) is used for communication with the host computer, therefore it can't be used as a general I/O pin.
- In some configuration of the debugging system, the IRQ pin can be also used to control the target board, therefore it can't be used in user application.