|
upm
0.4.1
Sensor/Actuator repository for libmraa (v0.8.0)
|
API for the Grove Relay. More...
UPM module for the Grove relay switch. Grove relay is a digital normally-open switch that uses low voltage or current to control a higher voltage and/or higher current. When closed, the indicator LED lights up and current is allowed to flow.
Public Member Functions | |
| synchronized void | delete () |
| GroveRelay (long pin) | |
| int | on () |
| int | off () |
| boolean | isOn () |
| boolean | isOff () |
Public Member Functions inherited from Grove | |
| synchronized void | delete () |
| String | name () |
| GroveRelay | ( | long | pin | ) |
Grove relay constructor
| gpio | Pin to use |
| boolean isOff | ( | ) |
Defines whether the relay switch is open.
| boolean isOn | ( | ) |
Defines whether the relay switch is closed.
| int off | ( | ) |
Sets the relay switch to off (open). This stops current from flowing and the indicator LED is not lit.
| int on | ( | ) |
Sets the relay switch to on (closed). This allows current to flow and lights up the indicator LED.


1.8.9.1