Step 5: Build, Program and Observe the Output

Last modified by Microchip on 2026/06/29 11:09

Build, Hardware Setup and Program

Build the project by clicking the Clean and Build drop-down arrow, then select Clean and Build Main Project

Clean and Build icon menu                                               

At this point, the application is ready to be implemented on the hardware. Check whether the lab builds and programs successfully, and verify the build results in the output dialog box.

Connect the PIC32CM LS00 Curiosity Nano+ Touch Evaluation Kit to the host PC using a USB cable attached to the debug USB port. This provides power to the board and enables debugging through the embedded debugger (nEDBG).

PIC32CM LS00 Curiosity Nano+ Touch Evaluation Kit connected                                                                              

In MPLAB® X IDE, navigate to File > Project Properties, and ensure that PIC32CM LS00 Curiosity Nano+ Touch Evaluation Kit EDBG is chosen as the debugger under Connected Hardware Tool, and XC32 is selected as the Compiler Toolchain for XC32.

Project Properties window            

Program the application to the device by clicking on the Make and Program button as shown in the accompanying image. Check whether the lab builds and programs successfully and verify the build results in the output dialog box.

Make and Program button                                                     


Observe the Output for CPU-Driven Transfer

Now, open the Tera Term terminal application on the PC from the Windows® Start menu by pressing the Start button. Select the Serial Port as shown in the accompanying image.

Tera Term window                                        

Note: If more than one COM port is connected, identify the correct COM port for the PIC32CM LS00 Curiosity Nano+ Touch Evaluation Kit and use it for the serial terminal.

Once the COM port is connected, click on Setup > Serial port. In the Tera Term: Additional settings window that appears, change the baud rate to 115200, as shown in the accompanying image.

Tera Term: Additional settings window                                           

Observe the output displayed on the serial terminal, which indicates the successful CPU memory transfer and shows the number of transfer cycles.

CPU Memory Transfer Demo in Tera Term window


Observe the Output for DMA-Driven Transfer

Observe the output displayed on the serial terminal, which indicates the successful CPU memory transfer and shows the number of transfer cycles.

DMAC Memory Transfer Demo in Tera Term window


Output Comparison for CPU-Driven and DMA-Driven Transfers

This lab evaluates and compares the performance of CPU-driven and DMA-driven projects to demonstrate that DMA-driven transfers significantly improve system efficiency over CPU-driven transfers.

Output Comparison for CPU-Driven and DMA-Driven transfers in Tera Term window

Note: To observe the comparison output in Tera Term, do not clear the output window after running the first project. Run the second project without clearing the window, so that both project outputs can be viewed together in the same terminal for comparison.

Back to Top