Xiaomi Gateway Volume - DzVents 2.4.22 - SwitchSelector - failed  [Solved]

Easy to use, 100% Lua-based event scripting framework.

Moderator: leecollings

Post Reply
szemisun
Posts: 2
Joined: Tuesday 04 June 2019 20:53
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Xiaomi Gateway Volume - DzVents 2.4.22 - SwitchSelector - failed

Post by szemisun »

Hi Guys,

I recently updated dzVents to 2.4.22 from 2.4.21 and my script has been broken and there are exceptions in the following line

Code: Select all

XGVolume.switchSelector(10)
XGDoorBell.switchSelector(10)
XGDoorBell.switchOff().afterSec(5)
XGVolume.switchOff().afterSec(5)

Code: Select all

2019-06-04 20:49:47.023 Status: dzVents: Debug: ElőszobaWirelessButton: Processing device-adapter for Xiaomi Gateway Volume: Switch device adapter
2019-06-04 20:49:47.024 Status: dzVents: Debug: ElőszobaWirelessButton: Processing device-adapter for Xiaomi Gateway Doorbell: Switch device adapter
2019-06-04 20:49:47.024 Status: dzVents: Error (2.4.22): ElőszobaWirelessButton: An error occured when calling event handler ElőszobaWirelessButton
2019-06-04 20:49:47.024 Status: dzVents: Error (2.4.22): ElőszobaWirelessButton: ...moticz/dzVents/runtime/device-adapters/switch_device.lua:117: attempt to get length of field 'levelNames' (a nil value)
I had not found any instruction, what do i need to modify my script to work

Can anybody help me or give guidance?

Best regards,
SzemiSun
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Xiaomi Gateway Volume - DzVents 2.4.22 - SwitchSelector - failed  [Solved]

Post by waaren »

szemisun wrote: Tuesday 04 June 2019 21:03 I recently updated dzVents to 2.4.22 from 2.4.21 and my script has been broken and there are exceptions in the following line

Code: Select all

XGVolume.switchSelector(10)
XGDoorBell.switchSelector(10)
It looks like you use the switchSelector method for a device that is not a selector.
You might want to try

Code: Select all

XGVolume.dimTo(10)
XGDoorBell.dimTo(10)
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
szemisun
Posts: 2
Joined: Tuesday 04 June 2019 20:53
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Xiaomi Gateway Volume - DzVents 2.4.22 - SwitchSelector - failed

Post by szemisun »

You are right, It works, thank You
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest