Vera - Smarter Home Control Forum

Advanced => Plugins & Plugin Development => Programming => ALTHue => Topic started by: jeubanks on March 30, 2018, 12:51:52 am

Title: ALTHue : Feature Requests
Post by: jeubanks on March 30, 2018, 12:51:52 am
I may have to give this a try.  I pulled my Hue lights out of Vera and into Home Assistant because the Vera plugin kept dropping the Hub.

Any chance of a revamped Lutron Caseta plugin???.  The RadioRA2 is ok... but not great.  I have a Caseta and Caseta PRO hub, so thankfully I'm good to go with Vera with RadioRA2 from the PRO hub.  But it would be nice to have the option of the other hub as well.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 30, 2018, 02:24:51 am
I may have to give this a try.  I pulled my Hue lights out of Vera and into Home Assistant because the Vera plugin kept dropping the Hub.

Any chance of a revamped Lutron Caseta plugin???.  The RadioRA2 is ok... but not great.  I have a Caseta and Caseta PRO hub, so thankfully I'm good to go with Vera with RadioRA2 from the PRO hub.  But it would be nice to have the option of the other hub as well.

I am not familiar with lutron and I can only realistically adresse plugin for devices that I own

Regarding althue, it is very stable for me right now I have 4 lamps including one led strip and 1 motion sensor
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: ChrisTheC on March 30, 2018, 07:33:20 am
. . .
Install and Setup instructions can be found here : https://github.com/amg0/ALTHue/blob/master/Doc/ALTHue%20Philips%20Hue%20plugin.pdf


Yipee! I was ready to buy a Hue system based on your work, but . . . I read the document.
Right off the document says "no UI5"

My Vera3 is UI5 with AltUI (and must remain UI5)
My Raspberry Pi3 is openLuup/AltUI

Does this exclude me from the fun?

Thanks,
Chris
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 30, 2018, 07:48:47 am
. . .
Install and Setup instructions can be found here : https://github.com/amg0/ALTHue/blob/master/Doc/ALTHue%20Philips%20Hue%20plugin.pdf


Yipee! I was ready to buy a Hue system based on your work, but . . . I read the document.
Right off the document says "no UI5"

My Vera3 is UI5 with AltUI (and must remain UI5)
My Raspberry Pi3 is openLuup/AltUI

Does this exclude me from the fun?

Thanks,
Chris

UI5 yes ( although the effort should no be that much, probably just writing a UI5 .json file and a small .lua change )
openluup : not tested but it should work nicely.  it does work nicely with ALTUI
 EDIT : v0.5 brings a bit of functionality, all minus RGB devices which are seen as std dimmers
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on March 30, 2018, 11:45:54 am
openluup : not tested but it should work nicely.  it does work nicely with ALTUI

I have tested with the latest openLuup/latest AltUI/Hue v2 bridge, and the the plugin does not work as-is.... It seems that openLuup does not populated the "data_command_url" variable for the javascript environment.

Manually adding the variable definition to the J_ALTHUE.js file (not the correct solution) resolves the problem, and the plugin then works under openLuup.

Code: [Select]
var data_command_url = "/data_request?";


NB: Actually... the "data_command_url" variable should probably be "data_request_url", as the former seems to have been deprecated years ago...
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 30, 2018, 12:20:24 pm
openluup : not tested but it should work nicely.  it does work nicely with ALTUI

I have tested with the latest openLuup/latest AltUI/Hue v2 bridge, and the the plugin does not work as-is.... It seems that openLuup does not populated the "data_command_url" variable for the javascript environment.

Manually adding the variable definition to the J_ALTHUE.js file (not the correct solution) resolves the problem, and the plugin then works under openLuup.

Code: [Select]
var data_command_url = "/data_request?";


NB: Actually... the "data_command_url" variable should probably be "data_request_url", as the former seems to have been deprecated years ago...

did you take the latest github ALTUI ?. I kind of remember making such a change
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on March 30, 2018, 12:29:34 pm
did you take the latest github ALTUI ?. I kind of remember making such a change

Yes, I did... You seem to have missed one occurrence... line 312.


PS: Wait... I misread... You stated ALTUI, I read ALTHUE...

The ALTUI version I used is from March 25. (your last update to J_ALTUI_api.js was on the 26th - AltUI/openLuup did not notify of an update.)

Although, in J_ALTHUE.js, you have five references to "data_request_url" and one reference to "data_command_url"... a correct fix could be to change the spurious reference. This would resolve the issue for anyone running a slightly older version of AltUI.

Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 30, 2018, 12:41:13 pm
Yes work in progress
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 30, 2018, 05:55:42 pm
@ChrisTheC

I have a version for UI5 on github, it sorts of work with the following problems
- RGB lights managed as std dimmer lights, when I use D_DimmableRGBLight1.xml for the device file it crashes so I use the std dimmer on UI5
- the user interface of the settings tab is not nice at all, it needs some rework for UI5 but if you use ALTUI, even on your UI5 box, then the user interface will be proper ( essentially UI5 behaves as UI7 )

cf my UI5 screen shot
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: jeubanks on March 31, 2018, 12:20:07 am
Pulled from github and installed.  Working nicely!  Kudo's on the work.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on March 31, 2018, 01:32:55 am
@amg0

Just a heads-up... Your "RefreshHueData" routine is having trouble processing sensor data. My Hue Brideg has several "phantom" temperature and light level sensors. The device data for these sensors contains null data, and this causes the refresh process to crash. (Note: I am testing under openLuup, but it should be the same issue for a real Vera...)
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 31, 2018, 03:39:32 am
Can you please send me the content of the setting tab called ? dump ?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 31, 2018, 03:40:22 am
Pulled from github and installed.  Working nicely!  Kudo's on the work.
Great, on what kind of setup ?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on March 31, 2018, 05:37:34 am
Can you please send me the content of the setting tab called ? dump ?

Attached...
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: ChrisTheC on March 31, 2018, 07:58:04 am
@ChrisTheC

I have a version for UI5 on github, it sorts of work with the following problems
- RGB lights managed as std dimmer lights, when I use D_DimmableRGBLight1.xml for the device file it crashes so I use the std dimmer on UI5
- the user interface of the settings tab is not nice at all, it needs some rework for UI5 but if you use ALTUI, even on your UI5 box, then the user interface will be proper ( essentially UI5 behaves as UI7 )

amg0,
Good Morning (from UTC -4:00)
Thanks for the promising news. Could, should, . . . and (in time) will work.
Now to order the hardware . . .  :)
Chris
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: jeubanks on March 31, 2018, 02:39:39 pm
Pulled from github and installed.  Working nicely!  Kudo's on the work.
Great, on what kind of setup ?

Currently on my primary VeraPlus with latest UI7
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: hellovn on March 31, 2018, 03:17:37 pm
Great plugins. I have been waiting for hue motion sensors for 2 years.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 31, 2018, 03:31:50 pm
@amg0

Just a heads-up... Your "RefreshHueData" routine is having trouble processing sensor data. My Hue Brideg has several "phantom" temperature and light level sensors. The device data for these sensors contains null data, and this causes the refresh process to crash. (Note: I am testing under openLuup, but it should be the same issue for a real Vera...)

can you please try 0.7
if problem persists, please enable DEBUG mode, reload luup and give me the log file
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on March 31, 2018, 03:34:29 pm
Great plugins. I have been waiting for hue motion sensors for 2 years.

thx. motion and also temperature,  light sensor ( the Hue motion sensor is a great piece of HW and include the 3 sensors )
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: florianec on March 31, 2018, 04:32:42 pm
@amg0

Just a heads-up... Your "RefreshHueData" routine is having trouble processing sensor data. My Hue Brideg has several "phantom" temperature and light level sensors. The device data for these sensors contains null data, and this causes the refresh process to crash. (Note: I am testing under openLuup, but it should be the same issue for a real Vera...)

can you please try 0.7
if problem persists, please enable DEBUG mode, reload luup and give me the log file

i had the same problem, refresh didn't work, for me 0.7 fixed it. I am very happy with your plugin now thx for the work!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: hellovn on March 31, 2018, 07:29:56 pm
Great plugins. I have been waiting for hue motion sensors for 2 years.

thx. motion and also temperature,  light sensor ( the Hue motion sensor is a great piece of HW and include the 3 sensors )

One question: did you use URL hashcode change to detect hue motion sensor change or periodic check the change every xxx of seconds?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 01, 2018, 03:52:21 am
Great plugins. I have been waiting for hue motion sensors for 2 years.

thx. motion and also temperature,  light sensor ( the Hue motion sensor is a great piece of HW and include the 3 sensors )

One question: did you use URL hashcode change to detect hue motion sensor change or periodic check the change every xxx of seconds?
Polling. the refresh period variable allows to control the frequency. Do you have details or doc page explaining the other method? I did not see it in the Philips hue api spec
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 01, 2018, 05:11:30 am
Have to give Karma for this...
Will it make its appearance in the Alt App Store?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 01, 2018, 06:17:20 am
Can you please send me the content of the setting tab called ? dump ?

yes when MCV approves it.
Plugin ID on MCV store is : 9066
easy install of v0.7 from store can be done by opening this url in your browser
http://<ip>:3480/data_request?id=action&serviceId=urn:micasaverde-com:serviceId:HomeAutomationGateway1&action=CreatePlugin&PluginNum=9066&Version=36116
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 01, 2018, 07:18:53 am
yes when MCV approves it.
Plugin ID on MCV store is : 9066
easy install of v0.7 from store can be done by opening this url in your browser

...not in the AltAppStore ???
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 01, 2018, 10:29:13 am
yes when MCV approves it.
Plugin ID on MCV store is : 9066
easy install of v0.7 from store can be done by opening this url in your browser

...not in the AltAppStore ???
should be now.
had to fix a bug in ALTUI to publish it !!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 01, 2018, 11:43:29 am
Yup, that worked!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: hellovn on April 02, 2018, 08:03:14 am
Great plugins. I have been waiting for hue motion sensors for 2 years.

thx. motion and also temperature,  light sensor ( the Hue motion sensor is a great piece of HW and include the 3 sensors )

One question: did you use URL hashcode change to detect hue motion sensor change or periodic check the change every xxx of seconds?
Polling. the refresh period variable allows to control the frequency. Do you have details or doc page explaining the other method? I did not see it in the Philips hue api spec

I was just thinking another way to reduce the network to hue hub. I look at the response header and it does not have a last modified date so it seems nothing we can do.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 02, 2018, 11:21:23 am
Hello all, the plugin is now published on the MCV store
http://apps.mios.com/plugin.php?id=9066

as well as on the Alternate App Store from ALTUI
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 02, 2018, 04:45:11 pm
Amg0: Something a little odd I discovered trying to install on Openluup. Once the plugin is installed, the iphone locator plugin stops working: it is no longer able to ping the iphone. Once I delete the althue plugin, the iphone locator works again...
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 02, 2018, 04:58:15 pm
Here's just a wild guess...

...some of this code adds extra functions to the string library.  This may cause incompatibilities between plugins.

I don't think modifying system libraries in general is a good plan.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 02, 2018, 05:18:03 pm
Amg0: Something a little odd I discovered trying to install on Openluup. Once the plugin is installed, the iphone locator plugin stops working: it is no longer able to ping the iphone. Once I delete the althue plugin, the iphone locator works again...

it works fine for me with both enabled , in UI7 and UI5.
please enable DEBUG on IphoneLocator, then reload luup and send me the logs
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: jeubanks on April 02, 2018, 06:37:15 pm
Not sure if this is "normal".  In a PLEG automation, I used setLoadLevel on a Hue light and nothing happened.  Do I need to turn on first then set the level?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 02, 2018, 07:09:11 pm
Not sure if this is "normal".  In a PLEG automation, I used setLoadLevel on a Hue light and nothing happened.  Do I need to turn on first then set the level?

The official action name is the dimming service file is SetLoadLevelTarget not setloadlevel
I tried on a switched off light to call SetLoadLevelTarget with a proper parameter and it switched the light on
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 02, 2018, 08:27:03 pm
Amg0: Something a little odd I discovered trying to install on Openluup. Once the plugin is installed, the iphone locator plugin stops working: it is no longer able to ping the iphone. Once I delete the althue plugin, the iphone locator works again...

it works fine for me with both enabled , in UI7 and UI5.
please enable DEBUG on IphoneLocator, then reload luup and send me the logs which I have PMed you

Ok. Will do. Will need some time as I will be out of time the rest of the week.

Edit: I was able to reproduce the problem 3 times by installing and uninstalling the ALTHue plugin. I found nothing useful in the logs.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Don Phillips on April 02, 2018, 08:38:24 pm
+1 amg0.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: jeubanks on April 02, 2018, 11:12:18 pm
Not sure if this is "normal".  In a PLEG automation, I used setLoadLevel on a Hue light and nothing happened.  Do I need to turn on first then set the level?

The official action name is the dimming service file is SetLoadLevelTarget not setloadlevel
I tried on a switched off light to call SetLoadLevelTarget with a proper parameter and it switched the light on

Yeah yeah, I didn't use the "offical" name when I was posting, sorry  ::)

Anyways, it was about 2 minutes later I came back and updated my post saying NEVERMIND.... but I don't see it anywhere, so it must not have actually posted.  It turns out that someone had turned the lamp off.  Found out when I went into the plugin and looked at the "information" section. 

On the flip side everything is working as it should (for me at least).  I'm doing so re-org stuff over the next couple days.  re-installing another pi with openLuup.  Not sure if I want to move Hue off to that or not.  I have two VeraPlus units already 1 for z-wave/zigbee one for virtual devices except for lights (Caseta and Hue).  Still looking for more ideas on what to do with openLuup and that second VeraPlus box...
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 03, 2018, 02:35:40 am
About ALTHue & IPhoneLocator issue on openluup

I have posted a fix on https://github.com/amg0/ALTHue and on https://github.com/amg0/IPhoneLocator for the issue.  you can download and apply these new versions. I have a openluup running with both enabled right now

it does seem to come from the fact that device plugins openluup share the same instance of the global libraries ( like string ), so I avoided the conflict but other plugins could have the same issue. I ll check on mines
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 03, 2018, 03:05:50 am
it does seem to come from the fact that device plugins openluup share the same instance of the global libraries ( like string ), so I avoided the conflict but other plugins could have the same issue.

I've just checked, and it turns out that the Arduino (MySensors) plugin also modifies the string library, so if you're running that, there may be problems too.

It's easy to generate an error and terminate a plugin if it tries to do this.  It turns out to be much harder to give each plugin its own set of system libraries.  I may add an optional check to openLuup to catch this type of error in future.  Apologies for any difficulties caused.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 03, 2018, 04:01:11 am
Thank you to both amg0 for the fix and akbooer for the idea and the openluup check.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 07, 2018, 03:15:38 am
Thank you to both amg0 for the fix and akbooer for the idea and the openluup check.

