How to start with SDK v.2.0 for LPC5411x using LPCXpresso IDE

Document created by soledad Employee on Nov 7, 2016Last modified by soledad Employee on Nov 18, 2016
Version 3Show Document
  • View in full screen mode

How to start with SDK v.2.0 for LPC5411x using LPCXpresso IDE

 

This document gives an overview of SDK v.2.0 for LPC5411x and also describes the steps required to build, run, and debug an example application provided in the SDK using LPCXpresso IDE. The steps described in the document are for the LPCXpresso54114 board (OM13089).

 

SDK for LPC5411x Derivatives Overview

 

The Software Development Kit (SDK) provides comprehensive software support for Microcontrollers. The SDK includes a flexible set of peripheral drivers designed to speed up and simplify development of embedded applications.

Along with the peripheral drivers, the SDK provides an extensive and rich set of example applications covering everything from basic peripheral use case examples to full demo applications. The SDK also contains RTOS kernels and various other middleware to support rapid development on devices.

SDK board support provides example applications for development and evaluation boards. Board support packages are found inside of the top level boards folder, and each supported board has its own folder (a SDK package can support multiple boards). Within each <board_name> folder there are various sub-folders to classify the type of examples they contain. These include (but are not limited to):

  • demo_apps: Full-featured applications intended to highlight key functionality and use cases of the target MCU. These applications typically use multiple MCU peripherals and may leverage stacks and middleware.
  • driver_examples: Simple applications intended to concisely illustrate how to use the SDK’s peripheral drivers for a single use case. These applications typically only use a single peripheral, but there are cases where multiple are used (for example, ADC conversion using DMA).
  • rtos_examples: Basic FreeRTOS examples showcasing the use of various RTOS objects (semaphores, queues, and so on) and interfacing with the SDK’s RTOS drivers
  • multicore_examples: Applications for both cores showing the usage of multicore software components and the interaction between cores.

 

Build, run and debug a SDK example

 

This section describes the steps required to configure LPCXpresso IDE to build, run, and debug an example application. The hello_world demo application targeted for the LPCXpresso54114 is used as an example, though these steps can be applied to any example application in the SDK.

 

 

1. Download and install the latest LPCXpresso version from the next link:

http://www.nxp.com/products/software-and-tools/software-development-tools/software-tools/lpc-microcontroller-utilities/lpcxpresso-ide-v8.2.2:LPCXPRESSO

 

2. Follow the steps describe here to download the Software Development Kit (SDK) v2.0 for LPCXpresso54114:

Generating a downloadable MCUXpresso SDK v.2 package 

 

3. Select "File -> Import" from the LPCXpresso IDE menu. In the window that appears, expand the "General" folder and select "Existing Projects into Workspace". Then, click the "Next" button.

 

   

 

4. Click the "Browse" button next to the "Import from file:" option, and point to the example application project, which can be found using this path:

<install_dir>/boards/<board_name>/<example_type>/<application_name>/lpcx/cm4

For this example, the specific location is:

<install_dir_SDK_2.0_LPCXpresso54114>\boards\lpcxpresso54114\demo_apps\hello_world\lpcx\cm4

Then Click the "Finish" button.

 

 

5. There are two project configurations (build targets) supported for each SDK project:

Debug – Compiler optimization is set to low, and debug information is generated for the executable. This target should be selected for development and debug.

Release – Compiler optimization is set to high, and debug information is not generated. This target should be selected for final application deployment.

So it is necessary to choose the appropriate build target. For this example, select the "Debug" target.

 

6. Build the project using the hammer icon.

 

7. Connect the development platform to your PC via USB cable between the Link2 USB connector (named Link for some boards) and the PC USB connector. If connecting for the first time, allow some seconds for the devices to enumerate.

 

8. In the Windows operating system environment, open the terminal application on the PC and connect to the debug serial port number. For this example it is used Tera Term.

 

Configure the terminal with these settings:

115200

No parity

8 data bits

1 stop bit

  

 

9. In LPCXpresso IDE, click on “Debug Configurations”. In the Debug Configurations dialog box, select the debug configuration that corresponds to the hardware platform you’re using. In this example, select is the CMSIS-DAP option under C/C++ (NXP Semiconductors) MCU Application.

 

10. After selecting the debugger interface, click the "Debug" button to launch the debugger.

 

11. Additional dialog windows may appear to select LPC-INK2 CMSIS-DAP emulator and core in case of multicore derivatives. Select it and click the "OK" button. Then select the Cortex-M4. The application is downloaded to the target and automatically run to main():

  

 

 

12. Start the application by clicking the "Resume" button. The hello_world application is now running and a banner is displayed on the terminal.

 

Enjoy!!

 

 

Related links:

Introducing MCUXpresso SDK v.2 for LPC54xxx Series 

Generating a downloadable MCUXpresso SDK v.2 package 

MCUXpresso Config Tools is now available!  

Attachments

    Outcomes