Jump to content

Kasa Node for HS300 install problem


Breezyken
Go to solution Solved by Breezyken,

Recommended Posts

Posted

I have a Kasa HS300 6 outlet plug strip and I want to install the node server on my eisy.  I previously had the trial version of the node, so I deleted that, purchased the current paid version and installed that.  Going to the admin console I selected Kasa, but was unsure how to proceed from there.  My choices are ADD NODE or ADD ALL NODES. Selecting Add Node gives me a list of Kasa devices but no model numbers.  I might guess at any of the first four, but then I get a window asking for Name(whose name?), Node Address, Primary Node Address(what is this?), so I stopped there.  So far the Kasa Controller shows up in the admin console Device list, but no outlets. Searching the wiki's etc. I found one that said all this should be automatic and #1 do NOT open the Node Servers option.  General info about installing node servers does not help. I believe I am up to date with Kasa 3.1.4, PG3x 3.2.17 & IoX 5.7.1.  I've been at this for over three hours now, and it's very frustrating. I just stopped the server and will wait for help.

LOG Follows:

2024-12-22 12:42:29.797 MainThread udi_interface      INFO     polylogger:set_basic_config: set_basic_config: enable=True level=30
2024-12-22 12:42:29.798 MainThread udi_interface      INFO     __init__:<module>: UDI interface initializing
2024-12-22 12:42:29.798 MainThread udi_interface      INFO     __init__:<module>: User=0021b9026837_4
2024-12-22 12:42:29.798 MainThread udi_interface      INFO     __init__:<module>: Home=/var/polyglot/pg3/ns/0021b9026837_4
2024-12-22 12:42:29.798 MainThread udi_interface      INFO     __init__:<module>: Node Server Path=/var/polyglot/pg3/ns/0021b9026837_4
2024-12-22 12:42:29.798 MainThread udi_interface      INFO     __init__:<module>: PG3INIT=eyJ1dWlkIjoiMDA6MjE6Yjk6MDI6Njg6MzciLCJwcm9maWxlTnVtIjo0LCJsb2dMZXZlbCI6IldBUk5JTkciLCJ0b2tlbiI6Ik0/VGwqSndEZ2tOJkN4V2EiLCJtcXR0SG9zdCI6ImxvY2FsaG9zdCIsIm1xdHRQb3J0Ijo4ODgzLCJzZWN1cmUiOjEsImlzUEczeCI6dHJ1ZSwicGczVmVyc2lvbiI6IjMuMi4xNyIsImlzeVZlcnNpb24iOiI1LjcuMSIsImVkaXRpb24iOiJTdGFuZGFyZCJ9
2024-12-22 12:42:29.798 MainThread udi_interface      INFO     __init__:<module>: Loading interface module
2024-12-22 12:42:29.834 MainThread udi_interface      INFO     interface:<module>: Loading MQTT module
2024-12-22 12:42:30.334 MainThread udi_interface      INFO     interface:<module>: MQTT module loaded
2024-12-22 12:42:30.558 MainThread udi_interface      INFO     __init__:<module>: Loading udi_interface module
2024-12-22 12:42:30.559 MainThread udi_interface      INFO     __init__:<module>: Loading node module
2024-12-22 12:42:30.559 MainThread udi_interface      INFO     __init__:<module>: Loading custom module
2024-12-22 12:42:30.559 MainThread udi_interface      INFO     __init__:<module>: Loading isy module
2024-12-22 12:42:30.559 MainThread udi_interface      INFO     __init__:<module>: Loading OAuth module
2024-12-22 12:42:30.560 MainThread udi_interface      INFO     __init__:<module>: UDI interface initialized
2024-12-22 12:42:30.560 MainThread udi_interface      INFO     __init__:<module>: UDI Python Interface for Polyglot version 3 3.3.14 Starting...
2024-12-22 12:42:30.659 MainThread udi_interface.interface INFO     interface:__init__: Initialization received from Polyglot V3 3.2.17  [ISY: 5.7.1, Slot: 4]
2024-12-22 12:42:30.659 MainThread udi_interface.interface INFO     interface:__init__: Connect: Network Interface: {'addr': '192.168.1.38', 'netmask': '255.255.255.0', 'broadcast': '192.168.1.255'}
2024-12-22 12:42:30.660 Interface  udi_interface.interface INFO     interface:_startMqtt: Connecting to MQTT... localhost:8883
2024-12-22 12:42:30.660 MainThread udi_interface.interface WARNING  interface:db_getNodeDrivers: tplkasactl not found in database.
2024-12-22 12:42:30.660 Interface  udi_interface.interface INFO     interface:_startMqtt: Using SSL cert: 0021b9026837_4.cert key: 0021b9026837_4.key ca: /usr/local/etc/ssl/certs/ud.ca.cert
2024-12-22 12:42:30.660 MainThread udi_interface.interface INFO     interface:addNode: Adding node Kasa Controller(tplkasactl) [None]
2024-12-22 12:42:30.660 MainThread udi_interface.interface INFO     interface:setController: Using node "tplkasactl", driver "ST" for connection status.
2024-12-22 12:42:30.661 Interface  udi_interface.interface INFO     interface:_startMqtt: MQTT keepalive is 300 seconds.
2024-12-22 12:42:30.710 MQTT       udi_interface.interface INFO     interface:_connect: MQTT Connected with Reason code: Success
2024-12-22 12:42:30.710 MQTT       udi_interface.interface INFO     interface:_connect: MQTT Subscribing to topic: udi/pg3/ns/clients/00:21:b9:02:68:37_4 -  MID: 2 Result: MQTTErrorCode.MQTT_ERR_SUCCESS
2024-12-22 12:42:30.752 MQTT       udi_interface.interface INFO     interface:_subscribe: MQTT Subscribed Successfully for Message ID: 2. Reason codes: ['Granted QoS 0']
2024-12-22 12:42:30.836 Thread-5   udi_interface      WARNING  Controller:handler_data: No custom data
2024-12-22 12:42:30.980 Thread-11  udi_interface      WARNING  Controller:handler_start: Waiting for all to be loaded params=None data=True... cnt=600
2024-12-22 12:42:32.152 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a14343 not found in database.
2024-12-22 12:42:32.239 Thread-20  udi_interface      WARNING  Controller:handler_data: No custom data
2024-12-22 12:42:35.241 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434301 not found in database.
2024-12-22 12:42:35.242 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434302 not found in database.
2024-12-22 12:42:35.242 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434303 not found in database.
2024-12-22 12:42:35.243 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434304 not found in database.
2024-12-22 12:42:35.243 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434305 not found in database.
2024-12-22 12:42:35.243 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434306 not found in database.
2024-12-22 12:42:35.402 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434301 not found in database.
2024-12-22 12:42:35.403 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434302 not found in database.
2024-12-22 12:42:35.403 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434303 not found in database.
2024-12-22 12:42:35.404 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434304 not found in database.
2024-12-22 12:42:35.404 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434305 not found in database.
2024-12-22 12:42:35.405 Thread-12  udi_interface.interface WARNING  interface:db_getNodeDrivers: 5091e3a1434306 not found in database.
2024-12-22 13:09:07.511 MainThread udi_interface      INFO     polylogger:set_basic_config: set_basic_config: enable=True level=30
2024-12-22 13:09:07.511 MainThread udi_interface      INFO     __init__:<module>: UDI interface initializing
2024-12-22 13:09:07.512 MainThread udi_interface      INFO     __init__:<module>: User=0021b9026837_4
2024-12-22 13:09:07.512 MainThread udi_interface      INFO     __init__:<module>: Home=/var/polyglot/pg3/ns/0021b9026837_4
2024-12-22 13:09:07.512 MainThread udi_interface      INFO     __init__:<module>: Node Server Path=/var/polyglot/pg3/ns/0021b9026837_4
2024-12-22 13:09:07.512 MainThread udi_interface      INFO     __init__:<module>: PG3INIT=eyJ1dWlkIjoiMDA6MjE6Yjk6MDI6Njg6MzciLCJwcm9maWxlTnVtIjo0LCJsb2dMZXZlbCI6IldBUk5JTkciLCJ0b2tlbiI6Ik0/VGwqSndEZ2tOJkN4V2EiLCJtcXR0SG9zdCI6ImxvY2FsaG9zdCIsIm1xdHRQb3J0Ijo4ODgzLCJzZWN1cmUiOjEsImlzUEczeCI6dHJ1ZSwicGczVmVyc2lvbiI6IjMuMi4xNyIsImlzeVZlcnNpb24iOiI1LjcuMSIsImVkaXRpb24iOiJTdGFuZGFyZCJ9
2024-12-22 13:09:07.512 MainThread udi_interface      INFO     __init__:<module>: Loading interface module
2024-12-22 13:09:07.549 MainThread udi_interface      INFO     interface:<module>: Loading MQTT module
2024-12-22 13:09:08.051 MainThread udi_interface      INFO     interface:<module>: MQTT module loaded
2024-12-22 13:09:08.277 MainThread udi_interface      INFO     __init__:<module>: Loading udi_interface module
2024-12-22 13:09:08.278 MainThread udi_interface      INFO     __init__:<module>: Loading node module
2024-12-22 13:09:08.278 MainThread udi_interface      INFO     __init__:<module>: Loading custom module
2024-12-22 13:09:08.278 MainThread udi_interface      INFO     __init__:<module>: Loading isy module
2024-12-22 13:09:08.279 MainThread udi_interface      INFO     __init__:<module>: Loading OAuth module
2024-12-22 13:09:08.279 MainThread udi_interface      INFO     __init__:<module>: UDI interface initialized
2024-12-22 13:09:08.279 MainThread udi_interface      INFO     __init__:<module>: UDI Python Interface for Polyglot version 3 3.3.14 Starting...
2024-12-22 13:09:08.353 MainThread udi_interface.interface INFO     interface:__init__: Initialization received from Polyglot V3 3.2.17  [ISY: 5.7.1, Slot: 4]
2024-12-22 13:09:08.353 MainThread udi_interface.interface INFO     interface:__init__: Connect: Network Interface: {'addr': '192.168.1.38', 'netmask': '255.255.255.0', 'broadcast': '192.168.1.255'}
2024-12-22 13:09:08.354 Interface  udi_interface.interface INFO     interface:_startMqtt: Connecting to MQTT... localhost:8883
2024-12-22 13:09:08.354 MainThread udi_interface.interface WARNING  interface:db_getNodeDrivers: tplkasactl not found in database.
2024-12-22 13:09:08.354 Interface  udi_interface.interface INFO     interface:_startMqtt: Using SSL cert: 0021b9026837_4.cert key: 0021b9026837_4.key ca: /usr/local/etc/ssl/certs/ud.ca.cert
2024-12-22 13:09:08.354 MainThread udi_interface.interface INFO     interface:addNode: Adding node Kasa Controller(tplkasactl) [None]
2024-12-22 13:09:08.355 MainThread udi_interface.interface INFO     interface:setController: Using node "tplkasactl", driver "ST" for connection status.
2024-12-22 13:09:08.355 Interface  udi_interface.interface INFO     interface:_startMqtt: MQTT keepalive is 300 seconds.
2024-12-22 13:09:08.406 MQTT       udi_interface.interface INFO     interface:_connect: MQTT Connected with Reason code: Success
2024-12-22 13:09:08.407 MQTT       udi_interface.interface INFO     interface:_connect: MQTT Subscribing to topic: udi/pg3/ns/clients/00:21:b9:02:68:37_4 -  MID: 2 Result: MQTTErrorCode.MQTT_ERR_SUCCESS
2024-12-22 13:09:08.450 MQTT       udi_interface.interface INFO     interface:_subscribe: MQTT Subscribed Successfully for Message ID: 2. Reason codes: ['Granted QoS 0']
2024-12-22 13:18:53.241 Thread-203 udi_interface      ERROR    udi_interface:write: Exception in thread
2024-12-22 13:18:53.241 Thread-203 udi_interface      ERROR    udi_interface:write: Thread-203
2024-12-22 13:18:53.242 Thread-203 udi_interface      ERROR    udi_interface:write: :
2024-12-22 13:18:53.242 Thread-203 udi_interface      ERROR    udi_interface:write: Traceback (most recent call last):
2024-12-22 13:18:53.242 Thread-203 udi_interface      ERROR    udi_interface:write: File "/usr/local/lib/python3.9/threading.py", line 980, in _bootstrap_inner
2024-12-22 13:18:53.242 Thread-203 udi_interface      ERROR    udi_interface:write: self.run()
2024-12-22 13:18:53.243 Thread-203 udi_interface      ERROR    udi_interface:write: File "/usr/local/lib/python3.9/threading.py", line 917, in run
2024-12-22 13:18:53.243 Thread-203 udi_interface      ERROR    udi_interface:write: self._target(*self._args, **self._kwargs)
2024-12-22 13:18:53.243 Thread-203 udi_interface      ERROR    udi_interface:write: File "/var/polyglot/pg3/ns/0021b9026837_4/nodes/Controller.py", line 461, in handler_typed_data
2024-12-22 13:18:53.244 Thread-203 udi_interface      ERROR    udi_interface:write: self.add_manual_devices()
2024-12-22 13:18:53.244 Thread-203 udi_interface      ERROR    udi_interface:write: File "/var/polyglot/pg3/ns/0021b9026837_4/nodes/Controller.py", line 140, in add_manual_devices
2024-12-22 13:18:53.244 Thread-203 udi_interface      ERROR    udi_interface:write: res = future.result()
2024-12-22 13:18:53.244 Thread-203 udi_interface      ERROR    udi_interface:write: File "/usr/local/lib/python3.9/concurrent/futures/_base.py", line 446, in result
2024-12-22 13:18:53.244 Thread-203 udi_interface      ERROR    udi_interface:write: return self.__get_result()
2024-12-22 13:18:53.245 Thread-203 udi_interface      ERROR    udi_interface:write: File "/usr/local/lib/python3.9/concurrent/futures/_base.py", line 391, in __get_result
2024-12-22 13:18:53.245 Thread-203 udi_interface      ERROR    udi_interface:write: raise self._exception
2024-12-22 13:18:53.245 Thread-203 udi_interface      ERROR    udi_interface:write: File "/var/polyglot/pg3/ns/0021b9026837_4/nodes/Controller.py", line 147, in _add_manual_devices
2024-12-22 13:18:53.245 Thread-203 udi_interface      ERROR    udi_interface:write: LOGGER.info(f"Adding manual device {mdev['address']}")
2024-12-22 13:18:53.245 Thread-203 udi_interface      ERROR    udi_interface:write: KeyError
2024-12-22 13:18:53.245 Thread-203 udi_interface      ERROR    udi_interface:write: :
2024-12-22 13:18:53.245 Thread-203 udi_interface      ERROR    udi_interface:write: 'address'
 

