Strong electric field, when exposed to a MOS device, can cause destruction of the gate oxide and
ultimately degrade the device operation. Steps must be taken to stop generation of static electricity
as much as possible, and quickly dissipate it once, when it has occurred. Environmental control
must be adequate. When it is dry, humidifier should be used. It is recommended to avoid using
insulators that easily build static electricity. Semiconductor devices must be stored and transported
in an anti-static container, static shielding bag or conductive material. All test and measurement
tools including work bench and floor should be grounded. The operator should be grounded using
wrist strap. Semiconductor devices must not be touched with bare hands. Similar precautions need
to be taken for PW boards with semiconductor devices on it.
2HANDLING OF UNUSED INPUT PINS FOR CMOS
Note:
No connection for CMOS device inputs can be cause of malfunction. If no connection is provided
to the input pins, it is possible that an internal input level may be generated due to noise, etc., hence
causing malfunction. CMOS devices behave differently than Bipolar or NMOS devices. Input levels
of CMOS devices must be fixed high or low by using a pull-up or pull-down circuitry. Each unused
pin should be connected to V
DD
or GND with a resistor, if it is considered to have a possibility of
being an output pin. All handling related to the unused pins must be judged device by device and
related specifications governing the devices.
3STATUS BEFORE INITIALIZATION OF MOS DEVICES
Note:
Power-on does not necessarily define initial status of MOS device. Production process of MOS
does not define the initial operation status of the device. Immediately after the power source is
turned ON, the devices with reset function have not yet been initialized. Hence, power-on does
not guarantee out-pin levels, I/O settings or contents of registers. Device is not initialized until the
reset signal is received. Reset operation must be executed immediately after power-on for devices
having reset function.
Caution: Purchase of NEC I2C components conveys a license under the Philips I2C Patent Rights to use these
components in an I
defined by Philips.
IEBus is a trademark of NEC Corporation.
2
C system, provided that the system conforms to the I2C Standard Specification as
User's Manual U12326EJ4V0UM
3
The export of these products from Japan is regulated by the Japanese government. The export of some or all of these
products may be prohibited without governmental license. To export or re-export some or all of these products from a
country other than Japan may also be prohibited without a license from that country. Please call an NEC sales
representative.
•
The information in this document is current as of August, 2001. The information is subject to
change without notice. For actual design-in, refer to the latest publications of NEC's data sheets or
data books, etc., for the most up-to-date specifications of NEC semiconductor products. Not all
products and/or types are available in every country. Please check with an NEC sales representative
for availability and additional information.
•
No part of this document may be copied or reproduced in any form or by any means without prior
written consent of NEC. NEC assumes no responsibility for any errors that may appear in this document.
•
NEC does not assume any liability for infringement of patents, copyrights or other intellectual property rights of
third parties by or arising from the use of NEC semiconductor products listed in this document or any other
liability arising from the use of such products. No license, express, implied or otherwise, is granted under any
patents, copyrights or other intellectual property rights of NEC or others.
•
Descriptions of circuits, software and other related information in this document are provided for illustrative
purposes in semiconductor product operation and application examples. The incorporation of these
circuits, software and information in the design of customer's equipment shall be done under the full
responsibility of customer. NEC assumes no responsibility for any losses incurred by customers or third
parties arising from the use of these circuits, software and information.
•
While NEC endeavours to enhance the quality, reliability and safety of NEC semiconductor products, customers
agree and acknowledge that the possibility of defects thereof cannot be eliminated entirely. To minimize
risks of damage to property or injury (including death) to persons arising from defects in NEC
semiconductor products, customers must incorporate sufficient safety measures in their design, such as
redundancy, fire-containment, and anti-failure features.
•
NEC semiconductor products are classified into the following three quality grades:
"Standard", "Special" and "Specific". The "Specific" quality grade applies only to semiconductor products
developed based on a customer-designated "quality assurance program" for a specific application. The
recommended applications of a semiconductor product depend on its quality grade, as indicated below.
Customers must check the quality grade of each semiconductor product before using it in a particular
application.
"Standard": Computers, office equipment, communications equipment, test and measurement equipment, audio
and visual equipment, home electronic appliances, machine tools, personal electronic equipment
and industrial robots
systems, anti-crime systems, safety equipment and medical equipment (not specifically designed
for life support)
"Specific": Aircraft, aerospace equipment, submersible repeaters, nuclear reactor control systems, life
support systems and medical equipment for life support, etc.
The quality grade of NEC semiconductor products is "Standard" unless otherwise expressly specified in NEC's
data sheets or data books, etc. If customers wish to use NEC semiconductor products in applications not
intended by NEC, they must contact an NEC sales representative in advance to determine NEC's willingness
to support a given application.
(Note)
(1) "NEC" as used in this statement means NEC Corporation and also includes its majority-owned subsidiaries.
(2) "NEC semiconductor products" means any semiconductor product developed or manufactured by or for
NEC (as defined above).
M8E 00. 4
4
User's Manual U12326EJ4V0UM
Regional Information
Some information contained in this document may vary from country to country. Before using any NEC
product in your application, pIease contact the NEC office in your country to obtain a list of authorized
representatives and distributors. They will verify:
•
Device availability
•
Ordering information
•
Product release schedule
•
Availability of related technical literature
•
Development environment specifications (for example, specifications for third-party tools and
components, host computers, power plugs, AC supply voltages, and so forth)
•
Network requirements
In addition, trademarks, registered trademarks, export restrictions, and other legal issues may also vary
from country to country.
NEC Electronics Inc. (U.S.)
Santa Clara, California
Tel: 408-588-6000
800-366-9782
Fax: 408-588-6130
800-729-9288
Unlike a general-purpose register, each special-function register has a special function.
Special function registers are allocated in the 256-byte area FF00H to FFFFH.
Special function registers can be manipulated, like general-purpose registers, by operation, transfer and bit
manipulation instructions. The manipulatable bit units (1, 8, and 16) differ depending on the special function
register type.
Each manipulation bit unit can be specified as follows.
• 1-bit manipulation
Describes a symbol reserved by the assembler for the 1-bit manipulation instruction operand (sfr.bit). This
manipulation can also be specified by an address.
• 8-bit manipulation
Describes a symbol reserved by the assembler for the 8-bit manipulation instruction operand (sfr). This
manipulation can also be specified by an address.
• 16-bit manipulation
Describes a symbol reserved by the assembler for the 16-bit manipulation instruction operand (sfrp). When
addressing an address, describe an even address.
For details of the special function registers, refer to the user’s manual of each product.
Caution Do not access addresses to which SFRs are not allocated. If an address is erroneously
accessed, the CPU may become deadlocked.
User's Manual U12326EJ4V0UM
19
CHAPTER 3 ADDRESSING
3.1 Instruction Address Addressing
An instruction address is determined by program counter (PC) contents. The PC contents are normally
incremented (+1 for each byte) automatically according to the number of bytes of an instruction to be fetched each
time another instruction is executed. When a branch instruction is executed, the branch destination information
is set to the PC and branched by the following addressing (for details of each instruction, refer to CHAPTER 5
EXPLANATION OF INSTRUCTIONS).
3.1.1 Relative addressing
[Function]
The value obtained by adding 8-bit immediate data (displacement value: jdisp8) of an instruction code to
the start address of the following instruction is transferred to the program counter (PC) and branched. The
displacement value is treated as signed two’s complement data (–128 to +127) and bit 7 becomes a sign
bit. In other words, in relative addressing, the value is relatively transferred to the range between –128 and
+127 from the start address of the following instruction.
This function is carried out when the “BR $addr16” instruction or a conditional branch instruction is executed.
[Illustration]
PC
150
PC
+
150
α
150
When S = 0, α indicates all bits "0".
When S = 1, α indicates all bits "1".
87 6
S
jdisp8
...
PC is the start address of
the next instruction of
a BR instruction.
20
User's Manual U12326EJ4V0UM
CHAPTER 3 ADDRESSING
3.1.2 Immediate addressing
[Function]
Immediate data in the instruction word is transferred to the program counter (PC) and branched.
This function is carried out when the “CALL !addr16” or “BR !addr16” or “CALLF !addr11” instruction is
executed. The CALL !addr16 and BR !addr16 instructions can be branched to all memory spaces. The
CALLF !addr11 instruction is branched to the area of 0800H to 0FFFH.
[Illustration]
CALL !addr16, BR !addr16 instruction
70
CALL or BR
Low Addr.
High Addr.
PC
CALLF !addr11 instruction
PC
150
70
643
fa
10
to fa
8
CALLF
7
to fa
0
fa
150
11 10
87
87
00001
User's Manual U12326EJ4V0UM
21
CHAPTER 3 ADDRESSING
3.1.3 Table indirect addressing
[Function]
Table contents (branch destination address) of the particular location to be addressed by the lower-5-bit
immediate data of an instruction code from bit 1 to bit 5 are transferred to the program counter (PC) and
branched.
When the “CALLT [addr5]” instruction is executed, table indirect addressing is performed. Executing this
instruction enables the value to be branched to all memory spaces referencing the address stored in the
memory table of 40H to 7FH.
[Illustration]
76510
Instruction code
ta
4–0
111
Effective address
Effective address+1
151
00000000
01
70
Memory (Table)
Low addr.
High addr.
150
PC
87
650
87
0
22
User's Manual U12326EJ4V0UM
CHAPTER 3 ADDRESSING
3.1.4 Register addressing
[Function]
The register pair (AX) contents to be specified by an instruction word are transferred to the program counter
(PC) and branched.
This function is carried out when the “BR AX” instruction is executed.
[Illustration]
70
rp
150
PC
AX
07
87
User's Manual U12326EJ4V0UM
23
CHAPTER 3 ADDRESSING
3.2 Operand Address Addressing
The following methods are available to specify the register and memory (addressing) to undergo manipulation
during instruction execution.
3.2.1 Implied addressing
[Function]
This addressing automatically specifies the address of the registers that function as an accumulator (A and
AX) in the general-purpose register area.
Of the 78K/0 Series instruction words, the following instructions employ implied addressing.
InstructionRegister to Be Specified by Implied Addressing
MULUA register for multiplicand and AX register for product storage
DIVUWAX register for dividend and quotient storage
ADJBA/ADJBSA register for storage of numeric values targeted for decimal correction
ROR4/ROL4A register for storage of digit data that undergoes digit rotation
[Operand format]
Because implied addressing can be automatically employed with an instruction, no particular operand format
is necessary.
[Description example]
In the case of MULU X
With an 8-bit x 8-bit multiply instruction, the product of the A register and X register is stored in AX. In this
example, the A and AX registers are specified by implied addressing.
24
User's Manual U12326EJ4V0UM
CHAPTER 3 ADDRESSING
3.2.2 Register addressing
[Function]
Register addressing accesses a general-purpose register as an operand. The general-purpose register to
be accessed is specified by the register bank selection flags (RBS0 and RBS1) and the register specification
codes (Rn and RPn) in the instruction codes.
Register addressing is carried out when an instruction with the following operand format is executed. When
an 8-bit register is specified, one of the eight registers is specified by 3 bits in the instruction code.
[Operand format]
IdentifierDescription
rX, A, C, B, E, D, L, H
rpAX, BC, DE, HL
‘r’ and ‘rp’ can be described with absolute names (R0 to R7 and RP0 to RP3) as well as function names
(X, A, C, B, E, D, L, H, AX, BC, DE and HL).
[Description example]
MOV A, C; When selecting the C register for r
Instruction code01100010
INCW DE; When selecting the DE register pair for rp
Instruction code10000100
Register specification code
Register specification code
User's Manual U12326EJ4V0UM
25
CHAPTER 3 ADDRESSING
3.2.3 Direct addressing
[Function]
Direct addressing directly addresses the memory indicated by the immediate data in the instruction word.
[Operand format]
IdentifierDescription
addr16Label or 16-bit immediate data
[Description example]
MOV A, !FE00H; When setting !addr16 to FE00H
Instruction code1 0001110OP code
0000000000H
11111110FEH
[Illustration]
07
OP code
addr16 (lower)
addr16 (upper)
Memory
26
User's Manual U12326EJ4V0UM
CHAPTER 3 ADDRESSING
3.2.4 Short direct addressing
[Function]
The memory to be manipulated in the fixed space is directly addressed with 8-bit data in an instruction word.
This addressing is applied to the 256-byte fixed space FE20H to FF1FH. An internal high-speed RAM and
special function registers (SFRs) are mapped at FE20H to FEFFH and FF00H to FF1FH, respectively.
The SFR area (FF00H to FF1FH) where short direct addressing is applied is a part of the entire SFR area.
Ports that are frequently accessed in a program, a compare register of the timer/event counter and a capture
register of the timer/event counter are mapped in the area FF00H through FF1FH, and these SFRs can be
manipulated with a small number of bytes and clocks.
When 8-bit immediate data is at 20H to FFH, bit 8 of an effective address is set to 0. When it is at 00H to
1FH, bit 8 is set to 1. See [Illustration] below.
[Operand format]
IdentifierDescription
saddrLabel or FE20H to FF1FH immediate data
saddrpLabel or FE20H to FF1FH immediate data (even address only)
[Description example]
MOV FE30H, #50H; When setting saddr to FE30H and the immediate data to 50H
Instruction code00010001OP code
0011000030H (saddr-offset)
0101000050H (immediate data)
[Illustration]
07
OP code
saddr-offset
Short direct memory
Effective
address
15
1
111111
When 8-bit immediate data is 20H to FFH, α = 0.
When 8-bit immediate data is 00H to 1FH, α = 1.
87
α
0
User's Manual U12326EJ4V0UM
27
CHAPTER 3 ADDRESSING
3.2.5 Special-function register (SFR) addressing
[Function]
A memory-mapped special function register (SFR) is addressed with 8-bit immediate data in an instruction
word.
This addressing is applied to the 240-byte spaces FF00H to FFCFH and FFE0H to FFFFH. However, the
SFRs mapped at FF00H to FF1FH can be accessed with short direct addressing.
[Operand format]
IdentifierDescription
sfrSpecial function register name
sfrp16-bit-manipulatable special function register name (even address only)
[Description example]
MOV PM0, A; When selecting PM0 for sfr
Instruction code11110110OP code
[Illustration]
15
Effective
address
OP code
sfr-offset
1
111111
0010000020H (sfr-offset)
07
87
1
0
SFR
28
User's Manual U12326EJ4V0UM
CHAPTER 3 ADDRESSING
3.2.6 Register indirect addressing
[Function]
Register indirect addressing addresses memory with register pair contents specified as an operand. The
register pair to be accessed is specified by the register bank selection flags (RBS0 and RBS1) and the
register pair specification in instruction codes.
[Operand format]
IdentifierDescription
—
[DE], [HL]
[Description example]
MOV A, [DE]; When selecting register pair [DE]
Instruction code10000101
[Illustration]
1508D7
DE
Contents of memory to be
addressed are transferred
7 0
A
E
Memory
07
Memory address specified
by register pair DE
User's Manual U12326EJ4V0UM
29
CHAPTER 3 ADDRESSING
3.2.7 Based addressing
[Function]
8-bit immediate data is added to the contents of the HL register pair as a base register and the sum is used
to address the memory. The HL register pair to be accessed is in the register bank specified by the register
bank select flag (RBS0 and RBS1). Addition is performed by expanding the offset data as a positive number
to 16 bits. A carry from the 16th bit is ignored. This addressing can be carried out for all the memory spaces.
[Operand format]
IdentifierDescription
—
[HL+byte]
[Description example]
MOV A, [HL+10H]; When setting byte to 10H
Instruction code10101110
00010000
3.2.8 Based indexed addressing
[Function]
The B or C register contents specified in an instruction word are added to the contents of the HL register
pair as a base register and the sum is used to address the memory. The HL, B, and C registers to be accessed
are registers in the register bank specified by the register bank select flag (RBS0 to RBS1). Addition is
performed by expanding the B or C register as a positive number to 16 bits. A carry from the 16th bit is
ignored. This addressing can be carried out for all the memory spaces.
[Operand format]
IdentifierDescription
—
[HL+B], [HL+C]
[Description example]
In the case of MOV A, [HL+B]
Instruction code10101011
30
User's Manual U12326EJ4V0UM
Loading...
+ 99 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.