Configure Datastreamer and Visualize Touch Data using Data Visualizer

 Objective

This page provides information on configuring the Data Visualizer option in MPLAB® Harmony based touch projects and visualizing the touch technology data in the Data Visualizer tool.

 Materials

 Procedure

1

Enable Data Visualizer

Ensure the Enable Data-Streamer option is selected in the Debug Option section of the Parameters tab while generating the project in the Harmony Configurator.

enable.PNG

Detailed information on how to generate a touch project using Harmony Configurator can be found on the "Generate a Touch Project with MPLAB® Harmony" page.

2

Choose and configure UART

  • In the Project Graph window, in the QTouch® Library middleware, a new dependency called UART (a yellow icon) is shown.
    uart.PNG
  • Right-click on the UART icon and select the proper SERCOM from the Satisfiers list.
    sercom.PNG
  • The chosen SERCOM appears on the project graph and the connection to the QTouch Library is made.
    sercom-option.PNG
  • Click on the SERCOM module. The configuration options are on the right side. Choose the PADs for the receive and transmit pinout from the schematics.
    pad.PNG

3

Select pin configuration

  • Click on Tools > Pin Configuration to choose the UART pins.
    pin.PNG
  • From the schematics of the board, we know the UART TX and RX pins. Go to the Pin Settings tab and choose the pins for the configured SERCOM.
    choosepin.PNG

4

Generate and program the board

  • Click on the Generate Code icon at the top left corner of the screen to generate the code.
    generate.PNG
  • The project is populated with touch source and header files. The datastreamer source files and script files are found under the datastreamer folder of the project.
    source.PNG
  • In the main.c file, call the function touch_process to invoke all touch functionalities.
    main.PNG
  • Build the project and program the generated HEX file to the device.

5

Open Data Visualizer.

The Xplained Pro Kits support Data Gateway Interface (DGI) and virtual COM Port Interface in order to transmit data from the kits to the Data Visualizer.

In touch projects, debug data is sent through the serial interface (COM Port).

When the kit is connected, the EDBG will be recognized under Serial Port Control Panel title bar.

dv.PNG

6

Select COM Port

In the Serial Port Control Panel:

  • Select the EDBG Virtual COM Port (COMxx) (If multiple Xplained Pro kits are connected, disconnect other Xplained Pro kits to identify correct COM Port).
  • Uncheck the Open Terminal check-box and select Autodetect Protocol.
  • Click on the config search path and choose the datastreamer folder where the script files are located.
  • Click Connect.
connect.PNG

The Data Visualizer tool automatically checks for data on 9600, 19200, 38400, 57600, 115200, 230400, 500000, 1000000 and 2000000 baud rates.

7

Configuration Files

  • Verify whether the DS, DB, SC files are present in the ../touch/datastreamer/ folder. The Data Visualizer prompts you to select the folder containing configuration information if there was no folder selected before.
  • Configuration files are stored as part of the project source files. Browse the ../touch/datastreamer/ project folder and click on Select Folder.
  • The selected folder will be saved by the Data Visualizer. It may be necessary to change this folder location when you want to view data of another/updated project.

8

Dashboard

The dashboard displays basic and advanced information in a tabular/graphical form:

Basic Information

basic.PNG

Advanced Information

advanced.PNG

Graphical Information
The graphical view provides a graphical representation of the signal, reference, and touch delta.

graph.PNG

Lastly, by clicking on the legends, you can select the desired signals to plot.

© 2019 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.