Posted

I have removed the Kasa trial version(expired) and installed the paid version.  Configured according to instructions and it shows connected on admin console.  There are no nodes (plugs) shown. Upon restart I recieve the following error:

2024-12-23 11:29:39.536 Thread-11 udi_interface ERROR Controller:_add_manual_devices: Timed out getting discovery response for 192.168.1.38 trying to connect to 192.168.1.38

Discover is not working for the plug nodes.  How do I get them installed?

I disabled my firewall and I did another restart and discover in PG3 and get the following error:

12/23/2024, 11:35:25 [pg3] warn: Request for customtypedparams. Not found in database

Also, I have set change_node_names to true.  The existing names have been picked up from the app on my phone.  Is this a problem/conflict?  

Looking for answers.  Thanks!

Posted
22 hours ago, Breezyken said:

 Going to the admin console I selected Kasa, but was unsure how to proceed from there.  My choices are ADD NODE or ADD ALL NODES.

All plugin setup should be done in the web portal for Polyglot for the specific plugin then there is usually a customization tab/button should you need to add specific information. 

Check the "more info" button found on the plugin page in the plugin store. Usually that will have more install and setup guidance if it's needed. It might also have examples of settings.

22 hours ago, Breezyken said:

I believe I am up to date with Kasa 3.1.4, PG3x 3.2.17 & IoX 5.7.1.

