LED

Simple API#

/* Add this line to your main function
* to turn on the LED*/
setLed(pin, ON);
/* Add this line to your main function
* to turn on the LED*/
setLed(pin, OFF);
import commingsoon
var commingsoon = 1;

Advance API#

/* Add this line to your main function
* to turn on the LED*/
setLed(pin, ON);
/* Add this line to your main function
* to turn on the LED*/
setLed(pin, OFF);
import commingsoon
var commingsoon = 1;
Note:

pin - Represents the physical GPIO pin number where the LED is connected.

For Example: To set LED at pin 40 on, use API,

setLed(40, ON);

Facing errors with the component?#