James Nagendran
/
AT42QT1010_Hello_world
Example Hello World example for interfacing the AT42QT1010 Device
Revision 0:3009c861d060, committed 2014-10-20
- Comitter:
- jnagendran3
- Date:
- Mon Oct 20 13:14:18 2014 +0000
- Child:
- 1:6f970f5a63d4
- Commit message:
- Initial Example
Changed in this revision
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/AT42QT1010.lib Mon Oct 20 13:14:18 2014 +0000 @@ -0,0 +1,1 @@ +http://developer.mbed.org/users/jnagendran3/code/AT42QT1010/#7eca199a5506
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Mon Oct 20 13:14:18 2014 +0000 @@ -0,0 +1,20 @@ +#include "mbed.h" +#include "AT42QT1010.h" + +DigitalOut read_led(LED1); +DigitalOut auto_led(LED2); +DigitalOut interrupt_led(LED3); +AT42QT1010 touch_sensor(p21,p23); + +void interrupt(){ + interrupt_led=!interrupt_led; +} + +int main() { + touch_sensor.attach(&interrupt); + while(1) { + read_led = touch_sensor.read(); + auto_led = touch_sensor; + touch_sensor.write(auto_led); + } +}
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Mon Oct 20 13:14:18 2014 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/552587b429a1 \ No newline at end of file