PIC24FJ32GB002-E/ML MICROCHIP [Microchip Technology], PIC24FJ32GB002-E/ML Datasheet - Page 134

no-image

PIC24FJ32GB002-E/ML

Manufacturer Part Number
PIC24FJ32GB002-E/ML
Description
28/44-Pin, 16-Bit, Flash Microcontrollers with USB On-The-Go (OTG) and nanoWatt XLP Technology
Manufacturer
MICROCHIP [Microchip Technology]
Datasheet
PIC24FJ64GB004 FAMILY
EXAMPLE 10-2:
EXAMPLE 10-3:
DS39940D-page 134
;unlock
push
push
push
mov
mov
mov
mov.b
mov.b
bclr
; Configure Input Functions (Table10-2)
; Assign U1CTS To Pin RP1, U1RX To Pin RP0
mov
mov
; Configure Output Functions (Table 10-3)
; Assign U1RTS To Pin RP3, U1TX To Pin RP2
mov
mov
;lock
mov
mov
mov
mov.b
mov.b
bset
pop
pop
pop
//unlock registers
__builtin_write_OSCCONL(OSCCON & 0xBF);
// Configure Input Functions (Table 9-1)
// Assign U1RX To Pin RP0
RPINR18bits.U1RXR = 0;
// Assign U1CTS To Pin RP1
RPINR18bits.U1CTSR = 1;
// Configure Output Functions (Table 9-2)
// Assign U1TX To Pin RP2
RPOR1bits.RP2R = 3;
// Assign U1RTS To Pin RP3
RPOR1bits.RP3R = 4;
//lock registers
__builtin_write_OSCCONL(OSCCON | 0x40);
w1;
w2;
w3;
w2, [w1];
w3, [w1];
OSCCON, #6;
#0x0100, w1;
w1,RPINR18;
#0x0403, w1;
w1, RPOR1;
registers
#OSCCON, w1;
#0x46, w2;
#0x57, w3;
w2, [w1];
w3, [w1];
OSCCON, #6;
w3;
w2;
w1;
#OSCCON, w1;
#0x46, w2;
#0x57, w3;
registers
CONFIGURING UART1 INPUT AND OUTPUT FUNCTIONS IN ASSEMBLY CODE
CONFIGURING UART1 INPUT AND OUTPUT FUNCTIONS IN ‘C’
 2010 Microchip Technology Inc.

Related parts for PIC24FJ32GB002-E/ML