This is the documentation for the latest (main) development branch of mcuxpresso sdk. If you are looking for the documentation of previous releases, use the drop-down menu on the left and select the desired version.

Run a demo application using IAR

This section describes the steps required to build, run, and debug example applications provided in the MCUXpresso SDK.

Note: IAR Embedded Workbench for Arm version is used as an example to show below steps, and the IAR toolchain should correspond to the latest supported version, as described in the MCUXpresso SDK Release Notes for TWR-KM35Z75M (document MCUXSDKKM35Z75MRN).

Build an example application

Perform the following steps to build the hello_world example application.

  1. Open the desired demo application workspace. Most example application workspace files can be located using the following path:

    <install_dir>/boards/<board_name>/<example_type>/<application_name>/iar
    

    Using the TWR-KM35Z75M hardware platform as an example, the hello_world workspace is located in:

    <install_dir>/boards/twrkm35z75m/demo_apps/hello_world/iar/hello_world.eww
    
  2. Select the desired build target from the drop-down menu. For this example, select the hello_world – debug target.

    |

|

  1. To build the demo application, click the Make button highlighted in red below.

    |

|

  1. The build completes without errors.

Parent topic:Run a demo application using IAR

Run an example application

To download and run the application, perform these steps:

  1. See the table in Default debug interfaces to determine the debug interface that comes loaded on your specific hardware platform.

  2. Connect the development platform to your PC via USB cable.

  3. Open the terminal application on the PC, such as PuTTY or TeraTerm, and connect to the debug COM port (to determine the COM port number, see How to determine COM port). Configure the terminal with these settings:

    1. 115200 or 9600 baud rate, depending on your board (reference BOARD_DEBUG_UART_BAUDRATE variable in the board.h file)

    2. No parity

    3. 8 data bits

    4. 1 stop bit

      |

|

  1. In IAR, click the Download and Debug button to download the application to the target.

    |

|

  1. The application is then downloaded to the target and automatically runs to the main() function.

    |

|

  1. Run the code by clicking the Go button.

    |

|

  1. The hello_world application is now running and a banner is displayed on the terminal. If it does not appear, check your terminal settings and connections.

    |

|

Parent topic:Run a demo application using IAR