calib sensor
Dependencies: mbed
Revision 0:cb4f2b95e2a7, committed 2017-02-18
- Comitter:
- vidica94
- Date:
- Sat Feb 18 18:49:36 2017 +0000
- Commit message:
- calibrazione sensore
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 |
diff -r 000000000000 -r cb4f2b95e2a7 main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Sat Feb 18 18:49:36 2017 +0000 @@ -0,0 +1,22 @@ +#include "mbed.h" + +/* + This basic program could be usefull to calibrate the IR_Sensor + Run the program , bet a dark target with the sensor and roatate the trimmer until the second led on the PCB with the sensor shutdown. + +*/ + +AnalogIn ir(A2); + + +DigitalOut led(LED1); + +int main() +{ + float lettura=0; + while(1) { + lettura=ir.read()*3.00; + printf("lettura = %f\n",lettura ); + + } +}
diff -r 000000000000 -r cb4f2b95e2a7 mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Sat Feb 18 18:49:36 2017 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/ef9c61f8c49f \ No newline at end of file