Lab 1: Create the Application

Step 6: With MHC, Configure Debug System Service, Console System Service, and USB Driver as CDC USB, and USB Pins

1

Add the Debug system service from the Available Components window under Harmony > System Services > DEBUG.

lab1_step6_01a.png
Figure 1: Add Debug System Service

The Device Used field will be auto-populated when connected to Console System Service.

lab1_step6_01b.png
Figure 2: Debug System Service Configuration Options

2

Attach the Console System Service to the Debug module.

Right-click on the red diamond next to the DEBUG component. From the Satisfiers list, select CONSOLE (sys_console).

lab1_step6_02a.png
Figure 3: Connect Debug with Console System Service
lab1_step6_02b.png
Figure 4: SYS_CONSOLE Options

3

Connect CONSOLE with USB CDC module.

Right-click on the diamond next to USB_DEVICE_CDC. From the Satisfiers list, select CDC function Driver (usb_device_cdc).

lab1_step6_03a.png
Figure 5: Satisfy Console Component

Select Yes to agree with USB Device Layer auto-activation.

lab1_step6_03b.png
Figure 6: USB Device Layer Auto-Activation

Select Yes to auto-activate the USB Full Speed Driver component.

lab1_step6_03c.png
Figure 7: USB Full Speed Driver Auto-Activation

Note: A USB Device Layer and a USB Full Speed Driver are now part of the project.

lab1_step6_03d.png
Figure 8: Project Graph Overview

Select and configure the USB Device Layer component as follows.

  • Product ID Selection: cdc_com_port_single_demo
lab1_step6_03e.png
Figure 9: USB Device Layer Options

Note: USB Device pins are configured automatically. You can check under MHC > Tools > Pin Configuration > Pin Settings and look for pin D- (#A63) and pin D+ (#A64).

lab1_step6_03f.png
Figure 10: USB Pins Configuration

This completes the configurations of the Debug System Service, Console System Service, and USB CDC Driver. The application code will use the SYS_DEBUG_MESSAGE() and SYS_DEBUG_PRINT() APIs to print the temperature values over the USB CDC module.



Next Step >

© 2022 Microchip Technology, Inc.
Notice: ARM and Cortex are the registered trademarks of ARM Limited in the EU and other countries.
Information contained on this site regarding device applications and the like is provided only for your convenience and may be superseded by updates. It is your responsibility to ensure that your application meets with your specifications. MICROCHIP MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND WHETHER EXPRESS OR IMPLIED, WRITTEN OR ORAL, STATUTORY OR OTHERWISE, RELATED TO THE INFORMATION, INCLUDING BUT NOT LIMITED TO ITS CONDITION, QUALITY, PERFORMANCE, MERCHANTABILITY OR FITNESS FOR PURPOSE. Microchip disclaims all liability arising from this information and its use. Use of Microchip devices in life support and/or safety applications is entirely at the buyer's risk, and the buyer agrees to defend, indemnify and hold harmless Microchip from any and all damages, claims, suits, or expenses resulting from such use. No licenses are conveyed, implicitly or otherwise, under any Microchip intellectual property rights.