Plymouth ELEC351 Group T
/
ELEC351_Group_T
FINAL PROJECT isn't it
Fork of ELEC351 by
Diff: LED.cpp
- Revision:
- 51:47f5db68500b
- Parent:
- 5:2594b953f111
- Child:
- 52:99915f5240b2
--- a/LED.cpp Tue Jan 09 12:19:12 2018 +0000 +++ b/LED.cpp Tue Jan 09 15:15:08 2018 +0000 @@ -16,17 +16,17 @@ this->pin =1; //You access the attributes of the class by using the this command and then the name of the attribute } -void LED::switchOff() +void LED::switchOff()//Turns off the LED { this->pin =0; } -void LED::flash(float time) +void LED::flash(float time)//Flashes the LED for the time passed in { this->pin = 1; wait(time); this->pin = 0; } -void LED::Toggle() +void LED::Toggle()//Toggles the current state of the LED { this->pin= !this->pin; } \ No newline at end of file