IoX 5.8.4 has been out since late June. If you're still on 5.7.1 you would need to update. PG3x version looks "current". It was released before 5.8.4 so you might have not updated since PG3x version was released.

 

Posted
I have removed the Kasa trial version(expired) and installed the paid version.  Configured according to instructions and it shows connected on admin console.  There are no nodes (plugs) shown. Upon restart I recieve the following error:
2024-12-23 11:29:39.536 Thread-11 udi_interface ERROR Controller:_add_manual_devices: Timed out getting discovery response for 192.168.1.38 trying to connect to 192.168.1.38
Discover is not working for the plug nodes.  How do I get them installed?
I disabled my firewall and I did another restart and discover in PG3 and get the following error:
12/23/2024, 11:35:25 [pg3] warn: Request for customtypedparams. Not found in database
Also, I have set change_node_names to true.  The existing names have been picked up from the app on my phone.  Is this a problem/conflict?  
Looking for answers.  Thanks!


You should not have to add the HS300 manually, it should be auto-discovered if they are on the same network, if you have multiple subnets at your place then you will can add that sub-net to the list on the configuration page and allow discovery across the subnets.

If your device is 192.168.1.38 the error says your IoX is not able to see that device so discovery and communication will not work. Something on your network is stopping the IoX from seeing that device.

