PIC24F32KA301-E/SS Microchip Technology, PIC24F32KA301-E/SS Datasheet - Page 63

no-image

PIC24F32KA301-E/SS

Manufacturer Part Number
PIC24F32KA301-E/SS
Description
32KB Flash, 2KB RAM, 512B EEPROM, 16 MIPS, 12-bit ADC, CTMU, XLP 20 SSOP .209in
Manufacturer
Microchip Technology
Series
PIC® XLP™ 24Fr
Datasheet

Specifications of PIC24F32KA301-E/SS

Core Processor
PIC
Core Size
16-Bit
Speed
32MHz
Connectivity
I²C, IrDA, LIN, SPI, UART/USART
Peripherals
Brown-out Detect/Reset, HLVD, POR, PWM, WDT
Number Of I /o
18
Program Memory Size
32KB (11K x 24)
Program Memory Type
FLASH
Eeprom Size
512 x 8
Ram Size
2K x 8
Voltage - Supply (vcc/vdd)
1.8 V ~ 3.6 V
Data Converters
A/D 12x12b
Oscillator Type
Internal
Operating Temperature
-40°C ~ 125°C
Package / Case
20-SSOP (0.209", 5.30mm Width)
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
EXAMPLE 5-2:
EXAMPLE 5-3:
 2011 Microchip Technology Inc.
// C example using MPLAB C30
//Set up pointer to the first memory location to be written
; Set up NVMCON for row programming operations
; Set up a pointer to the first program memory location to be written
; program memory selected, and writes enabled
; Perform the TBLWT instructions to write the latches
; 0th_program_word
; 1st_program_word
;
; 32nd_program_word
2nd_program_word
int __attribute__ ((space(auto_psv))) progAddr = &progAddr;// Global variable located in Pgm Memory
unsigned int offset;
TBLPAG = __builtin_tblpage(&progAddr);
offset = &progAddr & 0xFFFF;
__builtin_tblwtl(offset, 0x0000);
NVMCON = 0x4058;
asm("DISI #5");
__builtin_write_NVM();
MOV
MOV
MOV
MOV
MOV
MOV
MOV
TBLWTL W2, [W0]
TBLWTH W3, [W0++]
MOV
MOV
TBLWTL W2, [W0]
TBLWTH W3, [W0++]
MOV
MOV
TBLWTL W2, [W0]
TBLWTH W3, [W0++]
MOV
MOV
TBLWTL W2, [W0]
TBLWTH W3, [W0]
#0x4004, W0
W0, NVMCON
#0x0000, W0
W0, TBLPAG
#0x6000, W0
#LOW_WORD_0, W2
#HIGH_BYTE_0, W3
#LOW_WORD_1, W2
#HIGH_BYTE_1, W3
#LOW_WORD_2, W2
#HIGH_BYTE_2, W3
#LOW_WORD_31, W2
#HIGH_BYTE_31, W3
ERASING A PROGRAM MEMORY ROW – ‘C’ LANGUAGE CODE
LOADING THE WRITE BUFFERS – ASSEMBLY LANGUAGE CODE
PIC24FV32KA304 FAMILY
;
; Initialize NVMCON
;
; Initialize PM Page Boundary SFR
; An example program memory address
;
;
; Write PM low word into program latch
; Write PM high byte into program latch
;
;
; Write PM low word into program latch
; Write PM high byte into program latch
;
;
; Write PM low word into program latch
; Write PM high byte into program latch
;
;
; Write PM low word into program latch
; Write PM high byte into program latch
// Initialize PM Page Boundary SFR
// Initialize lower word of address
// Set base address of erase block
// with dummy latch write
// Initialize NVMCON
// Block all interrupts for next 5
// instructions
// C30 function to perform unlock
// sequence and set WR
DS39995B-page 63

Related parts for PIC24F32KA301-E/SS