PIC17C42 Microchip Technology, PIC17C42 Datasheet - Page 108

no-image

PIC17C42

Manufacturer Part Number
PIC17C42
Description
High-Performance 8-Bit CMOS EPROM/ROM Microcontroller
Manufacturer
Microchip Technology
Datasheets

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
PIC17C42-16/JW
Manufacturer:
AD
Quantity:
12
Part Number:
PIC17C42A-16/L
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-16/PQ
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-16/PQ
Manufacturer:
MICROCH
Quantity:
20 000
Part Number:
PIC17C42A-16/PT
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-16E/L
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-16E/PQ
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC17C42A-25/P
Manufacturer:
MICROCLOCK
Quantity:
20 000
PIC17C4X
Table 15-2 lists the instructions recognized by the
MPASM assembler.
All instruction examples use the following format to rep-
resent a hexadecimal number:
where h signifies a hexadecimal digit.
To represent a binary number:
where b signifies a binary string.
FIGURE 15-1: GENERAL FORMAT FOR
DS30412C-page 108
Byte-oriented file register operations
Byte to Byte move operations
Bit-oriented file register operations
Literal and control operations
Call and GOTO operations
Note 1: Any unused opcode is Reserved. Use of
Note 2: The shaded instructions are not available
15
15
15
15
15
OPCODE
OPCODE
0xhh
0000 0100b
d = 0 for destination WREG
d = 1 for destination f
f = 8-bit file register address
p = peripheral register file address
f = 8-bit file register address
b = 3-bit address
f = 8-bit file register address
k = 8-bit immediate value
k = 13-bit immediate value
OPCODE
OPCODE
OPCODE
any reserved opcode may cause unex-
pected operation.
in the PIC17C42
13 12
13 12
INSTRUCTIONS
p (FILE #)
11 10
9
8
b (BIT #)
d
8
8 7
7
7
8 7
k (literal)
f (FILE #)
f (FILE #)
k (literal)
f (FILE #)
0
0
0
0
0
15.1
The PIC17C4X’s orthogonal instruction set allows read
and write of all file registers, including special function
registers. There are some special situations the user
should be aware of:
15.1.1
If an instruction writes to ALUSTA, the Z, C, DC and OV
bits may be set or cleared as a result of the instruction
and overwrite the original data bits written. For exam-
ple, executing CLRF
ALUSTA, and then set the Z bit leaving 0000 0100b in
the register.
15.1.2
Read, write or read-modify-write on PCL may have the
following results:
Read PC:
Write PCL:
Read-Modify-Write:
Where PCH = program counter high byte (not an
addressable register), PCLATH = Program counter
high holding latch, dest = destination, WREG or f.
15.1.3
All bit manipulation instructions are done by first read-
ing the entire register, operating on the selected bit and
writing the result back (read-modify-write). The user
should keep this in mind when operating on special
function registers, such as ports.
Special Function Registers as
Source/Destination
ALUSTA AS DESTINATION
PCL AS SOURCE OR DESTINATION
BIT MANIPULATION
PCH
PCLATH
8-bit destination value
PCLATH
8-bit result
PCL
ALUSTA will clear register
1996 Microchip Technology Inc.
ALU operand
PCLATH; PCL
PCH;
PCH;
PCL
PCL
dest

Related parts for PIC17C42