PIC18F4520-I/PT Microchip Technology, PIC18F4520-I/PT Datasheet - Page 57

IC MCU FLASH 16KX16 44TQFP

PIC18F4520-I/PT

Manufacturer Part Number
PIC18F4520-I/PT
Description
IC MCU FLASH 16KX16 44TQFP
Manufacturer
Microchip Technology
Series
PIC® 18Fr

Specifications of PIC18F4520-I/PT

Program Memory Type
FLASH
Program Memory Size
32KB (16K x 16)
Package / Case
44-TQFP, 44-VQFP
Core Processor
PIC
Core Size
8-Bit
Speed
40MHz
Connectivity
I²C, SPI, UART/USART
Peripherals
Brown-out Detect/Reset, HLVD, POR, PWM, WDT
Number Of I /o
36
Eeprom Size
256 x 8
Ram Size
1.5K x 8
Voltage - Supply (vcc/vdd)
4.2 V ~ 5.5 V
Data Converters
A/D 13x10b
Oscillator Type
Internal
Operating Temperature
-40°C ~ 85°C
Processor Series
PIC18F
Core
PIC
Data Bus Width
8 bit
Data Ram Size
1.5 KB
Interface Type
MSSP/SPI/I2C/PSP/USART
Maximum Clock Frequency
40 MHz
Number Of Programmable I/os
36
Number Of Timers
4
Operating Supply Voltage
2 V to 5.5 V
Maximum Operating Temperature
+ 85 C
Mounting Style
SMD/SMT
3rd Party Development Tools
52715-96, 52716-328, 52717-734, 52712-325, 53275-917, EWPIC18
Development Tools By Supplier
PG164130, DV164035, DV244005, DV164005, PG164120, ICE2000, ICE4000, DV164136, DM163022
Minimum Operating Temperature
- 40 C
On-chip Adc
13-ch x 10-bit
Package
44TQFP
Device Core
PIC
Family Name
PIC18
Maximum Speed
40 MHz
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
For Use With
XLT44PT3 - SOCKET TRAN ICE 44MQFP/TQFPAC164305 - MODULE SKT FOR PM3 44TQFP444-1001 - DEMO BOARD FOR PICMICRO MCUAC164020 - MODULE SKT PROMATEII 44TQFP
Lead Free Status / Rohs Status
Lead free / RoHS Compliant

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
PIC18F4520-I/PT
Manufacturer:
TI
Quantity:
14 300
Part Number:
PIC18F4520-I/PT
Manufacturer:
Microchip Technology
Quantity:
33 055
Part Number:
PIC18F4520-I/PT
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
PIC18F4520-I/PT
Manufacturer:
MICROCHIP
Quantity:
510
Part Number:
PIC18F4520-I/PT
Manufacturer:
MICROCHIP/微芯
Quantity:
20 000
Part Number:
PIC18F4520-I/PT
0
5.1.2.2
The STKPTR register (Register 5-1) contains the stack
pointer value, the STKFUL (stack full) status bit and the
STKUNF (stack underflow) status bits. The value of the
stack pointer can be 0 through 31. The stack pointer
increments before values are pushed onto the stack
and decrements after values are popped off the stack.
On Reset, the stack pointer value will be zero. The user
may read and write the stack pointer value. This feature
can be used by a Real-Time Operating System (RTOS)
for return stack maintenance.
After the PC is pushed onto the stack 31 times (without
popping any values off the stack), the STKFUL bit is
set. The STKFUL bit is cleared by software or by a
POR.
The action that takes place when the stack becomes
full depends on the state of the STVREN (Stack Over-
flow Reset Enable) configuration bit. (Refer to
Section 23.1 “Configuration Bits” for a description of
the device configuration bits.) If STVREN is set
(default), the 31st push will push the (PC + 2) value
onto the stack, set the STKFUL bit and reset the
device. The STKFUL bit will remain set and the stack
pointer will be set to zero.
If STVREN is cleared, the STKFUL bit will be set on the
31st push and the stack pointer will increment to 31.
Any additional pushes will not overwrite the 31st push
and STKPTR will remain at 31.
REGISTER 5-1:
 2004 Microchip Technology Inc.
bit 7
bit 6
bit 5
bit 4-0
Return Stack Pointer (STKPTR)
STKPTR REGISTER
bit 7
STKFUL: Stack Full Flag bit
1 = Stack became full or overflowed
0 = Stack has not become full or overflowed
STKUNF: Stack Underflow Flag bit
1 = Stack underflow occurred
0 = Stack underflow did not occur
Unimplemented: Read as ‘0’
SP4:SP0: Stack Pointer Location bits
Legend:
R = Readable bit
-n = Value at POR
STKFUL
Note 1: Bit 7 and bit 6 are cleared by user software or by a POR.
R/C-0
(1)
STKUNF
R/C-0
PIC18F2420/2520/4420/4520
(1)
W = Writable bit
‘1’ = Bit is set
Preliminary
(1)
U-0
(1)
R/W-0
When the stack has been popped enough times to
unload the stack, the next pop will return a value of zero
to the PC and sets the STKUNF bit, while the stack
pointer remains at zero. The STKUNF bit will remain
set until cleared by software or until a POR occurs.
5.1.2.3
Since the Top-of-Stack is readable and writable, the
ability to push values onto the stack and pull values off
the stack without disturbing normal program execution
is a desirable feature. The PIC18 instruction set
includes two instructions, PUSH and POP, that permit
the TOS to be manipulated under software control.
TOSU, TOSH and TOSL can be modified to place data
or a return address on the stack.
The PUSH instruction places the current PC value onto
the stack. This increments the stack pointer and loads
the current PC value onto the stack.
The POP instruction discards the current TOS by decre-
menting the stack pointer. The previous value pushed
onto the stack then becomes the TOS value.
SP4
Note:
U = Unimplemented
‘0’ = Bit is cleared
R/W-0
Returning a value of zero to the PC on an
underflow has the effect of vectoring the
program to the Reset vector, where the
stack conditions can be verified and
appropriate actions can be taken. This is
not the same as a Reset, as the contents
of the SFRs are not affected.
SP3
PUSH and POP Instructions
R/W-0
SP2
C = Clearable only bit
x = Bit is unknown
R/W-0
SP1
DS39631A-page 55
R/W-0
SP0
bit 0

Related parts for PIC18F4520-I/PT