In the latest openLuup development release v18.4.7, I've managed to sandbox the string library between separate devices, so this potential issue with other plugins should not happen, and there's no need to modify their code.

I still believe, however, that it is bad practice to modify system libraries.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 07, 2018, 05:28:29 am
Hi
Does Althue plugin support IKEA Tradfri led lamps?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 07, 2018, 12:54:03 pm
Hi
Does Althue plugin support IKEA Tradfri led lamps?
If Philips hue bridge does I do not see why not (, but it as to be tested )
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on April 08, 2018, 03:55:21 pm
If Philips hue bridge does I do not see why not (, but it as to be tested )

I have tested Ikea bulbs connected to a Hue bridge, and ALTHue does support them.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 09, 2018, 07:36:50 am
Hi,
Tested 2 IKEA LED lamps and they are visable in AltHUE information tab.
Althue finds the hue hub and there was no problems to pair but unfortenately i am receiving Can't Detect Device message from Althue plugin.

Althue version: 0.7
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 09, 2018, 11:26:44 am
Hi,
Tested 2 IKEA LED lamps and they are visable in AltHUE information tab.
Althue finds the hue hub and there was no problems to pair but unfortenately i am receiving Can't Detect Device message from Althue plugin.

Althue version: 0.7

Try version on github.
also please try this :
1- enable debug mode on althue
2- reload luup
3- play with the lamp if possible
4- share the log
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 09, 2018, 02:42:37 pm
Hi,
Tested 2 IKEA LED lamps and they are visable in AltHUE information tab.
Althue finds the hue hub and there was no problems to pair but unfortenately i am receiving Can't Detect Device message from Althue plugin.

Althue version: 0.7

Try version on github.
also please try this :
1- enable debug mode on althue
2- reload luup
3- play with the lamp if possible
4- share the log

Hi,
Thanks for support!!

Installed via the link provided as method 1; Install from MCV store.
After setting the IP adress, i am getting luup engine is taking longer to reload. Try again.
Pairing the hue bridge and get OK.
Lamp information for both Hue and IKEA is available under tab: Hue devices.
AltHue reporting: Can't Detect Device

Anything in the logfile i should check for?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 09, 2018, 03:12:51 pm
I suggested using the version on github .  Github/amg0/althue
Regarding the log , I do not know what to search for, so wanted to have a general look myself in the debug mode log file
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 11, 2018, 09:54:44 am
I suggested using the version on github .  Github/amg0/althue
Regarding the log , I do not know what to search for, so wanted to have a general look myself in the debug mode log file

Hi,
First of all, many thanks for your kind support!
Have tried the version on Github without success. Same story, the plugin detects the hue hub but get the Can't Detect Device message.
Tried the Hue2 plugin from store. Not working.
Today i wiped the Vera and started from 0. Installed the althue plugin but get the same message. Cant detect the device.
From logfile: luup_log:7: ALTHUE: warning: Communication failure with the Hue Hub; msg: <0x751ba520>

Vera Firmware: 1.7.3535

Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 11, 2018, 11:44:02 am
I suggested using the version on github .  Github/amg0/althue
Regarding the log , I do not know what to search for, so wanted to have a general look myself in the debug mode log file

Hi,
First of all, many thanks for your kind support!
Have tried the version on Github without success. Same story, the plugin detects the hue hub but get the Can't Detect Device message.
Tried the Hue2 plugin from store. Not working.
Today i wiped the Vera and started from 0. Installed the althue plugin but get the same message. Cant detect the device.
From logfile: luup_log:7: ALTHUE: warning: Communication failure with the Hue Hub; msg: <0x751ba520>

Vera Firmware: 1.7.3535
Please try this
1- enable debug mode on althue
2- reload luup
3- play with the lamp if possible
4- share the log
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 11, 2018, 02:19:07 pm
I suggested using the version on github .  Github/amg0/althue
Regarding the log , I do not know what to search for, so wanted to have a general look myself in the debug mode log file

Hi,
First of all, many thanks for your kind support!
Have tried the version on Github without success. Same story, the plugin detects the hue hub but get the Can't Detect Device message.
Tried the Hue2 plugin from store. Not working.
Today i wiped the Vera and started from 0. Installed the althue plugin but get the same message. Cant detect the device.
From logfile: luup_log:7: ALTHUE: warning: Communication failure with the Hue Hub; msg: <0x751ba520>

Vera Firmware: 1.7.3535
Please try this
1- enable debug mode on althue
2- reload luup
3- play with the lamp if possible
4- share the log
1. Done
2. Done
3. No lamps to play with in the interface
(Getting: Luup engine is taking longer to reload.)
4. attached
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 11, 2018, 03:58:46 pm
I suggested using the version on github .  Github/amg0/althue
Regarding the log , I do not know what to search for, so wanted to have a general look myself in the debug mode log file

Hi,
First of all, many thanks for your kind support!
Have tried the version on Github without success. Same story, the plugin detects the hue hub but get the Can't Detect Device message.
Tried the Hue2 plugin from store. Not working.
Today i wiped the Vera and started from 0. Installed the althue plugin but get the same message. Cant detect the device.
From logfile: luup_log:7: ALTHUE: warning: Communication failure with the Hue Hub; msg: <0x751ba520>

Vera Firmware: 1.7.3535
Please try this
1- enable debug mode on althue
2- reload luup
3- play with the lamp if possible
4- share the log
1. Done
2. Done
3. No lamps to play with in the interface
(Getting: Luup engine is taking longer to reload.)
4. attached
Ok I found one issue, I ll send an update when I am back home in a few days
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 12, 2018, 09:34:39 am
I suggested using the version on github .  Github/amg0/althue
Regarding the log , I do not know what to search for, so wanted to have a general look myself in the debug mode log file

Hi,
First of all, many thanks for your kind support!
Have tried the version on Github without success. Same story, the plugin detects the hue hub but get the Can't Detect Device message.
Tried the Hue2 plugin from store. Not working.
Today i wiped the Vera and started from 0. Installed the althue plugin but get the same message. Cant detect the device.
From logfile: luup_log:7: ALTHUE: warning: Communication failure with the Hue Hub; msg: <0x751ba520>

Vera Firmware: 1.7.3535
Please try this
1- enable debug mode on althue
2- reload luup
3- play with the lamp if possible
4- share the log
1. Done
2. Done
3. No lamps to play with in the interface
(Getting: Luup engine is taking longer to reload.)
4. attached
Ok I found one issue, I ll send an update when I am back home in a few days
Many thanks!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 13, 2018, 11:19:37 am
I committed a version 0.9 on github which should allow us to go at least one step further. please let me know how it goes

in case it fails, Please follow this
1- enable debug mode on althue
2- reload luup
3- play with the lamp if possible
4- share the log
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 13, 2018, 12:51:11 pm
I committed a version 0.9 on github which should allow us to go at least one step further. please let me know how it goes

in case it fails, Please follow this
1- enable debug mode on althue
2- reload luup
3- play with the lamp if possible
4- share the log
Thank you !
Downloaded all files from Github and installed. Entered IP adress and saved. Reload Luua. Unfortenately, I can not pair to the hue HUB.
Message: The operation did not succeed
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 13, 2018, 02:26:42 pm
Ok then please follow the steps 1 to 4 so we see what happens
How exactly did you try to pair ?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on April 13, 2018, 06:05:30 pm
@amg0: With version 0.9, I am seeing the pluging crash when setAttrIfChanged is called... Specifically, it is being passed the modelid for an Ecosmart bulb, and the value is nil causing the string.format function in the debug statement to error out...

Code: [Select]
2018-04-13 12:41:36.041   luup_log:76: ALTHUE: debug: data:{"2":{"etag":"f5ec436d66027f7b14258aca04695b27","hascolor":false,"manufacturername":"2.1.0_16d_YF05","modelid":null,"name":"Light 2","state":{"alert":"none","bri":25,"on":false,"reachable":true},"swversion":null,"type":"Dimmable light","uniqueid":"dd:16:ab:ff:f1:a1:67:70-01"}}
2018-04-13 12:41:36.041   luup.variable_set:: 76.urn:upnp-org:serviceId:althue1.LastValidComm was: 1523644896 now: 1523644896 #hooks:0
2018-04-13 12:41:36.041   luup_log:76: ALTHUE: debug: ALTHueHttpCall(76,GET,sensors,)
2018-04-13 12:41:36.041   luup_log:76: ALTHUE: debug: Calling Hue with GET http://192.168.1.124/api/AADD8AA672/sensors , body:
2018-04-13 12:41:36.061   luup_log:76: ALTHUE: debug: request:1
2018-04-13 12:41:36.061   luup_log:76: ALTHUE: debug: code:200
2018-04-13 12:41:36.061   luup_log:76: ALTHUE: debug: data:{"1":{"config":{"configured":true,"on":true,"sunriseoffset":30,"sunsetoffset":-30},"etag":"529620323fdefbfa2f549f9c32fa48c7","manufacturername":"Philips","modelid":"PHDL00","name":"Daylight","state":{"daylight":true,"lastupdated":"2018-04-13T13:27:04","status":160},"swversion":"1.0","type":"Daylight","uniqueid":"00:21:2e:ff:ff:01:02:e5-01"}}
2018-04-13 12:41:36.061   luup.variable_set:: 76.urn:upnp-org:serviceId:althue1.LastValidComm was: 1523644896 now: 1523644896 #hooks:0
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: SyncLights(76)
2018-04-13 12:41:36.062   luup.chdev.append:: [dd:16:ab:ff:f1:a1:67:70-01] Hue Light 2
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: SyncSensors(76)
2018-04-13 12:41:36.062   luup.chdev.sync:: [76] raspbeegw, syncing children
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: InitDevices(76) MapUID2Index is: {"dd:16:ab:ff:f1:a1:67:70-01":"2"}
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: setAttrIfChanged(name,Hue Light 2,77)
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: setAttrIfChanged(manufacturer,2.1.0_16d_YF05,77)
2018-04-13 12:41:36.063   luup.attr_set:: 77.manufacturer = 2.1.0_16d_YF05
2018-04-13 12:41:36.063   openLuup.context_switch::  ERROR: [string "L_ALTHUE.lua"]:150: bad argument #3 to 'format' (string expected, got nil)
2018-04-13 12:41:36.063   luup.delay_callback:: function: 0x1c321e0 ERROR: [string "L_ALTHUE.lua"]:150: bad argument #3 to 'format' (string expected, got nil)

Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 14, 2018, 04:20:50 am
Ok then please follow the steps 1 to 4 so we see what happens
How exactly did you try to pair ?
Hi,
Re-installed all files from Github this morning and everything works fine with ver 0.9! (Hmm, Dont know what i did yesterday evening but....)
All lamps are now showing up in the interface.
Big thanks for all support and kind help!!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 14, 2018, 04:58:55 am
Ok then please follow the steps 1 to 4 so we see what happens
How exactly did you try to pair ?
Hi,
Re-installed all files from Github this morning and everything works fine with ver 0.9! (Hmm, Dont know what i did yesterday evening but....)
All lamps are now showing up in the interface.
Big thanks for all support and kind help!!
Great, For the community could you please confirm the lamp name / type so that we know what is compatible ?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 14, 2018, 05:18:21 am
@amg0: With version 0.9, I am seeing the pluging crash when setAttrIfChanged is called... Specifically, it is being passed the modelid for an Ecosmart bulb, and the value is nil causing the string.format function in the debug statement to error out...

Code: [Select]
2018-04-13 12:41:36.041   luup_log:76: ALTHUE: debug: data:{"2":{"etag":"f5ec436d66027f7b14258aca04695b27","hascolor":false,"manufacturername":"2.1.0_16d_YF05","modelid":null,"name":"Light 2","state":{"alert":"none","bri":25,"on":false,"reachable":true},"swversion":null,"type":"Dimmable light","uniqueid":"dd:16:ab:ff:f1:a1:67:70-01"}}
2018-04-13 12:41:36.041   luup.variable_set:: 76.urn:upnp-org:serviceId:althue1.LastValidComm was: 1523644896 now: 1523644896 #hooks:0
2018-04-13 12:41:36.041   luup_log:76: ALTHUE: debug: ALTHueHttpCall(76,GET,sensors,)
2018-04-13 12:41:36.041   luup_log:76: ALTHUE: debug: Calling Hue with GET http://192.168.1.124/api/AADD8AA672/sensors , body:
2018-04-13 12:41:36.061   luup_log:76: ALTHUE: debug: request:1
2018-04-13 12:41:36.061   luup_log:76: ALTHUE: debug: code:200
2018-04-13 12:41:36.061   luup_log:76: ALTHUE: debug: data:{"1":{"config":{"configured":true,"on":true,"sunriseoffset":30,"sunsetoffset":-30},"etag":"529620323fdefbfa2f549f9c32fa48c7","manufacturername":"Philips","modelid":"PHDL00","name":"Daylight","state":{"daylight":true,"lastupdated":"2018-04-13T13:27:04","status":160},"swversion":"1.0","type":"Daylight","uniqueid":"00:21:2e:ff:ff:01:02:e5-01"}}
2018-04-13 12:41:36.061   luup.variable_set:: 76.urn:upnp-org:serviceId:althue1.LastValidComm was: 1523644896 now: 1523644896 #hooks:0
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: SyncLights(76)
2018-04-13 12:41:36.062   luup.chdev.append:: [dd:16:ab:ff:f1:a1:67:70-01] Hue Light 2
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: SyncSensors(76)
2018-04-13 12:41:36.062   luup.chdev.sync:: [76] raspbeegw, syncing children
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: InitDevices(76) MapUID2Index is: {"dd:16:ab:ff:f1:a1:67:70-01":"2"}
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: setAttrIfChanged(name,Hue Light 2,77)
2018-04-13 12:41:36.062   luup_log:76: ALTHUE: debug: setAttrIfChanged(manufacturer,2.1.0_16d_YF05,77)
2018-04-13 12:41:36.063   luup.attr_set:: 77.manufacturer = 2.1.0_16d_YF05
2018-04-13 12:41:36.063   openLuup.context_switch::  ERROR: [string "L_ALTHUE.lua"]:150: bad argument #3 to 'format' (string expected, got nil)
2018-04-13 12:41:36.063   luup.delay_callback:: function: 0x1c321e0 ERROR: [string "L_ALTHUE.lua"]:150: bad argument #3 to 'format' (string expected, got nil)

I have put a v0.91 on github which should fix this issue. if it works, please report back the device name/type so we know what is compatible
thx !
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: json on April 14, 2018, 08:35:48 am
Ok then please follow the steps 1 to 4 so we see what happens
How exactly did you try to pair ?
Hi,
Re-installed all files from Github this morning and everything works fine with ver 0.9! (Hmm, Dont know what i did yesterday evening but....)
All lamps are now showing up in the interface.
Big thanks for all support and kind help!!
Great, For the community could you please confirm the lamp name / type so that we know what is compatible ?
Have tested IKEA and Phillips lamp:
   Type         Model                  Swversion   Reachable
   Color light      IKEA of Sweden TRADFRI bulb E27 CWS opal 600lm   1.3.002      true
   Color temperature   IKEA of Sweden TRADFRI bulb E14 WS opal 400lm   1.2.217      true
   Dimmable light      Philips LWB010   1.29.0_r21169               true
   Dimmable light      Philips LWB010   1.29.0_r21169               true
   Dimmable light      IKEA of Sweden TRADFRI bulb GU10 W 400lm   1.2.214      true
   Color temperature    IKEA of Sweden TRADFRI bulb E27 WS opal 980lm   1.2.217      true
   Dimmable light      IKEA of Sweden TRADFRI bulb E27 W opal 1000lm   1.2.214      true
   Color temperature   IKEA of Sweden TRADFRI bulb E14 WS opal 400lm   1.2.217      true
Works GREAT!!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 14, 2018, 08:38:47 am
Thanks a lot

EDIT: I added a table of "seen working devices" on post #1
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 14, 2018, 08:45:49 am
I think it's time for me to invest in a Philips Hue Hub!

It's interesting to see kit moving into the mainstream with suppliers like Philips.  The good thing about the environment that we're playing in, is that it makes it easy (thanks to folks like you all developing and testing here) to integrate other stuff.  It's why we bought Vera in the first place, and whilst Vera itself is slow on the uptake (and support) we're not so dependent on that actual hardware now.

Purchasing from suppliers of domestic goods, rather than hobby shops for geeks (if you excuse me) also has the potential to raise the WAF enormously, and allay any fears about "who is going to fix it if you're not around?"
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cokeman on April 14, 2018, 01:02:29 pm
Hi,

Will there be an edition that works with the IKEA gateway ??
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 14, 2018, 01:38:30 pm
Successfully moved my hue integration from the vera to openluup with this plugin! One more ste towards a lower Vera dependance. It is less cluttered, more responsive and one less factor in random luup reloads on the vera.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Ripley on April 15, 2018, 07:58:05 am
Many thanks for this new plugin! For some unknown reason the old plugin failed to start-up and I hadn’t gotten around to analyzing the problem yet. Installation of this new and shiny plugin restored my Hue integration.

One question: I can’t select the Hue bridge and select a Hue scene as part of a Vera scene. The Hue bridge doesn’t show in the list of devices while defining the Vera scene. For now, I defined each Hue light individually in the Vera scene. Should I be able to select a Hue scene, or is this by design?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 15, 2018, 09:41:43 am
Many thanks for this new plugin! For some unknown reason the old plugin failed to start-up and I hadn?t gotten around to analyzing the problem yet. Installation of this new and shiny plugin restored my Hue integration.

One question: I can?t select the Hue bridge and select a Hue scene as part of a Vera scene. The Hue bridge doesn?t show in the list of devices while defining the Vera scene. For now, I defined each Hue light individually in the Vera scene. Should I be able to select a Hue scene, or is this by design?

thank you for the feedback.

from a personal preference, I prefer to create my scene in vera and use the Hue lamp devices in it.
but otherwise, the AltHue device can be selected in the vera scene editor ( advanced mode ), and it offers a UPNP action called "RunHueScene" which accepts the Hue scene ID as a parameter

the Hue scene ID can be found by hovering the mouse over the Hue scene name that you want in the ALTHUE settings tab called "Hue Scenes", in the future I may work on simplifying this but it is not clear how to uniquely identify a scene in Hue except this internal Hue ID. each Hue scenes can have the same name and be associated to an array of lights so to uniquely identify a scene you would need scene name and the array of lights which is not user convenient...

screen shot attached.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Ripley on April 15, 2018, 05:10:21 pm
I wasn?t aware of the Advanced option in the scene editor. Thanks for the heads-up.

I agree that it?s cleaner to define the scene exclusively in Vera, but I find it cumbersome to select the desired intensity and color levels, as the lights do not immediately reflect the new values when you edit the scene. Editing the scene, waiting for Vera to restart, then test the scene, decide you want something changed, edit again, ... awkward. Perhaps I?m doing something wrong?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 15, 2018, 05:57:37 pm
I wasn?t aware of the Advanced option in the scene editor. Thanks for the heads-up.

I agree that it?s cleaner to define the scene exclusively in Vera, but I find it cumbersome to select the desired intensity and color levels, as the lights do not immediately reflect the new values when you edit the scene. Editing the scene, waiting for Vera to restart, then test the scene, decide you want something changed, edit again, ... awkward. Perhaps I?m doing something wrong?
You are correct
It is a little bit better using altui and I will probably enhance the integration altui/Althue to additional level in the future but that won?t benefit ui7 users
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on April 15, 2018, 09:03:31 pm
It is a little bit better using altui and I will probably enhance the integration altui/Althue to additional level in the future but that won?t benefit ui7 users

A simple modification to make things easier would be to add an id field to the ALTHue scene table... That way a user can find the scene name and the lights that are affected and test it by running the scene... then easily copy the scene id to be input into the scene editor.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 16, 2018, 06:41:53 am
It is a little bit better using altui and I will probably enhance the integration altui/Althue to additional level in the future but that won?t benefit ui7 users

A simple modification to make things easier would be to add an id field to the ALTHue scene table... That way a user can find the scene name and the lights that are affected and test it by running the scene... then easily copy the scene id to be input into the scene editor.
it is already in ( not in official version but in github )
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Ripley on April 16, 2018, 07:54:44 am
Another idea is to show the RGBW values and make it possible to enter the digits manually in the editor.

Or to copy the actual RGBW values when you edit a scene, so you can set the lights manually, enter the scene editor, select ACTIONS, and the selected lights will use the present settings, unless you fiddle with them.

It?s not something you do on a daily basis, so for now I?ll manage. Very happy it?s working again!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 16, 2018, 08:12:39 am
Another idea is to show the RGBW values and make it possible to enter the digits manually in the editor.

Or to copy the actual RGBW values when you edit a scene, so you can set the lights manually, enter the scene editor, select ACTIONS, and the selected lights will use the present settings, unless you fiddle with them.

It?s not something you do on a daily basis, so for now I?ll manage. Very happy it?s working again!

again the advanced scene editor allow you to select the RGBW device and select the SetColorRGB action and pass the actual RGB value as a parameter like "rr,gg,bb"
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Ripley on April 16, 2018, 08:45:39 am
I really should start reading the FM 🙄

Is there also a place to read the current values?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 16, 2018, 09:07:10 am
I really should start reading the FM 🙄

Is there also a place to read the current values?

variable "CurrentColor" of the device
but the format is a bit different. it is something like 0=0,1=0,2=43,3=194,4=71
2 3 and 4 are the rgb values
check the MCV wiki
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Ripley on April 16, 2018, 09:25:31 am
My devices don?t have this variable. They?re all Philips LCT007 (according to the device parms), and they have these variables: Status, Target, LoadLevelStatus, LoadLevelTarget.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on April 16, 2018, 12:35:50 pm
variable "CurrentColor" of the device

My devices don?t have this variable. They?re all Philips LCT007 (according to the device parms), and they have these variables: Status, Target, LoadLevelStatus, LoadLevelTarget.

This variable is currently only populated if the color of the bulb is changed from the GUI (UI7 or openLuup). The plugin does not (yet) set these variables from the data received from the bridge.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 16, 2018, 01:24:24 pm
I have added support for that variable in v 0.96 on github
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on April 16, 2018, 03:50:08 pm
I have added support for that variable in v 0.96 on github

This update works for bulbs in colormode="xy", but will not update any bulbs in colormode="ct" or colormode="hs". Any bulb that has been set to a specific color temperature in the hue app(s) will be in ct mode, and selecting certain color values in gamut B (older) bulbs will set them to "hs" mode.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on April 16, 2018, 04:55:50 pm
Also note:

In ALTUI (under both UI7 and openLuup), the warm white/cool white selections sliders (for color temperature selection) are not displayed in the control panel... This appears to be an issue with processing the D_DimmableRGBLight1.json file.


Under openLuup, the color selection dropdown on the device page does not display the correct color, the color selection dropdown in the device control panel does display the correct color.


Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 17, 2018, 06:56:04 am
Also note:

In ALTUI (under both UI7 and openLuup), the warm white/cool white selections sliders (for color temperature selection) are not displayed in the control panel... This appears to be an issue with processing the D_DimmableRGBLight1.json file.


Under openLuup, the color selection dropdown on the device page does not display the correct color, the color selection dropdown in the device control panel does display the correct color.
What?s the value of currentcolor variable in both case

The display of the file is a bigger pb. Ui7 does not follow the file and hard code a display ( like it does for?most Built in devices). I think a custom panel for altui would be a better option and not care about ui7. This is a simple JS method declared as a Altui plugin in case somebody is interested to contribute to it.  Also the upnp setcolor with the syntax Wxxx or Dxxx should work to set the color temp of the light
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 17, 2018, 09:41:48 am
I have added support for that variable in v 0.96 on github

This update works for bulbs in colormode="xy", but will not update any bulbs in colormode="ct" or colormode="hs". Any bulb that has been set to a specific color temperature in the hue app(s) will be in ct mode, and selecting certain color values in gamut B (older) bulbs will set them to "hs" mode.
v0.97 in github should support all modes
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 17, 2018, 10:06:56 am
Just ordered a hub... can't wait to give this all a go!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 17, 2018, 08:12:32 pm
I have added support for that variable in v 0.96 on github

This update works for bulbs in colormode="xy", but will not update any bulbs in colormode="ct" or colormode="hs". Any bulb that has been set to a specific color temperature in the hue app(s) will be in ct mode, and selecting certain color values in gamut B (older) bulbs will set them to "hs" mode.
v0.97 in github should support all modes

I can confirm that it is working. Only one more thing: the color control does not appear to work with "Friends of Hue" devices. I have a couple of Hue Iris (LLC010)  and Hue Bloom (LLC011) which the vera plugin supports. I am sure other FOH don't work either.

I suspect changing their implementation and device files from the dimmable to the RGB ones should fix it?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 18, 2018, 01:24:24 am
What are friend of hue devices ? Are they 3rd party devices ? Could you send me the hue data Json ( settings tab ).
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 18, 2018, 01:52:51 am
They are actually Philips devices but from a series called "friends of hue".
I have no settings tab because the json used is for the standard dimmable light D_DimmableLight1.xml, D_DimmableLight1.json... It is run through the plugin but does not use the plugin files.

https://www2.meethue.com/en-us/friends-of-hue
https://www2.meethue.com/en-us/p/hue-bloom/729976049
https://www2.meethue.com/en-us/p/hue-white-and-color-ambiance-go-portable-light/714606048

Edit: I verified that changing the device json and xml files in the attributes to D_DimmableRGBLight1.xml and D_DimmableRGBLight1.json works. So I think it is just a matter for the plugin to recognize them and assign the right files for the devices.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 18, 2018, 03:59:20 am
They are actually Philips devices but from a series called "friends of hue".
I have no settings tab because the json used is for the standard dimmable light D_DimmableLight1.xml, D_DimmableLight1.json... It is run through the plugin but does not use the plugin files.

https://www2.meethue.com/en-us/friends-of-hue
https://www2.meethue.com/en-us/p/hue-bloom/729976049
https://www2.meethue.com/en-us/p/hue-white-and-color-ambiance-go-portable-light/714606048

Edit: I verified that changing the device json and xml files in the attributes to D_DimmableRGBLight1.xml and D_DimmableRGBLight1.json works. So I think it is just a matter for the plugin to recognize them and assign the right files for the devices.

I know it will work but not manually as it will be reset at every reload
the Settings tab I am talking about is a setting tab on the AltHue  Plugin itself
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 18, 2018, 04:11:00 am
I see.

This is for the iris:

Code: [Select]
    "11": {
      "productname": "Hue iris",
      "capabilities": {
        "streaming": {
          "renderer": true,
          "proxy": false
        },
        "control": {
          "mindimlevel": 10000,
          "colorgamuttype": "A",
          "colorgamut": [
            [
              0.704,
              0.296
            ],
            [
              0.2151,
              0.7106
            ],
            [
              0.138,
              0.08
            ]
          ],
          "maxlumen": 210
        },
        "certified": true
      },
      "manufacturername": "Philips",
      "swversion": "5.105.1.21778",
      "state": {
        "hue": 64000,
        "effect": "none",
        "on": false,
        "colormode": "hs",
        "sat": 254,
        "mode": "homeautomation",
        "reachable": true,
        "xy": [
          0.6795,
          0.2858
        ],
        "alert": "none",
        "bri": 1
      },
      "config": {
        "function": "decorative",
        "direction": "upwards",
        "archetype": "hueiris"
      },
      "swupdate": {
        "state": "noupdates",
        "lastinstall": "2017-12-28T19:41:32"
      },
      "name": "Bonus Iris",
      "type": "Color light",
      "modelid": "LLC010",
      "uniqueid": "XXXXXXXXXX"
    },

And this is for the bloom:

Code: [Select]
  "13": {
      "productname": "Hue bloom",
      "capabilities": {
        "streaming": {
          "renderer": true,
          "proxy": false
        },
        "control": {
          "mindimlevel": 10000,
          "colorgamuttype": "A",
          "colorgamut": [
            [
              0.704,
              0.296
            ],
            [
              0.2151,
              0.7106
            ],
            [
              0.138,
              0.08
            ]
          ],
          "maxlumen": 120
        },
        "certified": true
      },
      "manufacturername": "Philips",
      "swversion": "5.105.1.21778",
      "state": {
        "hue": 41422,
        "effect": "none",
        "on": false,
        "colormode": "xy",
        "sat": 39,
        "mode": "homeautomation",
        "reachable": true,
        "xy": [
          0.3909,
          0.3713
        ],
        "alert": "none",
        "bri": 1
      },
      "config": {
        "function": "decorative",
        "direction": "upwards",
        "archetype": "huebloom"
      },
      "swupdate": {
        "state": "noupdates",
        "lastinstall": "2017-12-28T19:39:59"
      },
      "name": "Bloom 3",
      "type": "Color light",
      "modelid": "LLC011",
      "uniqueid": "XXXXXXXX"
    }
  },
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 18, 2018, 04:12:37 am
Also strangely, it has not reset after the last luup reload...
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 18, 2018, 04:55:44 am
ok, I have put 0.98 in github with the (hopeful) fix
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 18, 2018, 10:54:50 am
I ran the upgrade and it seems to work though I cannot be 100% sure since I made it work by manually changing the device files before the upgrade. It just did not revert to the default dimmer files.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 18, 2018, 11:40:33 am
My Hue has just arrived, so I can now join in the fun!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 18, 2018, 12:33:31 pm
Absolute magic!

