MCUXpresso SDK Documentation

lpi2c_interrupt_b2b_transfer_slave

lpi2c_interrupt_b2b_transfer_slave#

Overview#

The lpi2c_interrupt_b2b_transfer_slave example shows how to use lpi2c driver as slave to do board to board transfer with interrupt:

In this example, one lpi2c instance as slave and another lpi2c instance on the other board as master. Master sends a piece of data to slave, and receive a piece of data from slave. This example checks if the data received from slave is correct.

Supported Boards#

EVK9-MIMX8ULP
Hardware requirements
  • Micro USB cable

  • two MIMX8ULP-EVK/EVK9 boards

  • J-Link Debug Probe

  • 5V power supply

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C0 pins of MASTER_BOARD are connected with LPI2C0 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
I2C0_SCL     J20-10             I2C0_SCL     J20-10
I2C0_SDA     J20-9              I2C0_SDA     J20-9
GND                             GND

Please note this application can’t support running with Linux BSP!

Prepare the Demo
  1. Connect 5V power supply and J-Link Debug Probe to the board, switch SW10 to power on the board.

  2. Connect a micro USB cable between the host PC and the J17 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. 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 example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
IMX952LPD5EVK-19
Hardware requirements
  • Micro USB cable

  • two IMX952-EVK boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C6)                connect to        SLAVE(LPI2C6)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J22 pin 3                         SCL         J22 pin 3
SDA         J22 pin 5                         SDA         J22 pin 5
GND         J22 pin 7                         GND         J22 pin 7
Please note this application can’t support running with Linux BSP!
Prepare the Demo
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW4 to power on the board.

  2. Connect a micro USB cable between the host PC and the J31 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
EVKB-IMXRT1050
Hardware requirements
  • Mini/micro USB cable

  • Two EVKB-IMXRT1050 board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J23-5              LPI2C1_SCL   J23-5
LPI2C1_SDA   J23-6              LPI2C1_SDA   J23-6
GND          J24-7              GND          J24-7
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
MIMXRT1060-EVKB
Hardware requirements
  • Mini/micro USB cable

  • Two MIMXRT1060-EVKB board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J33-6              LPI2C1_SCL   J33-6
LPI2C1_SDA   J33-5              LPI2C1_SDA   J33-5
GND          J17-7              GND          J17-7
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
MIMXRT1170-EVKB
Hardware requirements
  • Mini/micro USB cable

  • Two MIMXRT1170-EVKB board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J26-12             LPI2C1_SCL   J26-12
LPI2C1_SDA   J26-10             LPI2C1_SDA   J26-10
GND          J10-14             GND          J10-14
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
MIMXRT1060-EVKC
Hardware requirements
  • Mini/micro USB cable

  • Two MIMXRT1060-EVKC board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J33-6              LPI2C1_SCL   J33-6
LPI2C1_SDA   J33-5              LPI2C1_SDA   J33-5
GND          J17-7              GND          J17-7
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
FRDM-IMXRT1152
Hardware requirements
  • Type-C USB cable

  • Two FRDM-IMXRT1152 board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J47-12             LPI2C1_SCL   J47-12
LPI2C1_SDA   J47-10             LPI2C1_SDA   J47-10
GND          J47-1              GND          J47-1
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
EVK-MCIMX7ULP
Hardware requirements
  • Micro USB cable

  • two MCIMX7ULP-EVK boards

  • J-Link Debug Probe

  • 5V power supply

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C3 pins of MASTER_BOARD are connected with LPI2C3 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
I2C3_SCL     TP24               I2C3_SCL     TP24
I2C3_SDA     TP26               I2C3_SDA     TP26
GND                             GND

Please note this application can’t support running with Linux BSP!

Prepare the Demo
  1. Connect 5V power supply and J-Link Debug Probe to the board, switch SW1 to power on the board.

  2. Connect a micro USB cable between the host PC and the J6 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. 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 example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
EVK-MIMX8ULP
Hardware requirements
  • Micro USB cable

  • two MIMX8ULP-EVK/EVK9 boards

  • J-Link Debug Probe

  • 5V power supply

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C0 pins of MASTER_BOARD are connected with LPI2C0 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
I2C0_SCL     J20-10             I2C0_SCL     J20-10
I2C0_SDA     J20-9              I2C0_SDA     J20-9
GND                             GND

Please note this application can’t support running with Linux BSP!

Prepare the Demo
  1. Connect 5V power supply and J-Link Debug Probe to the board, switch SW10 to power on the board.

  2. Connect a micro USB cable between the host PC and the J17 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. 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 example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
EVK-MIMXRT1010
Hardware requirements
  • Mini/micro USB cable

  • Two EVK-MIMXRT1010 board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J57-20             LPI2C1_SCL   J57-20
LPI2C1_SDA   J57-18             LPI2C1_SDA   J57-18
GND          J57-14             GND          J57-14
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .

Note: To debug in qspiflash, following steps are needed:

  1. Select the flash target and compile.

  2. Set the SW8: 1 off 2 off 3 on 4 off, then power on the board and connect USB cable to J41.

  3. Start debugging in IDE.

    • Keil: Click “Download (F8)” to program the image to qspiflash first then clicking “Start/Stop Debug Session (Ctrl+F5)” to start debugging.

EVK-MIMXRT1015
Hardware requirements
  • Mini/micro USB cable

  • Two EVK-MIMXRT1015 board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J18-6               LPI2C1_SCL   J18-6
LPI2C1_SDA   J18-5               LPI2C1_SDA   J18-5
GND          J19-7               GND          J19-7
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .

Note: To debug in qspiflash, following steps are needed:

  1. Select the flash target and compile.

  2. Set the SW8: 1 off 2 off 3 on 4 off, then power on the board and connect USB cable to J41.

  3. Start debugging in IDE.

    • Keil: Click “Download (F8)” to program the image to qspiflash first then clicking “Start/Stop Debug Session (Ctrl+F5)” to start debugging.

EVK-MIMXRT1020
Hardware requirements
  • Mini/micro USB cable

  • Two EVK-MIMXRT1020 board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J18-6               LPI2C1_SCL   J18-6
LPI2C1_SDA   J18-5               LPI2C1_SDA   J18-5
GND          J19-7               GND          J19-7
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .

Note: To debug in qspiflash, following steps are needed:

  1. Select the flash target and compile.

  2. Set the SW8: 1 off 2 off 3 on 4 off, then power on the board and connect USB cable to J23.

  3. Start debugging in IDE.

    • Keil: Click “Download (F8)” to program the image to qspiflash first then clicking “Start/Stop Debug Session (Ctrl+F5)” to start debugging.

MIMXRT1024-EVK
Hardware requirements
  • Mini/micro USB cable

  • Two MIMXRT1024-EVK boards

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J18-12              LPI2C1_SCL   J18-12
LPI2C1_SDA   J18-10              LPI2C1_SDA   J18-10
GND          J19-14              GND          J19-14
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .

Note: To debug in qspiflash, following steps are needed:

  1. Select the flash target and compile.

  2. Set the SW8: 1 off 2 off 3 on 4 off, then power on the board and connect USB cable to J23.

  3. Start debugging in IDE.

    • Keil: Click “Download (F8)” to program the image to qspiflash first then clicking “Start/Stop Debug Session (Ctrl+F5)” to start debugging.

MIMXRT1040-EVK
Hardware requirements
  • Mini/micro USB cable

  • Two MIMXRT1040-EVK board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J17-10             LPI2C1_SCL   J17-10
LPI2C1_SDA   J17-9              LPI2C1_SDA   J17-9
GND          J17-7              GND          J17-7
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
EVK-MIMXRT1064
Hardware requirements
  • Mini/micro USB cable

  • Two EVK-MIMXRT1064 board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J23-6              LPI2C1_SCL   J23-6
LPI2C1_SDA   J23-5              LPI2C1_SDA   J23-5
GND          J24-7              GND          J24-7
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
MIMXRT1160-EVK
Hardware requirements
  • Mini/micro USB cable

  • Two MIMXRT1160-EVK board

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J26-12             LPI2C1_SCL   J26-12
LPI2C1_SDA   J26-10             LPI2C1_SDA   J26-10
GND          J10-14             GND          J10-14
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
MIMXRT1180-EVK
Hardware requirements
  • Mini/micro USB cable

  • Two MIMXRT1180-EVK board

  • Personal Computer

Board settings

Remove R79, R80 LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C2 pins of MASTER_BOARD are connected with LPI2C2 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C2_SCL   J44-20             LPI2C2_SCL   J44-20
LPI2C2_SDA   J44-18             LPI2C2_SDA   J44-18
GND          J44-19             GND          J44-19
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
FRDM-K32L2A4S
Hardware requirements
  • Mini USB cable

  • Two FRDM-K32L2A4S boards

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J4-12              LPI2C1_SCL   J4-12
LPI2C1_SDA   J4-10              LPI2C1_SDA   J4-10
GND          J3-14              GND          J3-14
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
FRDM-K32L3A6
Hardware requirements
  • Micro USB cable

  • Two FRDM-K32L3A6 boards

  • Personal Computer

Board settings

To make lpi2c example work(M4), connections needed to be as follows:

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J1-10(PTB14)       LPI2C1_SCL   J1-10(PTB14)
LPI2C1_SDA   J2-6(PTB6)         LPI2C1_SDA   J2-6(PTB6)
GND          J2-14              GND          J2-14

To make lpi2c example work(M0), connections needed to be as follows:

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C3_SCL   J3-15(PTB15)       LPI2C3_SCL   J3-15(PTB15)
LPI2C3_SDA   J3-13(PTB16)       LPI2C3_SDA   J3-13(PTB16)
GND          J2-14              GND          J2-14
Prepare the Demo
  1. Connect a micro USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal on PC for JLink serial device with these settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  3. Download the program to the target board.

  4. 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 message shows in the terminal if the example runs successfully.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .

FRDM-KE15Z
Hardware requirements
  • Micro USB cable

  • Two FRDM-KE15Z boards

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C0 pins of MASTER_BOARD are connected with LPI2C0 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C0_SCL   J4-12              LPI2C0_SCL   J4-12
LPI2C0_SDA   J4-10              LPI2C0_SDA   J4-10
GND          J3-14              GND          J3-14
Prepare the Demo
  1. Connect a USB cable between the host PC and the OpenSDA USB port on the target board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
FRDM-KE16Z
Hardware requirements
  • Micro USB cable

  • Two FRDM-KE16Z boards

  • Personal Computer

Board settings

LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C0 pins of MASTER_BOARD are connected with LPI2C0 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C0_SCL   J2-20              LPI2C0_SCL   J2-20
LPI2C0_SDA   J2-18              LPI2C0_SDA   J2-18
GND          J2-14              GND          J2-14
Prepare the Demo
  1. Connect a USB cable between the host PC and the OpenSDA USB port on the target board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
FRDM-KE17Z
Hardware requirements
  • Micro USB cable

  • Two FRDM-KE17Z boards

  • Personal Computer

Board settings

LPI2C two boards:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C0 pins of MASTER_BOARD are connected with LPI2C0 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C0_SCL   J2-20              LPI2C0_SCL   J2-20
LPI2C0_SDA   J2-18              LPI2C0_SDA   J2-18
GND          J2-14              GND          J2-14
Prepare the Demo
  1. Connect a USB cable between the host PC and the OpenSDA USB port on the target board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.


End of LPI2C example .
FRDM-KE17Z512
Hardware requirements
  • Micro USB cable

  • Two FRDM-KE17Z512 boards

  • Personal Computer

Board settings

LPI2C two boards:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C0 pins of MASTER_BOARD are connected with LPI2C0 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C0_SCL   J2-20              LPI2C0_SCL   J2-20
LPI2C0_SDA   J2-18              LPI2C0_SDA   J2-18
GND          J2-14              GND          J2-14
Prepare the Demo
  1. Connect a USB cable between the host PC and the MCU-LINK USB port on the target board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board EDMA example -- Master transfer.
Master will send data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  

Receive sent data from slave :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
FRDM-MCXA153
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA153 board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

LPI2C:

MASTER(LPI2C0)                connect to        SLAVE(LPI2C0)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J5 pin 6                           SDA         J5 pin 6
SCL         J5 pin 5                           SCL         J5 pin 5
GND         J5 pin 8                           GND         J5 pin 8

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a Type-C USB cable between the host PC and the MCU-Link port(J15) on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXA156
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA156 board

  • Personal Computer

Board settings
        MASTER(LPI2C0)           connect to        SLAVE(LPI2C3)
        LPI2C0 SCL(P0_17,J2-20)     -->          LPI2C3 SCL(P3_27,J5_5)
        LPI2C0 SDA(P0_16,J2-18)     -->          LPI2C3 SDA(P3_28,J5_6)

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXA346
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA346 board

  • Personal Computer

Board settings
MASTER(LPI2C2)                connect to        SLAVE(LPI2C2)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXE247
Hardware requirements
  • USB-C cable

  • Two FRDM-MCXE247 boards

  • Personal Computer

Board settings

LPI2C two boards:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C1 pins of MASTER_BOARD are connected with LPI2C1 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C1_SCL   J2-20              LPI2C1_SCL   J2-20
LPI2C1_SDA   J2-18              LPI2C1_SDA   J2-18
GND          J2-14              GND          J2-14
Prepare the Demo
  1. Connect a USB cable between the host PC and the MCU-LINK USB port on the target board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board EDMA example -- Master transfer.
Master will send data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  

Receive sent data from slave :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
FRDM-MCXN236
Overview

The lpi2c_interrupt_b2b_transfer_slave example shows how to use lpi2c driver as slave to do board to board transfer with interrupt:

In this example, one lpi2c instance as slave and another lpi2c instance on the other board as master. Master sends a piece of data to slave, and receive a piece of data from slave. This example checks if the data received from slave is correct.

Toolchain supported
  • IAR embedded Workbench 9.30.1

  • MCUXpresso 11.6.0

Hardware requirements
  • Type-C USB cable

  • FRDM-MCXN236 board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C2)                connect to        SLAVE(LPI2C2)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J5 pin 5                            SCL         J5 pin 5
SDA         J5 pin 6                            SDA         J5 pin 6
GND         J5 pin 8                            GND         J5 pin 8

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect the type-c and mini USB cable between the PC host and the USB ports on the board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXN947
Overview

The lpi2c_interrupt_b2b_transfer_slave example shows how to use lpi2c driver as slave to do board to board transfer with interrupt:

In this example, one lpi2c instance as slave and another lpi2c instance on the other board as master. Master sends a piece of data to slave, and receive a piece of data from slave. This example checks if the data received from slave is correct.

Toolchain supported
  • IAR embedded Workbench 9.30.1

  • MCUXpresso 11.6.0

Hardware requirements
  • Type-C USB cable

  • FRDM-MCXN947 board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C2)                connect to        SLAVE(LPI2C2)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect the type-c and mini USB cable between the PC host and the USB ports on the board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXN947T
Overview

The lpi2c_interrupt_b2b_transfer_slave example shows how to use lpi2c driver as slave to do board to board transfer with interrupt:

In this example, one lpi2c instance as slave and another lpi2c instance on the other board as master. Master sends a piece of data to slave, and receive a piece of data from slave. This example checks if the data received from slave is correct.

Toolchain supported
  • IAR embedded Workbench 9.30.1

  • MCUXpresso 11.6.0

Hardware requirements
  • Type-C USB cable

  • FRDM-MCXN947T board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C2)                connect to        SLAVE(LPI2C2)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect the type-c and mini USB cable between the PC host and the USB ports on the board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXW71
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXW71 Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J2 pin 2                            SDA         J2 pin 2
SCL         J2 pin 1                            SCL         J2 pin 1

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect the micro and mini USB cable between the PC host and the USB ports on the board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
MCX-W71-EVK
Hardware requirements
  • Type-C USB cable

  • MCX-W71-EVK Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J2 pin 3                            SDA         J2 pin 3
SCL         J2 pin 1                            SCL         J2 pin 1

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB cable between the host PC and the EVK board J14.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
FRDM-MCXW72
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXW72 Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J2 pin 2                            SDA         J2 pin 2
SCL         J2 pin 1                            SCL         J2 pin 1

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB cable between the host PC and the FRDM board J10.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
IMX95LPD5EVK-19
Hardware requirements
  • Micro USB cable

  • two IMX95LPD5-EVK boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J22 pin 3                         SCL         J22 pin 3
SDA         J22 pin 5                         SDA         J22 pin 5
GND         J22 pin 7                         GND         J22 pin 7

Please note this application can’t support running with Linux BSP!

Prepare the Demo
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW4 to power on the board.

  2. Connect a micro USB cable between the host PC and the J31 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
FRDM-IMX95
Hardware requirements
  • Micro USB cable

  • two FRDM-IMX95 boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C6)                connect to        SLAVE(LPI2C6)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J19 pin 3                         SCL         J19 pin 3
SDA         J19 pin 5                         SDA         J19 pin 5
GND         J19 pin 9                         GND         J19 pin 9

Please note this application can’t support running with Linux BSP!

Prepare the Demo
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW4 to power on the board.

  2. Connect a micro USB cable between the host PC and the J31 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
FRDM-IMX952
Hardware requirements
  • Micro USB cable

  • two IMX952-EVK boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C6)                connect to        SLAVE(LPI2C6)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J18 pin 5                           SCL         J18 pin 5
SDA         J18 pin 3                           SDA         J18 pin 3
GND         J18 pin 6                           GND         J18 pin 6

Note: J18 is the 40-PIN GPIO HDR expansion connector. - J18-Pin5: LPI2C6_SCL (GPIO_IO03) - J18-Pin3: LPI2C6_SDA (GPIO_IO02) - J18-Pin6: Common Ground (any GND pin on J18 can be used) - Pull-up resistors: 2.2kΩ @ 3.3V (built-in, no external pull-ups needed) - Each board must be powered independently - No IO expander configuration required for this example

Please note this application can’t support running with Linux BSP!
Prepare the Demo
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW4 to power on the board.

  2. Connect a micro USB cable between the host PC and the J31 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
FRDM-IMX937
Hardware requirements
  • Micro USB cable

  • two FRDM-IMX937 boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C6)                connect to        SLAVE(LPI2C6)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J19 pin 3                         SCL         J19 pin 3
SDA         J19 pin 5                         SDA         J19 pin 5
GND         J19 pin 9                         GND         J19 pin 9

Please note this application can’t support running with Linux BSP!

Prepare the Demo
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW4 to power on the board.

  2. Connect a micro USB cable between the host PC and the J31 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
KW45B41Z-EVK
Hardware requirements
  • Mini/micro USB cable

  • KW45B41Z-EVK Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J2 pin 9                            SDA         J2 pin 9
SCL         J2 pin 10                           SCL         J2 pin 10

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect the micro and mini USB cable between the PC host and the USB ports on the board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
KW47-EVK
Hardware requirements
  • Type-C USB cable

  • KW47-EVK Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J2 pin 3                            SDA         J2 pin 3
SCL         J2 pin 1                            SCL         J2 pin 1

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB cable between the host PC and the EVK board J14.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
MCIMX93AUTO-EVK
Hardware requirements
  • USB Type-C cable

  • two MCIMX93AUTO-EVK boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J17 pin 16                          SCL         J17 pin 16
SDA         J17 pin 18                          SDA         J17 pin 18
GND         J17 pin 29                          GND         J17 pin 29
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
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW2 to power on the board.

  2. Connect a USB Type-C cable between the host PC and the J26 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
MCIMX93-EVK
Hardware requirements
  • USB Type-C cable

  • two MCIMX93-EVK boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J1005 pin 3                         SCL         J1005 pin 3
SDA         J1005 pin 5                         SDA         J1005 pin 5
GND         J1005 pin 7                         GND         J1005 pin 7
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
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW301 to power on the board.

  2. Connect a USB Type-C cable between the host PC and the J1401 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
MCIMX93W-EVK
Hardware requirements
  • USB Type-C cable

  • two MCIMX93W-EVK boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J1005 pin 3                         SCL         J1005 pin 3
SDA         J1005 pin 5                         SDA         J1005 pin 5
GND         J1005 pin 7                         GND         J1005 pin 7
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
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW301 to power on the board.

  2. Connect a USB Type-C cable between the host PC and the J1401 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
MCIMX93-QSB
Hardware requirements
  • USB Type-C cable

  • two MCIMX93-QSB boards

  • J-Link Debug Probe

  • 12V~20V power supply

  • Personal Computer

Board settings

Connection as below:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J1406 pin 3                         SCL         J1406 pin 3
SDA         J1406 pin 5                         SDA         J1406 pin 5
GND         J1406 pin 7                         GND         J1406 pin 7