The "warn: Request for customtypedparams" is a PG3 error, so will need info from @bmercier why that is happening.

The change_node_names setting should not be any issue.





Sent from my Pixel 8 Pro using Tapatalk

Posted

I updated IoX to 5.8.4.  I've corrected the kasa IP address in configuration, I've deleted and reinstalled Kasa node several times.  I've restarted admin console over and over, shut down EISY and restarted.  The admin console shows the node connected, but it is unable to add the nodes for the outlets.  I had the trial version last year and it worked fine.  Log files tell me the install can't find db_getNodeDrivers: tplkasactl .  Has this software been tested with the HS-300 ???  Has anyone installed this node server for this device?  It's on my network (no sub networks) and my iPhone app works perfectly with it and also through Alexa voice commands.  That tells me there is something wrong with the node installer.  It's obvious that EISY is unable to communicate with Kasa HS-300.  Is there any little test routine I can use to test communication between EISY and Kasa HS-300?

I have edited out a lot of repetitive ERROR lines in the attached log file generated after the last install.  Error level is set to WARNING.  IoX Firmware & UI at v.5.8.4.  Other node servers such as WeatherLink work perfectly.

I am running WIN 11 PRO on my desktop.

 

Install Log 20241227_1629.log

Posted (edited)

The HS300 is one of my test devices and works perfectly with the latest production and beta releases of the plugin.  Something on your network is stopping the eisy from seeing that device.  Also, as I mentioned you should not have to manually enter any IP addresses for devices if they are all on the same network and you have no network rules in your router stopping them and decent WiFi coverage to the HS300.  The "Can't find db_getNodeDrivers" is a result of failure to communicate with the IP address you entered.  See the earlier errors.

