jec6613 Posted April 21, 2022 Posted April 21, 2022 First, this is what I get when I put in the configuration information. I've sanitized MAC and IP, obviously 022-04-21 14:11:30,003 MainThread udi_interface INFO __init__:<module>: UDI Python Interface for Polyglot version 3 3.0.40 Starting... 2022-04-21 14:11:30,255 MainThread udi_interface.interface INFO interface:__init__: Initialization received from Polyglot V3 3.0.56 [ISY: 5.3.0, Slot: 4] 2022-04-21 14:11:30,257 MainThread udi_interface.interface INFO interface:__init__: Connect: Network Interface: {'addr': '192.168.xx.xx', 'netmask': '255.255.255.0', 'broadcast': '192.168.20.255'} 2022-04-21 14:11:30,259 Interface udi_interface.interface INFO interface:_startMqtt: Connecting to MQTT... localhost:1888 2022-04-21 14:11:30,268 MainThread udi_interface.interface WARNING interface:db_getNodeDrivers: controller not found in database. 2022-04-21 14:11:30,269 MainThread udi_interface.interface WARNING interface:send: MQTT Send waiting on connection :: {'config': {'version': '3.1.6'}} 2022-04-21 14:11:30,316 MQTT udi_interface.interface INFO interface:_connect: MQTT Connected with result code 0 (Success) 2022-04-21 14:11:30,318 MQTT udi_interface.interface INFO interface:_connect: MQTT Subscribing to topic: udi/pg3/ns/clients/00:0d:b9:52:bf:7c_4 - MID: 1 Result: 0 2022-04-21 14:11:30,334 MQTT udi_interface.interface INFO interface:_subscribe: MQTT Subscribed Succesfully for Message ID: 1 - QoS: (0,) 2022-04-21 14:11:33,284 MainThread udi_interface.interface INFO interface:addNode: Adding node DysonFan(controller) [None] 2022-04-21 14:11:34,918 Thread-4 udi_interface ERROR dysonfan:dysonConnect: Error connecting to 192.168.xx.xx, 'NoneType' object has no attribute 'connect' 2022-04-21 14:11:34,920 Thread-4 udi_interface ERROR udi_interface:write: Exception in thread 2022-04-21 14:11:34,921 Thread-4 udi_interface ERROR udi_interface:write: Thread-4 2022-04-21 14:11:34,921 Thread-4 udi_interface ERROR udi_interface:write: : 2022-04-21 14:11:34,922 Thread-4 udi_interface ERROR udi_interface:write: Traceback (most recent call last): 2022-04-21 14:11:34,923 Thread-4 udi_interface ERROR udi_interface:write: File "/usr/local/lib/python3.8/threading.py", line 932, in _bootstrap_inner 2022-04-21 14:11:34,927 Thread-4 udi_interface ERROR udi_interface:write: self.run() 2022-04-21 14:11:34,928 Thread-4 udi_interface ERROR udi_interface:write: File "/usr/local/lib/python3.8/threading.py", line 870, in run 2022-04-21 14:11:34,932 Thread-4 udi_interface ERROR udi_interface:write: self._target(*self._args, **self._kwargs) 2022-04-21 14:11:34,933 Thread-4 udi_interface ERROR udi_interface:write: File "/var/polyglot/pg3/ns/00:0d:b9:52:bf:7c_4/nodes/dysonfan.py", line 71, in start 2022-04-21 14:11:34,934 Thread-4 udi_interface ERROR udi_interface:write: self.dysonConnect() 2022-04-21 14:11:34,935 Thread-4 udi_interface ERROR udi_interface:write: File "/var/polyglot/pg3/ns/xx:xx:xx:xx:xx:xx_4/nodes/dysonfan.py", line 98, in dysonConnect 2022-04-21 14:11:34,936 Thread-4 udi_interface ERROR udi_interface:write: LOGGER.debug(f"Auto Mode is {self.dysonData.auto_mode}, Night Mode is {self.dysonData.night_mode}") 2022-04-21 14:11:34,937 Thread-4 udi_interface ERROR udi_interface:write: AttributeError 2022-04-21 14:11:34,938 Thread-4 udi_interface ERROR udi_interface:write: : 2022-04-21 14:11:34,938 Thread-4 udi_interface ERROR udi_interface:write: 'NoneType' object has no attribute 'auto_mode' 2022-04-21 14:11:57,798 Thread-5 udi_interface ERROR dysonfan:dysonConnect: Error connecting to 192.168.xx.xx, 'NoneType' object has no attribute 'connect' 2022-04-21 14:11:57,800 Thread-5 udi_interface ERROR udi_interface:write: Exception in thread 2022-04-21 14:11:57,801 Thread-5 udi_interface ERROR udi_interface:write: Thread-5 2022-04-21 14:11:57,801 Thread-5 udi_interface ERROR udi_interface:write: : 2022-04-21 14:11:57,802 Thread-5 udi_interface ERROR udi_interface:write: Traceback (most recent call last): 2022-04-21 14:11:57,803 Thread-5 udi_interface ERROR udi_interface:write: File "/var/polyglot/pg3/ns/xx:xx:xx:xx:xx:xx_4/nodes/dysonfan.py", line 106, in poll 2022-04-21 14:11:57,805 Thread-5 udi_interface ERROR udi_interface:write: if self.dysonData.is_connected is False: 2022-04-21 14:11:57,806 Thread-5 udi_interface ERROR udi_interface:write: AttributeError 2022-04-21 14:11:57,806 Thread-5 udi_interface ERROR udi_interface:write: : 2022-04-21 14:11:57,807 Thread-5 udi_interface ERROR udi_interface:write: 'NoneType' object has no attribute 'is_connected' 2022-04-21 14:11:57,808 Thread-5 udi_interface ERROR udi_interface:write: During handling of the above exception, another exception occurred: 2022-04-21 14:11:57,808 Thread-5 udi_interface ERROR udi_interface:write: Traceback (most recent call last): 2022-04-21 14:11:57,809 Thread-5 udi_interface ERROR udi_interface:write: File "/usr/local/lib/python3.8/threading.py", line 932, in _bootstrap_inner 2022-04-21 14:11:57,813 Thread-5 udi_interface ERROR udi_interface:write: self.run() 2022-04-21 14:11:57,814 Thread-5 udi_interface ERROR udi_interface:write: File "/usr/local/lib/python3.8/threading.py", line 870, in run 2022-04-21 14:11:57,818 Thread-5 udi_interface ERROR udi_interface:write: self._target(*self._args, **self._kwargs) 2022-04-21 14:11:57,819 Thread-5 udi_interface ERROR udi_interface:write: File "/var/polyglot/pg3/ns/xx:xx:xx:xx:xx:xx_4/nodes/dysonfan.py", line 113, in poll 2022-04-21 14:11:57,821 Thread-5 udi_interface ERROR udi_interface:write: self.dysonConnect() 2022-04-21 14:11:57,822 Thread-5 udi_interface ERROR udi_interface:write: File "/var/polyglot/pg3/ns/xx:xx:xx:xx:xx:xx_4/nodes/dysonfan.py", line 98, in dysonConnect 2022-04-21 14:11:57,824 Thread-5 udi_interface ERROR udi_interface:write: LOGGER.debug(f"Auto Mode is {self.dysonData.auto_mode}, Night Mode is {self.dysonData.night_mode}") 2022-04-21 14:11:57,825 Thread-5 udi_interface ERROR udi_interface:write: AttributeError 2022-04-21 14:11:57,825 Thread-5 udi_interface ERROR udi_interface:write: : 2022-04-21 14:11:57,826 Thread-5 udi_interface ERROR udi_interface:write: 'NoneType' object has no attribute 'auto_mode' Second question, how can I put in multiple Dyson devices?
glarsen Posted April 21, 2022 Posted April 21, 2022 I think it's telling you that it wasn't succesful in connecting to your fan. Perhaps you can turn on DEBUG in logging, and then restart the node server again. You can PM the log to me instead if inserting in the public space. Double check your configuration - make sure there are no leading or trailing spaces in any of the elements. I know it's a bit tricky because of the Dyson API - acquiring that credential need to connect is a pain. I believe you can run two copies of a node server on PG3; they would just be installed in separate slots.
Recommended Posts