| 14 | // which specifies the pin to which the LED is attached. |
| 15 | |
| 16 | DEV_LED(int ledPin) : Service::LightBulb(){ |
| 17 | |
| 18 | power=new Characteristic::On(); // this is where we create the On Characterstic we had previously defined in setup(). Save this in the pointer created above, for use below |
| 19 | this->ledPin=ledPin; // don't forget to store ledPin... |
| 20 | pinMode(ledPin,OUTPUT); // ...and set the mode for ledPin to be an OUTPUT (standard Arduino function) |
| 21 | |
| 22 | } // end constructor |
| 23 | |
| 24 | // Finally, we over-ride the default update() method with instructions that actually turn on/off the LED. Note update() returns type boolean |
| 25 |
nothing calls this directly
no outgoing calls
no test coverage detected