RECAL_100
RECAL_50
RECAL_25
RECAL_12_5
RECAL_6_25
100% recalibration threshold
50% recalibration threshold
25% recalibration threshold
12.5% recalibration threshold
6.25% recalibration threshold
5.6.4 Data structures
This section lists the data structures that hold sensor status, settings, and diagnostics information
5.6.4.1
qt_touch_status_t
Structure
Input / Output
Use
Fields
sensor_states[]
qt_touch_status_t
Output from the Library
Holds the status ( On/ Off ) of the sensors and the linear and angular positions
of sliders and rotors respectively
Comment
For Sensor, the sensor_states. Bit “n” = state of nth sensor :
Bit Value 0 - indicates the sensor is not in detect
Bit Value 1 - indicates the sensor is in detect
rotor_slider_values[]
Rotors angles or slider positions if rotors and sliders are used. These
values are valid when sensor states shows that the corresponding rotor or
slider is in detect
The macro that can get the sensor state when the sensor number is provided can be something
as below:
#define
GET_SENSOR_STATE(SENSOR_NUMBER)
qt_measure_data.qt_touch_status.sensor_states[(SENSOR_NUMBER/8)] &
(1 << (SENSOR_NUMBER % 8))
The host application can use this macro to act accordingly, the following example shows how to
toggle a IO pin (PD2) based on the sensor0 state.( Set PD2 if sensor0 is in detect, and clear PD2
if sensor0 is not in detect)
Ex:
/*Set pin PD2 direction as output*/
DDRD |= (1u << PORTD2);
if (GET_SENSOR_STATE(0) !=0)
{
PORTD |= (1u << PORTD2); /* Set PORTD2 */
}
else {
PORTD &= ~(1u << PORTD2); /* Clear PORTD2 */
}
5.6.4.2
qt_touch_lib_config_data_t
Structure
Input / Output
qt_touch_lib_config_data_t
Input to the library
25
相关PDF资料
ATU6-P305T-R CABLE CAT6 FULL-BOX 305M GRAY
ATUP-P305T-R CABLE CAT5E PULL-BOX 305M GRAY
ATUP-V305T-R CABLE CAT5E REEL 305M GRAY
AWG28-05/F-1/300-R CABLE 5 COND MULTI 300' RIBBON
AWG28-05/G-1/300-R CABLE 5 COND GRAY 300' RIBBON
AWG28-09/F-1/300-R CABLE 9 COND MULTI 300' RIBBON
AWG28-09/G-1/300-R CABLE 9 COND GRAY 300' RIBBON
AWG28-25/F-1/300-R CABLE 25 COND MULTI 300' RIBBON
相关代理商/技术参数
ATQT600IB 功能描述:界面开发工具 ATQT600IB Interface Brd RoHS:否 制造商:Bourns 产品:Evaluation Boards 类型:RS-485 工具用于评估:ADM3485E 接口类型:RS-485 工作电源电压:3.3 V
ATQT6-XPRO 功能描述:Xplained Pro - Extension Board 制造商:atmel 系列:- 零件状态:有效 配件类型:扩展板 配套使用产品/相关产品:Xplained Pro 标准包装:1
ATR 1078 功能描述:TOOL INSERTION TWEEZER 20 GA 制造商:astro tool corp 系列:* 零件状态:有效 标准包装:1
ATR 1079 功能描述:TWEEZER INSERTION 20 GA 制造商:astro tool corp 系列:* 零件状态:有效 标准包装:1
ATR 1080 制造商:Astro Tool Corp 功能描述:TOOL INSERTION 20 GA
ATR 1080-135 功能描述:INSERTION TOOL 20 GA ANGLED TIP 制造商:astro tool corp 系列:* 零件状态:有效 标准包装:1
ATR 1080-S 功能描述:INSERTION TOOL STRAIGHT 制造商:astro tool corp 系列:* 零件状态:有效 标准包装:1
ATR 1105 功能描述:TOOL INSERTION TWEEZER 16 GA 制造商:astro tool corp 系列:* 零件状态:有效 标准包装:1