Peripheral Capacitive Sensing SubSubSystem[edit]
This page describes how to use the Capacitive Sensing API to interface with the Capacitive Sensing driver on a Wireless Network Processor.
Capacitive Sensing API over NPI[edit]
Following is a subset of the available APIs, just to give an idea of how the subsystem is used.
From Host[edit]
HalCapSenseControlStat(uint8 statOnOff) - AREQ
|
Byte 0 - 1
|
Byte 2
|
Byte 3
|
Byte 4
|
Byte 5
|
Length
|
Type / Sub-System
|
Peripheral Sub-Sub-System
|
Command ID
|
Parameters
|
0x00
|
0x50
|
0x01
|
0x01
|
Turn on Statistics TRUE:0x01 FALSE:0x00
|
|
HalCapSenseSetThreshold(uint8 length, uint8 *thresholds) - AREQ
|
Byte 0 - 1
|
Byte 2
|
Byte 3
|
Byte 4
|
Byte 5
|
Byte 6 - (length + 6)
|
Length
|
Type / Sub-System
|
Peripheral Sub-Sub-System
|
Command ID
|
Parameters
|
0x00
|
0x50
|
0x01
|
0x02
|
length
|
*thresholds
|
|
HalCapSenseSetStuckKeyDetectionThresholds(uint8 length, uint8 *thresholds) - AREQ
|
Byte 0 - 1
|
Byte 2
|
Byte 3
|
Byte 4
|
Byte 5
|
Byte 6 - (length + 6)
|
Length
|
Type / Sub-System
|
Peripheral Sub-Sub-System
|
Command ID
|
Parameters
|
0x00
|
0x50
|
0x01
|
0x02
|
length
|
*thresholds
|
|
From Network Processor[edit]
CapSenseButtonPressedInd(uint16 buttonBitMap) - AREQ
|
Byte 0 - 1
|
Byte 2
|
Byte 3
|
Byte 4
|
Byte 5-6
|
Length
|
Type / Sub-System
|
Peripheral Sub-Sub-System
|
Command ID
|
Parameters
|
0x00
|
0x50
|
0x01
|
0x01
|
buttonBitMap
|
|
CapSenseRawDataInd(uint8 btnId, uint16 value, uint16 mean, uint16 detectionOffset) - AREQ
|
Byte 0 - 1
|
Byte 2
|
Byte 3
|
Byte 4
|
Byte 5
|
Byte 6 - 7
|
Byte 8 - 9
|
Byte 10 - 11
|
Length
|
Type / Sub-System
|
Peripheral Sub-Sub-System
|
Command ID
|
Parameters
|
0x00
|
0x50
|
0x01
|
0x02
|
btnId
|
value
|
mean
|
detectionOffset
|
|
CapSenseRawDataInd32(uint8 btnId, int value, int mean, int detectionOffset) - AREQ
|
Byte 0 - 1
|
Byte 2
|
Byte 3
|
Byte 4
|
Byte 5
|
Byte 6 - 9
|
Byte 10 - 13
|
Byte 14 - 17
|
Length
|
Type / Sub-System
|
Peripheral Sub-Sub-System
|
Command ID
|
Parameters
|
0x00
|
0x50
|
0x01
|
0x02
|
btnId
|
value
|
mean
|
detectionOffset
|
|