This section discusses the steps to follow to run
the example for resistive touch detection on the MSPM0L1306 Launchpad.
- Calculate the IOs (Resistance and Pins) needed by
following the instructions in Section 4.1.
- Implement the Hardware Setup between MSPM0L1306
LaunchPad and the resistive touch screen following the instructions in Section 3.
- Install Code Composer Studio™ (CCS) on the computer.
- Import the example given in the link in the Introduction Section: load the resistive_touch_detection or
resisitve_click_drag_detection example.
- The user should add the X and Y axis, Min and Max
values for the touchscreen being used. This maintains that no noise is sent as a
coordinate.
- User should also adjust the
TOUCH_DETECTION_THD and detection frequency according to the
sensitivity and noise of the panel.
- Build the example.
- Create a Target configuration for MSPM0 in CCS,
MSPM0_XDS110.ccxml, select the XDS110 Debug Probe and the MSPM0L1306
Device type.
- Right-click on MSPM0_XDS110.ccxml in Target Configurations window
- Select Launch Selected Configuration
- Select Run, Connect Target
- Select Run, Load, Load Program
- Browse to the binary for the MSPM0 project, and
click OK.
- This writes the flash with the binary.
- After touching the Resistive Touchscreen, the ADC values for the X and Y axis are found and the result is sent through the UART peripheral to the Command line as shown in the Results Section. The coordinates are only updated when there is touch detected on the panel.