PIC16C782 Microchip Technology Inc., PIC16C782 Datasheet - Page 51
PIC16C782
Manufacturer Part Number
PIC16C782
Description
8-bit Cmos Microcontrollers With A/d, D/a, Opamp, Comparators And Psmc
Manufacturer
Microchip Technology Inc.
Datasheet
1.PIC16C782.pdf
(186 pages)
Available stocks
Company
Part Number
Manufacturer
Quantity
Price
- Current page: 51 of 186
- Download datasheet (4Mb)
4.3
To read a program memory location, the user must
write 2 bytes of the address to the PMADRH and
PMADRL
(PMCON1<0>). Once the read control bit is set, the
Program Memory Read (PMR) controller uses the sec-
ond instruction cycle after to read the data. This causes
the second instruction immediately following the “BSF
PMCON1,RD” instruction to be ignored. The data is
available, in the very next cycle, in the PMDATH and
PMDATL registers. Therefore, it can be read as 2 bytes
EXAMPLE 4-1:
;* This code block will read 1 word of program
;* memory at the memory address:
;* PROG_ADDR_HI : PROG_ADDR_LO
;*
;*
2001 Microchip Technology Inc.
BANKSEL
MOVLW
MOVWF
MOVLW
MOVWF
BANKSEL
CLEAR GIE
BCF
BSF
NOP
BSF
MOVF
MOVWF
MOVF
MOVWF
data will be returned in the variables;
NOP
PROG_DATA_HI, PROG_DATA_LO
Reading the EPROM Program
Memory
registers,
PMADRL
PROG_ADDR_LO
PMADRL
PROG_ADDR_HI
PMADRH
PMCON1
INTCON, GIE
PMCON1,RD
INTCON, GIE
PMDATL,W
PROG_DATA_LO
PMDATH,W
PROG_DATA_HI
OTP PROGRAM MEMORY READ
then
set
; Select Bank 2
;
; Store LSB of address
;
; Store MSB of address
; Select Bank 3
; Turn off INTs
; Initiate read
; Executed (Fig 4-1)
; Ignored (Fig 4-1)
; Turn on INTs
; Get LSB of word
; Get MSB of word
control
bit
Preliminary
RD
in the following instructions. PMDATH and PMDATL
registers hold this value until another read or until
RESET.
Note 1: Interrupts must be disabled during the
2: The following instructions should not be
time from setting PMCON1<0> (RD) to
the second instruction thereafter.
used following the start of a PMR read
cycle: CALL, GOTO, BTFSS, BTFSC,
RETFIE, RETURN, SLEEP.
PIC16C781/782
DS41171A-page 49
Related parts for PIC16C782
Image
Part Number
Description
Manufacturer
Datasheet
Request
R
Part Number:
Description:
Photo IC(photodiode with signal processing)
Manufacturer:
KODENSHI KOREA CORP
Datasheet:
Part Number:
Description:
INFRARED RECEIVER MODULE
Manufacturer:
ETC
Datasheet:
Part Number:
Description:
INFRARED RECEIVER MODULE
Manufacturer:
ETC
Datasheet:
Part Number:
Description:
Photo IC(photodiode with signal processing)
Manufacturer:
KODENSHI KOREA CORP
Datasheet:
Part Number:
Description:
(PIC-1204x) OPTICAL-RECEIVER OUTPUT PHOTO IC
Manufacturer:
Kodenshi
Datasheet:
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet: