Battery
Smart HomeMeasures the battery’s voltage, which drops as the battery empties.
How you reach it
Section titled “How you reach it”The Battery class is reached through this attribute of home.
home.battery
Section titled “home.battery”Always there.
All the attributes of home are in its table.
Methods
Section titled “Methods”voltage()
Section titled “voltage()”The battery’s voltage in volts, measured now, to two decimals (through a 20k/10k divider).
voltage() -> floatUsed in examples: Doorbell