2024-12-27 16:30:20.160 Thread-11 (run_forever) udi_interface      ERROR    Controller:_add_manual_devices: Timed out getting discovery response for 192.168.1.189 trying to connect to 192.168.1.189
2024-12-27 16:30:21.018 Thread-11 (run_forever) udi_interface      WARNING  SmartDeviceNode:connect_a: SmartStrip 5091E3A14343: Device 192.168.1.189 responding again
2024-12-27 16:30:21.018 Thread-11 (run_forever) udi_interface      ERROR    SmartDeviceNode:set_connected: SmartStrip 5091E3A14343: failed: You need to await update() to access the data
2024-12-27 16:30:21.019 Thread-11 (run_forever) udi_interface      ERROR    SmartDeviceNode:connect_a: SmartStrip 5091E3A14343: Unable to connect to device 192.168.1.189 will try again later: You need to await update() to access the data
 
2024-12-27 16:30:23.236 Thread-515 (handler_poll) udi_interface      WARNING  SmartDeviceNode:handler_poll: SmartStrip 5091E3A14343: Node not ready to poll, must be disconnected or slow to respond?
2024-12-27 16:30:23.723 Thread-11 (run_forever) udi_interface      ERROR    SmartDeviceNode:update_a: SmartStrip 5091E3A14343: failed: Unable to query the device 192.168.1.189:9999: [Errno 54] Connection reset by peer
 
