local device = {} device.model = "modeldevice2" device.vendor = "Legrand" device.description = "Galion UP IOT scene switch" device.zigbeeModel = { "modeldevice2" } device.exposes = { { type = "numeric", name = "battery", property = "battery", access = 1, unit = "%", min = 0, max = 100, description = "Remaining battery in %", category = "diagnostic", }, { type = "enum", name = "action", property = "action", access = 1, description = "Triggered scene action", category = "diagnostic", values = { "scene_1", "scene_2", "scene_3", "scene_4", "scene_5", "scene_6" }, }, } device.fromZigbee = { "battery" } device.configure = { bind = { "genPowerCfg" }, reporting = { { cluster = "genPowerCfg", attribute = "batteryPercentageRemaining", min = 3600, max = 65000, change = 0, }, { cluster = "genPowerCfg", attribute = "batteryVoltage", min = 3600, max = 65000, change = 0, }, }, } return device