The install process couldn't possibly be easier:
Imagine if Z-wave was that easy !!


One gripe: the log file entries...
Code: [Select]
2018-04-18 17:28:51.971   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068921 now: 1524068931 #hooks:0
2018-04-18 17:28:51.983   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068931 now: 1524068931 #hooks:0
2018-04-18 17:29:02.502   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068931 now: 1524068942 #hooks:0
2018-04-18 17:29:02.514   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068942 now: 1524068942 #hooks:0
2018-04-18 17:29:13.045   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068942 now: 1524068953 #hooks:0
2018-04-18 17:29:13.057   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068953 now: 1524068953 #hooks:0

Can we cut down on this a bit? ... or am I still in debug mode?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 18, 2018, 01:29:24 pm
Absolute magic!

The install process couldn't possibly be easier:
  • plugin hub
  • plugin bulbs
  • plugin ALTHue plugin, and set IP address
  • press the pair buttons on hub and plugin panel
  • Shazzam! we are there with functioning devices!!
Imagine if Z-wave was that easy !!


One gripe: the log file entries...
Code: [Select]
2018-04-18 17:28:51.971   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068921 now: 1524068931 #hooks:0
2018-04-18 17:28:51.983   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068931 now: 1524068931 #hooks:0
2018-04-18 17:29:02.502   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068931 now: 1524068942 #hooks:0
2018-04-18 17:29:02.514   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068942 now: 1524068942 #hooks:0
2018-04-18 17:29:13.045   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068942 now: 1524068953 #hooks:0
2018-04-18 17:29:13.057   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1524068953 now: 1524068953 #hooks:0

Can we cut down on this a bit? ... or am I still in debug mode?
great. I commited a version on github to address that
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 18, 2018, 01:33:51 pm
Formidable!

I noticed this when updating the plugin:
Code: [Select]
are you sure you want to update plugin #d117c862-8caf-4711-b0f8-11cdf457f290

...you're using a UUID for the plugin id?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 18, 2018, 03:27:41 pm
Formidable!

I noticed this when updating the plugin:
Code: [Select]
are you sure you want to update plugin #d117c862-8caf-4711-b0f8-11cdf457f290

...you're using a UUID for the plugin id?

You mean in AltAppStore ?  I saw this now and updated it to the true MCV pluginID, but the web interface does not allow that kind of update so I had to update it directly in the database and god knows what kind of side effect this can have... beware!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 18, 2018, 04:02:31 pm
You mean in AltAppStore ?

Actually, it was when using the Update button from the Plugins page.

But it's part of the InstalledPlugins2 structure that comes from the App store.  If you had put ALTHue in the MiOS app store, it would be a simple number (like AltUI is 8246.)

Code: [Select]
{
AllowMultiple = 0,
AutoUpdate = 1,
Description = "Alternate plugin for Philips Hue",
Devices = {{
DeviceFileName = "D_ALTHUE.xml",
DeviceType = "urn:schemas-upnp-org:device:althue:1",
ImplFile = "I_ALTHUE.xml",
Invisible = "0"
}},
Files = {{SourceName = "L_ALTHUE.lua"},{SourceName = "D_ALTHUE.json"},{SourceName = "D_ALTHUE_UI7.json"},{SourceName = "J_ALTHUE.js"},{SourceName = "I_ALTHUE.xml"},{SourceName = "S_ALTHUE.xml"},{SourceName = "D_ALTHUE.xml"}},
Icon = "https://raw.githubusercontent.com/amg0/ALTHue/master/iconALTHUE_100.png",
Instructions = "https://github.com/amg0/ALTHue",
Repository = {
folders = {""},
pattern = "ALTHUE",
source = "amg0/ALTHue",
type = "GitHub",
versions = {master = {release = "master"}}
},
Title = "ALTHue",
VersionMajor = "GitHub",
VersionMinor = "master",
id = "d117c862-8caf-4711-b0f8-11cdf457f290"
}

I was just trying to understand why.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 18, 2018, 04:58:10 pm
You mean in AltAppStore ?

Actually, it was when using the Update button from the Plugins page.

But it's part of the InstalledPlugins2 structure that comes from the App store.  If you had put ALTHue in the MiOS app store, it would be a simple number (like AltUI is 8246.)

Code: [Select]
{
AllowMultiple = 0,
AutoUpdate = 1,
Description = "Alternate plugin for Philips Hue",
Devices = {{
DeviceFileName = "D_ALTHUE.xml",
DeviceType = "urn:schemas-upnp-org:device:althue:1",
ImplFile = "I_ALTHUE.xml",
Invisible = "0"
}},
Files = {{SourceName = "L_ALTHUE.lua"},{SourceName = "D_ALTHUE.json"},{SourceName = "D_ALTHUE_UI7.json"},{SourceName = "J_ALTHUE.js"},{SourceName = "I_ALTHUE.xml"},{SourceName = "S_ALTHUE.xml"},{SourceName = "D_ALTHUE.xml"}},
Icon = "https://raw.githubusercontent.com/amg0/ALTHue/master/iconALTHUE_100.png",
Instructions = "https://github.com/amg0/ALTHue",
Repository = {
folders = {""},
pattern = "ALTHUE",
source = "amg0/ALTHue",
type = "GitHub",
versions = {master = {release = "master"}}
},
Title = "ALTHue",
VersionMajor = "GitHub",
VersionMinor = "master",
id = "d117c862-8caf-4711-b0f8-11cdf457f290"
}

I was just trying to understand why.

yes I do not know how it happened, It is in MCV store so I do have a normal integer ID which I have also put now in the AltAppStore DB.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 18, 2018, 06:39:39 pm
OK, understood (at last!)

It means that any openLuup installation with the wrong plugin ID will have to update ALTHue from the AltAppStore before being able to update directly from the Plugin page once more.

No problem, if this procedure followed.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: cybrmage on April 18, 2018, 07:28:32 pm
@amg0:

Here are the proposed changes.


<changes received by amg0, attachment removed>
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 21, 2018, 03:42:48 pm
@amg0:

Here are the proposed changes.


<changes received by amg0, attachment removed>

integrated in ALTHue and ALTUI ,github versions
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 21, 2018, 05:17:41 pm
@amg0:

Here are the proposed changes.


<changes received by amg0, attachment removed>

integrated in ALTHue and ALTUI ,github versions

Upgraded to 0.99. Looking good. Could be put as a release on the AltAppStore which is still only showing 0.94

One potential improvement with the icons: The mcv plugin has a bunch of various icons which matches the device description.
Maybe I could give it a shot with a pull request on github...
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 21, 2018, 07:41:31 pm
@amg0:

Here are the proposed changes.


<changes received by amg0, attachment removed>

integrated in ALTHue and ALTUI ,github versions

Upgraded to 0.99. Looking good. Could be put as a release on the AltAppStore which is still only showing 0.94

One potential improvement with the icons: The mcv plugin has a bunch of various icons which matches the device description.
Maybe I could give it a shot with a pull request on github...
If it is simple why not, I ll look at your proposals .
, we need to keep it simple and relatively device agnostic. (I need to avoid to have to edit the code and create versions every time a new type of device pops up )
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 21, 2018, 11:53:36 pm
Ok I am looking into it. I don't think it should be a problem, it will use a generic bulb icon for unknown devices and the specific icon for known devices
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Vinx on April 22, 2018, 05:17:27 am
Amazing Amg0, this is a huge improvement over the regular Hue plugin (which this week stopped working for the second time with no apparent way to revive)! Thumbs up!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 22, 2018, 11:35:13 am
released v0.99 in github https://github.com/amg0/ALTHue and in mcv Store

direct install with http://<ip>:3480/data_request?id=action&serviceId=urn:micasaverde-com:serviceId:HomeAutomationGateway1&action=CreatePlugin&PluginNum=9066&Version=36241

regarding ALTUI compatibility, it requires ALTUI >= v 2338
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 22, 2018, 12:28:35 pm
All great stuff, I must say.

I've not downloaded the Hua app on my iPad, and don't really intend to, unless someone gives me a good reason.  This means, I suppose, that Hue scenes will always be a closed book to me, but I don't see the need, really, since all my automation is on openLuup.

To me, then, Hue is just a Zigbee bridge, just like Vera is a Zwave bridge.  Given that, does it make sense to consider an "All Off" action for ALTHue?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 22, 2018, 11:51:58 pm
Yeah Hue scenes have been more a confusing duplicates than anything. I don't use it at all as I use openluup to run scenes combines with non hue devices.
I only use the mobile app for setups and firmware updates... So you may actually want to have it handy.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 23, 2018, 02:24:00 am
I submitted a pull request on GitHub. I had to add 2 variables to the devices. The icon recognition works and so does the opacity variation. Only remaining problem is ALTUI does not appear to show the svg changes of color. It was a bit more work than I thought.

Edit: Nevermind... The colors work too, it was different format of the hex string. It all works now.
amg0, please review.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 23, 2018, 03:48:31 am
I submitted a pull request on GitHub. I had to add 2 variables to the devices. The icon recognition works and so does the opacity variation. Only remaining problem is ALTUI does not appear to show the svg changes of color. It was a bit more work than I thought.

Edit: Nevermind... The colors work too, it was different format of the hex string. It all works now.
amg0, please review.

crazyly nice ! , I ll review the code and see how to integrate, thx
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 23, 2018, 03:56:03 am
I submitted a pull request on GitHub. I had to add 2 variables to the devices. The icon recognition works and so does the opacity variation. Only remaining problem is ALTUI does not appear to show the svg changes of color. It was a bit more work than I thought.

Edit: Nevermind... The colors work too, it was different format of the hex string. It all works now.
amg0, please review.

I only see a pull request on ALTHUE, is there any code change in ALTUI ?
I wonder about the D_DimmableLight2.json file  , will we get problems to deploy it in the MCV store as it is a system provided file already ?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 23, 2018, 10:31:28 am
I submitted a pull request on GitHub. I had to add 2 variables to the devices. The icon recognition works and so does the opacity variation. Only remaining problem is ALTUI does not appear to show the svg changes of color. It was a bit more work than I thought.

Edit: Nevermind... The colors work too, it was different format of the hex string. It all works now.
amg0, please review.

I only see a pull request on ALTHUE, is there any code change in ALTUI ?
I wonder about the D_DimmableLight2.json file  , will we get problems to deploy it in the MCV store as it is a system provided file already ?

Yeah I did not need anything on AltUI. It is ALTHue only. And yes I was thinking about a potential problem if MCV ever creates a new json/xml file. I will change the names to be ALTHue specific and submit later today.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 23, 2018, 10:39:15 am
I submitted a pull request on GitHub. I had to add 2 variables to the devices. The icon recognition works and so does the opacity variation. Only remaining problem is ALTUI does not appear to show the svg changes of color. It was a bit more work than I thought.

Edit: Nevermind... The colors work too, it was different format of the hex string. It all works now.
amg0, please review.

I only see a pull request on ALTHUE, is there any code change in ALTUI ?
I wonder about the D_DimmableLight2.json file  , will we get problems to deploy it in the MCV store as it is a system provided file already ?

Yeah I did not need anything on AltUI. It is ALTHue only. And yes I was thinking about a potential problem if MCV ever creates a new json/xml file. I will change the names to be ALTHue specific and submit later today.

agreed. also the .svg are they needed ? ( my box already had them .. is it because I had installed the Mios Hue plugin before ? )
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 23, 2018, 10:41:44 am
yes the svg came from the Mios Hue plugin. That's why you had them. They are needed for those who never installed it.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 23, 2018, 10:44:41 am
yes the svg came from the Mios Hue plugin. That's why you had them. They are needed for those who never installed it.
bummer... quite a pain to deal with in the MCV app publish wizard in the store. and in which folder ? ( do we support UI5 ? )
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 23, 2018, 10:51:04 am
yes the svg came from the Mios Hue plugin. That's why you had them. They are needed for those who never installed it.
bummer... quite a pain to deal with in the MCV app publish wizard in the store. and in which folder ? ( do we support UI5 ? )

The original files were in "/mios/www/skins/default/img/devices/device_states/" on my Vera. Openluup scans for icon files through several folders so in my case dropping them in /etc/cmh-ludl or /etc/cmh-ludl/icons worked just fine. I am not sure about UI5 as I don't have anything that can run it so I did not test. Fundamentally, based on the structure I think it would work but I can't be sure.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 23, 2018, 11:07:58 am
Openluup scans for icon files through several folders so in my case dropping them in /etc/cmh-ludl or /etc/cmh-ludl/icons worked just fine. I

Yes indeed - just to confirm this.  The following HTTP redirections are applied by the server:
Code: [Select]
local dir_alias = {
    ["cmh/skins/default/img/devices/device_states/"] = "icons/",  -- redirect UI7 icon requests
    ["cmh/skins/default/icons/"] = "icons/",                      -- redirect UI5 icon requests
    ["cmh/skins/default/img/icons/"] = "icons/" ,                 -- 2017.11.14
  }

...so there's never a need to make a real /www/cmh/... directory structure. 

openLuup always tries to operate within the folder tree beneath its own home directory.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 23, 2018, 11:58:11 am
yes the svg came from the Mios Hue plugin. That's why you had them. They are needed for those who never installed it.
bummer... quite a pain to deal with in the MCV app publish wizard in the store. and in which folder ? ( do we support UI5 ? )

Pull request in your inbox. I even added a line in the json for UI5 but again, I am not sure it works. Come to think about it I am not sure it supports the dynamic icon types. In that case UI5 may need to go back to the original mcv basic json.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 23, 2018, 12:56:14 pm
Pull request in your inbox. I even added a line in the json for UI5 but again, I am not sure it works. Come to think about it I am not sure it supports the dynamic icon types. In that case UI5 may need to go back to the original mcv basic json.

The basic multiple-icon mechanism is there in UI5.  I run two VeraLites with UI5 so I can test this when you're ready.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 23, 2018, 12:58:45 pm
Yes I know, but I am talking about the very specific "dynamic_icons" type which seems to be quite new and uses svg icon files as opposed to the multiple "state_icons" which uses png icon files...
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 23, 2018, 01:03:46 pm
Yes I know, but I am talking about the very specific "dynamic_icons" type which seems to be quite new and uses svg icon files as opposed to the multiple "state_icons" which uses png icon files...

Ah, probably not, then.  But that still leaves me with two UI5 machines on which I can test the plugin   ;)
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 23, 2018, 01:28:38 pm
Hello Both please make a note I made some small changes ( like renaming the files again to respect the ALTHue convention )
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on April 23, 2018, 01:44:26 pm
Hello Both please make a note I made some small changes ( like renaming the files again to respect the ALTHue convention )

