cop884bc National Semiconductor Corporation, cop884bc Datasheet

no-image

cop884bc

Manufacturer Part Number
cop884bc
Description
8-bit Cmos Rom Based Microcontrollers With 2k Memory, Comparators, And Can Interface
Manufacturer
National Semiconductor Corporation
Datasheet
© 2001 National Semiconductor Corporation
COP884BC
8-Bit CMOS ROM Based Microcontrollers with 2k
Memory, Comparators, and CAN Interface
General Description
The following part number is a pin count and tempera-
ture variation of the COP884BC: COP885BC.
The COP884BC ROM based microcontrollers are highly
integrated COP8
and advanced features including a CAN 2.0B (passive) in-
terface and two Analog comparators. These single-chip
CMOS devices are suited for applications requiring a full
featured controller with a CAN interface, low EMI, and an
8-bit 39 kHz PWM timer. COP87L84BC devices are pin and
software compatible 16k OTP (One Time Programmable)
versions for pre-production, and for use with a range of
COP8 software and hardware development tools.
Key Features
n CAN 2.0B (passive) Interface
n Power On Reset (selectable)
n One 16-bit timer, with two 16-bit registers supporting:
n High speed, constant resolution 8-bit PWM/frequency
n 2048 bytes on-board ROM
n 64 bytes on-board RAM
Additional Peripheral Features
n Idle Timer
n Multi-Input Wake Up (MIWU) with optional interrupts (7)
n Two analog comparators
n MICROWIRE/PLUS serial I/O
I/O Features
n Memory mapped I/O
n Software selectable I/O options (TRI-STATE
n Schmitt trigger inputs on ports G and L
n Packages: 28 SO with 18 I/O pins and 20 SO with 10
COP8
TRI-STATE
iceMASTER
— Processor Independent PWM mode
— External Event counter mode
— Input Capture mode
monitor timer with 2 output pins
Push-Pull Output, Weak Pull-Up Input, High Impedance
Input)
I/O pins
COP684BC
COP884BC
COP685BC
COP885BC
, and MICROWIRE/PLUS
Device
®
®
is a registered trademark of National Semiconductor Corporation.
is a registered trademark of MetaLink Corporation.
Feature core devices with 2k memory
Memory (bytes)
are trademarks of National Semiconductor Corporation.
2k ROM
2k ROM
2k ROM
2k ROM
DS012067
®
RAM (bytes)
Output,
64
64
64
64
Features include an 8-bit memory mapped architecture, 10
MHz CKI (crystal osc) with 1µs instruction cycle, one multi-
function 16-bit timer/counter, 8-bit 39 kHz PWM timer with 2
outputs, CAN 2.0B (passive) interface, MICROWIRE/
PLUS
ing HALT/IDLE modes, idle timer, MIWU, software selectable
I/O options, Power on Reset, low EMI 4.5V to 5.5V opera-
tion, and 20/28 pin packages.
Note: A companion device with CAN interface, more I/O and
memory, A/D, and USART is the COP888EB.
Devices included in this datasheet are:
CPU/Instruction Set Features
n 1 µs instruction cycle time
n Eleven multi-source vectored interrupts servicing
n Versatile and easy to use instruction set
n 8-bit Stack Pointer (SP) — stack in RAM
n Two 8-bit Register Indirect Data Memory Pointers
Fully Static CMOS
n Two power saving modes: HALT and IDLE
n Low current drain (typically
n Single supply operation: 4.5V–5.5V
n Temperature ranges: −40˚C to +85˚C, −55˚C to +125˚C
Development Support
n Emulation and OTP devices
n Real time emulation and full program debug offered by
(B and X)
MetaLink Development Systems
— External Interrupt
— Idle Timer T0
— Timer T1 (with 2 Interrupts)
— MICROWIRE/PLUS
— Multi-Input Wake Up
— Software Trap
— PWM Timer
— CAN Interface (with 3 interrupts)
I/O Pins
serial I/O, two Analog comparators, two power sav-
18
18
10
10
Packages
28 SOIC
28 SOIC
20 SOIC
20 SOIC
<
1 µA)
-55 to +125˚C
-40 to +85˚C
-55 to +125˚C
-40 to +85˚C
Temperature
September 1999
www.national.com

