Relay
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*/setRelay(pin, ON);
/* Add this line to your main function * to turn on the LED*/setRelay(pin, OFF);
import commingsoon
var commingsoon = 1;
Note:
pin
- Represents the physical GPIO pin number where the Relay is connected.
For Example: To set Relay at pin 40 on, use API,
setRelay(40, ON);