Ok I just saw it. Looks good. The [extended_color] file assignment puzzled me but I did not want to mess with it since it worked for me... I see now that it was a bug... Ha!
You think it is good for v1.0?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Vinx on April 23, 2018, 03:46:22 pm
Hi good people, Although I don't want to disturb these valuable developer-discussions, I got a noob user question :)
What would be an effective way to set the lights to "warm white" using the plugin? If I first set it to a warm white (in the Hue app), the plugin information shows RGB code 0,0,0 (which to my understanding would be black). So I figured RBG isn't be the way to go. I tried setting the SetColorTemp in the advanced editor of a scene, but that didn't do the trick either. I've also been reading about the Hue API, but that didn't give me the clues I needed either. Anyone know how this would work?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 23, 2018, 04:05:32 pm
Hi good people, Although I don't want to disturb these valuable developer-discussions, I got a noob user question :)
What would be an effective way to set the lights to "warm white" using the plugin? If I first set it to a warm white (in the Hue app), the plugin information shows RGB code 0,0,0 (which to my understanding would be black). So I figured RBG isn't be the way to go. I tried setting the SetColorTemp in the advanced editor of a scene, but that didn't do the trick either. I've also been reading about the Hue API, but that didn't give me the clues I needed either. Anyone know how this would work?

on the very latest version, you can use UPNP : SetColor  and parameter "W0"
W0     <--> W255  =  D0     <--> D255
2000K <--> 5500K = 5500K <--> 9000K

or you can use the device control panel ( but not for scene edition )


Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Vinx on April 25, 2018, 02:59:42 pm
Thanks, works like a charm!
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: bnflaherty on April 25, 2018, 03:18:09 pm
Maybe it's just me.. Or the rain.. or work from home today.. or it's Wednesday .. but just installed the new plugin on UI5 and it refuses to pair. I tried on a previous version but same issue.. and I'm sick of just using the Hue app ... I need my integration :)
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 26, 2018, 05:21:41 am
Maybe it's just me.. Or the rain.. or work from home today.. or it's Wednesday .. but just installed the new plugin on UI5 and it refuses to pair. I tried on a previous version but same issue.. and I'm sick of just using the Hue app ... I need my integration :)

to trouble shoot I can suggest this approach

1 describe your setup
2 enable debug mode on ALTHue device
3 reload luup engine
4 go to ALTHUE settings
5 make sure IP address is correct
6 press the pair button on the hub
7 press the pair button on the settings
8 remove debug mode on ALTHue device

if it fails,  get the log file from vera in /var/log/cmh covering the whole period ( step 2 to 8 ) and share so I can look at it
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 29, 2018, 10:33:49 am
Can this be used with the Philips Tap Smartswitch as a scene controller for Vera/openLuup devices?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 29, 2018, 10:41:02 am
Can this be used with the Philips Tap Smartswitch as a scene controller for Vera/openLuup devices?

never tested so probably wont work but we might be able to add. ( although not 100% sure, Hue api does not allow for trigger notifications ), you may need to setup the controller in Hue independently of vera
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 29, 2018, 10:55:53 am
OK, thanks. I'll probably get one and try.  As you say, it'll work within the Hue ecosystem anyway, and perhaps I can then trigger off the state change of the lights that it controls. 
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 30, 2018, 11:53:47 am
Can I possibly request a further reduction in logging of last successful communication with this plugin?  It outnumbers most of my other log entries by about 5:1.

Would it perhaps be possible just to log if there has been no successful communication for, say, 5 minutes or the like?

Obviously not a huge issue, but one which does have a significant impact on the rate at which the logs are rotated, and in finding other significant events in logs.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 30, 2018, 12:05:41 pm
Can I possibly request a further reduction in logging of last successful communication with this plugin?  It outnumbers most of my other log entries by about 5:1.

Would it perhaps be possible just to log if there has been no successful communication for, say, 5 minutes or the like?

Obviously not a huge issue, but one which does have a significant impact on the rate at which the logs are rotated, and in finding other significant events in logs.
are you in debug mode ?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 30, 2018, 12:25:30 pm
are you in debug mode ?

No, but I seem to have an entry in the log every 10 seconds...

2018-04-30 17:20:15.566   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1525105204 now: 1525105215 #hooks:0
2018-04-30 17:20:16.575   openLuup.http:: request completed (3341 bytes, 1 chunks, 1636 ms) tcp{client}: 0x1d650c8
2018-04-30 17:20:16.685   openLuup.http:: GET /data_request?id=lu_status2&output_format=json&DataVersion=83213044&Timeout=60&MinimumDelay=1500&_=1525085249822 HTTP/1.1 tcp{client}: 0x1d650c8
2018-04-30 17:20:25.271   luup.variable_set:: 10004.urn:micasaverde-com:serviceId:ZWaveNetwork1.LastPollSuccess was: 1525105132 now: 1525105222 #hooks:0
2018-04-30 17:20:25.784   openLuup.http:: request completed (8259 bytes, 1 chunks, 9098 ms) tcp{client}: 0x1d650c8
2018-04-30 17:20:25.808   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1525105215 now: 1525105225 #hooks:0
2018-04-30 17:20:25.894   openLuup.http:: GET /data_request?id=lu_status2&output_format=json&DataVersion=83213046&Timeout=60&MinimumDelay=1500&_=1525085249823 HTTP/1.1 tcp{client}: 0x1d650c8
2018-04-30 17:20:27.494   openLuup.http:: request completed (3341 bytes, 1 chunks, 1599 ms) tcp{client}: 0x1d650c8
2018-04-30 17:20:27.606   openLuup.http:: GET /data_request?id=lu_status2&output_format=json&DataVersion=83213047&Timeout=60&MinimumDelay=1500&_=1525085249824 HTTP/1.1 tcp{client}: 0x1d650c8
2018-04-30 17:20:36.014   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1525105225 now: 1525105236 #hooks:0

Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 30, 2018, 12:52:18 pm
are you in debug mode ?

No, but I seem to have an entry in the log every 10 seconds...

2018-04-30 17:20:15.566   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1525105204 now: 1525105215 #hooks:0
2018-04-30 17:20:16.575   openLuup.http:: request completed (3341 bytes, 1 chunks, 1636 ms) tcp{client}: 0x1d650c8
2018-04-30 17:20:16.685   openLuup.http:: GET /data_request?id=lu_status2&output_format=json&DataVersion=83213044&Timeout=60&MinimumDelay=1500&_=1525085249822 HTTP/1.1 tcp{client}: 0x1d650c8
2018-04-30 17:20:25.271   luup.variable_set:: 10004.urn:micasaverde-com:serviceId:ZWaveNetwork1.LastPollSuccess was: 1525105132 now: 1525105222 #hooks:0
2018-04-30 17:20:25.784   openLuup.http:: request completed (8259 bytes, 1 chunks, 9098 ms) tcp{client}: 0x1d650c8
2018-04-30 17:20:25.808   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1525105215 now: 1525105225 #hooks:0
2018-04-30 17:20:25.894   openLuup.http:: GET /data_request?id=lu_status2&output_format=json&DataVersion=83213046&Timeout=60&MinimumDelay=1500&_=1525085249823 HTTP/1.1 tcp{client}: 0x1d650c8
2018-04-30 17:20:27.494   openLuup.http:: request completed (3341 bytes, 1 chunks, 1599 ms) tcp{client}: 0x1d650c8
2018-04-30 17:20:27.606   openLuup.http:: GET /data_request?id=lu_status2&output_format=json&DataVersion=83213047&Timeout=60&MinimumDelay=1500&_=1525085249824 HTTP/1.1 tcp{client}: 0x1d650c8
2018-04-30 17:20:36.014   luup.variable_set:: 345.urn:upnp-org:serviceId:althue1.LastValidComm was: 1525105225 now: 1525105236 #hooks:0


ok but none of these lines are directely generated by the plugin. the 10 sec is the polling rate that you can reduce in the settings ( but it will be less reactive ).
the LastValidComm is a variable wich keeps track of last valid comm timestamp, I could eventually neutralize this one but that will not reduce the log so much, will it ?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on April 30, 2018, 01:00:45 pm
ok but none of these lines are directely generated by the plugin.

It was only the LastValidComm entries that I was concerned about.

Quote
the 10 sec is the polling rate that you can reduce in the settings ( but it will be less reactive ).
the LastValidComm is a variable wich keeps track of last valid comm timestamp, I could eventually neutralize this one but that will not reduce the log so much, will it ?

Oooh yes, you're right, of course.  My mistake.  I think I can handle this one myself.  Thanks.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on April 30, 2018, 01:28:28 pm
ok but none of these lines are directely generated by the plugin.

It was only the LastValidComm entries that I was concerned about.

Quote
the 10 sec is the polling rate that you can reduce in the settings ( but it will be less reactive ).
the LastValidComm is a variable wich keeps track of last valid comm timestamp, I could eventually neutralize this one but that will not reduce the log so much, will it ?

Oooh yes, you're right, of course.  My mistake.  I think I can handle this one myself.  Thanks.

I will use a LastFailedComm variable instead.  should be less frequent...
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on May 01, 2018, 01:02:04 pm
I see that Vera has updated their device category list here (on Jan 23, 2018):
http://wiki.micasaverde.com/index.php/Luup_Device_Categories

New ones I see include a 'Philips Controller'
Code: [Select]
25 Weather
26 Philips Controller
27 Appliance
28 UV Sensor
29 Mouse Trap
30 Doorbell
31 Keypad

Should ALTHue have category #26 ?
________________

PS:  has anyone actually GOT a Z-wave mousetrap??   :D
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on May 01, 2018, 02:09:46 pm
I see that Vera has updated their device category list here (on Jan 23, 2018):
http://wiki.micasaverde.com/index.php/Luup_Device_Categories

New ones I see include a 'Philips Controller'
Code: [Select]
25 Weather
26 Philips Controller
27 Appliance
28 UV Sensor
29 Mouse Trap
30 Doorbell
31 Keypad

Should ALTHue have category #26 ?
________________

PS:  has anyone actually GOT a Z-wave mousetrap??   :D

thank you, fixed. ( github version )
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: Don Phillips on May 01, 2018, 07:55:30 pm
I see that Vera has updated their device category list here (on Jan 23, 2018):
http://wiki.micasaverde.com/index.php/Luup_Device_Categories

And it seems to load a lot faster also.

PS:  has anyone actually GOT a Z-wave mousetrap??   :D

 ;D
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: hwve on May 02, 2018, 11:15:39 am
Amg0: Something a little odd I discovered trying to install on Openluup. Once the plugin is installed, the iphone locator plugin stops working: it is no longer able to ping the iphone. Once I delete the althue plugin, the iphone locator works again...

it works fine for me with both enabled , in UI7 and UI5.
please enable DEBUG on IphoneLocator, then reload luup and send me the logs
Where can I find the debug logs?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: jeubanks on May 02, 2018, 11:20:41 am
I see that Vera has updated their device category list here (on Jan 23, 2018):
http://wiki.micasaverde.com/index.php/Luup_Device_Categories

And it seems to load a lot faster also.

PS:  has anyone actually GOT a Z-wave mousetrap??   :D

 ;D

As for the mousetrap.  I have thought about it!!! I live in the woods and we get mice in the winter and they love the garage and attic.  I've thought of getting the z-wave trap to get notifications from it when a mouse is zapped!  Beats climbing into the attic every day to check a trap.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on May 02, 2018, 11:35:13 am
I don't know, but I can guess...

...this may be the problem with adding functions to the system string library.

Until recently, the sandboxing function of openLuup has not been working totally effectively.  In the very latest development version, though, this is fixed, and you can clearly see on the console Scheduler > Sandboxes page, which plugins define which functions, and also that they are (now) different instances of each function.  This was quite hard to do, but I do believe that I have it right now.

May not be this, but it would be the first thing to look at.  Try the latest openLuup update.   The work-around of renaming new functions locally is not really effective, since, apparently, quite a large number of plugins resort to this trick:


...so not quite all @amg0's  ;)

___________________

Edit:  I just loaded iPhone Locator onto my development system and, yes, here at least is evidence:

Code: [Select]
Sandboxed system tables 

string.sandbox:

   Private items (by device):

   [376] iPhone
        mytemplate   = function: 0x019661c8
        split        = function: 0x00671df8
        trim         = function: 0x007e2348

   [369] MySensors
        split        = function: 0x019283b8
        starts       = function: 0x007cd9b0

   [3] Alternate UI
        altui_split  = function: 0x00789168
        starts       = function: 0x001a5218
        template     = function: 0x0061cb88
        trim         = function: 0x00758ac0

   Shared items:

        byte         = function: builtin#79
        char         = function: builtin#80
        dump         = function: builtin#86
        find         = function: builtin#87
        format       = function: builtin#92
        gmatch       = function: builtin#90
        gsub         = function: builtin#91
        len          = function: builtin#78
        lower        = function: builtin#84
        match        = function: builtin#88
        rep          = function: builtin#82
        reverse      = function: builtin#83
        sub          = function: builtin#81
        upper        = function: builtin#85
   
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on May 02, 2018, 06:04:24 pm
Just installed ALTHue from the AltAppStore on a Vera Edge running UI7.

Pairs OK, and child devices appear, but don't operate.  I see this message in the log:

Code: [Select]
02 05/02/18 22:56:23.259 luvd_get_info mg conn can't read /etc/cmh-ludl/D_DimmableALTHue1.xml or /etc/cmh-lu/D_DimmableALTHue1.xml from filename /luvd/D_DimmableALTHue1.xml pPtrFile D_DimmableALTHue1.xml <0x72b8e520>

and, indeed, I can't find that file in /etc/cmh-ludl/.

The Repositories field of the AltAppStore database says:

Code: [Select]
[{"type":"GitHub","pattern":"ALTHUE","source":"amg0/ALTHue","folders":["","Icons"],"versions":{"1":{"release":"1.0"}}},{"type":"Vera","versions":{"1":{"release":"36206"}}}]
and that file doesn't match the missing filename.

The strange thing is, this seems to have worked previously under openLuup??
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on May 02, 2018, 06:31:55 pm
Just installed ALTHue from the AltAppStore on a Vera Edge running UI7.

Pairs OK, and child devices appear, but don't operate.  I see this message in the log:

Code: [Select]
02 05/02/18 22:56:23.259 luvd_get_info mg conn can't read /etc/cmh-ludl/D_DimmableALTHue1.xml or /etc/cmh-lu/D_DimmableALTHue1.xml from filename /luvd/D_DimmableALTHue1.xml pPtrFile D_DimmableALTHue1.xml <0x72b8e520>

and, indeed, I can't find that file in /etc/cmh-ludl/.

