Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
Fork of Flame_Sensor by
Revision 0:4a9b01e7359c, committed 2017-02-23
- Comitter:
- mspeed93
- Date:
- Thu Feb 23 00:07:15 2017 +0000
- Commit message:
- flame sensor currently detecting presence of IR light from a fire. effective distance still needing to be evaluated and then adjusted for optimal results
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 4a9b01e7359c main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Thu Feb 23 00:07:15 2017 +0000 @@ -0,0 +1,13 @@ +#include "mbed.h" + +DigitalOut myled(LED1); +DigitalIn Flame(p5); + +int main() { + while(1) { + if (Flame == 0){ //flame sensor outputs a voltage 0 when IR light is detected + myled = 1;} + else if (Flame == 1){ //No IR light detected input voltage = 1 + myled = 0;} + } +}
diff -r 000000000000 -r 4a9b01e7359c mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Thu Feb 23 00:07:15 2017 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/ef9c61f8c49f \ No newline at end of file