Pre-Release Version - Indigo WLED Controller Plugin

Posted on
Thu Nov 14, 2019 2:05 pm
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

Seeker wrote:
after 0.0.8, I'm getting this periodically. I did configure/save the plugin.

I have found it and will be fixed in 0.0.9 to be released later this evening

Posted on
Thu Nov 14, 2019 4:27 pm
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

https://github.com/neilkplugins/WLED-in ... .0.9-alpha

- Fixes address bug (as discovered by Seeker), I was unable to replicate the issue though so please check
- Palette and effect lists are now created per device instance, and updated whenever the action is edited. This will allow multiple WLED versions to co-exist on the same network as well and not requiring a new plugin version if new palettes or effects are added.
- Fixed a minor typo in the log entry when a palette is set

This version does not improve error handling if the WLED is not responsive or offline, but it is improved over 0.0.7 due to using exclusively requests. More on this later this week.

Note: It is possible the running "Set Palette" or "Set Effect" actions defined with earlier versions may error, opening them and reselecting the effect from the pull down should fix the error.

These issues relate to the early nature of the plugin, when I can go beta this will stabilise and I will not be adding new functionality.

Posted on
Thu Nov 14, 2019 5:18 pm
Seeker offline
Posts: 430
Joined: Aug 05, 2013

Re: Pre-Release Version - Indigo WLED Controller Plugin

just updated. getting this:

WLED sent "WLED1" set brightness to 15
WLED Error Error in plugin execution ExecuteAction:

Code: Select all
Traceback (most recent call last):
  File "plugin.py", line 397, in setEffect
KeyError: key wledeffects not found in dict

   WebServer                       request to execute "Mac" control #302 from 192.168.1.45
   Action Group                    wled twinkle 3 on
   WLED                            sent "WLED1" on
   WLED Error                      Error in plugin execution ExecuteAction:

Traceback (most recent call last):
  File "plugin.py", line 397, in setEffect
KeyError: key wledeffects not found in dict

   Schedule                        _delayed_action_14
   WLED                            sent "WLED1" set brightness to 15


edit: more testing. twinkle action gives the errors above. my merry christmas action works and does the christmas pattern.

edit 2: i edited the twinkle action, toggle the type to solid, then twinkle, saved. it now seems to work ok via the action. and no errors in log yet.

Posted on
Thu Nov 14, 2019 5:39 pm
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

Seeker wrote:
just updated. getting this:

WLED sent "WLED1" set brightness to 15
WLED Error Error in plugin execution ExecuteAction:

Code: Select all
Traceback (most recent call last):
  File "plugin.py", line 397, in setEffect
KeyError: key wledeffects not found in dict

   WebServer                       request to execute "Mac" control #302 from 192.168.1.45
   Action Group                    wled twinkle 3 on
   WLED                            sent "WLED1" on
   WLED Error                      Error in plugin execution ExecuteAction:

Traceback (most recent call last):
  File "plugin.py", line 397, in setEffect
KeyError: key wledeffects not found in dict

   Schedule                        _delayed_action_14
   WLED                            sent "WLED1" set brightness to 15


Can you try editing the "Set Effect" action in your "WLED twinkle 3 on" action, or just create another "set effect" action on the same device. As soon as it populates the effect list it should update the device with the dictionary it needs, and the error will stop. (The same will apply to any palette actions you have).

Any new actions will automatically populate the list when they are setup so it is an anomaly of the upgrades from these early versions of the actions. The good news is all that is really needed now is the error handling so this should be the last of these issues.

Posted on
Thu Nov 14, 2019 5:42 pm
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

Seeker wrote:
edit 2: i edited the twinkle action, toggle the type to solid, then twinkle, saved. it now seems to work ok via the action. and no errors in log yet.

Great - even just opening the list should be enough to force the update.

Posted on
Thu Nov 14, 2019 7:48 pm
Seeker offline
Posts: 430
Joined: Aug 05, 2013

Re: Pre-Release Version - Indigo WLED Controller Plugin

latest version seems to be running great with no problems!

thanks for your work on this.

Posted on
Fri Nov 15, 2019 10:52 am
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

No problems at all, I had been looking for a reason to learn some of this for a while and I am really enjoying the exercise. Thanks again for the feedback, and let me know if you think of anything else you would find useful.

Neil

Posted on
Fri Nov 15, 2019 3:46 pm
Seeker offline
Posts: 430
Joined: Aug 05, 2013

Re: Pre-Release Version - Indigo WLED Controller Plugin

i'm not to the christmas scene point yet, but just thinking if it would be better to program scenes (changes in FX mode, FX speed, etc) in the WLED app and kick them off via indigo, or to all the changes based on timers in indigo. I think it would be easier to do in indigo, but i'm not exactly sure.

i don't know what you think of this or if there are any thoughts on building anything into the plugin to accomplish this. it could be done with simple action groups in indigo which is probably the easiest. mode 1 for 5 minutes, change colors, speed, etc, set mode 2 for 5 minutes, etc.

Posted on
Sat Nov 16, 2019 10:10 am
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

https://github.com/neilkplugins/WLED-in ... 0.10-alpha

I added a new release that :-

