On and Off¶
The trait “On and Off” allows you to, well, turn devices on or off (rather easy, isn’t it?).
Fitting device types¶
These device types could be combined well with this trait:
Air Conditioners
Outlets
Switches
Lights
Air Purifiers
Dishwashers
Dryers
Fans
Vacuums
Washers
Action topics¶
The gBridge service publishes either 0
(device should be turned off) or 1
(device should be turned on) when you say a voice command.
Status topics¶
Your application should publish the current device state to the status topic everytime the device is turned on or off. Data from the status topic is cached and used to response to questions about the device state from Google.
You may publish these values on the status topic:
One of
0
,off
,false
means the device is off.One of
1
,on
,true
means the device is turned on.
These values are case-insensitive.