.
Diff: led.cpp
- Revision:
- 0:324f895054e0
diff -r 000000000000 -r 324f895054e0 led.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/led.cpp Tue Apr 06 08:24:02 2021 +0000 @@ -0,0 +1,17 @@ +#include "led.h" +#include "mbed.h" + +LED::LED(PinName pin) : _pin(pin) +{ + _pin = 0; +} +//metoda određivanja stanja led diode +void LED::stanje(int stanje) +{ + _pin = stanje; +} + //metoda promjena stanja led diode +void LED::promjena() +{ + _pin = !_pin; +} \ No newline at end of file