Please note this application can’t support running with Linux BSP!

Prepare the Demo
  1. Connect 12V~20V power supply and J-Link Debug Probe to the board, switch SW301 to power on the board.

  2. Connect a USB Type-C cable between the host PC and the J1708 USB port on the target board.

  3. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  4. Download the program to the target board.

  5. Either re-power up your board or launch the debugger in your IDE to begin running the example

Running the demo

When the example runs successfully, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f

End of LPI2C example .
MCX-N5XX-EVK
Overview

The lpi2c_interrupt_b2b_transfer_slave example shows how to use lpi2c driver as slave to do board to board transfer with interrupt:

In this example, one lpi2c instance as slave and another lpi2c instance on the other board as master. Master sends a piece of data to slave, and receive a piece of data from slave. This example checks if the data received from slave is correct.

Toolchain supported
  • IAR embedded Workbench 9.30.1

  • MCUXpresso 11.6.0

Hardware requirements
  • Mini/micro USB cable

  • MCX-N9xx-EVK board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C2)                connect to        SLAVE(LPI2C2)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect the micro and mini USB cable between the PC host and the USB ports on the board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
MCX-N9XX-EVK
Overview

The lpi2c_interrupt_b2b_transfer_slave example shows how to use lpi2c driver as slave to do board to board transfer with interrupt:

In this example, one lpi2c instance as slave and another lpi2c instance on the other board as master. Master sends a piece of data to slave, and receive a piece of data from slave. This example checks if the data received from slave is correct.

Toolchain supported
  • IAR embedded Workbench 9.30.1

  • MCUXpresso 11.6.0

Hardware requirements
  • Mini/micro USB cable

  • MCX-N9xx-EVK board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C2)                connect to        SLAVE(LPI2C2)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect the micro and mini USB cable between the PC host and the USB ports on the board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
MCX-W72-EVK
Hardware requirements
  • Type-C USB cable

  • MCX-W72-EVK Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J2 pin 3                            SDA         J2 pin 3
SCL         J2 pin 1                            SCL         J2 pin 1

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB cable between the host PC and the EVK board J14.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
MIMXRT700-EVK
Hardware requirements
  • Micro USB cable

  • Target microcontroller board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C8)                connect to        SLAVE(LPI2C8)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J11 pin 5                           SCL         J11 pin 5
SDA         J11 pin 6                           SDA         J11 pin 6
GND         J11 pin 8                           GND         J11 pin 8

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect the micro and mini USB cable between the PC host and the USB ports on the board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXE31B
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXE31B board

  • Personal Computer

