Pins available for digital input:
- PORTA: RA0 through RA6 gives 7 inputs
- PORTB: RB0 through RB7 gives 8 inputs
- PORTC: RB0 through RB2 and RB4 through RB7 gives 7 inputs
- PORTE: RE3 gives one input
Configure options:
- FOSC = INTOSCIO_EC //using the internal oscillator will free pins RA5 and RA6
- LVP = OFF //you don't have to ground RB5 anymore
- PBADEN = OFF //disable the analog inputs on RB0 through RB4
- DEBUG = OFF //disable debug output, free RB6 and RB7
- MCLRE = OFF //disable the master clear option, free RE3
Registers to set:
- ADCON1 = 0x0F; //disable analog inputs on RA0 through RA3
- UCON = 0x00; //disable the usb module, free RC4 and RC5
- UCFG = 0x08;
Keine Kommentare:
Kommentar veröffentlichen