The Repositories field of the AltAppStore database says:

Code: [Select]
[{"type":"GitHub","pattern":"ALTHUE","source":"amg0/ALTHue","folders":["","Icons"],"versions":{"1":{"release":"1.0"}}},{"type":"Vera","versions":{"1":{"release":"36206"}}}]
and that file doesn't match the missing filename.

The strange thing is, this seems to have worked previously under openLuup??

can you try to get the file from github ? maybe I should name them with capital letters ?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on May 02, 2018, 06:57:25 pm
can you try to get the file from github ?

No problem with that, but I was concerned for others...

Quote
maybe I should name them with capital letters ?

No need, we should just be able to change the pattern.  I'll check tomorrow, but this should work...
Code: [Select]
"pattern":"ALTH[Uu][Ee]"

Or even just
Code: [Select]
"pattern":"ALT"


Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on May 02, 2018, 11:28:38 pm
Just installed ALTHue from the AltAppStore on a Vera Edge running UI7.

Pairs OK, and child devices appear, but don't operate.  I see this message in the log:

Code: [Select]
02 05/02/18 22:56:23.259 luvd_get_info mg conn can't read /etc/cmh-ludl/D_DimmableALTHue1.xml or /etc/cmh-lu/D_DimmableALTHue1.xml from filename /luvd/D_DimmableALTHue1.xml pPtrFile D_DimmableALTHue1.xml <0x72b8e520>

and, indeed, I can't find that file in /etc/cmh-ludl/.

The Repositories field of the AltAppStore database says:

Code: [Select]
[{"type":"GitHub","pattern":"ALTHUE","source":"amg0/ALTHue","folders":["","Icons"],"versions":{"1":{"release":"1.0"}}},{"type":"Vera","versions":{"1":{"release":"36206"}}}]
and that file doesn't match the missing filename.

The strange thing is, this seems to have worked previously under openLuup??

Huh... I guess it?s my bad for not following completely amg0?s ALT naming convention to the letter... sorry. It had to be renamed a couple of times causing this confusion.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on May 03, 2018, 01:10:08 am
Huh... I guess it?s my bad for not following completely amg0?s ALT naming convention to the letter... sorry. It had to be renamed a couple of times causing this confusion.

Yes, it is.  The documentation for publishing stuff explains the rationale and discipline for file naming in GitHub repositories:

GitHub

patternthis may be blank, but otherwise contains a Lua string pattern which matches ALL the files you want to download from your GitHub repository, which often contains lots of other things (documentation, licence, folders, ...) which you don't want to download.  If you have a bit of discipline in naming your files (eg. AltUI files all contain "ALTUI") then this is easy.  If you stick to the traditional Vera naming convention for device files, then this can be "[DIJLS]_%w+%.%w+"
sourcea string of the form "amg0/ALTUI", being simply <your username>/<your GitHub repository for the plugin>
foldersthis may be blank, in which case the files matching the pattern (above) are downloaded from the root folder of the repository.  However, multiple folders may also be defined, the top level one being simply "".  Example: "luup_files, more_files" or even  ",subfolder" for top level + subfolder
releaserelease name or GitHub tag or branch name

So...

It may be necessary to update the AltAppStore plugin to handle these new icons, or it may be that a bit of renaming and moving some of the GitHub folders can do it. 

I need to understand what's needed to be achieved before I can suggest the way forward.  As it is, the AltAppStore install of ALTHue is currently broken.

______________

Edit:  I see that "anonymous" (@amg0?) has updated the database with the pattern "ALTH[Uu][Ee]"

Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on May 03, 2018, 01:49:01 am
Huh... I guess it?s my bad for not following completely amg0?s ALT naming convention to the letter... sorry. It had to be renamed a couple of times causing this confusion.

Yes, it is.  The documentation for publishing stuff explains the rationale and discipline for file naming in GitHub repositories:

GitHub

patternthis may be blank, but otherwise contains a Lua string pattern which matches ALL the files you want to download from your GitHub repository, which often contains lots of other things (documentation, licence, folders, ...) which you don't want to download.  If you have a bit of discipline in naming your files (eg. AltUI files all contain "ALTUI") then this is easy.  If you stick to the traditional Vera naming convention for device files, then this can be "[DIJLS]_%w+%.%w+"
sourcea string of the form "amg0/ALTUI", being simply <your username>/<your GitHub repository for the plugin>
foldersthis may be blank, in which case the files matching the pattern (above) are downloaded from the root folder of the repository.  However, multiple folders may also be defined, the top level one being simply "".  Example: "luup_files, more_files" or even  ",subfolder" for top level + subfolder
releaserelease name or GitHub tag or branch name

So...
  • There's nothing difficult in changing the pattern, but it is just a single pattern, not per directory.  speaking of which...
  • you have multiple directories.  This is fine too, but only .png files are recognised as icons and placed in the appropriate icon directories on Vera (much easier on openLuup)
  • where do you need these new .svg icon files to end up?
  • there's also a UI5 directory in GitHub - what's supposed to be done with that?

It may be necessary to update the AltAppStore plugin to handle these new icons, or it may be that a bit of renaming and moving some of the GitHub folders can do it. 

I need to understand what's needed to be achieved before I can suggest the way forward.  As it is, the AltAppStore install of ALTHue is currently broken.
Thank you AK
I did manually change the pattern ( based on your earlier suggestion , have a look?olease )

Svg should go to the same folder as png. There are the dynamics vectoriel icon styles to enable color changes in icons

Ui5 folder can be ignored for now, I need to think about it.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: akbooer on May 03, 2018, 02:01:49 am
I did manually change the pattern ( based on your earlier suggestion , have a look?olease )

So you did.  I just updated my previous post as you were typing your reply!
I reloaded this on Vera and it all seems to work - even the fancy icons (very cool.)

Quote
Svg should go to the same folder as png. There are the dynamics vectoriel icon styles to enable color changes in icons

How can it be working if the AltAppStore plugin is not handling the .svg files correctly?!
(I only have dimmable white bulbs at present, if that makes any difference.)

Quote
Ui5 folder can be ignored for now, I need to think about it.

OK.  Perhaps requires a bit of manual intervention required for those on UI5.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: rafale77 on May 03, 2018, 10:08:56 am
How can it be working if the AltAppStore plugin is not handling the .svg files correctly?!
(I only have dimmable white bulbs at present, if that makes any difference.)
 it.

Not sure where the Veras look for their icons by default. I think amg0 had sent them to the correct one for the mios hosted one. On openLuup, as you well know they just need to be in the openLuup folder so it has not been a problem.
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on May 04, 2018, 01:28:29 pm
How can it be working if the AltAppStore plugin is not handling the .svg files correctly?!
(I only have dimmable white bulbs at present, if that makes any difference.)
 it.

Not sure where the Veras look for their icons by default. I think amg0 had sent them to the correct one for the mios hosted one. On openLuup, as you well know they just need to be in the openLuup folder so it has not been a problem.
Note: .svg files from Icons folder must be uploaded on:
UI7 => /www/cmh/skins/default/img/devices/device_states
UI5 => /www/cmh/skins/default/icons
Title: Re: ALTHue : Feature Requests
Post by: rafale77 on May 04, 2018, 01:36:55 pm
@amg0
FYI for 1.2, it does not appear that you updated the version number everywhere. The device shows 1.2 but the plugin page still show 1.1b.
Title: Re: ALTHue : Feature Requests
Post by: akbooer on May 04, 2018, 01:40:41 pm
Quote
UI7 => /www/cmh/skins/default/img/devices/device_states
UI5 => /www/cmh/skins/default/icons


Yes indeed, I had no doubt about that.  The trouble is that the current version only does this for .png files and not .svg.

No problem with that... I'll update it and then you can have the pleasure of downloading the AltAppStore plugin from the AltAppStore!
Title: Re: ALTHue : Feature Requests
Post by: amg0 on May 04, 2018, 01:48:19 pm
@amg0
FYI for 1.2, it does not appear that you updated the version number everywhere. The device shows 1.2 but the plugin page still show 1.1b.
ouch. you are most likely right
can you do a screen shot ?,  it is not totally clear to me what you mean by "device shows" or "plugin page".
Title: Re: ALTHue : Feature Requests
Post by: rafale77 on May 04, 2018, 02:03:22 pm
See what I am referring to. I just updated to 1.2 and this page still shows 1.1b
Title: Re: ALTHue : Feature Requests
Post by: amg0 on May 04, 2018, 02:06:11 pm
See what I am referring to. I just updated to 1.2 and this page still shows 1.1b

ok  I think this is related to vera store or openluup. that page displays the user_data version of that info and I do not control it, it must depand on vera store version availability and vera store does not yet have 1.2 version in it

on OpenLuup, i am not sure where this info comes from
do you see 1.2 in the device Version variable ?
Title: Re: ALTHue : Feature Requests
Post by: rafale77 on May 04, 2018, 02:09:12 pm
I don't think it is related to the appstore. All my other plugins, when updating from this page and pull from github, update the version number (including the ALTHue previously since I started at 0.9X) even without changing the version published on the alt appstore. This is the first time I am seeing out of sync. The only one published on the altappstore is currently 1.02...

Edit: Got it fixed by running another update by forcing download from "master" branch. This was strange. Now I see "1.2."
Title: Re: ALTHue : Feature Requests
Post by: akbooer on May 04, 2018, 02:53:53 pm
My fault, I believe.
Another thing to add to the list.

I'm sorry, but I'm not well enough at the moment to do anything much.  I seem to be making things worse, not better.

"I'll be back."
Title: Re: ALTHue : Feature Requests
Post by: a-lurker on May 05, 2018, 11:13:33 pm
This plugin is working well - thanks for the nice job.

Minor problem: using ver 1.0 on openLuup with a simple white bulb.

If you set the dimming level to 100, it goes to and stays at 100. Likewise for zero. However, if you set level to say 20, it will be at 20 until the plugin polls the lights and then it drops back by one to 19. It does this for all levels between 99 and 1. They become 98 to 0. The zero is then not considered to be off. You can see this in AltUI - the slider moves a little and the percent value drops by one.

Why is this a problem? I have a light that I set to a level of 5 as a night light. I can tell if someone changes the level (to say 90), as it will no longer be 5. So after a time period I check the level and if its not 5, I change it back to 5. ie back to nightlight mode.

However when I set it to 5 it always reads back as 4, so it gets set to 5 again ... forever. I could accept a range of 4 to 5 as being OK but it seems that once a level is set the status should read back with the set level.

It's probably something to do with how the dimming is mapped in the plugin. I note that the Hue API says:

Quote
On/Off ...true turns a light on to its last setting. Setting to false turns the light off.
dimming ...light will actually return 1 when set to 0 and return 254 when set to 255
Title: Re: ALTHue : Feature Requests
Post by: amg0 on May 06, 2018, 10:45:55 am
This plugin is working well - thanks for the nice job.

Minor problem: using ver 1.0 on openLuup with a simple white bulb.

If you set the dimming level to 100, it goes to and stays at 100. Likewise for zero. However, if you set level to say 20, it will be at 20 until the plugin polls the lights and then it drops back by one to 19. It does this for all levels between 99 and 1. They become 98 to 0. The zero is then not considered to be off. You can see this in AltUI - the slider moves a little and the percent value drops by one.

Why is this a problem? I have a light that I set to a level of 5 as a night light. I can tell if someone changes the level (to say 90), as it will no longer be 5. So after a time period I check the level and if its not 5, I change it back to 5. ie back to nightlight mode.

However when I set it to 5 it always reads back as 4, so it gets set to 5 again ... forever. I could accept a range of 4 to 5 as being OK but it seems that once a level is set the status should read back with the set level.

It's probably something to do with how the dimming is mapped in the plugin. I note that the Hue API says:

Quote
On/Off ...true turns a light on to its last setting. Setting to false turns the light off.
dimming ...light will actually return 1 when set to 0 and return 254 when set to 255

I have put a new version in github.  I think it fixes this issue,  i needed to find a reversible law to map 0-100 to 0-255 and vice versa arriving to the same values. I think I have a valid one now with an mix of floor and ceil logic


Vera   v/100 * 255   Floor()   v/255 * 100   Vera Ceil()
100   255,00   255,00   100,00   100
99   252,45   252,00   98,82   99
90   229,50   229,00   89,80   90
80   204,00   204,00   80,00   80
20   51,00   51,00   20,00   20
10   25,50   25,00   9,80   10
1   2,55   2,00   0,78   1
0   0,00   0,00   0,00   0
Title: Re: ALTHue : Feature Requests
Post by: rafale77 on May 10, 2018, 12:22:58 pm
A minor general thing: I noticed that Safari frequently has a hard time with cached icons from "raw.githubusercontent.com" and I tend to get them turned into a generic zwave icon. Is there any reason to keep hosting them there as opposed to just make them local? I am seeing ALTHue, ALTUI and the verabridge as the icons which tend to not work until I clear the cache from "raw.githubusercontent.com"
Title: Re: ALTHue : Feature Requests
Post by: amg0 on May 10, 2018, 12:57:11 pm
A minor general thing: I noticed that Safari frequently has a hard time with cached icons from "raw.githubusercontent.com" and I tend to get them turned into a generic zwave icon. Is there any reason to keep hosting them there as opposed to just make them local? I am seeing ALTHue, ALTUI and the verabridge as the icons which tend to not work until I clear the cache from "raw.githubusercontent.com"
I notice the same, in fact raw.githubusercontent.com is not supposed to be used
we are supposed to use this : https://rawgit.com/
I ll migrate my urls to it. the bonus is the url will include the commit number so caching issue should go away

EDIT: I commited the change in github
EDIT2: remote icons works better for remote access. it is true that if internet cnx is not there it may fail but it would be in your cache hopefully
Title: Re: ALTHue : Feature Requests
Post by: a-lurker on May 10, 2018, 08:55:10 pm
In a similar vein, I use the secure github.io for my icons:

https://github.com/a-lurker/a-lurker.github.io/tree/master/icons

https://blog.github.com/2013-04-05-new-github-pages-domain-github-io/

However, I note they get redirected to https://raw.githubusercontent.com but the headers are correct. However, having a CDN in place is good but  https://rawgit.com/  does not seem to be affiliated with GitHub.
Title: Re: ALTHue : Feature Requests
Post by: wise72 on May 15, 2018, 07:25:43 pm
Thank you for the great work.
Any way to get a variable (within lua script) as to wether a specific bulb is reachable (as shown in the control menu)?
Title: Re: ALTHue : Feature Requests
Post by: tomtcom on May 19, 2018, 12:39:54 pm
Hello, thanks for the excellent work!

2 small bugs noted.

1. When typing in the IP or selecting it, I finally saw two spaces inserted after selecting the IP address. This prevented the plugin from starting until I manually backspaced the spaces. I did not copy/paste my IP or anything like that.

2. When selecting the option to remove Hue from the prefix of the name, the setting does not retain and the lights still have Hue instead of the custom name.
Title: Re: ALTHue : Feature Requests
Post by: RichieB on May 27, 2018, 12:32:22 pm
 hey Color temperature light   is there a way to change the tempreture
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: sk1.publicc on June 06, 2018, 08:34:45 am

on the very latest version, you can use UPNP : SetColor  and parameter "W0"
W0     <--> W255  =  D0     <--> D255
2000K <--> 5500K = 5500K <--> 9000K

or you can use the device control panel ( but not for scene edition )

@amg0 Thanks for the parameter value ranges. 
If I started with a desired color temp and wanted to work back to the D or W value, is there a specific formula to use? 
eg. is it as simple as 255 increments (W0 - W255) of 13.7K between 2000K - 5500K?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: amg0 on June 06, 2018, 04:19:48 pm

on the very latest version, you can use UPNP : SetColor  and parameter "W0"
W0     <--> W255  =  D0     <--> D255
2000K <--> 5500K = 5500K <--> 9000K

or you can use the device control panel ( but not for scene edition )

@amg0 Thanks for the parameter value ranges. 
If I started with a desired color temp and wanted to work back to the D or W value, is there a specific formula to use? 
eg. is it as simple as 255 increments (W0 - W255) of 13.7K between 2000K - 5500K?

it s been while a went into this code, i think it comes down to what you say more or less but there is the exact code
Code: [Select]
-- Warm White: Wx
-- Cool White: Dx
-- W0     <--> W255  =  D0     <--> D255
-- 2000K <--> 5500K = 5500K <--> 9000K
-- mired range : 153 (6500K) to 500 (2000K).

function UserSetColor(lul_device,newColorTarget)
debug(string.format("UserSetColor(%s,%s)",lul_device,newColorTarget))
local warmcool = string.sub(newColorTarget, 1, 1)
local value = tonumber(string.sub(newColorTarget, 2))
local kelvin = math.floor((value*3500/255)) + ((warmcool=="D") and 5500 or 2000)

local mired = math.floor(1000000/kelvin)
local newValue = luup.variable_get("urn:upnp-org:serviceId:Dimming1", "LoadLevelStatus", lul_device)
local bri = math.floor(255*newValue/100)

debug(string.format("UserSetColor target: %s => bri:%s ct:%s",newColorTarget, bri,mired))
local body = string.format('{"on":true, "bri": %d, "ct":%s}', bri, mired )
HueLampSetState(lul_device,body)
end
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: sk1.publicc on June 11, 2018, 12:26:38 am

it s been while a went into this code, i think it comes down to what you say more or less but there is the exact code



Brilliant - thanks for that.  Great app BTW.  I've been able to solve a lot of lighting issues using it!
Title: Re: ALTHue : Feature Requests
Post by: Kositch on June 11, 2018, 05:11:53 am
Can I install it normaly using native UI7: Apps - Install Apps?

I see there plugin Philips Hue ALTHue plugin, Updated:2018-05-06 09:57:50, Current Version:1.3.

Is this the latest version?

Thanks.

Title: Re: ALTHue : Feature Requests
Post by: rafale77 on June 11, 2018, 05:26:47 am
Can I install it normaly using native UI7: Apps - Install Apps?

I see there plugin Philips Hue ALTHue plugin, Updated:2018-05-06 09:57:50, Current Version:1.3.

Is this the latest version?

Thanks.



Yes. Check here:

http://forum.micasaverde.com/index.php/topic,77266.0.html
Title: Re: ALTHue : Feature Requests
Post by: Kositch on June 11, 2018, 07:50:35 am

Yes. Check here:

http://forum.micasaverde.com/index.php/topic,77266.0.html

Thanks, I was not sure, if "published in the MCV Store http://apps.mios.com/plugin.php?id=9066" means Vera store, I suppose MCV is Vera store indeed  :D
Title: Re: ALTHue : Feature Requests
Post by: fullmoonguru on June 11, 2018, 01:15:59 pm
Just experimenting with this plugin and I wanted to create a scene to change the color of the lights. Looks like that's not available in UI7 so I tried in AltUI. I have the action set as this: RunHueScene (hueSceneID: NPN5zwYf-zQgo39). That should be changing the lights to the arctic blue scene but I'm getting anything. Should this be working or is there some issue I'm not aware of?
Title: Re: ALTHue : Feature Requests
Post by: amg0 on June 11, 2018, 02:09:28 pm
Just experimenting with this plugin and I wanted to create a scene to change the color of the lights. Looks like that's not available in UI7 so I tried in AltUI. I have the action set as this: RunHueScene (hueSceneID: NPN5zwYf-zQgo39). That should be changing the lights to the arctic blue scene but I'm getting anything. Should this be working or is there some issue I'm not aware of?

Just tested , It works for me. Have you tried from the ? hue scene ?  tabs in settings? The scene Id is displayed and you can click the button to run it.
Title: Re: ALTHue : Feature Requests
Post by: fullmoonguru on June 11, 2018, 03:16:39 pm
That's weird. Definitely not working here. If I create a scene in UI7 and pick a color I see this in the AltUI scene editor:

SetColorRGB (newColorRGBTarget: 243,247,245)

That works fine but using RunHueScene with the Hue scene ID doesn't work for me.
Title: Re: ALTHue : Feature Requests
Post by: amg0 on June 11, 2018, 03:30:22 pm
That's weird. Definitely not working here. If I create a scene in UI7 and pick a color I see this in the AltUI scene editor:

SetColorRGB (newColorRGBTarget: 243,247,245)

That works fine but using RunHueScene with the Hue scene ID doesn't work for me.

What?s version of the althue plugin do you have ?
Can you go into settings / hue scenes / and tu one from here ? Does it work ?
Title: Re: ALTHue : Feature Requests
Post by: Kositch on June 11, 2018, 04:34:31 pm

Just tested , It works for me. Have you tried from the ? hue scene ?  tabs in settings? The scene Id is displayed and you can click the button to run it.

I have tested it as well, just installed Hue system today and it works (running scenes on my bulbs).

I have only one issue - whenever I rename bulb in UI7, it gets back to original name I put on Hue app after a few seconds, is it normal behaviour? And if don't want any prefix, how can I do that? When I remove Hue prefix and leave it blank in Settings, it gets back to Hue.
Title: Re: ALTHue : Feature Requests
Post by: fullmoonguru on June 11, 2018, 04:42:37 pm
Sorry, forgot to answer that question. It does work when I run it from the Hue app. The app version is 1.3. Just installed it today on an Edge with updated firmware.
Title: Re: ALTHue : Feature Requests
Post by: amg0 on June 11, 2018, 04:56:32 pm

Just tested , It works for me. Have you tried from the ? hue scene ?  tabs in settings? The scene Id is displayed and you can click the button to run it.

I have tested it as well, just installed Hue system today and it works (running scenes on my bulbs).

I have only one issue - whenever I rename bulb in UI7, it gets back to original name I put on Hue app after a few seconds, is it normal behaviour? And if don't want any prefix, how can I do that? When I remove Hue prefix and leave it blank in Settings, it gets back to Hue.

I confirm, names in Hue app are the master.
regarding the prefix,  maybe it is a UI7 bug ? I did this experiment in ALTUI ( go to settings tab, clear the prefix ) and after save/reload the devices were renamed without prefix.
Title: Re: ALTHue : Feature Requests
Post by: amg0 on June 11, 2018, 05:00:00 pm
Sorry, forgot to answer that question. It does work when I run it from the Hue app. The app version is 1.3. Just installed it today on an Edge with updated firmware.
sorry but I do not understand. can you please share a screen copy of your Hue device 'Hue Scenes" tab, and show another screen copy of how you try to call the action : RunHueScene(id) which fails so I try to get what you do exactly ?
Title: Re: ALTHue : Feature Requests
Post by: fullmoonguru on June 11, 2018, 05:30:14 pm
Attached
Title: Re: ALTHue : Feature Requests
Post by: Kositch on June 12, 2018, 02:30:11 am
This plugin is so perfect, it works far better then the Vera native one.

I want to ask just few questions:

1) How can I run Hue scenes withing Vera scenes? For example I would like to run hue scene called "polar" when the temperature drops below X degrees on my Netatmo sensor.

2) Is there some way to create Vera shortcut or just simple "virtual" device with on/off trigger to run a specific Hue scene on specific bulb? Something like widget on Philips Hue app.

3) Is it normal, that all hue color bulbs show as simple bulbs on Vera mobile app (iOS)? I cant set color or even intensity of those bulbs on mobile app (see screenshot). White ambiente bulbs shows correctly and I can even set intensity on those bulbs.


Thanks, I would definitely make donation for this plugin!
Title: Re: ALTHue : Feature Requests
Post by: amg0 on June 12, 2018, 05:57:35 am
Attached

I suggest you try to put it in a delayed group of actions like 10s later for now and gradually reduce to 1s  if it works
( doing 2 actions n the same device in the same group may not work that great , not even sure the order is garanteed by vera )
Title: Re: ALTHue : Feature Requests
Post by: amg0 on June 12, 2018, 06:02:17 am
This plugin is so perfect, it works far better then the Vera native one.

I want to ask just few questions:

1) How can I run Hue scenes withing Vera scenes? For example I would like to run hue scene called "polar" when the temperature drops below X degrees on my Netatmo sensor.

2) Is there some way to create Vera shortcut or just simple "virtual" device with on/off trigger to run a specific Hue scene on specific bulb? Something like widget on Philips Hue app.

3) Is it normal, that all hue color bulbs show as simple bulbs on Vera mobile app (iOS)? I cant set color or even intensity of those bulbs on mobile app (see screenshot). White ambiente bulbs shows correctly and I can even set intensity on those bulbs.


Thanks, I would definitely make donation for this plugin!

1) AltHue supports a UPNP action which you can use in VERA scenes
2) no , I figured the right way of using it is to program VERA scenes using Hue virtual devices.  1) is the workaround of trigeering a Hue scene in a vera scene
3) not exactly sure how VERA app does it but if you would use ALTUI plugin and its interface on phone it would look like this
Title: Re: ALTHue : Feature Requests
Post by: Kositch on June 12, 2018, 06:23:33 am
1) AltHue supports a UPNP action which you can use in VERA scenes
2) no , I figured the right way of using it is to program VERA scenes using Hue virtual devices.  1) is the workaround of trigeering a Hue scene in a vera scene
3) not exactly sure how VERA app does it but if you would use ALTUI plugin and its interface on phone it would look like this

Thanks for reply, any advice or guide somewhere present for 1)? I am quite new to Vera world, so I would like to learn how to create UPNP action if it is the only way how to run Hue Scenes in Vera scenes.
Title: Re: ALTHue : Feature Requests
Post by: darbey on June 12, 2018, 03:08:29 pm
Is it just me or is it not possible to remove the "Hue " prefix? I'd prefer no prefix........

Literally my only gripe with the app. Incredible work and so easy to get up and running.
Title: Re: ALTHue : Feature Requests
Post by: Kositch on June 12, 2018, 04:21:38 pm
Is it just me or is it not possible to remove the "Hue " prefix? I'd prefer no prefix........

Literally my only gripe with the app. Incredible work and so easy to get up and running.

+1 I can't remove it either (UI7, Edge).
Title: Re: ALTHue : Feature Requests
Post by: amg0 on June 12, 2018, 04:34:11 pm
R?cent ui7 has a pretty nasty bug, you cannot edit a variable and set it to empty.

You can via either the settings tab of the device , or by using ALTUI. Just go into prefix field ( or to NamePrefix variable and clear the value ), save , reload luup.

Alternative in ui7 is to write a luup line in test lua window which sets the variable to empty string
Title: Re: ALTHue : Feature Requests
Post by: fullmoonguru on June 12, 2018, 04:34:55 pm
I haven't tried the delay but wouldn't the scenes that specify the colors work fine, whereas the ones that specify the Hue scene ID don't. Is there some reason calling the ID would take longer? I would try it but not sure how to enter the delay in AltUI scene.

Also I did try one that just changed the color without the power command.
Title: Re: ALTHue : Feature Requests
Post by: amg0 on June 12, 2018, 04:37:57 pm
1) AltHue supports a UPNP action which you can use in VERA scenes
2) no , I figured the right way of using it is to program VERA scenes using Hue virtual devices.  1) is the workaround of trigeering a Hue scene in a vera scene
3) not exactly sure how VERA app does it but if you would use ALTUI plugin and its interface on phone it would look like this

Thanks for reply, any advice or guide somewhere present for 1)? I am quite new to Vera world, so I would like to learn how to create UPNP action if it is the only way how to run Hue Scenes in Vera scenes.

Use the scene advanced editor , select althue device , select runhuescene action, type the hue scene Id that you can find in the hue scene settings tab.
Title: Re: ALTHue : Feature Requests
Post by: darbey on June 12, 2018, 06:16:13 pm
R?cent ui7 has a pretty nasty bug, you cannot edit a variable and set it to empty.

You can via either the settings tab of the device , or by using ALTUI. Just go into prefix field ( or to NamePrefix variable and clear the value ), save , reload luup.

Alternative in ui7 is to write a luup line in test lua window which sets the variable to empty string

Can?t remove it on settings tab (it keeps reappearing). Renaming the device works temporarily but the name gets changed back next think it talks to the hub it seems.

As I said it?s a relatively minor issue. Incredible work for it to work so simply (just the 3 bulbs at the moment but will be adding another 3 tomorrow)
Title: Re: ALTHue : Feature Requests
Post by: Nefasto78 on June 30, 2018, 04:48:31 am
I tested Osram smart+ plug and unfortunately it does not work well as seen as dimmable, Lightify Flex, on the other hand, works well.
Title: Re: ALTHue : Feature Requests
Post by: amg0 on July 05, 2018, 05:28:50 pm
I tested Osram smart+ plug and unfortunately it does not work well as seen as dimmable, Lightify Flex, on the other hand, works well.
many horror story on the web about firmware issue and shaky compatiblity. the very first thing to establish is what works with the philips Hue App.  THen, you can give me the device huename, the device_type, device_json and content of ALTUI "Hue Data" settings tab
Title: Re: ALTHue : Feature Requests
Post by: darbey on July 08, 2018, 05:30:52 pm
Any possibility of adding or confiming compatibility with the new 24v drivers from Ikea?

https://www.ikea.com/gb/en/products/lighting/integrated-lighting/tr%C3%A5dfri-driver-for-wireless-control-grey-art-60342656/?tduid=7c7e6c1c3246a17eae929ac3b1d50af1&cid=af|de|no_cc_topic|8QLTLHoMXcHjkMCiMkq45STGXzeHDv
Title: Re: ALTHue : Feature Requests
Post by: Peiloy on July 10, 2018, 08:57:31 am
If possible, can Hue dimmer switches be added in the future?
Title: Re: ALTHue : Feature Requests
Post by: rafale77 on July 10, 2018, 09:33:05 am
If possible, can Hue dimmer switches be added in the future?

