Hardware requirements

  • Mini USB cable

  • TWR-KM34Z50MV3 board

  • Personal Computer

Board settings

No special settings are required.

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

  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

When the demo runs successfully, similar message will be displayed in the terminal:

I2C example – Read Accelerometer Value Found MMA8491 on board, the device address is 0x55. The accel values: status_reg = 0xf , x = -26 , y = 29 , z = 1036 status_reg = 0xf , x = -7 , y = -6 , z = 1017 status_reg = 0xf , x = -4 , y = 43 , z = 1031 status_reg = 0xf , x = -22 , y = 33 , z = 1035 status_reg = 0xf , x = -18 , y = 35 , z = 1020 status_reg = 0xf , x = 2 , y = 11 , z = 1029 status_reg = 0xf , x = -10 , y = 34 , z = 1029 status_reg = 0xf , x = 1 , y = 15 , z = 1016 status_reg = 0xf , x = -8 , y = 41 , z = 1041 status_reg = 0xf , x = -21 , y = 20 , z = 1045

End of I2C example .