参数资料
型号: PIC18LF96J65-I/PT
厂商: Microchip Technology
文件页数: 114/131页
文件大小: 0K
描述: IC PIC MCU FLASH 48KX16 100TQFP
标准包装: 90
系列: PIC® 18F
核心处理器: PIC
芯体尺寸: 8-位
速度: 41.667MHz
连通性: EBI/EMI,以太网,I²C,SPI,UART/USART
外围设备: 欠压检测/复位,POR,PWM,WDT
输入/输出数: 70
程序存储器容量: 96KB(48K x 16)
程序存储器类型: 闪存
RAM 容量: 3808 x 8
电压 - 电源 (Vcc/Vdd): 2 V ~ 3.6 V
数据转换器: A/D 16x10b
振荡器型: 内部
工作温度: -40°C ~ 85°C
封装/外壳: 100-TQFP
包装: 托盘
2011 Microchip Technology Inc.
DS39762F-page 83
PIC18F97J60 FAMILY
6.1.6.4
Stack Full and Underflow Resets
Device Resets on stack overflow and stack underflow
conditions are enabled by setting the STVREN bit in
Configuration Register 1L. When STVREN is set, a full
or underflow condition will set the appropriate STKFUL
or STKUNF bit and then cause a device Reset. When
STVREN is cleared, a full or underflow condition will set
the appropriate STKFUL or STKUNF bit, but not cause
a device Reset. The STKFUL or STKUNF bit is cleared
by user software or a Power-on Reset.
6.1.7
FAST REGISTER STACK
A Fast Register Stack (FSR) is provided for the
STATUS, WREG and BSR registers to provide a “fast
return” option for interrupts. This stack is only one level
deep and is neither readable nor writable. It is loaded
with the current value of the corresponding register
when the processor vectors for an interrupt. All inter-
rupt sources will push values into the Stack registers.
The values in the registers are then loaded back into
the working registers if the RETFIE, FAST instruction
is used to return from the interrupt.
If both low and high-priority interrupts are enabled, the
Stack registers cannot be used reliably to return from
low-priority interrupts. If a high-priority interrupt occurs
while servicing a low-priority interrupt, the Stack
register values stored by the low-priority interrupt will
be overwritten. In these cases, users must save the key
registers in software during a low-priority interrupt.
If interrupt priority is not used, all interrupts may use the
Fast Register Stack for returns from interrupt. If no
interrupts are used, the Fast Register Stack can be
used to restore the STATUS, WREG and BSR registers
at the end of a subroutine call. To use the Fast Register
Stack for a subroutine call, a CALL label, FAST
instruction must be executed to save the STATUS,
WREG and BSR registers to the Fast Register Stack. A
RETURN, FAST
instruction is then executed to restore
these registers from the Fast Register Stack.
Example 6-1 shows a source code example that uses
the Fast Register Stack during a subroutine call and
return.
EXAMPLE 6-1:
FAST REGISTER STACK
CODE EXAMPLE
6.1.8
LOOK-UP TABLES IN PROGRAM
MEMORY
There may be programming situations that require the
creation of data structures, or look-up tables, in
program memory. For PIC18 devices, look-up tables
can be implemented in two ways:
Computed GOTO
Table Reads
6.1.8.1
Computed GOTO
A computed GOTO is accomplished by adding an offset
to the program counter. An example is shown in
A look-up table can be formed with an ADDWF PCL
instruction and a group of RETLW nn instructions. The
W register is loaded with an offset into the table before
executing a call to that table. The first instruction of the
called routine is the ADDWF PCL instruction. The next
instruction executed will be one of the RETLW nn
instructions, that returns the value ‘nn’ to the calling
function.
The offset value (in WREG) specifies the number of
bytes that the program counter should advance and
should be multiples of 2 (LSb = 0).
In this method, only one data byte may be stored in
each instruction location and room on the return
address stack is required.
EXAMPLE 6-2:
COMPUTED GOTO USING
AN OFFSET VALUE
6.1.8.2
Table Reads
A better method of storing data in program memory
allows two bytes of data to be stored in each instruction
location.
Look-up table data may be stored, two bytes per
program word, while programming. The Table Pointer
(TBLPTR) specifies the byte address and the Table
Latch (TABLAT) contains the data that is read from the
program memory. Data is transferred from program
memory, one byte at a time.
Table read operation is discussed further in
CALL
SUB1, FAST
;STATUS, WREG, BSR
;SAVED IN FAST REGISTER
;STACK
SUB1
RETURN FAST ;RESTORE VALUES SAVED
;IN FAST REGISTER STACK
MOVF
OFFSET, W
CALL
TABLE
ORG
nn00h
TABLE
ADDWF
PCL
RETLW
nnh
RETLW
nnh
RETLW
nnh
.
相关PDF资料
PDF描述
PIC24F16KL401-I/P IC MCU 16BIT 16KB FLASH 20-PDIP
PIC24FJ128GA010-I/PF IC PIC MCU FLASH 128KB 100TQFP
PIC24FJ256GA110-I/PF IC PIC MCU FLASH 256K 100TQFP
PIC24FJ256GB110-I/PF IC PIC MCU FLASH 256K 100TQFP
PIC24FJ64GA004-E/ML IC PIC MCU FLASH 64K 44-QFN
相关代理商/技术参数
参数描述
PIC1-R68-JT 制造商:RCD 制造商全称:RCD COMPONENTS INC. 功能描述:SURFACE MOUNT POWER INDUCTORS
PIC1-R68-JTQ 制造商:RCD 制造商全称:RCD COMPONENTS INC. 功能描述:SURFACE MOUNT POWER INDUCTORS
PIC1-R68-JTW 制造商:RCD 制造商全称:RCD COMPONENTS INC. 功能描述:SURFACE MOUNT POWER INDUCTORS
PIC1-R68-KT 制造商:RCD 制造商全称:RCD COMPONENTS INC. 功能描述:SURFACE MOUNT POWER INDUCTORS
PIC1-R68-KTQ 制造商:RCD 制造商全称:RCD COMPONENTS INC. 功能描述:SURFACE MOUNT POWER INDUCTORS