SLAAEU1 August   2025 MSPM0L1306 , MSPM0L1306

 

  1.   1
  2.   Abstract
  3.   Trademarks
  4. 1Introduction
  5. 2Hardware Connection
  6. 3LaunchPad Setup
  7. 4Software Structure
  8. 5Design Considerations
    1. 5.1 IO Selection Consideration
    2. 5.2 Y-axis and X-axis Measurement Method
    3. 5.3 Touch Detection Method
  9. 6Evaluation Steps
  10. 7Summary
  11. 8References

Y-axis and X-axis Measurement Method

The touch detection method is shown in Figure 5-1. When there is human touch, the detection method connects the resistive layers to the top and bottom.

 Measurement Setup Figure 5-1 Measurement Setup

For the X-axis detection, set PA17 to output high and PA15 to output low. Set other pins to be analog functions (Hiz mode). Then, enable the ADC channel at PA16 to do the measurement.

For the Y-axis detection, set PA16 and PA24 to output high and PA25 and PA21 to output low. Set other pins to be analog functions (Hiz mode). Then, enable the ADC channel at PA15 to do the measurement.

After getting the voltage, the ADC does an oversampling to reduce the noise and directly use the ADC result as the coordinate and output to UART communication.