News:

Let's find out together what makes a PIC Tick!

Main Menu

ADin channel numbering with PIC16F18854 ?

Started by Fred Philpott, Feb 10, 2022, 11:26 AM

Previous topic - Next topic

Fred Philpott

The 16F18854 family have the ADC pins grouped by port instead of consecutive numbers like older devices. ANA0-7, ANB0-7 etc.
How do the channel numbers for the ADin command tie in with this structure?
Philpott's corollary to Murphy's Law - Murphy was an optimist!

trastikata

Quote from: Fred Philpott on Feb 10, 2022, 11:26 AMHow do the channel numbers for the ADin command tie in with this structure?

I'd guess it follows the ADC channel selection bits as stated in ADPCH<5:0>.

ADin 0 = ANA0 ... ADin 8 = ANB0 ... ADin 23 = ANC7 ... ADin 63 = FVR

Fred Philpott

Philpott's corollary to Murphy's Law - Murphy was an optimist!