pdm_interrupt#
Overview#
The pdm interrupt example shows how to use pdm driver with interrupt:
In this example, pdm will trigger interrupt to transfer data when watermark value is reached.
Supported Boards#
EVK9-MIMX8ULP
Hardware requirements
Micro USB cable
MIMX8ULP-EVK/EVK9 board
J-Link Debug Probe
5V power supply
Personal Computer
Microphone
Board settings
populate J20, J21 Connect microphone module to EVK board: 3V->J20-8 GND->J20-7 CLK->J21-4 DATA->J21-3
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 5V power supply and JLink Plus to the board, switch SW10 to power on the board
Connect a micro USB cable between the host PC and the J17 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
IMX952LPD5EVK-19
Hardware requirements
Micro USB cable
IMX952-EVK board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
Set SW9[3]=0.
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V~20V power supply and JLink Plus to the board, switch SW4 to power on the board
Connect a micro USB cable between the host PC and the J31 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
MIMXRT1170-EVKB
Hardware requirements
Mini/micro USB cable
MIMXRT1170-EVKB board
Personal Computer
Board settings
No special settings are required.
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
The log below shows the output demo in the terminal window:
PDM interrupt example started!
PDM recieve data::
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PDM interrupt example finished!
EVK-MIMX8MM
Hardware requirements
Micro USB cable
MIMX8MM6-EVK board
J-Link Debug Probe
12V power supply
Personal Computer
Microphone
Board settings
Connect microphone to EVK board: 3V->J1003-1 GND->J1003-6 CLK->J1003-40 DATA->J1003-38
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V power supply and J-Link Debug Probe to the board, switch SW101 to power on the board
Connect a USB cable between the host PC and the J901 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
EVK-MIMX8MN
Hardware requirements
Micro USB cable
MIMX8MN6-EVK board
J-Link Debug Probe
12V power supply
Personal Computer
Microphone
Board settings
Connect microphone module to EVK board: 3V->J1003-1 GND->J1003-6 CLK->J1003-40 DATA->J1003-38
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V power supply and J-Link Debug Probe to the board, switch SW101 to power on the board
Connect a USB cable between the host PC and the J901 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
EVK-MIMX8MNDDR3L
Hardware requirements
Micro USB cable
MIMX8MN6-EVK board
J-Link Debug Probe
12V power supply
Personal Computer
Microphone
Board settings
Connect microphone module to EVK board: 3V->J1003-1 GND->J1003-6 CLK->J1003-40 DATA->J1003-38
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V power supply and J-Link Debug Probe to the board, switch SW101 to power on the board
Connect a USB cable between the host PC and the J901 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
EVK-MIMX8MP
Hardware requirements
Micro USB cable
EVK-MIMX8M Plus board
J-Link Debug Probe
12V power supply
Personal Computer
Microphone
Board settings
Connect microphone module to EVK board: 3V->J21-1 GND->J21-6 CLK->J21-40 DATA->J21-38
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V power supply and J-Link Debug Probe to the board, switch SW3 to power on the board
Connect a USB cable between the host PC and the J23 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.
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 debugger terminal like:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
EVK-MIMX8ULP
Hardware requirements
Micro USB cable
MIMX8ULP-EVK/EVK9 board
J-Link Debug Probe
5V power supply
Personal Computer
Microphone
Board settings
populate J20, J21 Connect microphone module to EVK board: 3V->J20-8 GND->J20-7 CLK->J21-4 DATA->J21-3
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 5V power supply and JLink Plus to the board, switch SW10 to power on the board
Connect a micro USB cable between the host PC and the J17 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
MIMXRT1160-EVK
Hardware requirements
Mini/micro USB cable
MIMXRT1160-EVK board
Personal Computer
Board settings
No special settings are required.
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
The log below shows the output demo in the terminal window:
PDM interrupt example started!
PDM recieve data::
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PDM interrupt example finished!
MIMXRT1180-EVK
Hardware requirements
Mini/micro USB cable
MIMXRT1180-EVK board
Personal Computer
Board settings
No special settings are required.
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
The log below shows the output demo in the terminal window:
PDM interrupt example started!
PDM recieve data::
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PDM interrupt example finished!
FRDM-MCXN236
Hardware requirements
Type-C USB cable
FRDM-MCXN236 board
Personal Computer
Board settings
No special settings are required.
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
The log below shows the output demo in the terminal window:
PDM interrupt example started!
PDM recieve data::
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PDM interrupt example finished!
FRDM-MCXN947
Hardware requirements
Type-C USB cable
MCX-N5XX-EVK board
Personal Computer
Board settings
No special settings are required.
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
The log below shows the output demo in the terminal window:
PDM interrupt example started!
PDM recieve data::
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PDM interrupt example finished!
FRDM-MCXN947T
Hardware requirements
Type-C USB cable
MCX-N5XX-EVK board
Personal Computer
Board settings
No special settings are required.
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
The log below shows the output demo in the terminal window:
PDM interrupt example started!
PDM recieve data::
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PDM interrupt example finished!
IMX95LPD5EVK-19
Hardware requirements
Micro USB cable
IMX95LPD5-EVK board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
No special settings are required.
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V~20V power supply and JLink Plus to the board, switch SW4 to power on the board
Connect a micro USB cable between the host PC and the J31 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
FRDM-IMX95
Hardware requirements
Micro USB cable
FRDM-IMX95 board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
No special settings are required.
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V~20V power supply and JLink Plus to the board, switch SW4 to power on the board
Connect a micro USB cable between the host PC and the J31 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
FRDM-IMX952
Hardware requirements
Micro USB cable
IMX952-EVK board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
Set SW9[3]=0.
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V~20V power supply and JLink Plus to the board, switch SW4 to power on the board
Connect a micro USB cable between the host PC and the J31 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
FRDM-IMX937
Hardware requirements
Micro USB cable
FRDM-IMX937 board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
No special settings are required.
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V~20V power supply and JLink Plus to the board, switch SW4 to power on the board
Connect a micro USB cable between the host PC and the J31 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
MCIMX93-EVK
Hardware requirements
USB Type-C cable
MCIMX93-EVK board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
No special settings are required.
Note
Please run the application in Low Power boot mode (without Linux BSP). The IP module resource of the application is also used by Linux BSP. Or, run with Single Boot mode by changing Linux BSP to avoid resource conflict.
Prepare the Demo
Connect 12V~20V power supply and JLink Plus to the board, switch SW301 to power on the board
Connect a USB Type-C cable between the host PC and the J1401 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
MCIMX93-QSB
Hardware requirements
USB Type-C cable
MCIMX93-QSB board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
No special settings are required.
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V~20V power supply and JLink Plus to the board, switch SW301 to power on the board
Connect a USB Type-C cable between the host PC and the J1708 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
IMX943-EVK
Hardware requirements
Micro USB cable
IMX943-EVK board
J-Link Debug Probe
12V~20V power supply
Personal Computer
Board settings
No special settings are required.
Please note this application can’t support running with Linux BSP!
Prepare the Demo
Connect 12V~20V power supply and JLink Plus to the board, switch SW1(SYS_PWR) to power on the board
Connect a micro USB cable between the host PC and the J15(FTDI_DEBUG) 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.
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:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!
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 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
The log below shows the output demo in the terminal window:
PDM interrupt example started!
PDM recieve data::
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PDM interrupt example finished!
MCX-N9XX-EVK
Hardware requirements
Mini/micro USB cable
MCX-N5XX-EVK board
Personal Computer
Board settings
No special settings are required.
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
The log below shows the output demo in the terminal window:
PDM interrupt example started!
PDM recieve data::
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PDM interrupt example finished!
MIMXRT700-EVK
Hardware requirements
Micro USB cable
MIMXRT700-EVK board
Personal Computer
Board settings
Prepare the Demo
Connect a micro USB cable between the PC host and the MCU-LINK USB port (J54) 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, the log would be seen on the terminal like:
PDM interrupt example started!
PDM recieve data:
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXX
PDM interrupt example finished!