PanaXSeries is a trademark of Matsushita Electric Industrial Co., Ltd. The other corporation names,logotype and product names written in this book are trademarks or registered trademarks of their corresponding corporations. Request for your special attention and precautions in using the technical information and semiconductors described in this book An export permit needs to be obtained from the competent authorities of the Japanese Government if any of the products or technologies described in this book and controlled under the "Foreign Exchange and...
How to Read This Manual The MN101C11x incorporates more than one ROM/RAM to meet a variety of applications. An EPROM version as well as a Mask ROM version is available so users can write a program by themselves. Organization In this LSI manual, the MN101C117 functions are presented in the following order: overview, CPU basic functions, port functions, timer functions, serial functions, and other peripheral hardware functions.
Manual Configuration Each section of this manual consists of a title, summary, main text, supplemental information, precautions and warnings. The layout and definition of each section are shown below. Subtitle 4-3 16-bit Timer Operation (timer 4) Sub-subtitle The smallest block 4-3-1 Overview in this manual.
Page 6
Where to Send Inquires Please send any inquires or questions concerning the contents of this manual to the Panasonic semiconductor design center closest to you. A list of addresses is provided at the end of this manual for your convenience.
Chapter 5 Serial Functions 5-1 Overview ...92 5-2 Synchronous Serial Interface ...94 5-2-1 5-2-2 5-2-3 5-3 Half-duplex UART Serial Interface ...101 5-3-1 5-3-2 5-3-3 5-4 Serial Interface Control Registers ...106 5-4-1 5-4-2 5-4-3 5-4-4 Chapter 6 A/D Conversion Functions 6-1 Overview ...114 6-2 A/D Conversion...115 6-3 A/D Converter Control Registers ...117 6-3-1...
Page 13
Appendices 8-1 EPROM Versions ...130 8-1-1 Overview ...130 8-1-2 Cautions on Use...131 8-1-3 Erasing Written Data in Windowed Packages ...132 (PX-AP101C11-SDC, PX-AP101C11-FBC) 8-1-4 Characteristics of EPROM Versions...133 8-1-5 Writing to Internal EPROM...134 8-1-6 Cautions on Handling the ROM Writer...136 8-1-7 Option Bit ...137 8-1-8 Writing Adapter Connection...138...
1-1 Product Overview 1-1-1 Overview The MN101C00 series of 8-bit single-chip microcomputers incorporate several types of peripheral functions. This chip series is well suited for VCR, MD, TV, CD, LD, printer, telephone, home automation, pager, air conditioner, PPC, remote control, fax machine, musical instrument, and other applications.
1-2 Hardware Functions ROM/RAM Size: <Single chip mode> Internal ROM Internal RAM Machine Cycles: High speed mode 0.10µs/20MHz (4.5V to 5.5V) Low speed mode 125µs/32KHz(2.0V to 5.5V)* Interrupts: 12 interrupts(11 interrupts except for 48-pin QFH package) <External interrupts> The active edge can be selected for all external interrupts IRQ0 External interrupt (can be connected to noise filter) IRQ1 External interrupt (can determine zero crossings, can be connected to noise filter)
Page 18
Chapter 1 Overview 26 ports for 44-QFP 27 ports for 48-QFH 12 ports for 48-QFH 4 ports for 48-QFH Hardware Functions Timers 2 and 3 can be cascaded. Timer 4 Square wave output, 16-bit PWM output are possible. Clock source: fosc, fs/4, fs/16, TM4IO pin input Input capture function Time base timer Clock source: fosc, fs/4, fx*...
Chapter 1 Overview Pin No. Name Type Dual Function – OSC1 Input OSC2 Output Input Output 20 to 23 P00 to P02 I/O SBO0(TXD), I/O port 0 SBI0(RXD), SBT0, (BUZZER) Pins 1-3-2 Pin Function Summary *The pin numbers in the list correspond to the QFH package(Refer to Figure 1-3-3 Pin connection.) Be careful when using SDIP and QFP packages.
Page 23
Pin No. Name Type Dual Function 24 to 28 P10 to P14 RMOUT, TM2IO to TM4IO 29 to 32 P20 to P23 Input IRQ0, IRQ1(SENS), IRQ2 to 3 Input 33 to 40 P60 to P67 41 to 42 P70 to P71 I/O 1 to 4 P80 to P87 I/O LED0 to 7...
Page 24
Chapter 1 Overview Pin No. Name Type Dual Function Output SBO0(P00) Input SBI0(P01) SBO0 Output TXD(P00) SBI0 Input RXD(P01) SBT0 Buzzer RMOUT 26 to 28 TM2IO to P12 to P14 TM4IO Pins Table 1-3-1 Pin Function Summary (3/4) Function UART transmit In the serial interface in UART mode, these pins are configured as data output pin the receive data input pin and transmit data output pin.
Page 25
Pin No. Name Type Dual Function MMOD Input 29 to 32 IRQ0 to Input P20, IRQ3 P21(SENS), P22,P23 6 to 13 AN0 to AN7 Input PA0 to PA7 SENS Input IRQ1(P21) Table 1-3-1 Pin Function Summary (4/4) Function This pin sets the test mode. Test mode switch input pin Must be set to L.
1-5 Electrical Characteristics Model MN101C117/115 Contents Classification CMOS integrated circuit General purpose Function CMOS, 8-bit, single-chip microcomputer 1-5-1 Absolute Maximum Ratings Parameter Supply voltage Input clamp current (SENS) Input pin voltage Output pin voltage I/O pin voltage Peak output Except P8 current All pins Average output...
Chapter 1 Overview 700k MN101C The instruction cycle is twice the clock cycle. The feedback resistor is built-in. Figure 1-5-1 Crystal Oscillator 1 Electrical Characteristics 1-5-2 Operating Conditions Parameter Symbol Supply voltage Supply voltage 3 during operation 5 Voltage to maintain RAM data V Operating speed Instruction execution time tc4 *...
Page 29
Parameter Symbol External clock input 1 OSC1 (OSC2 is unconnected) 18 Clock frequency 19 High level pulse width twh 1 20 Low level pulse width twl 1 21 Rise time twr 1 22 Fall time twf 1 External clock input 2 XI (XO is unconnected)*2 23 Clock frequency 24 High level pulse width twh 2...
1-5-3 DC Characteristics Parameter Symbol Supply current (no load at output) 1 Supply current 2 during operation Supply current during HALT mode Supply current during STOP mode Notes: Measured under conditions of Ta=25°C and no load. The supply current during operation, I following conditions: After all I/O pins are set to input mode and the oscillation is set to <NORMAL mode>, the MMOD pin is fixed at V fixed at V...
Page 32
Chapter 1 Overview Electrical Characteristics Parameter Symbol Input pin 1 MMOD 8 Input high voltage 1 9 Input high voltage 2 10 Input low voltage 1 11 Input low voltage 2 12 Input leakage current Input pin 2 P20, P22~P23 (Schmitt trigger input) 13 Input high voltage 14 Input low voltage 15 Input leakage current...
Page 33
SENS pin Rise time Fall time Input voltage level 1 (Input) Input voltage level 2 (Output) Figure 1-5-5 Operation of AC Zero-Cross Detection Circuit Parameter Symbol Input pin 4 PA0~PA7 29 Input high voltage 1 30 Input high voltage 2 31 Input low voltage 1 32 Input low voltage 2 33 Input leakage current...
Page 34
Chapter 1 Overview Parameter Symbol I/O pin 5 P27 (RST) 36 Input high voltage 37 Input low voltage 38 Input leakage current 39 Input high current I/O pin 6 P00 to P06, P10 to P14 (Schmitt trigger input) 40 Input high voltage 41 Input low voltage 42 Input leakage current 43 Input high current...
Parameter Symbol I/O pin 9 P80~P87 63 Input high voltage 1 IH13 64 Input high voltage 2 IH14 65 Input low voltage 1 IL113 66 Input low voltage 2 IL14 67 Input leakage current LK13 68 Input high current IH13 69 Output high voltage OH13 70 Output low voltage...
Chapter 1 Overview − Option 1-6 Option 1-6-1 ROM Option The product equipped with this LSI or an EPROM with this LSI controls the oscillation mode after resetting as well as the runaway-detection watchdog timer, using bits 2 to 0 of the last address of the built-in ROM. Option bits −...
1-6-2 Option Form Model MN101C Name 1. Oscillation mode Type B Type A Note: Type A: Operation begins from the reset cycle in the NORMAL mode. Type B: Operation begins from the reset cycle in the SLOW mode. 2. Watchdog timer period setting Selection Detection Period fs/2...
Chapter 1 Overview External Dimensions 1-7 Outline Drawings Body Material: Epoxy Resin Lead Material:Fe Ni Figure 1-7-1 42-SDIP The external dimensions of the package are subject to change. Before using this product, please obtain product specifications from the sales office. Package code: SDIP042-P-0600 Unit: mm Lead Finish Method:Soldering dip...
Page 39
Body Material: Epoxy Resin Figure 1-7-2 44-QFP The external dimensions of the package are subject to change. Before using this product, please obtain product specifications from the sales office. Package code: QFP044-P-1010 Lead Material:Fe Ni Lead Finish Method:Soldering dip External Dimensions) Chapter 1 Overview Unit: mm...
Page 40
Chapter 1 Overview Package code: QFH048-P-0707 Unit: mm Material: Epoxy Resin Lead Material:Fe Ni-42 Alloy Lead Finish Method:Soldering dip Figure 1-7-3 48-QFH The external dimensions of the package are subject to change. Before using this product, please obtain product specifications from the sales office.
Chapter 2 Basic CPU Functions Overview/Address Space 2-1 Overview Basic CPU functions are in conformance with the MN101C00 series manual (architecture manual). This chapter describes specifications unique to the MN101C117/115. 2-2 Address Space 2-2-1 Memory Configuration X'00000' 256 bytes 512 bytes...
2-2-2 Special Function Registers Memory control register(MEMCTR) is a 4-bit register which set up the base Table 2-2-1 Register Map 03F0X CPUM MEMCTR WDCTR DLYCTR 03F1X P0OUT P1OUT P2OUT P0IN P1IN P2IN 03F2X 03F3X P0DIR P1DIR 03F4X P0PLU P1PLU P2PLU SC0MD0 SC0MD1 SC0MD2 SC0MD3 SC0CTR SC0TRB SC0RXB...
Chapter 2 Basic CPU Functions IOW1 IOW0 MEMCTR Bus Interface 2-3 Bus Interface 2-3-1 Overview The MN101C117, unlike other MN101C series microcomputers, does not support memory expansion mode and processor mode. 2-3-2 Control Registers The memory control register is a four-bit register that sets up wait-count at a time of access to a base address of interrupt vector table and a special register zone.
2-4 Interrupts 2-4-1 Accepting and Returning from Interrupts In the MN101C00 series, when an interrupt is accepted, the hardware pushes the program's return address and the PSW, on to the stack, and branches to the beginning address of the interrupt program specified by the interrupt vector table.
Page 46
Chapter 2 Basic CPU Functions Interrupts Operation when Returning from Interrupt After the program POPs the register and other values saved by the interrupt service routine, an RTI instruction is implemented to return to the program that was being executed when the interrupt was received. The processing sequence for the return from interrupt instruction, RTI, is listed below.
2-4-2 Interrupt Sources and Vector Addresses In addition to reset, there are 20 interrupt vectors that indicate the starting addresses of interrupt programs. These vectors are located in the 80-byte ROM address area X'04004' to X'04053'. Table 2-4-1 Interrupt Control Registers Interrupt Source Vector Number Reset...
Chapter 2 Basic CPU Functions Be sure to use the MIE flag of the PSW register to write to all interrupt control registers. NMICR By setting xxxLVn to '11' (level IRQnICR 3), the corresponding interrupt vector will disabled, regardless of the state of the interrupt enable and interrupt request flags.
Page 49
Internal Interrupt Control Registers (TMnICR, TBICR, SCOICR, ATCICR, ADICR) The internal interrupt control registers (TMnICR, TBICR, SCnICR, ATCICR, ADICR) control the interrupt levels of internal interrupts, timer interrupts, serial interrupts, A/D conversion complete interrupts, and interrupt request/enable. Be sure to disable all interrupts before writing to these registors. TMnICR, TBICR, SCnICR, xxxLV1 xxxLV0 –...
Chapter 2 Basic CPU Functions For the reset to be stable, the low pulse must be maintained for at least four clock cycles. However, it is important to minimize noise, since a reset may occur in a smaller number of clock cycles. Reset 2-5 Reset The CPU contents are reset and registers are initialized when the RST pin is...
Chapter 3 Port Functions Overview 3-1 Overview A total of 39 pins on the MN101C117, including those shared with special function pins, are allocated for the 7 ports of P0 to P2, P6 to P8, and PA. Each I/O port is assigned according to the special function register area in memory.
Page 53
Port 1 (P1) 5-bit CMOS tri-state I/O port. Table 3-1-3 Port 1 Functions Pin Name Type Dual Function P10 to P14 I/O RMOUT, TM2IO to TM4IO Port 2 (P2) 4-bit CMOS tri-state input port. Table 3-1-4 Port 2 Functions Pin Name Type Dual Function P20 to P23...
Page 54
Chapter 3 Port Functions Overview Port 7 (P7) 8-bit CMOS tri-state I/O port. Table 3-1-6 Port 7 Functions Pin Name Type Dual Function P70 to P71 I/O Port 8 (P8) 8-bit CMOS tri-state I/O port. Table 3-1-7 Port 8 Functions Pin Name Type Dual Function...
3-2-2 I/O Port Control Registers This section describes the special function registers that control the MN101C117's I/O ports. Data Registers • PnOUT registers Data registers to output to the ports. Data written to these registers is output from the ports. Low (Vss level) is output.
Page 60
Chapter 3 Port Functions Setting the PAIMD register prevents unnecessary current from flowing in a pin when an intermediate voltage (analog voltage) is applied to the pin. FLOAT1 Port Control Registers Port Output/Input Mode Registers • PnOMD/PnIMD registers These register settings determine whether the port pins(P10 to P14, PA0 to PA5) are used as I/O ports or as special function pins (dual function).
3-3 I/O Port Configuration and Functions P00,P02,P10 to P14 Pull-up resistor control I/O direction control Port output data Port input data Special function input data Special function output control Special function output data Pull-up Control bit resistor Register control (address) Control bit direction Register...
Page 62
Chapter 3 Port Functions Pull-up resistor control I/O direction control Port output data Port input data Special function input data I/O Port Configuration and Functions Reset Write Read Reset Write Read Reset Write Read Read Control bit Pull-up resistor Register control (address) Control bit...
Page 63
PA0 to PA7 Pull-up/pull-down resistor control Pull-up/pull-down resistor selection Port input data Input mode control Analog input Control bit Pull-up PAPLUD0 PAPLUD1 PAPLUD2 PAPLUD3 PAPLUD4 PAPLUD5 PAPLUD6 PAPLUD7 resistor Register control (address) Pull-up/ Control bit pull-down Register resistor (address) control Control bit PAAIN0 PAAIN1 PAAIN2 PAAIN3 Input mode...
Page 64
Chapter 3 Port Functions Pull-up resistor control Port input data Special function input data * P23 is only for 48-pin package. I/O Port Configuration and Functions Pin Configuration for P20, P22 to P23 Reset Write Read Read Control bit P2PLU0 P2PLU2 Pull-up resistor Register...
Page 65
Pull-up resistor control Read Special function input data Read Port input data Special function input data Control bit Pull-up resistor Register control (address) Control bit Port input Register (address) Special function Special function Control bit input Register selection (address) Figure 3-3-5 Configuration and Functions of P21 Reset Read Reset...
Page 66
Chapter 3 Port Functions Port output data I/O Port Configuration and Functions Schmitt trigger input Reset signal input Reset Write Special input Soft reset output Special function Special Control bit function output Register (address) Figure 3-3-6 Configuration and Functions of P27 P2OUT7 P2OUT (x'03F12')
Page 67
P70 to P71 Pull-up/pull-down resistor control Write Pull-up/pull-down resistor selection Write I/O direction control Write Port output data Write Port input data Pull-up/ Control bit pull-down Register resistor control (address) Control bit Pull-up/ pull-down Register resistor control (address) Control bit I/O direction Register control...
Page 68
Chapter 3 Port Functions Pull-up resistor control I/O direction control Port output data Port input data Port output Port output I/O Port Configuration and Functions P60 to P67,P80 to P87 Reset Write Read Reset Write Read Reset Write Read Read P6PLU0 P6PLU1 P6PLU2 P6PLU3 P6PLU4 Pull-up Control bit...
Chapter 4 Timer Functions Overview 4-1 Overview The MN101C117 contains three 8-bit timers, one 16-bit timer, a watchdog timer, a time base timer, and circuits for remote control output and buzzer output. Table 4-1-1 Summary of Timer Functions Timer 2 (8-bit) Interrupt TM2IRQ...
4-2-2 Operation Timer Operation (timers 2, 3) Settings for timer operation are listed below. Timer 2 is used as an example. Set the TM2EN flag of the timer 2 mode register (TM2MD) to "0" to stop the count operation of timer 2. Set the TM2CK2 0 flags of the TM2MD register to select fs, fs/4, fx, or synchronized fx as the clock source.
Page 78
Chapter 4 Timer Functions If TM2IO input is selected as the clock source and the value of binary counter 2 is to be read during operation, select synchronized TM2IO input to avoid reading data that may be incomplete during count-up transitions.
Page 79
Timer Pulse Output Function (timers 2, 3) Settings for the timer pulse output function are listed below. Timer 2 is used as an example. Set the TM2EN flag of the timer 2 mode register (TM2MD) to "0" to stop the count operation of timer 2.
Page 80
Chapter 4 Timer Functions If the TM3PWM flag of the TM3MD register is set to "1" and timer 2 PWM output is selected, the PWM output of timer 2 will also be output from the TM3IO pin. If port 1 is to be used as a PWM output pin, the P1DIR and P1PLU registers must be set.
Page 82
Chapter 4 Timer Functions The clock source for the serial interface has a frequency that is 1/2 of the overflow output of timer For serial interface settings, refer to the chapter on serial functions. Disable the timer 2 interrupt. 8-bit Timer Operation (timers 2, 3) Serial Transfer Clock Function(timer 3) Settings for the serial transfer clock function are listed below.
4-3 16-bit Timer Operation (timer 4) 4-3-1 Overview Timer 4 is a 16-bit programmable counter that can be used as an event counter. A signal with a frequency of 1/2 of the timer 4 overflow signal can be output from the TM4IO pin.
Page 84
Chapter 4 Timer Functions Clock TM4EN Binary counter 4 16-bit Timer Operation (timer 4) Figure 4-3-1 Binary Counter 4 (TM4BC) Count Timing If the TM4EN flag of the TM4MD register is changed simultaneously with other bits, the switching operation may cause binary counter 4 to be incremented.
Page 85
Event Count Function Settings for the event count function are listed below. Set the TM4EN flag of the timer 4 mode register (TM4MD) to "0" to stop the count operation of timer 4. Use the TM4CK2 to 0 flags of the TM4MD register to select TM4IO input or synchronized TM4IO input as the clock source.
Page 86
Chapter 4 Timer Functions The period of the output signal from the port is 1/2 of the period set in the TM4OCH, TM4OCL register. Binary counter 4 TM4OUT 16-bit Timer Operation (timer 4) Timer Pulse Output Function Settings for the timer pulse output function are listed below. Set the TM4EN flag of the timer 4 mode register (TM4MD) to "0"...
Page 87
Pulse Added Type PWM Output Function In the pulse added method, a 1-bit output is appended to the basic component of the 8-bit PWM output. Precise control is possible based on the number of PWM repetitions (256 times) to which this bit is appended. Settings for the pulse added type PWM output function are listed below.
Page 88
Chapter 4 Timer Functions 5-2-3 "Serial Interface Transfer Timing"] TM4OCH Register setting value X '00' X '01' X '02' X '04' X '08' X '10' Position of added pulse X'87' 16-bit Timer Operation (timer 4) Setting the Added Pulse Position The upper 8 bits of compare register 4 (TM4OCH) set the position of the added pulse.
Page 89
Capture Function Settings for the capture function are listed below. Set the TM4EN flag of the timer 4 mode register (TM4MD) to "0" to stop the count operation of timer 4. Use the TM4CK2 to 0 flags of the TM4MD register to select fosc, fs/4, or fs/16 as the clock source.
Chapter 4 Timer Functions When servicing an interrupt, reset the timer 5 interrupt request flag before starting timer 5. When choosing either time base timer output or time base timer synchronized output for the timer 5 clock source, the time base must be set up.
4-5 Time Base Operation 4-5-1 Overview The clock source for the time base timer can be set to fosc or fx. Also, the interrupt period for time base timer (TBIRQ) can be set to 1/2 clock source. 4-5-2 Operation Time Base Function Settings for the time base function are listed below.
Chapter 4 Timer Functions The upper 2 bits of the watchdog timer are cleared when the WDEN flag is set to "0." Therefore, if WDEN flag is set to 0 when an uppermost bit of a watchdog timer is 1, WDT interrupt occurs depending on the timing of this clear the watchdog timer may be reset at 1/4T...
4-7 Remote Control Output Operation 4-7-1 Overview A remote control carrier pulse can be generated using the overflow of timer 3. Two duty ratios of 1/2 or 1/3 can be selected. 4-7-2 Setup and Operation Set the RMOEN flag of the remote control carrier output control register (RMCTR)to "0"...
Chapter 4 Timer Functions Buzzer Output 4-8 Buzzer Output 4-8-1 Buzzer Output Setup and Operation The square wave having a frequency 1/2 output from the P06/BUZZER pin. Set the BUZOE flag of the oscillation stabilization wait control register (DLYCTR) to "0" so that the buzzer output is turned off. Set the buzzer output frequency with the BUZCK1 and BUZCK0 flags of the DLYCTR.
Chapter 4 Timer Functions Timer Function Control Registers 4-9-2 Programmable Timer/Counters Timers 2~5 all contain a programmable 8-bit timer/counter (16-bit in timer 4). Programmable timer/counters consist of a compare register and a binary counter. (1) Compare register 2 (TM2OC) TM2OC7 TM2OC6 TM2OC5 TM2OC4...
4-9-4 Timer Control Registers (1) Watchdog timer control register (WDCTR) – – – WDCTR Figure 4-9-17 Watchdog Timer Control Register (WDCTR: X'03F02', R/W) (2) Oscillation stabilization wait control register (DLYCTR) BUZCK1 BUZCK0 DLYCTR BUZOE Figure 4-9-18 Oscillation Stabilization Wait Counter Control Register (DLYCTR: X'03F03', R/W) –...
Page 104
Chapter 4 Timer Functions – RMCTR Timer Function Control Registers (3) Remote control carrier output control register (RMCTR) – – – – RMOEN RMDTY0 Figure 4-9-19 Remote Control Carrier Control Register (RMCTR: X'03F89', R/W) (at reset: ---00XX0) – Must be set to "0." Remote control carrier RMDTY0 output duty selection...
Chapter 5 Serial Functions Overview 5-1 Overview The MN101C117 contains a serial interface that can operate in synchronous and simple UART modes. An overview of serial functions is shown below. Table 5-1-1 Overview of Serial Functions Interrupt Synchronous Simple UART Clock selection 1/8 period of clock Serial 0...
Page 107
Chapter 5 Serial Functions Figure 5-1-1 Serial 0 Block Diagram Overview...
Chapter 5 Serial Functions Section 5-2-3, "Serial Interface Transfer Timing"] Synchronous Serial Interface 5-2 Synchronous Serial Interface 5-2-1 Overview A serial interface begins operation when data is written to the shift buffer. A bit counter is incremented at each 1-bit transfer. The transfer is complete when the counter overflows.
Page 109
When the clock source is an external clock (SBT0 pin input): • Set the SC0SBTM flag of the SC0MD3 register. • Set bit 2 of the P0DIR register to input mode. • Set the P0PLU register, if necessary. Select the SC0SBOM flag of the SC0MD3 register. Select the SC0IOM flag of the SC0MD3 register.
Page 110
Chapter 5 Serial Functions Synchronous Serial Interface Clock Start condition enabled Start condition disabled Interrupt SC0BSY SC0LNG2 to 0 Figure 5-2-1 Synchronous Serial Interface Transmission Timing (falling edge) Clock Start condition enabled Start condition disabled Interrupt SC0BSY SC0LNG2 to 0 Figure 5-2-2 Synchronous Serial Interface Transmission Timing (rising edge)
Page 111
Reception Select the synchronous serial interface by setting the SC0CMD flag of the serial interface 0 control register (SC0CTR) to "0." Select the transfer bit count with the SC0LNG2 to 0 flags of the serial interface 0 mode register 0 (SC0MD0). The transfer bit count can be set as 1 to 8 bits.
Page 112
Chapter 5 Serial Functions Synchronous Serial Interface Clock Start condition enabled Start condition disabled Interrupt SC0BSY start condition enabled SC0BSY start condition disabled SC0LNG2 to 0 Figure 5-2-3 Synchronous Serial Interface Reception Timing (reception at rising edge) Clock Start condition enabled Start condition disabled...
5-2-3 Serial Interface Transfer Timing Serial interface 0 uses the SC0CE0 and SC0CE1 flags of serial interface 0 mode register 0 (SC0MD0), to control the edge at which transmission data is output and the edge at which reception data is input. During transmission, when the SCnCE1 flag is "0,"...
Page 114
Chapter 5 Serial Functions Synchronous Serial Interface When serial interface 0 is used for simultaneous transmission and reception, set the SCnCE0 and SCnCE1 flags of the SCnMD0 register to "00" or "01", so that the reception data input edge is opposite in polarity to the transmit data output edge. Also, the polarity of the reception data input edge is opposite polarity of the transmit data output edge of the other device.
5-3 Half-duplex UART Serial Interface 5-3-1 Overview Setup and operation of UART transmission and reception are described below. 5-3-2 Setup and Operation Transmission Select UART by setting the SC0CMD flag of the serial interface 0 control register (SC0CTR) to "1." Specify the first bit to be transferred (MSB first or LSB first) with the SC0DIR flag of the serial interface 0 mode register 0 (SC0MD0).
Page 116
Chapter 5 Serial Functions Serial interface 0 begins operation when the SC0SBOS flag or the SC0SBIS flag is set to "1." Set the SC0SBOS flag or the SC0SBIS flag after all conditions have been set. Parity enabled Parity disabled Interrupt Parity enabled Interrupt Parity disabled...
Page 117
Reception Select UART by setting the SC0CMD flag of the serial interface 0 control register (SC0CTR) to "1." Specify the first bit to be transferred (MSB first or LSB first) with the SC0DIR flag of the serial interface 0 mode register 0 (SC0MD0). Select the valid edge of the clock signal with the SC0CE1 to 0 flags of the SC0MD0 register.
5-3-3 How to Use the Baud Rate Timer Refer to the following when using the baud rate timer to set the UART transfer speed. (1) Specifying the timer clock source The clock source is specified by the TM3CKS3 to 1 flags of the timer 3 mode register (TM3MD).
Chapter 5 Serial Functions Serial Interface Control Registers 5-4 Serial Interface Control Registers 5-4-1 Overview 7 registers control the serial interface. See table 5-4-1. Table 5-4-1 Serial Interface Registers Name Address SC0MD0 X'03F50' SC0MD1 X'03F51' SC0MD2 X'03F52' SC0MD3 X'03F53' SC0CTR X'03F54' SC0TRB X'03F55'...
5-4-2 Transmit/Receive Shift Registers, Receive Data Buffer (1) Serial interface 0 transmit/receive shift register (SC0TRB) This 8-bit, writable register shifts the transmission data and the reception data. The direction of transfer can be specified as LSB first or MSB first. SC0TRB SC0TRB7 SC0TRB6...
Chapter 5 Serial Functions SC0CTR SC0BSY SC0CMD – Serial Interface Control Registers 5-4-4 Serial Interface Control Register (1) Serial interface 0 control register (SC0CTR) – SC0FEF SC0PEK SC0ORE – Figure 5-4-7 Serial Interface 0 Control Register (SC0CTR: X'03F54', R) (R/W available with SC0CMD only) (at reset: 00XX000X) SC0ORE Overrun error detection...
Chapter 6 A/D Conversion Functions ANCTR0 ANCHS0 ANCHS1 ANCHS2 ANLADE ANCK0 ANCK1 ANSH0 ANSH1 Overview 6-1 Overview The MN101C117 has an internal A/D converter with 10-bit resolution. A sample-and-hold circuit is contained on-chip and software can switch the analog input between channels 0 to 7 (AN0 to AN7). When the A/D converter is stopped, power consumption can be reduced by turning off the internal ladder resistors.
6-2 A/D Conversion The procedures for operating the A/D conversion circuit are listed below. (1) Set the ANCHS2 to ANCHS0 flags of A/D control register 0 (ANCTR0) to specify one of pins AN7 to AN0 (PA7 to PA0) as the analog input. (2) Set the ANCK1 and ANCK0 flags of A/D control register 0 to select the A/D conversion clock.
Page 130
Chapter 6 A/D Conversion Functions A/D Converter Control Registers The following items must be implemented to maintain the accuracy of the A/D converter: 1. Use a maximum input pin impedance, R, of 500kΩ capacitor, C, that is minimum 1,000pF and maximum 1µF 2.
Chapter 6 A/D Conversion Functions ANSH1 ANSH0 ANCK1 ANCTR0 A/D Converter Control Registers 6-3-2 A/D Control Register (ANCTR) This readable and writable 8-bit register controls the operation of the A/D converter. ANCK0 ANLADE ANCHS2 ANCHS1 ANCHS0 (1) A/D control register 0 (ANCTR0) 1:Specify that where the period of the A/D conversion clock is greater than 800ns.
Page 133
(2) A/D conversion control register 1 (ANCTR1) ANCTR1 ANST Figure 6-3-2 A/D Control Register 1 (ANCTR1: X'03F91', R/W) Chapter 6 A/D Conversion Functions (at reset: 0-------) A/D conversion status ANST A/D conversion completed or stopped A/D conversion started or in progress A/D Converter Control Registers...
Chapter 7 AC Zero-Cross Circuit/Noise Filter P21/IRQ1/SENS Overview 7-1 Overview The P21/SENS pin is the input pin for the AC zero-cross detection circuit. The AC zero-cross detection circuit outputs a high level when the input is at an intermediate level, and a low level at all other times. FLOAT1 P7RDWN PARDWN...
7-2 AC Zero-Cross Circuit Operation 7-2-1 Setup and Operation Settings for zero-cross circuit operation are listed below. (1) Set the REDG1 flag of the IRQ1ICR register to select the valid edge for IRQ1. (2) Set the NF1EN and NF1CK1 to 0 flags of the NFCTR register to set the noise filter and its sampling clock.
Chapter 7 AC Zero-Cross Circuit/Noise Filter IRQ0: External interrupt 0 IRQ1: External interrupt 1 P21/IRQ1/SENS Noise Filter 7-3 Noise Filter 7-3-1 Overview External interrupt pins IRQ0 and IRQ1 contain noise filtering circuit. This circuitry can be used for remote control signal reception. fs/2 fs/2 fs/2...
7-3-2 Example Input and Output Waveforms for Noise Filter When the noise filter is used, the waveform input to the IRQ0 pin is sampled based on the clock specified by the NF0CKS0 and NF0CKS1 flags of the noise filter control register (NFCTR).
Chapter 7 AC Zero-Cross Circuit/Noise Filter 2-4-3 "Interrupt Control Registers External Interrupt Control Registers"] 3-2-2 "I/O Port Control Registers Pin Control Registers"] AC Zero-Cross Control Register 7-4 AC Zero-Cross Control Register 7-4-1 Overview Four registers control the AC zero-cross circuit. Table 7-4-1 AC Zero-Cross Control Register Name Address...
256Kbit EPROM(Vpp=12.5V, tpw=0.2ms). Therefore, by replacing theEPROM Version's 42-pin socket with a special 28-pin socket adapter(supplied by Panasonic) having the same configuration as a normal EPROM, a general-purpose EPROM writer can be used to perform read and write operations.
8-1-2 Cautions on Use EPROM Versions differs from the MN101C11* in some of its electrical characteristics. The user should be aware of these differences. (1) To prevent data from being erased by ultraviolet light after a program is written, affix seals impermeable to UV rays to the glass sections at the top and side sections of the CPU.
Chapter 8 Appendices EPROM Versions 8-1-3 Erasing Written Data in Windowed Packages (PX-AP101C11-SDC, PX-AP101C11-FBC) In an internal EPROM with windowed packaging, data is erased("0" when UV light at 253.7nm permeates the window to irradiate the chip. The recommended exposure is 10W · s/cm by using a commercial UV lamp positioned 2 to 3cm above the package for 15-20 minutes(when the illumination intensity of the package surface is12000...
8-1-4 Characteristics of EPROM Version The MN101C11*(mask ROM version) and the Microcomputer with internal EPROM version have the following differences. Table 8-1-1 Difference between MN101C*(Mask ROM version) and Internal EPROM version) Operating temperature 4.5 to 5.5V(0.1μs/20MHz) 2.7 to 5.5v(0.25μs/8MHz) Operating voltage 2.0 to 5.5v(1.00μs/2MHz)...
Chapter 8 Appendices Package type 42-SDIP 44-QFP 48-QFH No.1 Pin No.1 Pin (PX-AP101C11-SDC) (top view) EPROM Versions 8-1-5 Writing to Microcomputer with Internal EPROM Fit in the writing adapter and position the No.1 pin. No.1 pin must be matched to this position.
Page 149
ROM writer Selection The device names should be set up as listed below. Table 8-1-2 Device selection Equip. name Vendor Pecker 30 Avarl Data 1890A Minato Electronics Lab Site Data I/O The above settings are based on the standard samples. When you use the other equipment than the ones listed, contact the nearest semiconductor design center.(Refer to the sales office table attached at the end of the manual.)
Chapter 8 Appendices EPROM Versions 8-1-6 Cautions on Operating the ROM Writer Cautions on operating the ROM writer (1)The Vpp programming voltage for the EPROM versions is 12.5V. Programming with a 21-volt ROM writer can lead to damage. The ROM writer specifications must match those for standard 1-megabit EPROMS:Vpp=12.5V V;tpw=0.2ms.
8-1-7 Option Bit The MN101C117 and the MN101CP117 control the oscillation mode after resetting as well as the runaway-detection watch dog timer, using bit 2 to 0 of the last address (X'7FFF) of the built-in ROM. Option bit PKGSEL2 PKGSEL1 Fig.
8-2 Instruction Set MN101C00 SERIES INSTRUCTION SET Group Mnemonic Operation Data move instructions MOV Dn,Dm Dn Dm MOV imm8,Dm imm8 Dm MOV Dn,PSW Dn PSW MOV PSW,Dm PSW Dm MOV (An),Dm mem8(An) Dm MOV (d8,An),Dm mem8(d8+An) Dm MOV (d16,An),Dm mem8(d16+An) Dm...
Page 156
Chapter 10 Appendices MN101C00 SERIES INSTRUCTION SET Group Mnemonic Operation MOVW imm16,Am imm16 Am MOVW SP,Am SP Am MOVW An,SP An SP MOVW DWn,DWm DWn DWm MOVW DWn,Am DWn Am MOVW An,DWm An DWm MOVW An,Am An Am PUSH PUSH Dn...
Page 157
MN101C00 SERIES INSTRUCTION SET Group Mnemonic Operation NOT Dn Dn Dn ASR Dn Dn.msb temp,Dn.lsb CF Dn>>1 Dn,temp Dn.msb LSR Dn Dn.lsb CF,Dn>>1 Dn 0 Dn.msb ROR Dn Dn.Isb temp,Dn>>1 Dn CF Dn.msb,temp CF Bit manipulation instructions mem8(IOTOP+io8)&bpdata...PSW 0 ● 0 ● 5 BSET...
Page 158
Chapter 10 Appendices MN101C00 SERIES INSTRUCTION SET Group Mnemonic Operation BGT label if((VF^NF)|ZF=0),PC+6+d11(label)+H PC – if((VF^NF)|ZF=1),PC+6 PC BHI label if(CFIZF=0),PC+5+d7(label)+H PC – if(CFIZF=1), PC+5 PC BHI label if(CFIZF=0),PC+6+d11(label)+H PC – if(CFIZF=1), PC+6 PC BLS label if(CFIZF=1),PC+5+d7(label)+H PC – if(CFIZF=0), PC+5 PC BLS label if(CFIZF=1),PC+6+d11(label)+H PC –...
Page 159
MN101C00 SERIES INSTRUCTION SET Group Mnemonic Operation TBZ (io8)bp,label if(mem8(IOTOP+io8)bp=0),PC+7+d7(label)+H PC 0 if(mem8(IOTOP+io8)bp=1),PC+7 PC TBZ (io8)bp,label if(mem8(IOTOP+io8)bp=0),PC+8+d11(label)+H PC 0 if(mem8(IOTOP+io8)bp=1),PC+8 PC TBZ (abs16)bp,label if(mem8(abs16)bp=0),PC+9+d7(label)+H PC 0 if(mem8(abs16)bp=1),PC+9 PC TBZ (abs16)bp,label if(mem8(abs16)bp=0),PC+10+d11(label)+H PC 0 if(mem8(abs16)bp=1),PC+10 PC TBNZ TBNZ (abs8)bp,label if(mem8(abs8)bp=1),PC+7+d7(label)+H PC 0...
Page 160
Chapter 10 Appendices MN101C00 SERIES INSTRUCTION SET Group Mnemonic Operation mem8(SP)→(PC).bp7∼0 mem8(SP+1)→(PC).bp15∼8 mem8(SP+2).bp7→(PC).H mem8(SP+2).bp1∼0→(PC).bp17∼16 SP+3→SP mem8(SP)→PSW mem8(SP+1)→(PC).bp7∼0 mem8(SP+2)→(PC).bp15∼8 mem8(SP+3).bp7→(PC).H mem8(SP+3).bp1∼0→(PC).bp17∼16 mem8(SP+4)→HA-l mem8(SP+5)→HA-h SP+6→SP Control instruction REP imm3 imm3→RPC Note: "Page" refers to the corresponding page in the Instruction Manual. Instruction Set...
Port 8 output P0IN6 P1IN4 P1IN3 Chapter 10 Appendices Reference Bit 2 Bit 1 Bit 0 page HALT OSC1 OSC0 MN101C00 series゙ HALT LSI Manual Oscillation control transfer request IRWE WDEN Watchdog timer table DLYS1 DLYS0 Sets oscillation stabilization wait period...
Page 164
Chapter 10 Appendices Register Address Bit 7 X’ 3F24’ Disables to use Disables to use X’ 3F25’ P6IN7 X’ 3F26’ P6IN P7IN X’ 3F27’ P8IN7 P8IN X’ 3F28’ PAIN7 PAIN X’ 3F2A’ P0DIR X’ 3F30’ X’ 3F31’ P1DIR X’ 3F33’ Disables to use Disables to use X’...
Page 165
Register Address Bit 7 P2PLU X’ 3F42’ Disables to use X’ 3F43’ Disables to use X’ 3F44’ Disables to use X’ 3F45’ P6PLU7 P6PLU X’ 3F46’ X’ 3F47’ P7PLUD P8PLU7 P8PLU X’ 3F48’ PAPLUD7 PAPLUD X’ 3F4A’ FLOAT1 X’ 3F4B’ Disables to use X’...
Page 166
Chapter 10 Appendices Address Register X’ 3F59’ Disables to use X’ 3F5A’ Disables to use X’ 3F5B’ Disables to use X’ 3F5C’ Disables to use X’ 3F5D’ Disables to use X’ 3F60’ Disables to use Disables to use X’ 3F61’ X’...
Page 167
Register Address Bit 7 X’ 3FE0’ Disables to use NMICR X’ 3FE1’ IRQ0LV1 IRQ0LV0 X’ 3FE2’ IRQ0ICR Interrup level flag for external interrupt IRQ1LV1 IRQ1LV0 IRQ1ICR X’ 3FE3’ Interrupt level flag for external interrupt Disables to use X’ 3FE4’ Disables to use X’...
Page 168
Chapter 10 Appendices Register Address Bit 7 X’ 3FE0’ Disables to use NMICR X’ 3FE1’ IRQ0LV1 IRQ0LV0 X’ 3FE2’ IRQ0ICR Interrup level flag for external interrupt IRQ1LV1 IRQ1LV0 IRQ1ICR X’ 3FE3’ Interrupt level flag for external interrupt Disables to use X’...