2 ADC Example Component, Running the Examples
2.1 Running the ADC Basic Printf Example
When using the MPLAB Data Visualizer Time Plot to run the ADC Basic Printf example, the following will appear:
2.2 Running the ADC Data Streamer Example
When using the MPLAB Data Visualizer Time Plot to run the ADC Basic Printf example, the following will appear:
2.3 Running the ADCC Spike Detection Example
A change (above a set threshold) in the ADC result between successive conversions
represents a spike. When a spike is detected, a callback updates the
adcResult_lastSpike
and adcSpikeCount
variables.Tip: The spike takes place between an
average of samples, if the ADC is in Average mode.
The following video shows a similar example from the MCC Melody API Reference for PIC16F/18F MCU Families.
2.4 Example Board for the ADCC Examples
The ADCC example can be run on Curiosity Nano boards, such as the PIC18F-Q41 or PIC18F-Q43. The image below shows an ADC reading of the Q43, taken by using the potentiometer on the Curiosity Nano Explorer.
All three ADCC examples were tested using the hardware setup presented below.