Related parts for cop884bc

cop884bc Summary of contents

Page 1

... Memory, Comparators, and CAN Interface General Description The following part number is a pin count and tempera- ture variation of the COP884BC: COP885BC. The COP884BC ROM based microcontrollers are highly integrated COP8 ™ Feature core devices with 2k memory and advanced features including a CAN 2.0B (passive) in- terface and two Analog comparators ...

Page 2

Block Diagram www.national.com FIGURE 1. Block Diagram 2 DS012067-1 ...

Page 3

... Connection Diagrams Top View Order Number COP884BC-xxx/WM or COP684BC-xxx/WM See NS Package Number M28B Top View Order Number COP885BC-xxx/WM or COP685BC-xxx/WM See NS Package Number M20B FIGURE 2. Connection Diagrams Pinouts for 28-SO Package Port Type Pin G0 I/O G1 I/O G2 I/O G3 I/O G4 I I/O L1 I/O L2 I/O L3 I/O L4 I/O L5 I/O DS012067-2 L6 I/O D0 ...

Page 4

... Absolute Maximum Ratings If Military/Aerospace specified devices are required, please contact the National Semiconductor Sales Office/ Distributors for availability and specifications. Supply Voltage ( Voltage at Any Pin DC Electrical Characteristics COP884BC: −40˚C T +85˚C A Parameter Operating Voltage Power Supply Ripple (Note 3) Supply Current ...

Page 5

... DC Electrical Characteristics COP884BC: −40˚C T +85˚C A Parameter Maximum Input Current without Latchup (Notes 8, 10) RAM Retention Voltage, V (Note 9) r Input Capacitance Load Capacitance on D2 Note 3: Maximum rate of voltage change must be less than 0.5 V/ms Note 4: Supply current is measured after running 2000 cycles with a square wave CKI input, CKO open, inputs at V Note 5: The HALT mode will stop CKI from oscillating in the Crystal configurations. Halt test conditions: All inputs tied to V outputs and programmed low ...

Page 6

Absolute Maximum Ratings If Military/Aerospace specified devices are required, please contact the National Semiconductor Sales Office/ Distributors for availability and specifications. Supply Voltage ( Voltage at Any Pin DC Electrical Characteristics COP684BC: −55˚C T +125˚C A Parameter Operating ...

Page 7

... These two pins will not latch up. The voltage at the pins must be limited to less than 14V. Note 9: Condition and parameter valid only for part in HALT mode. Note 10: Parameter characterized but not tested. AC Electrical Characteristics COP684BC and COP884BC: −55˚C T +125˚C ...

Page 8

On-Chip Voltage Reference: −55˚C T +125˚C A Parameter Reference Voltage V REF Reference Supply Current Note 15: Reference supply I is supplied for information purposes only not tested. DD Comparator DC/AC Characteristics: 4.5V V 5.5V, −55˚C ...

Page 9

Typical Performance Characteristics Port D Source Current Ports G/L Source Current Ports G/L Weak Pull-Up Source Current −55˚C T +125˚C A Port D Sink Current DS012067-39 Port G/L Sink Current DS012067-41 Dynamic DS012067-43 9 DS012067-40 DS012067-42 ...

Page 10

Typical Performance Characteristics Idle CAN Tx0 Sink Current Pin Descriptions V and GND are the power supply pins. CC CKI is the clock input. The clock can come from a crystal oscillator (in conjunction with ...

Page 11

Pin Descriptions (Continued) registers associated with the G Port, a data register and a configuration register. Therefore, each of the 6 I/O bits (G0–G5) can be individually configured under software con- trol. Since input only pin and ...

Page 12

Functional Description The device has 64 bytes of RAM. Sixteen bytes of RAM are mapped as “registers” at addresses 0F0 to 0FF Hex. These registers can be loaded immediately, and also decremented and tested with the DRSZ (decrement register and ...

Page 13

Oscillator Circuits (Continued) TABLE 1. Crystal Oscillator Configuration CKI Freq (pF) (pF) (MHz 30– 30– 200 100–150 0.455 Control Registers CNTRL Register (Address ...

Page 14

Timers (Continued) The timer block has three operating modes: Processor Inde- pendent PWM mode, External Event Counter mode, and Input Capture mode. The control bits T1C3, T1C2, and T1C1 allow selection of the different modes of operation. Mode 1. Processor ...

Page 15

Timers (Continued) FIGURE 10. Timer 1 in External Event Counter Mode FIGURE 11. Timer 1 in Input Capture Mode 15 DS012067-10 DS012067-11 www.national.com ...

Page 16

Timers (Continued) TIMER CONTROL FLAGS The control bits and their functions are summarized below. T1C3 Timer mode control T1C2 Timer mode control T1C1 Timer mode control T1C0 Timer Start/Stop control in Modes 1 and 2 (Pro- cessor Independent PWM and ...

Page 17

Timers (Continued) FIGURE 12. PWM Timer Capture Mode Block Diagram FIGURE 13. PWM Timer PWM Mode Block Diagram PWM Control Register (PWMCON) (Address X’00A2) Reserved ESEL PWPND PWIE PWMD PWON Bit 7 The PWMCON Register Bits are: Reserved This bit ...

Page 18

Timers (Continued) a fixed, non-programmable repetition rate of 255 PWM clock cycles. The timer is clocked by the output of an 8-bit, pro- grammable prescaler, which is clocked with the chip’s CKI frequency. Thus the PWM signal frequency can be ...

Page 19

Timers (Continued) becomes greater than RLON, the PWPND bit in the PWM control register is set to “1”. If the PWIE bit is also set to “1”, the PWPND bit is enabled to request an interrupt. It should be noted ...

Page 20

Power Save Modes (Continued) T0, are stopped. The power supply requirements of the microcontroller in this mode of operation are typically around 30% of normal power requirement of the microcontroller. As with the HALT mode, the device can be returned ...

Page 21

Multi-Input Wake Up (Continued) CAN RECEIVE WAKE UP The CAN Receive Wake Up source is always enabled and is always active on a falling edge of the CAN comparator output. There is no specific enable bit for the CAN Wake ...

Page 22

CAN Interface Block (Continued) Fully automatic transmission on error is supported for mes- sages not longer than two bytes. Messages which are longer than two bytes have to be processed by software. The interface is compatible with CAN Specification 2.0 ...

Page 23

Functional Block Description of the CAN Interface (Continued) Transceive Logic (TCL) The TCL is a state machine which incorporates the bit stuff logic and controls the output drivers, CRC logic and the Rx/Tx shift registers. It also controls the synchronization ...

Page 24

Functional Block Description of the CAN Interface In the case of an interrupt driven CAN interface, the calculation of the actual t INT: ; Interrupt latency = µs PUSH A,AB ; PUSH A ...

Page 25

Functional Block Description of the CAN Interface (Continued) RECEIVE IDENTIFIER HIGH (RID) (Address X’00B7) Reserved RID10 RID9 RID8 RID7 Bit 7 This register is read/write. Reserved Bit 7 is reserved and must be zero. RID10..RID4 Receive Identifier bits (upper bits) ...

Page 26

Functional Block Description of the CAN Interface (Continued) secutive “recessive” bits including the End of Frame, whereas the standard mode may time out after 128 x 11 recessive bits (e.g., bus idle). TRANSMIT CONTROL/STATUS (TCNTL) (00BB) NS1 NS0 TERR RERR ...

Page 27

Functional Block Description of the CAN Interface (Continued) until the transmission is completed, even if the user’s soft- ware has requested cancellation of the message error occurs during transmission, a requested cancellation may occur prior to the begining ...

Page 28

Functional Block Description of the CAN Interface (Continued) For information on bus synchronization and status of the CAN related registers after external reset refer to the RESET section. ON-CHIP VOLTAGE REFERENCE The on-chip voltage reference is a ratiometric reference. For ...

Page 29

Frame Formats (Continued) The control frames are: error/overload frame Note: This device cannot send an overload frame as a result of not being able to process all information. However, the device is able to recog- nize an overload condition and ...

Page 30

Frame Formats (Continued) A remote frame is identical to a data frame, except that the RTR bit is “recessive”, and there is no data field. IDE = Identifier Extension Bit The IDE bit in the standard format is transmitted “dominant”, ...

Page 31

Frame Formats (Continued) START OF FRAME (SOF) The Start of Frame indicates the beginning of data and remote frames. It consists of a single “dominant” bit. A node is only allowed to start transmission when the bus is idle. All ...

Page 32

Frame Formats (Continued) tive node detecting an error, starts transmitting an active error flag consisting of six “dominant” bits. This causes the destruction of the actual frame on the bus. The other nodes detect the error flag as either a ...

Page 33

Frame Formats (Continued) module 1 = error active transmitter detects bit error at t2 module 2 = error active receiver with a local fault at t1 module 3 = error active receiver detects stuff error at t2 FIGURE 27. Error ...

Page 34

Frame Formats (Continued) module 1 = error active receiver with a local fault at t1 module 2 = error passive transmitter detects bit error at t2 module 3 = error passive receiver detects stuff error at t2 FIGURE 28. Error ...

Page 35

Frame Formats (Continued) An error passive unit can participate in bus communication. However, if the unit detects an error it is not allowed to send an active error flag. The unit sends only a passive (“reces- sive”) error flag. A ...

Page 36

Frame Formats (Continued) • If only one device is on the bus and this device transmits a message, it will get no acknowledgment. This will be detected as an error and message will be repeated. When the device goes “error ...

Page 37

Frame Formats (Continued) Comparators The device has two differential comparators. Port L is used for the comparators. The output of the comparators is multi- plexed out to two pins. The following are the Port L assign- ments: L6 Comparator 2 ...

Page 38

Comparators (Continued) CMP1EN Enables comparator 1 (“1”=enable). If compara- tor 1 is disabled the associated L-pins can be used as standard I/O. Reserved This bit is reserved and should be zero. The Comparator Select/Control bits are cleared on RESET (the ...

Page 39

Interrupts (Continued) MASKABLE INTERRUPTS All interrupts other than the Software Trap are maskable. Each maskable interrupt has an associated enable bit and pending flag bit. The pending bit is set to 1 when the interrupt condition occurs. The state of ...

Page 40

Interrupts (Continued) An interrupt service routine typically ends with an RETI instruction. This instruction sets the GIE bit back to 1, pops the address stored on the stack, and restores that address to the program counter. Program execution then proceeds ...

Page 41

Interrupts (Continued) Arbitration Ranking Note 18 VIS page If, by accident, a VIS gets executed and no interrupt is active, ...

Page 42

Interrupts (Continued) www.national.com DS012067-78 FIGURE 36. VIS Operation DS012067-79 FIGURE 37. VIS Flowchart 42 ...

Page 43

Interrupts (Continued) Programming Example: External Interrupt PSW =00EF CNTRL =00EE RBIT 0,PORTGC RBIT 0,PORTGD SBIT IEDG, CNTRL SBIT EXEN, PSW SBIT GIE, PSW WAIT: JP WAIT . . . .=0FF VIS . . . .=01FA .ADDRW SERVICE . . INT_EXIT: ...

Page 44

Interrupts (Continued) NON-MASKABLE INTERRUPT Pending Flag There is a pending flag bit associated with the non-maskable interrupt, called STPND. This pending flag is not memory- mapped and cannot be accessed directly by the software. The pending flag is reset to ...

Page 45

Detection of Illegal Conditions The device can detect various illegal conditions resulting from coding errors, transient noise, power supply voltage drops, runaway programs, etc. Reading of undefined ROM gets zeroes. The opcode for software interrupt is zero. If the program ...

Page 46

MICROWIRE/PLUS (Continued) TABLE 10. MICROWIRE/PLUS Master Mode Clock Selection SL1 SL0 Where t is the instruction cycle clock c MICROWIRE/PLUS Slave Mode Operation In the MICROWIRE/PLUS Slave mode of operation the SK clock is ...

Page 47

Memory Map All RAM, ports and registers (except A and PC) are mapped into data memory address space. Address Contents On-Chip RAM bytes (48 bytes Unused RAM Address Space (Reads As All Ones) 80 ...

Page 48

Addressing Modes (Continued) TRANSFER OF CONTROL ADDRESSING MODES Relative This mode is used for the JP instruction, with the instruction field being added to the program counter to get the new program location. JP has a range from −31 to ...

Page 49

Instruction Set (Continued) INSTRUCTION SET ADD A,Meml ADD ADC A,Meml ADD with Carry SUBC A,Meml Subtract with Carry AND A,Meml Logical AND ANDSZ A,Imm Logical AND Immed., Skip if Zero OR A,Meml Logical OR XOR A,Meml Logical EXclusive OR IFEQ ...

Page 50

Instruction Set (Continued) JSRL Addr. Jump SubRoutine Long JSR Addr. Jump SubRoutine JID Jump InDirect RET RETurn from subroutine RETSK RETurn and SKip RETI RETurn from Interrupt INTR Generate an Interrupt NOP No OPeration www.national.com [SP] PL, [SP−1] PU,SP−2, PC ...

Page 51

Instruction Execution Time Most instructions are single byte (with immediate addressing mode instructions taking two bytes). Most single byte instructions take one cycle time to execute. Skipped instructions require x number of cycles to be skipped, where x equals the ...

Page 52

NIBBLE LOWER 52 ...

Page 53

... Mask Options The COP684BC and COP884BC mask programmable op- tions are shown below. The options are programmed at the same time as the ROM pattern submission. OPTION 1: CLOCK CONFIGURATION =1 Crystal Oscillator (CKI/10) G7 (CKO) is clock generator output to crystal/resonator CKI is the clock input OPTION 2: HALT =1 Enable HALT mode ...

Page 54

... COP8-NSASM, COP8C, and WCOP8 IDE.) • COP8-UTILS: Free set of COP8 assembly code ex- amples, device drivers, and utilities to speed up code development. TOOLS ORDERING NUMBERS FOR THE COP884BC/COP8885BC FAMILY DEVICES Vendor Tools National COP8-NSEVAL COP8-NSEVAL ...

Page 55

Development Tools Support OTP Programmers Contact vendor < Cost: Free $100 $100 - $300 $300 - $1k $1k - $3k $3k - $5k WHERE TO GET TOOLS Tools are ordered ...

Page 56

... Physical Dimensions Order Number COP884BC-xxx/M or COP684BC-xxx/M Order Number COP885BC-xxx/M or COP685BC-xxx/M www.national.com inches (millimeters) unless otherwise noted NS Package Number M28B NS Package Number M20B 56 ...

Page 57

... NATIONAL’S PRODUCTS ARE NOT AUTHORIZED FOR USE AS CRITICAL COMPONENTS IN LIFE SUPPORT DEVICES OR SYSTEMS WITHOUT THE EXPRESS WRITTEN APPROVAL OF THE PRESIDENT AND GENERAL COUNSEL OF NATIONAL SEMICONDUCTOR CORPORATION. As used herein: 1. Life support devices or systems are devices or systems which, (a) are intended for surgical implant ...

Related keywords