We strongly encourage users to use Package manager for sharing their code on Libstock website, because it boosts your efficiency and leaves the end user with no room for error. [more info]
Rating:
Author: MIKROE
Last Updated: 2019-06-05
Package Version: 1.0.0.0
mikroSDK Library: 1.0.0.0
Category: Capacitive
Downloaded: 3582 times
Not followed.
License: MIT license
CAP Wheel Click is a capacitive touch sensor with round shaped electrodes integrated on a click board.
Do you want to subscribe in order to receive notifications regarding "CAP Wheel click" changes.
Do you want to unsubscribe in order to stop receiving notifications regarding "CAP Wheel click" changes.
Do you want to report abuse regarding "CAP Wheel click".
Library Description
Library performs the control of the CAP Wheel click board and allows to set all necessary configurations which include number of activated channels, threshold values for touch for each channel and for proximity, and etc. Also can read data from capacitance wheel and represent that value on LEDs. For more details check documentation.
Key functions:
uint8_t capwheel_writeReg( uint8_t register_address, uint8_t *dataIn, uint8_t nBytes )
- Function writes the determined number of bytes to the register.void capwheel_getData( uint16_t *wheelData )
- Function reads data from wheel 1 and stores this value in memory via output parameter.void capwheel_setOutput( uint16_t inputData, uint8_t outputMode )
- Function sets output LEDs depending on the input wheel data value in the way which is determined with the ouputMode parameter.Examples description
The application is composed of three sections :
void applicationTask()
{
readyCheck = capwheel_checkDataReady();
if (readyCheck == _CAPWHEEL_DATA_READY)
{
capwheel_getData( &senseData );
capwheel_setOutput( senseData, _CAPWHEEL_LED_BRIGHTNESS_NUMBER );
}
}
Other mikroE Libraries used in the example:
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.