lpadc_interrupt#
Overview#
The lpadc_interrupt example shows how to use interrupt with LPADC driver.
In this example, user should indicate a channel to provide a voltage signal (can be controlled by user) as the LPADC’s sample input. When running the project, typing any key into debug console would trigger the conversion. ADC watermark interrupt would be asserted once the number of datawords stored in the ADC Result FIFO is greater than watermark value. In ADC ISR, the watermark flag would be cleared by reading the conversion result value. Also, result information would be printed when the execution return to the main function.
Supported Boards#
EVK9-MIMX8ULP
Hardware requirements
Micro USB cable
MIMX8ULP-EVK/EVK9 board
J-Link Debug Probe
5V power supply
Personal Computer
Board settings
Set 0~1.8V voltage input to CH5A(J11-7) by using DC power supply
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 5V power supply and J-Link Debug Probe to the board, switch SW1 to power on the board.
Connect a micro USB cable between the host PC and the J6 USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the example.
Running the demo
When the demo runs successfully, following information can be seen on the terminal:
LPADC Interrupt Example
ADC Full Range: 4096
Full channel scale (Factor of 1).
Please press any key to get user channel's ADC value.
ADC value: 0
ADC interrupt count: 1
ADC value: 2714
ADC interrupt count: 2
ADC value: 4095
ADC interrupt count: 3
MIMXRT1170-EVKB
Hardware requirements
Mini/micro USB cable
MIMXRT1170-EVKB board
Personal Computer
Board settings
ADC1_IN0 is ADC input. Please sample voltage by J9-10 pin.
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
These instructions are displayed/shown on the terminal window:
LPADC Interrupt Example
ADC Full Range: 4096
Full channel scale (Factor of 1).
Please press any key to get user channel's ADC value.
ADC Value: 1211
ADC Interrupt Counter: 1
ADC Value: 968
ADC Interrupt Counter: 2
ADC Value: 1161
ADC Interrupt Counter: 3
ADC Value: 422
ADC Interrupt Counter: 4
...
EVK-MIMX8ULP
Hardware requirements
Micro USB cable
MIMX8ULP-EVK/EVK9 board
J-Link Debug Probe
5V power supply
Personal Computer
Board settings
Set 0~1.8V voltage input to CH5A(J11-7) by using DC power supply
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 5V power supply and J-Link Debug Probe to the board, switch SW1 to power on the board.
Connect a micro USB cable between the host PC and the J6 USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the example.
Running the demo
When the demo runs successfully, following information can be seen on the terminal:
LPADC Interrupt Example
ADC Full Range: 4096
Full channel scale (Factor of 1).
Please press any key to get user channel's ADC value.
ADC value: 0
ADC interrupt count: 1
ADC value: 2714
ADC interrupt count: 2
ADC value: 4095
ADC interrupt count: 3
MIMXRT1160-EVK
Hardware requirements
Mini/micro USB cable
MIMXRT1160-EVK board
Personal Computer
Board settings
ADC1_IN0 is ADC input. Please sample voltage by J9-10 pin.
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
These instructions are displayed/shown on the terminal window:
ENC Basic Example.
Press any key to get the encoder values ...
LPADC Interrupt Example
ADC Full Range: 4096
Full channel scale (Factor of 1).
Please press any key to get user channel's ADC value.
ADC Value: 1211
ADC Interrupt Counter: 1
ADC Value: 968
ADC Interrupt Counter: 2
ADC Value: 1161
ADC Interrupt Counter: 3
ADC Value: 422
ADC Interrupt Counter: 4
...
MIMXRT1180-EVK
Hardware requirements
Mini/micro USB cable
MIMXRT1180-EVK board
Personal Computer
Board settings
ADC CH7A input signal J41-2(GPIO_AD_02).
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
When the demo runs successfully, the log would be seen on the OpenSDA terminal like:
LPADC Interrupt Example
ADC Full Range: 65536
Full channel scale (Factor of 1).
Please press any key to get user channel's ADC value.
ADC interrupt count: 1
ADC value: 10538
ADC interrupt count: 2
ADC value: 10538
The analog voltage input range is theoretically 0-1.8V. However, due to the workaround for ERR051152, the maximum voltage should be limited to 1.78V. Due to the errata051385, the ADC reference voltage is connect to the VDDA_ADC_1P8.
EVK-MIMXRT595
Hardware requirements
Micro USB cable
EVK-MIMXRT595 board
Personal Computer
Board settings
Input voltage signal(0~1.8V) to J30-1(LPADC0 CH0).
Prepare the Demo
Connect a micro USB cable between the PC host and the CMSIS DAP USB port (J40) on the board
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Launch the debugger in your IDE to begin running the demo.
Running the demo
When the demo runs successfully, following information can be seen on the terminal:
LPADC Interrupt Example
Please press any key to get user channel's ADC value.
ADC value: 4093
ADC interrupt count: 1
ADC value: 4095
ADC interrupt count: 2
ADC value: 4093
ADC interrupt count: 3
EVK-MIMXRT685
Hardware requirements
Micro USB cable
EVK-MIMXRT685 board
Personal Computer
Board settings
Set VREF_L to GND, VREF_H to 1.8V (connect JP9, JP10).
Input voltage signal(0~1.8V) to J30-1(LPADC0 CH0).
Prepare the Demo
Connect a micro USB cable between the PC host and the CMSIS DAP USB port (J5) on the board
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Launch the debugger in your IDE to begin running the demo.
Running the demo
When the demo runs successfully, following information can be seen on the terminal:
LPADC Interrupt Example
Please press any key to get user channel's ADC value.
ADC value: 4093
ADC interrupt count: 1
ADC value: 4095
ADC interrupt count: 2
ADC value: 4093
ADC interrupt count: 3
FRDM-K32L3A6
Hardware requirements
Mini/micro USB cable
FRDM-K32L3A6 board
Personal Computer
Board settings
LPADC CH6A Input signal to J4-2(ptc11)
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the example.
Running the demo
The log below shows in the terminal window:
LPADC Interrupt Example
Please press any key to get user channel's ADC value.
ADC value: 4093
ADC interrupt count: 1
ADC value: 4095
ADC interrupt count: 2
ADC value: 4093
ADC interrupt count: 3
...
FRDM-IMXRT1152
Hardware requirements
Type-C USB cable
FRDM-IMXRT1152 board
Personal Computer
Board settings
ADC1_IN0 is ADC input. Please sample voltage by J47-8 pin.
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
These instructions are displayed/shown on the terminal window:
LPADC Interrupt Example
ADC Full Range: 4096
Full channel scale (Factor of 1).
Please press any key to get user channel's ADC value.
ADC Value: 1211
ADC Interrupt Counter: 1
ADC Value: 968
ADC Interrupt Counter: 2
ADC Value: 1161
ADC Interrupt Counter: 3
ADC Value: 422
ADC Interrupt Counter: 4
...
FRDM-MCXA153
Hardware requirements
Type-C USB cable
FRDM-MCXA153 board
Personal Computer
Board settings
ADC CH0A input signal J4-8(PIO2_0).
Prepare the Demo
Connect a Type-C USB cable between the host PC and the MCU-Link port(J15) on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the hello world demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-MCXA156
Hardware requirements
Type-C USB cable
FRDM-MCXA156 board
Personal Computer
Board settings
ADC CH0A input signal J4-2(P1_10).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the hello world demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-MCXA346
Hardware requirements
Type-C USB cable
FRDM-MCXA346 board
Personal Computer
Board settings
ADC1 CH8A input signal J2-3(P1_10).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-MCXL255
Hardware requirements
Type-C USB cable
FRDM-MCXL255 board
Personal Computer
Board settings
Provide 0-3.3V voltage to J6-1 “AN” pin (ADC ch0 P3_9).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port (J16) on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-MCXN236
Hardware requirements
Type-C USB cable
FRDM-MCXN236 board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect the type-c and mini USB cable between the PC host and the USB ports on the board.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J8 pin 12 (ADC0_A2) on EVK board is used to monitor the voltage.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
FRDM-MCXN947
Hardware requirements
Type-C USB cable
FRDM-MCXN947 Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect the type-c and mini USB cable between the PC host and the USB ports on the board.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J8 Pin 28 (ADC0_A2) on EVK board is used to monitor the voltage.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
FRDM-MCXN947T
Hardware requirements
Type-C USB cable
FRDM-MCXN947T Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect the type-c and mini USB cable between the PC host and the USB ports on the board.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J8 Pin 28 (ADC0_A2) on EVK board is used to monitor the voltage.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
FRDM-MCXW71
Hardware requirements
Type-C USB cable
FRDM-MCXW71 Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect the micro and mini USB cable between the PC host and the USB ports on the board.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The 6 Pin 1 (ADC0_A6) on EVK board is used to monitor the voltage. The VREFO 1.8v is used as the ADC reference.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
MCX-W71-EVK
Hardware requirements
Type-C USB cable
MCX-W71-EVK Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect a USB cable between the host PC and the EVK board J14.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J4 Pin 9 (ADC0_A6) on EVK board is used to monitor the voltage. The VREFO 1.8v is used as the ADC reference.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
KW45B41Z-EVK
Hardware requirements
Mini/micro USB cable
KW45B41Z-EVK Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect the micro and mini USB cable between the PC host and the USB ports on the board.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J12 Pin 1 (ADC0_A6) on EVK board is used to monitor the voltage. The VREFO 1.8v is used as the ADC reference.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
KW47-EVK
Hardware requirements
Type-C USB cable
KW47-EVK Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect a USB cable between the host PC and the EVK board J14.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J4 Pin 9 (ADC0_A6) on EVK board is used to monitor the voltage. The VREFO 1.8v is used as the ADC reference.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
LPCXpresso55S06
Hardware requirements
Mini/micro USB cable
LPCXpresso55S06 board
Personal Computer
Board settings
ADC CH0A input signal J13-3(PIO0_23).
Prepare the Demo
Connect a micro USB cable between the PC host and the CMSIS DAP USB port (J1) on the board
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the hello world demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
LPCXpresso55S16
Hardware requirements
Mini/micro USB cable
LPCXpresso55S16 board
Personal Computer
Board settings
ADC CH0A input signal J13-3(PIO0_23). The jumper setting: Default jumpers configuration does not work, you will need to add JP20 and JP21 (JP22 optional for ADC use)
Prepare the Demo
Connect a micro USB cable between the PC host and the CMSIS DAP USB port (J1) on the board
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the hello world demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
LPCXpresso55S28
Hardware requirements
Mini/micro USB cable
LPCXpresso55S28 board
Personal Computer
Board settings
Connect a jumper to P15-2 and P15-3.
ADC CH0A input signal P28-1(PIO0-23).
Prepare the Demo
Note: MCUXpresso IDE project default debug console is semihost
Connect a micro USB cable between the PC host and the CMSIS DAP USB port (P6) on the board
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the hello world demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
LPCXpresso55S36
Hardware requirements
Mini/micro USB cable
LPCXpresso55S36 board
Personal Computer
Board settings
ADC CH0A input signal J7-1(PIO1_9).
Prepare the Demo
Connect a micro USB cable between the PC host and the CMSIS DAP USB port (J1) on the board
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the hello world demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
LPCXpresso55S69
Hardware requirements
Mini/micro USB cable
LPCXpresso55s69 board
Personal Computer
Board settings
Connect a jumper to P15-2 and P15-3.
ADC CH0A input signal P28-1(PIO0-23).
Prepare the Demo
Note: MCUXpresso IDE project default debug console is semihost
Connect a micro USB cable between the PC host and the CMSIS DAP USB port (P6) on the board
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the hello world demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
MCX-N5XX-EVK
Hardware requirements
Mini/micro USB cable
MCX-N5XX-EVK Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect the micro and mini USB cable between the PC host and the USB ports on the board.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J20 Pin 28 (ADC0_A2) on EVK board is used to monitor the voltage.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
MCX-N9XX-EVK
Hardware requirements
Mini/micro USB cable
MCX-N9XX-EVK Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect the micro and mini USB cable between the PC host and the USB ports on the board.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J20 Pin 28 (ADC0_A2) on EVK board is used to monitor the voltage.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
MCX-W72-EVK
Hardware requirements
Type-C USB cable
MCX-W72-EVK Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect a USB cable between the host PC and the EVK board J14.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J4 Pin 9 (ADC0_A6) on EVK board is used to monitor the voltage. The VREFO 1.8v is used as the ADC reference.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
MIMXRT685-AUD-EVK
Hardware requirements
Micro USB cable
MIMXRT685-AUD-EVK board
Personal Computer
Board settings
Set VREF_L to GND, VREF_H to 1.8V (connect JP9, JP10).
Input voltage signal(0~1.8V) to LPADC0 CH0 (R405, P_5_ADC0_0 side)
Prepare the Demo
Connect a micro USB cable between the PC host and the CMSIS DAP USB port (J5) on the board
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Launch the debugger in your IDE to begin running the demo.
Running the demo
When the demo runs successfully, following information can be seen on the terminal:
LPADC Interrupt Example
Please press any key to get user channel's ADC value.
ADC value: 4093
ADC interrupt count: 1
ADC value: 4095
ADC interrupt count: 2
ADC value: 4093
ADC interrupt count: 3
MIMXRT700-EVK
Hardware requirements
Micro USB cable
MIMXRT700-EVK board
Personal Computer
Board settings
ADC CH0A input signal J24-1(PIO10_0).
Prepare the Demo
Connect a USB cable between the host PC and the MCU-LINK USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
When the example runs successfully, you can see the similar information from the terminal as below.
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC interrupt count: 1
ADC value: 10538
ADC interrupt count: 2
ADC value: 10538
FRDM-MCXA174
Hardware requirements
Type-C USB cable
FRDM-MCXA174 board
Personal Computer
Board settings
ADC1 CH8A input signal J2-3(P1_10).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-MCXA344
Hardware requirements
Type-C USB cable
FRDM-MCXA344 board
Personal Computer
Board settings
ADC1 CH8A input signal J2-3(P1_10).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
KW47-LOC
Hardware requirements
Type-C USB cable
KW47-LOC Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect a USB cable between the host PC and the LOC board J3.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J1 Pin 1 (ADC0_A15) on LOC board is used to monitor the voltage. The VREFO 1.8v is used as the ADC reference.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: 4096
Please press any key to get user channel's ADC value.
ADC value: 2714
MCXW72-LOC
Hardware requirements
Type-C USB cable
MCXW72-LOC Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect a USB cable between the host PC and the LOC board J3.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J1 Pin 1 (ADC0_A15) on LOC board is used to monitor the voltage. The VREFO 1.8v is used as the ADC reference.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: 4096
Please press any key to get user channel's ADC value.
ADC value: 2714
FRDM-IMXRT1186
Hardware requirements
Type-C USB cable
FRDM-IMXRT1186 board
Personal Computer
Board settings
Change Jumper J27 from 1-2 to 2-3
ADC CHA1 input signal J51-8(GPIO_AD_14).
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
When the demo runs successfully, the log would be seen on the OpenSDA terminal like:
LPADC Interrupt Example
ADC Full Range: 65536
Full channel scale (Factor of 1).
Please press any key to get user channel's ADC value.
ADC interrupt count: 1
ADC value: 10538
ADC interrupt count: 2
ADC value: 10538
The analog voltage input range is theoretically 0-1.8V. However, due to the workaround for ERR051152, the maximum voltage should be limited to 1.78V. Due to the errata051385, the ADC reference voltage is connect to the VDDA_ADC_1P8.
FRDM-MCXA266
Hardware requirements
Type-C USB cable
FRDM-MCXA266 board
Personal Computer
Board settings
ADC1 CH8A input signal J2-3(P1_10).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-MCXA366
Hardware requirements
Type-C USB cable
FRDM-MCXA366 board
Personal Computer
Board settings
ADC1 CH8A input signal J2-3(P1_10).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-MCXW72
Hardware requirements
Type-C USB cable
FRDM-MCXW72 Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect a USB cable between the host PC and the FRDM board J10.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
The J6 Pin 1 (ADC0_A6) on FRDM board is used to monitor the voltage. The VREFO 1.8v is used as the ADC reference.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: 4096
Please press any key to get user channel's ADC value.
ADC value: 2714
FRDM-MCXA577
Hardware requirements
Type-C USB cable
FRDM-MCXA577 board
Personal Computer
Board settings
ADC0 CH0A input signal J8-21(P2_0).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-MCXC162
Hardware requirements
Type-C USB cable
FRDM-MCXC162 board
Personal Computer
Board settings
ADC0 CH0A input signal J1-8(P2_0).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2
FRDM-KW43
Hardware requirements
Type-C USB cable
FRDM-KW43 Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect a USB cable between the host PC and the FRDM board J28.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
FRDM-MCXW70
Hardware requirements
Type-C USB cable
FRDM-MCXW70 Board
Personal Computer
Board settings
No special settings are required.
Prepare the Demo
Connect a USB cable between the host PC and the FRDM board J28.
Open a serial terminal on PC for the serial device with these settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The following lines are printed to the serial terminal when the demo program is executed.
LPADC Interrupt Example
ADC Full Range: XXXX
Please press any key to get user channel's ADC value.
ADC value: 2714
FRDM-MCXA287
Hardware requirements
Type-C USB cable
FRDM-MCXA287 board
Personal Computer
Board settings
ADC0 CH0A input signal J8-21(P2_0).
Prepare the Demo
Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.
Open a serial terminal with the following settings (See Appendix A in Getting started guide for description how to determine serial port number):
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
The log below shows the output of the demo in the terminal window:
LPADC Interrupt Example
ADC Full Range: 65536
Please press any key to get user channel's ADC value.
ADC value: 35852
ADC interrupt count: 1
ADC value: 35586
ADC interrupt count: 2