Sarah Boyd / Mbed 2 deprecated control_power_out_with_slider

Dependencies:   mbed tsi_sensor

Files at this revision

API Documentation at this revision

Comitter:
sarahboydster
Date:
Mon May 26 00:22:43 2014 +0000
Commit message:
First version.

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
tsi_sensor.lib Show annotated file Show diff for this revision Revisions of this file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Mon May 26 00:22:43 2014 +0000
@@ -0,0 +1,19 @@
+#include "mbed.h"
+#include "tsi_sensor.h"
+
+#define ELEC0 9
+#define ELEC1 10
+
+
+AnalogOut analogOut(PTE30);
+
+int main(void) {
+    PwmOut led(LED_GREEN);
+    TSIAnalogSlider tsi(ELEC0, ELEC1, 40);
+    
+    while (true) {
+        led = 1.0 - tsi.readPercentage();
+        analogOut = tsi.readPercentage();
+        wait(0.1);
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Mon May 26 00:22:43 2014 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/0b3ab51c8877
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tsi_sensor.lib	Mon May 26 00:22:43 2014 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/Kojto/code/tsi_sensor/#20ffa9b18488