4. Running The Demonstration Example

This section describes the steps required to prepare the Pro DevKit and other tools to successfully run an example. The example is based on the freertos_retarget sample code found in the SDK. which prints the character # on a regular basis. To make things more interesting, let’s give some extra functionality to the device making the LED D1 on the Pro DevKit to toggle upon a button event. It also enables the wake-up (WKUP) timer for handling external events. For demonstration purposes, the K1 button on the Pro DevKit has been configured as a wake-up input pin. For more information on the wake-up controller read DA1469x External Interrupt Tutorial

There are two main methods to verify the correct behavior of the demonstrated code. The first method is to use a Serial Terminal and the second is to use the SmartSnippets™ Toolbox.

4.1. Verifying with a Serial Terminal

  1. Establish a connection between the target device and your PC through the USB1 port of the motherboard. This port is used both for powering and communicating to the DA1469x SoC. For this tutorial a Pro DevKit is used.

  2. Import and then make a copy of the freertos_retarget sample code found in the SDK of the DA1469x family of devices.

Note

It is essential to import the folder named python_scripts to perform various operations (including building, debugging, and downloading)

  1. In the target application, add/modify all the required code blocks as illustrated in the Code Overview section.

  1. Build the project either in Debug_QSPI or Release_QSPI mode and burn the generated image to the chip.

  2. Press the RESET button on Pro DevKit to start the chip executing its firmware.

  3. Select your favorite serial console. In this tutorial we have selected Tera Term which is a free and easy-to-use serial terminal. Follow the steps below i to successfully establish a connection via the USB port. If the target device is connected to your PC it should be automatically displayed as an option (2).

'Select the Serial Port to which the Development Kit is Connected'

Figure 15 Select the Serial Port to which the Development Kit is Connected

In the displayed window, select the UART parameters:

'Configure the Serial Port with the Correct Settings'

Figure 16 Configure the Serial Port with the Correct Settings

After successfully setting the serial port you should see the special character ‘#’ displayed on the console.

'The Special Character '#' is Displayed on the Screen'

Figure 17 The Special Character ‘#’ is Displayed on the Screen

  1. Press and release the K1 button on Pro DevKit. LED D1 on Pro DevKit should be turned on. For as long as LED D1 is active, the device is not allowed to enter sleep. Press and release the K1 button on Pro DevKit again. LED D1 should be turned off and the device should enter sleep.

4.2. Verifying with SmartSnippets Toolbox

Another useful tool that can be used both for debugging and power measurements is the SmartSnippets™ Toolbox.

  1. With the system up and running, open the SmartSnippets™ Toolbox and execute the following steps:

    1. (Optional) Select New to create a new project (1). In the New Project window, enter a name for the project (2). This step is optional if a project has already been created.

    2. Choose an available project (4).

    3. Choose a communication interface (3) and a port (5).

    4. Select the family of devices to use (6).

    5. Open the selected project (7).

'Opening SmartSnippets Toolbox'

Figure 18 Opening a Project in the SmartSnippets Toolbox

  1. Start power profile monitoring:

    1. Switch to the Power Profiler window (1).

    2. Initialize Power Profiler (2).

    3. Start Power Profiler (3).

'Initializing Power Profiler'

Figure 19 Initializing Power Profiler

The following video shows how to use the Power Profiler part of SmartSnippets™ Toolbox.

Presentation of the SmartSnippets Toolbox

  1. Press the RESET button on Pro Dev Kit to reset the device. It should enter sleep approximately 8 seconds after a Power-on Reset (POR).

'Verifying the Correct Functionality of the Device before and after Entering Sleep'

Figure 20 Verifying the Correct Functionality of the Device before and after Entering Sleep

After the passage of 8 seconds the device should wake up every 200ms (LED D1 is turned off).

'Import 22'

Figure 21 Verifying the Correct Functionality of the Device between Wake-Ups

Press and release the K1 button on Pro DevKit three. Verify the increased power consumption while the device is in active mode (LED D1 on).

'Verifying the Power Dissipation while in Active and Sleep Mode'

Figure 22 Verifying the Power Consumption while in Active and Sleep Mode