engineerpervez1
Member level 5
- Joined
- Dec 26, 2010
- Messages
- 84
- Helped
- 15
- Reputation
- 30
- Reaction score
- 14
- Trophy points
- 1,288
- Location
- Lahore Pakistan
- Activity points
- 1,844
Interrupt based ADC channels reading of PIC18F4431
I want to read all 5 or 8 channels of PIC18F2431 or PIC18F4431 in assembly language out of 9 channels.
Application note by MICROCHIP "AN900a" is not helping much.
These all channels are belong to PORT A and PORTE
The difficulty is this chip ADC reading is some what different to others normal use pic controllers.
Its data book dosn't help much. It dosn't include practical examples.
What is different it have more ADC control registers comparing to other normal pic controllers
Actually AN0 to AN5 are belongs to PORTA and remaining 3 analog channels are in PORTE from AN6 to AN9, PIC18F4431 has 9 ADC channels altogether.
It include
ADCON0
ADCON1
ADCON2
ADCON3
ADCHS
ANSEL0
ANSEL1
ADRESL
ADRESH
Comparing to other normal chip in this chip ADCON2,ADCON3,ADCHS,ANSEL0 and ANSEL1 are extra added registers moreover there 4 nos of buffer result registers instead of one.
I am able to take result of one any of one channels but not all channels at interrupt base.
I have given all this detail to avoid some idea and practical example of any other simple 18F series PIC controller to avoid some body time waste.
If some body really use and have done sofwaree work on this particular chip he can give the better idea.
Hope for best and luck
I want to read all 5 or 8 channels of PIC18F2431 or PIC18F4431 in assembly language out of 9 channels.
Application note by MICROCHIP "AN900a" is not helping much.
These all channels are belong to PORT A and PORTE
The difficulty is this chip ADC reading is some what different to others normal use pic controllers.
Its data book dosn't help much. It dosn't include practical examples.
What is different it have more ADC control registers comparing to other normal pic controllers
Actually AN0 to AN5 are belongs to PORTA and remaining 3 analog channels are in PORTE from AN6 to AN9, PIC18F4431 has 9 ADC channels altogether.
It include
ADCON0
ADCON1
ADCON2
ADCON3
ADCHS
ANSEL0
ANSEL1
ADRESL
ADRESH
Comparing to other normal chip in this chip ADCON2,ADCON3,ADCHS,ANSEL0 and ANSEL1 are extra added registers moreover there 4 nos of buffer result registers instead of one.
I am able to take result of one any of one channels but not all channels at interrupt base.
I have given all this detail to avoid some idea and practical example of any other simple 18F series PIC controller to avoid some body time waste.
If some body really use and have done sofwaree work on this particular chip he can give the better idea.
Hope for best and luck
Last edited: