mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-21 16:18:29 -04:00
AP_Relay: added enabled() API
This commit is contained in:
parent
e3804e2846
commit
4aa901f203
@ -32,6 +32,9 @@ public:
|
||||
// de-activate the relay
|
||||
void off(uint8_t relay);
|
||||
|
||||
// see if the relay is enabled
|
||||
bool enabled(uint8_t relay) { return relay < AP_RELAY_NUM_RELAYS && _pin[relay] != -1; }
|
||||
|
||||
// toggle the relay status
|
||||
void toggle(uint8_t relay);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user