- Improves error handling if the WLED's go offline, more testing needed in this area to trap as many failure modes as possible
- I added "Not Responding" error state for the device, which will also turn red in the Indigo UI. This is based on a error response to a state request from the JSON API. I also removed remaining requests calls that did not include error trapping
- The main plugin configuration has added a "requests timeout" option. If you get timeout errors in the logs, increase this value. I found as the WLED's drive larger amounts of LED's, and with more complex effects, the WLED device can become less responsive (they will be slow to respond to pings, and even drop responses periodically). I have no science behind this, more testing required.
- I have added a "Recall Preset" action, that can recall presets defined in the WLED UI.

I need to investigate Macro's, and more advanced control of presets (the HTTP API is richer in this area) but I am not clear if this is really needed as action groups can create the same control.

This is now close to a beta release. and will be followed by a full release and publication to the plugin store. Thanks to Seeker for helping to test.

Neil

Posted on
Sat Nov 16, 2019 10:21 am
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

Seeker wrote:
i'm not to the christmas scene point yet, but just thinking if it would be better to program scenes (changes in FX mode, FX speed, etc) in the WLED app and kick them off via indigo, or to all the changes based on timers in indigo. I think it would be easier to do in indigo, but i'm not exactly sure.

i don't know what you think of this or if there are any thoughts on building anything into the plugin to accomplish this. it could be done with simple action groups in indigo which is probably the easiest. mode 1 for 5 minutes, change colors, speed, etc, set mode 2 for 5 minutes, etc.


My focus has been on the plugin, rather than my WLED usage, so I haven't got too far on this. With the "Recall Preset" functionality I just added, this should cover Colo(u)r, Mode, FX speed, FX intensity etc. The only thing it doesn't recall by default is Brightness, which you can do via a Plugin Action anyway in an action group.

My sense like you is that the Preset setup makes sense on the WLED UI, and then use Indigo functionality to control the rest. I am going to play with Macro's now, as well as 3d printing a case for the WLED, so I can mount them outside.

Neil

Posted on
Sun Nov 17, 2019 4:43 pm
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

Beta version of the plugin posted on GitHub
https://github.com/neilkplugins/WLED-indigo-plugin/releases/tag/0.0.11-beta

I have posted what should be considered the beta version of the plugin. All functionality to be included in the first official release is now complete, and I have added what I hope is comprehensive error checking. All user configurable fields are also fully validated.

Reasonably comprehensive documentation is also complete in the GitHub Wiki at https://github.com/neilkplugins/WLED-indigo-plugin/wiki

The learning journey has been excellent, and I appreciate the help and support from all. I am sure we will find problems, and the code has improved, but is very clunky in places but I will continue to learn and refine.

Posted on
Mon Nov 18, 2019 5:27 pm
Seeker offline
Posts: 430
Joined: Aug 05, 2013

Re: Pre-Release Version - Indigo WLED Controller Plugin

excellent job, i've been playing with this a lot and i cannot break it! :D

is there a way to have control actions to INCREASE and DECREASE SPEED and BRIGHTNESS, or is a value required? thinking about my control page.

Posted on
Tue Nov 19, 2019 1:42 am
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

Good to hear. On the brightness you have the standard dimmer options to dim or brighten by a percentage. I can easily add the same for speed and intensity. Watch this space.

Posted on
Tue Nov 19, 2019 6:33 am
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

Seeker wrote:
excellent job, i've been playing with this a lot and i cannot break it! :D

is there a way to have control actions to INCREASE and DECREASE SPEED and BRIGHTNESS, or is a value required? thinking about my control page.


I have updated the Wiki to make it clear how the Brighten by %, Dim by % actions can be called, from the (Device Action) (Light/Appliance Controls).

It did remind me that I have not recently tested that action (I did all the rest) so I will do that and confirm later today, but it should be fine. If this tests OK, I intend to submit my release version to the plugin store later. I have one very minor code update I found yesterday, that would only have surfaced in a very specific error circumstance I would otherwise have trapped.

I also clarified that the "Set RGBW" will not apply to WLED devices (they won't appear in the device pull down when you select the option) as you use the WLED specific options for colour. Future versions may have a better colour picker UI approach, but in my first evaluation the standard RGBW device in Indigo did not map to the Primary/Secondary notion in WLED, and it did not make sense to have two different UI's to set what are associated values.

I then hope that very soon afterwards I will add the equivalent functionality for Effect Speed and Intensity (it may even squeeze into the release version tonight, as long as I can test it thoroughly), as it should not break any core functionality.(Famous last words).

Really appreciate the feedback, It gives me the confidence to push this out.

Posted on
Tue Nov 19, 2019 5:01 pm
neilk offline
Posts: 510
Joined: Jul 13, 2015
Location: Reading, UK

Re: Pre-Release Version - Indigo WLED Controller Plugin

Hopefully the final beta version now posted

https://github.com/neilkplugins/WLED-indigo-plugin/releases/tag/0.0.12-beta

I have posted what should be the final beta version, this includes the additional functionality requested by Seeker (and a great suggestion) and fixes a bug I spotted where I set the wrong value on the WLED in testing. The new functionality included :-

1) Tested the existing Dimmer "Actions Dim by %" and "Brighten by %" that I forget to retest. All is good, they are in the "Device Actions - Appliance/Light Controls" menu, not the WLED actions
2) Added the "Increase Effect Intensity by %" and "Decrease Effect Intensity by %" actions to the WLED action menu
3)Added the "Increase Effect Speed by %" and "Decrease Speed by %" actions to the WLED action menu

The documentation on the Wiki on GitHub is also updated. With that I am pretty much ready to push to a v1.0.0 and to submit to the plugin store.

Who is online

Users browsing this forum: No registered users and 1 guest