Program to demo the LTR-303ALS ambient light sensor

Dependencies:   mbed-dev

main.cpp

Committer:
michaelVisimid
Date:
2017-01-27
Revision:
1:a169d660661b
Parent:
0:eb6683a37c0b

File content as of revision 1:a169d660661b:

#include "mbed.h"

DigitalOut myled(LED1);
byte testByte;
int main() {
    while(1) {
        myled = 1; // LED is ON
        wait(0.2); // 200 ms
        myled = 0; // LED is OFF
        wait(1.0); // 1 sec
    }
}