How To Use Dbg Pin; Used As 1-Line Uart Pin / P12 Pin; Used As Ec0 Pin - Fujitsu MB95210H Series Application Note

8-bit microcontroller, how to use dbg pin
Hide thumbs Also See for MB95210H Series:
Table of Contents

Advertisement

3 How to Use DBG Pin

EXAMPLES FOR DBG PIN SETTING IN DIFFERENT MODE

3.1 Used as 1-line UART pin / P12 pin

In Debug mode, DBG pin is used as 1-line UART pin automatically. Then DBG pin keeps
high when UART is in idle status. And in free-run mode, DBG pin is used as P12 according
to default setting. If write user code as follow:
DDR1_D12 = 1;
PDR1_P12 = 0;
After execute these codes in debug mode, the DBG pin still keeps high level. But after run
these codes in free-run mode, the DBG pin pulls to low level.

3.2 Used as EC0 pin

DBG pin can't be used as EC0 pin in debug mode. To realize the external clock input for the
8/16 compound timer, EC0 pin can be changed to P04 pin in debug mode.
SYSC = 0xEB;
T00CR0 = 0x71;
TMCR0 = 0x43;
T00DR = 0x08;
T00CR1 = 0x81;
The upper sample code sets P04 as EC0 pin, and sets Timer00 in continuous interval timer
mode. Input a clock signal to P04 pin; execute these codes in debug mode; check the T00
pin; you can see the output clock is the input clock divided by 8.
SYSC = 0xE3;
T00CR0 = 0x71;
TMCR0 = 0x43;
T00DR = 0x08;
T00CR1 = 0x81;
The upper sample code sets P12 as EC0 pin, and sets Timer00 in continuous interval timer
mode. Input a clock signal to P12 pin; run these codes in free-run mode, check the T00 pin,
you can see the output clock is the input clock divided by 8.
DBG pin operation V1.0
Chapter 3 How to Use DBG Pin
// set P12 as output pin
// pull P12 to low.
// set P04 as EC0 pin, disable HCLK1
// interval timer, external clock source.
// 8bit mode, output timer00.
// set counter.
// enable output, start timer00.
// set P12 as EC0 pin, disable HCLK1
// interval timer, external clock source.
// 8bit mode, output timer00.
// set counter.
// enable output, start timer00.
MCU-AN-500009-E-10 – Page 6

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mb95200h seriesF2mc-8fx series

Table of Contents