11.07.2015 Views

Atmel QTouch Library User Guide

Atmel QTouch Library User Guide

Atmel QTouch Library User Guide

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

QMatrix method API Flow for UC3LFor the QMatrix operation, the CAT_CLK and GCLK_CAT clocks must be setup appropriately asa first step. The QMatrix and Common configuration parameters in the touch_config_at32uc3l.hconfiguration must then be set up.Using the init_clock() in main.c and clock.c files,Set the CAT_CLK Clock to appropriate value.Set the GCLK_CAT Clock to appropriate value.Using the touch_config_at32uc3l.h configuration file,Set DEF_TOUCH_QMATRIX = 1.Set all QM_xx and TOUCH_xx macros to appropriate values.(This includes 2 peripheral DMA Channels required for QMatrix operation.)In the main.c file,Set appropriate qm_burst_length[] values corresponding to all Touch channels .Set the desired measurement_period_ms for Touch measurement.touch_qm_sensors_init()Configure multipleQMatrix sensorstouch_qm_sensors_config()touch_qm_sensors_calibrate()Call in looptouch_event_dispatcher()filter_callback(), if enabledtime_to_measure_touchtouch_qm_sensors_start_acquisition(NORMAL_ACQ_MODE)measure_complete_callback(),measured data and Touch StatusHost Application code123

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!