Board settings
MASTER(LPI2C_1)                connect to        SLAVE(LPI2C_1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXE32B
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXE32B board

  • Personal Computer

Board settings
MASTER(LPI2C_1)                connect to        SLAVE(LPI2C_1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXL255
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXL255 board

  • Personal Computer

Board settings

LPI2C:

CM33

            MASTEE(I2C0)    connect to  SLAVE(I2C0)
Pin Name    Board Location  Pin Name    Board Location
LPI2C0_SCL  J5-5            LPI2C0_SCL  J5-5
LPI2C0_SDA  J5-6            LPI2C0_SDA  J5-6
GND         J5-8            GND         J5-8

CM0PLUS:

MASTER(AON__I2C0)   connect to      SLAVE(AON__I2C0)
Pin Name            Board Location  Pin Name            Board Location
AON__I2C0_SCL       J2-9            AON__I2C0_SCL       J2-9
AON__I2C0_SDA       J2-7            AON__I2C0_SDA       J2-7
GND                 J2-14           GND                 J2-14

Make sure you have solder bridges SJ1 and SJ2 set to

  • 2-1 for the main core (cm33)

  • 2-3 for AON core (cm0+)

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port (J16) on the target board.

  2. Open a serial terminal with the following settings:

    • 115200 baud rate

    • 8 data bits

    • No parity

    • One stop bit

    • No flow control

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXA174
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA174 board

  • Personal Computer

Board settings
MASTER(LPI2C0)                connect to        SLAVE(LPI2C0)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXA344
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA344 board

  • Personal Computer

Board settings
MASTER(LPI2C0)                connect to        SLAVE(LPI2C0)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
KW47-LOC
Hardware requirements
  • Type-C USB cable

  • KW47-LOC Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 5                            SCL         J2 pin 5
SDA         J2 pin 6                            SDA         J2 pin 6

Short the JP24-2 and JP24-3 with the jumper, other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB cable between the host PC and the LOC board J3.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
MCXW72-LOC
Hardware requirements
  • Type-C USB cable

  • MCXW72-LOC Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 5                            SCL         J2 pin 5
SDA         J2 pin 6                            SDA         J2 pin 6

Short the JP24-2 and JP24-3 with the jumper, other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB cable between the host PC and the LOC board J3.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-IMXRT1186
Hardware requirements
  • Type-C USB cable

  • Two FRDM-IMXRT1186 boards

  • Personal Computer

Board settings

Change Jumper J31 from 1-2 to 2-3, Jumper J35 from 1-2 to 2-3. LPI2C one board:

  • Transfer data from MASTER_BOARD to SLAVE_BOARD of LPI2C interface, LPI2C3 pins of MASTER_BOARD are connected with LPI2C3 pins of SLAVE_BOARD

MASTER_BOARD        CONNECTS TO         SLAVE_BOARD
Pin Name     Board Location     Pin Name     Board Location
LPI2C3_SCL   J51-12             LPI2C3_SCL   J51-12
LPI2C3_SDA   J51-10             LPI2C3_SDA   J51-10
GND          J51-1              GND          J51-1
Prepare the Demo
  1. Connect a mini USB cable between the PC host and the OpenSDA USB port on the board.

  2. Open a serial terminal with the following settings:

  • 115200 baud rate

  • 8 data bits

  • No parity

  • One stop bit

  • No flow control

  1. Download the program to the target board.

  2. 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, the following message is displayed in the terminal:

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7  
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f  
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17  
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f  


End of LPI2C example .
FRDM-MCXA266
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA266 board

  • Personal Computer

Board settings
MASTER(LPI2C2)                connect to        SLAVE(LPI2C2)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXA366
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA366 board

  • Personal Computer

Board settings
MASTER(LPI2C2)                connect to        SLAVE(LPI2C2)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXA577
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA577 board

  • Personal Computer

Board settings
MASTER(LPI2C0)                connect to        SLAVE(LPI2C0)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXC162
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXC162 board

  • Personal Computer

Board settings
MASTER(LPI2C0)                connect to        SLAVE(LPI2C0)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-KW43
Hardware requirements
  • Type-C USB cable

  • FRDM-KW43 Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J24 pin 5                           SDA         J24 pin 5
SCL         J24 pin 6                           SCL         J24 pin 6

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB cable between the host PC and the FRDM board J28.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXW70
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXW70 Board

  • Personal Computer

Board settings

To make the example work, connections needed to be as follows: Jumper setting:

MASTER(LPI2C1)                connect to        SLAVE(LPI2C1)
Pin Name    Board Location                      Pin Name    Board Location
SDA         J24 pin 5                           SDA         J24 pin 5
SCL         J24 pin 6                           SCL         J24 pin 6

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB cable between the host PC and the FRDM board J28.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .
FRDM-MCXA287
Hardware requirements
  • Type-C USB cable

  • FRDM-MCXA287 board

  • Personal Computer

Board settings
MASTER(LPI2C0)                connect to        SLAVE(LPI2C0)
Pin Name    Board Location                      Pin Name    Board Location
SCL         J2 pin 20                           SCL         J2 pin 20
SDA         J2 pin 18                           SDA         J2 pin 18
GND         J2 pin 14                           GND         J2 pin 14

Other jumpers keep default configuration.

Prepare the Demo
  1. Connect a USB Type-C cable between the host PC and the MCU-Link USB port on the target board.

  2. 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

  3. Download the program to the target board.

  4. 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.

LPI2C board2board interrupt example -- Slave transfer.

Slave received data :
0x 0  0x 1  0x 2  0x 3  0x 4  0x 5  0x 6  0x 7
0x 8  0x 9  0x a  0x b  0x c  0x d  0x e  0x f
0x10  0x11  0x12  0x13  0x14  0x15  0x16  0x17
0x18  0x19  0x1a  0x1b  0x1c  0x1d  0x1e  0x1f


End of LPI2C example .