Edited by Jimbo.Automates
Posted

@dbwarner5 just reminded me in another post that if your eisy has WiFi enabled this plugin will not work because the WiFi creates its own network. It may be fixable by entering your real network in the config but I can't be sure since my development box is a polisy.

Sent from my Pixel 8 Pro using Tapatalk

  • Like 1
Posted
46 minutes ago, Jimbo.Automates said:

@dbwarner5 just reminded me in another post that if your eisy has WiFi enabled this plugin will not work because the WiFi creates its own network. It may be fixable by entering your real network in the config but I can't be sure since my development box is a polisy.

Sent from my Pixel 8 Pro using Tapatalk
 

I tried to add my own network at the bottom of config: 192.168.68.255. and it still wont find anything while under wifi. 

 

Posted
I tried to add my own network at the bottom of config: 192.168.68.255. and it still wont find anything while under wifi. 
 
Interesting, can you enable debug log, run discover, download log package and PM it to me?

Sent from my Pixel 8 Pro using Tapatalk

  • Like 1
  • Solution
Posted

I finally have the HS-300 power strip nodes installed and working.  Even though it was connected to my WiFi and could be controlled via the Alexa app, apparently it needs a stronger connection while the PG3 node install is made.  I ended up relocating it nearer the wireless access point and the install completed without error.  One thing to note, and YMMV, when it shows up in the admin console, it was way down off screen in my list of many devices because it installs with the label beginning with SmartStrip, not Kasa.  I kept looking for the plug nodes under Kasa Controller, and they were not there.  Maybe the name in the install script could be changed to group it with the main controller node??  Anyway, Jimbo, thanks for bearing with me through this process.

Posted
1 hour ago, Breezyken said:

I finally have the HS-300 power strip nodes installed and working.  Even though it was connected to my WiFi and could be controlled via the Alexa app, apparently it needs a stronger connection while the PG3 node install is made.  I ended up relocating it nearer the wireless access point and the install completed without error.  

Glad you got it working, and thanks for following up.  That's interesting, I guess the discovery packets were not making it to the device when WiFi was weak.  But, I'm not sure why it wouldn't work when you manually put in the device IP address.

1 hour ago, Breezyken said:

One thing to note, and YMMV, when it shows up in the admin console, it was way down off screen in my list of many devices because it installs with the label beginning with SmartStrip, not Kasa.  I kept looking for the plug nodes under Kasa Controller, and they were not there.  Maybe the name in the install script could be changed to group it with the main controller node??  Anyway, Jimbo, thanks for bearing with me through this process.

The devices are not "grouped" by name, for Kasa devices that only have one thing to control the plugin sets their "parent" to the Controller.  But devices that have multiple, like a powerstrip can not have their "parent" be the controller, because IoX doesn't allow multiple levels of hierarchy, so the powerstrip has no parent, and each plug sets its parent to the powerstrip.  You can right click on the Controller and select "Ungroup" and then move them into folders if you desire.  I could prefix the name with Kasa and once you restart the AC it will show up near the Controller.  I'll think about it.

  • Like 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...