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
- Data Visualizer: Download
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.
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.
- Right-click on the UART icon and select the proper SERCOM from the Satisfiers list.
- The chosen SERCOM appears on the project graph and the connection to the QTouch Library is made.
- 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.
4
Generate and program the board
- Click on the Generate Code icon at the top left corner of the screen to generate the code.
- 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.
- In the main.c file, call the function touch_process to invoke all touch functionalities.
- 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.
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.
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
Advanced Information
Graphical Information
The graphical view provides a graphical representation of the signal, reference, and touch delta.
Lastly, by clicking on the legends, you can select the desired signals to plot.