Not sure what you would want to do with the dimmer on the vera: it is a light controller. Why would you want to control it from another controller when you can control all the lights already?
Title: Re: Re: New Plugin : ALTHue - the Alternate Edition of the Philips Hue Plugin
Post by: bnflaherty on July 11, 2018, 12:12:14 pm
Maybe it's just me.. Or the rain.. or work from home today.. or it's Wednesday .. but just installed the new plugin on UI5 and it refuses to pair. I tried on a previous version but same issue.. and I'm sick of just using the Hue app ... I need my integration :)

to trouble shoot I can suggest this approach

1 describe your setup
2 enable debug mode on ALTHue device
3 reload luup engine
4 go to ALTHUE settings
5 make sure IP address is correct
6 press the pair button on the hub
7 press the pair button on the settings
8 remove debug mode on ALTHue device

if it fails,  get the log file from vera in /var/log/cmh covering the whole period ( step 2 to 8 ) and share so I can look at it

I'm good Now .. never did get it working then .. but today I took the jump and upgraded to UI7 .. Plugin Installed flawlessly :)
Title: Re: ALTHue : Feature Requests
Post by: Peiloy on July 12, 2018, 09:38:58 pm
If possible, can Hue dimmer switches be added in the future?

Not sure what you would want to do with the dimmer on the vera: it is a light controller. Why would you want to control it from another controller when you can control all the lights already?

In certain situations it?s applicable. For example, in my master bedroom I have recessed lighting that is on a zwave dimmer, but my side lamps and main light pendant are hue bulbs which are controlled by the hue dimmer. Right now I have to set up a scene to turn off the recessed lighting when the hue bulbs are off and to turn it back on when the bulbs are on. This poses two problems. 1) I don?t have direct control of the recessed light dimming as the scenes are for a fixed value. 2) there is a delay between the hue lights turning on and off and the recessed turning on and off. Sometimes the Vera doesn?t fire the scene and the recessed lights stay on or off as the case may be.
Title: Re: ALTHue : Feature Requests
Post by: rafale77 on July 13, 2018, 09:48:36 am
If possible, can Hue dimmer switches be added in the future?

Not sure what you would want to do with the dimmer on the vera: it is a light controller. Why would you want to control it from another controller when you can control all the lights already?

In certain situations it?s applicable. For example, in my master bedroom I have recessed lighting that is on a zwave dimmer, but my side lamps and main light pendant are hue bulbs which are controlled by the hue dimmer. Right now I have to set up a scene to turn off the recessed lighting when the hue bulbs are off and to turn it back on when the bulbs are on. This poses two problems. 1) I don?t have direct control of the recessed light dimming as the scenes are for a fixed value. 2) there is a delay between the hue lights turning on and off and the recessed turning on and off. Sometimes the Vera doesn?t fire the scene and the recessed lights stay on or off as the case may be.

I am still scratching my head as I don't understand how controlling the hue dimmer would help any of these two problems.
The delay between the hue light and zwave is a vera/zwave network problem. I have a vera similar setup with scenes triggering both and the inconsistency is all due to the vera poor handling of the zwave network. Control of the dimming of the recessed light is easy to fix it is all coding of your scene. Controlling the hue dimmer will not help. What you are trying to control is the dimming of your zwave dimmer.
Title: Re: ALTHue : Feature Requests
Post by: CaptainMoody on July 24, 2018, 06:00:01 am
I have just installed this plugin and it all works flawlessly.

I have some Innr GU10 downlights (https://www.amazon.co.uk/Innr-Smart-Dimmable-Compatible-Ecosystem/dp/B01LT9UK7I (https://www.amazon.co.uk/Innr-Smart-Dimmable-Compatible-Ecosystem/dp/B01LT9UK7I)) in my system that can be added to the "works with" list.  :)
Title: Support for the Osram outdoor plug
Post by: Alealvag on September 02, 2018, 03:01:56 pm
Hello,

It would be great if we could control the Osram outdoor plug that is compatible with Hue

I currently have 2 plugs that are recognised as dimmable lights. I am able to turn them on via the altHue plugin. But not possible to turn off.

Thanks!

Andreas
Title: Re: Support for the Osram outdoor plug
Post by: amg0 on September 03, 2018, 05:16:47 am
Hello,

It would be great if we could control the Osram outdoor plug that is compatible with Hue

I currently have 2 plugs that are recognised as dimmable lights. I am able to turn them on via the altHue plugin. But not possible to turn off.

Thanks!

Andreas
I do not have it so makes it impractical to support, can you give the althue data tab export and try to see which command is the on off using Philips api tester http://<bridge ip address>/debug/clip.html
 as explained here : https://developers.meethue.com/documentation/getting-started
Title: Re: Support for the Osram outdoor plug
Post by: Alealvag on September 03, 2018, 08:10:07 am
Hello,

It would be great if we could control the Osram outdoor plug that is compatible with Hue

I currently have 2 plugs that are recognised as dimmable lights. I am able to turn them on via the altHue plugin. But not possible to turn off.

Thanks!

Andreas
I do not have it so makes it impractical to support, can you give the althue data tab export and try to see which command is the on off using Philips api tester http://<bridge ip address>/debug/clip.html
 as explained here : https://developers.meethue.com/documentation/getting-started


I'll give that a go and revert back here with my findings!
Title: Re: Support for the Osram outdoor plug
Post by: Alealvag on September 03, 2018, 01:56:20 pm
Hello,

It would be great if we could control the Osram outdoor plug that is compatible with Hue

I currently have 2 plugs that are recognised as dimmable lights. I am able to turn them on via the altHue plugin. But not possible to turn off.

Thanks!

Andreas
I do not have it so makes it impractical to support, can you give the althue data tab export and try to see which command is the on off using Philips api tester http://<bridge ip address>/debug/clip.html
 as explained here : https://developers.meethue.com/documentation/getting-started


I'll give that a go and revert back here with my findings!

I have now used the Philips API tester and command {"on":false} and {"on":true} turns the device on and off. I believe that the problem is that it is recognised in altHue as a dimmable device... But I am not sure.

This the way it looks in altHue data now with the plug turned off. When turned on the state below says: "on": true

"5": {
      "productname": "On/Off plug",
      "capabilities": {
        "streaming": {
          "renderer": false,
          "proxy": false
        },
        "control": [],
        "certified": false
      },
      "manufacturername": "OSRAM",
      "swversion": "V1.04.90",
      "state": {
        "reachable": true,
        "mode": "homeautomation",
        "alert": "none",
        "on": false
      },
      "config": {
        "function": "functional",
        "direction": "omnidirectional",
        "archetype": "classicbulb"
      },
      "swupdate": {
        "state": "notupdatable"
      },
      "name": "Outdoor lightning veranda",
      "type": "On/Off plug-in unit",
      "modelid": "Plug 01",
      "uniqueid": "7c:b0:3e:aa:00:ab:31:ba-03"
    }
Title: Re: ALTHue : Feature Requests
Post by: amg0 on September 03, 2018, 06:16:10 pm
can you please try v1.41 from https://github.com/amg0/ALTHue ?
Title: Re: ALTHue : Feature Requests
Post by: Alealvag on September 04, 2018, 02:59:13 am
can you please try v1.41 from https://github.com/amg0/ALTHue ?

I downloaded the updated LUA file from Github and uploaded to my vera.

And I am glad to say that it works as expected now. I have checked to see that the true and false values changes in the altHue data tab, it does. I have also checked to see that it updates in the Hue app and it does. It also works the other way around if I use the Hue app to control my lights and switches.


Thank you very much! Sent a donation your way :)

Regards
Andreas

Title: Re: ALTHue : Feature Requests
Post by: amg0 on September 04, 2018, 04:54:11 am
can you please try v1.41 from https://github.com/amg0/ALTHue ?

I downloaded the updated LUA file from Github and uploaded to my vera.

And I am glad to say that it works as expected now. I have checked to see that the true and false values changes in the altHue data tab, it does. I have also checked to see that it updates in the Hue app and it does. It also works the other way around if I use the Hue app to control my lights and switches.


Thank you very much! Sent a donation your way :)

Regards
Andreas
thx a lot, well appreciated plus now we can add a new supported device in the list
Title: Re: ALTHue : Feature Requests
Post by: AndyPlus on October 12, 2018, 06:22:47 pm
Thanks for an excellent plugin!

I had issues connecting my Vera plus and Hue bridge 2 and followed the suggested steps:
"

Quote
to trouble shoot I can suggest this approach:
1 describe your setup
2 enable debug mode on ALTHue device
3 reload luup engine
4 go to ALTHUE settings
5 make sure IP address is correct
6 press the pair button on the hub
7 press the pair button on the settings
8 remove debug mode on ALTHue device"

To read out the log i used the following apporach:
"http://XXX.XXX.XXX.XXX/cgi-bin/cmh/log.sh?Device=LuaUPnP"        Replace xxx with your IP.
Found it at:
https://www.vesternet.com/resources/application-notes/apnt-32/

Found the following logged error, despite a very distinct pushing of the button on the hub:
"luup_log:230: ALTHUE: error: New User is not accepted by the bridge, did you press the Link button on the Bridge ? : link button not pressed"

The "hue essentials" app can send "virtual push button":
https://www.reddit.com/r/Hue/comments/7sszdw/hue_bridge_virtual_button_press/

The Virtual push button did the trick and the Hue bridge connected to vera plus!   :)

Could it be so simple that the button is broken?

Regards,
Andy





Title: Re: ALTHue : Feature Requests
Post by: amg0 on October 15, 2018, 05:43:04 am
Thanks for an excellent plugin!

I had issues connecting my Vera plus and Hue bridge 2 and followed the suggested steps:
"

Quote
to trouble shoot I can suggest this approach:
1 describe your setup
2 enable debug mode on ALTHue device
3 reload luup engine
4 go to ALTHUE settings
5 make sure IP address is correct
6 press the pair button on the hub
7 press the pair button on the settings
8 remove debug mode on ALTHue device"

To read out the log i used the following apporach:
"http://XXX.XXX.XXX.XXX/cgi-bin/cmh/log.sh?Device=LuaUPnP"        Replace xxx with your IP.
Found it at:
https://www.vesternet.com/resources/application-notes/apnt-32/

Found the following logged error, despite a very distinct pushing of the button on the hub:
"luup_log:230: ALTHUE: error: New User is not accepted by the bridge, did you press the Link button on the Bridge ? : link button not pressed"

The "hue essentials" app can send "virtual push button":
https://www.reddit.com/r/Hue/comments/7sszdw/hue_bridge_virtual_button_press/

The Virtual push button did the trick and the Hue bridge connected to vera plus!   :)

Could it be so simple that the button is broken?

Regards,
Andy

very weird, it does feel like a faulty push button on the philips hub.
Title: Re: ALTHue : Feature Requests
Post by: hmspain on January 24, 2019, 08:58:51 pm
I'm running a Vera Plus with UI7.  Your ALTHUE app installed and configured fine... but before I go further, can your app support more than one hub?  I just finished skimming through 14 pages (sorry, late to the party), but could not find anyone with more than one hub.

Thank you!  It is encouraging to see some progress in the Vera/Hue world; we've been stuck for quite some time :-).
Title: Re: ALTHue : Feature Requests
Post by: hmspain on January 25, 2019, 12:51:59 am
I'm running a Vera Plus with UI7.  Your ALTHUE app installed and configured fine... but before I go further, can your app support more than one hub?  I just finished skimming through 14 pages (sorry, late to the party), but could not find anyone with more than one hub.

Thank you!  It is encouraging to see some progress in the Vera/Hue world; we've been stuck for quite some time :-).

Figured it out :-).  You have to manually add the device.  Check the device that ALTHue created, and use the filenames etc from it.  The rest is just "keep at it" until the second device connects to your second hub.

I named the first hub devices "Hue1 " (yes with a space), and the second hub devices are "Hue2 ".

Everything appears to work :-).  I'm looking forward to playing with it!  Especially the motion sensors since Vera support said this could not be done due to the protocol???
Title: Re: ALTHue : Feature Requests
Post by: amg0 on January 25, 2019, 06:18:17 am
I'm running a Vera Plus with UI7.  Your ALTHUE app installed and configured fine... but before I go further, can your app support more than one hub?  I just finished skimming through 14 pages (sorry, late to the party), but could not find anyone with more than one hub.

Thank you!  It is encouraging to see some progress in the Vera/Hue world; we've been stuck for quite some time :-).

Figured it out :-).  You have to manually add the device.  Check the device that ALTHue created, and use the filenames etc from it.  The rest is just "keep at it" until the second device connects to your second hub.

I named the first hub devices "Hue1 " (yes with a space), and the second hub devices are "Hue2 ".

Everything appears to work :-).  I'm looking forward to playing with it!  Especially the motion sensors since Vera support said this could not be done due to the protocol???

Good, maybe Vera uses the zigbeeLL protocol directly in their plugin. I use the philips hub api , there are pros and cons bu at least, it works.
Title: Re: ALTHue : Feature Requests
Post by: Jesper on March 02, 2019, 04:37:26 pm
Hello, many thanks for a good application!
I read that the SML001 sensor is compatible with the app. I have a SML002 ("Philips HUE outdoor") sensor that adds well as a device in my VeraPlus. I can add it to scenes, arm it and so on. The problem is that it doesnt register motion (dont work as trigger in scenes).
Since its a pretty new device to the market, I can imagine it hasnt been implemeted to ALTHUE yet :)

//Jesper
Title: Re: ALTHue : Feature Requests
Post by: amg0 on March 05, 2019, 05:42:52 am
Possible
Since I do not have one could you send me the data setting page content by PM
Thx
Title: Re: ALTHue : Feature Requests
Post by: amg0 on March 09, 2019, 08:06:37 am
Hello, many thanks for a good application!
I read that the SML001 sensor is compatible with the app. I have a SML002 ("Philips HUE outdoor") sensor that adds well as a device in my VeraPlus. I can add it to scenes, arm it and so on. The problem is that it doesnt register motion (dont work as trigger in scenes).
Since its a pretty new device to the market, I can imagine it hasnt been implemeted to ALTHUE yet :)

//Jesper

I received the data and could not see something problematic so the problem should be somewhere else. can you please enable debug mode on ALTHUE device,  then restart luup
then take your watch and start to trigger your motion sensor at a precise time

then come back to vera,  grab the log file and send me the log file + the time at which you did trigger the motion
I will send you an email to use to send the file more conveniently

thank you