We have moved at community.getvera.com

Author Topic: openLuup: Suggestions  (Read 27724 times)

Offline akbooer

  • Moderator
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +292/-70
  • "Less is more"
Re: openLuup: Suggestions
« Reply #15 on: November 12, 2015, 10:10:21 am »
If I understand this correctly then openLuup would be able to clone both devices and plugins right?
Well this it does at the moment.  What it didn't do until today (I have it working in my development branch) was to give access to scenes.

I was actually thinking of removing the cloning of Vera-installed plugins, since they are not operational in openLuup (although locally installed plugins obviously are.)

Quote
But any modifications would need to happen on the original vera. I like this idea.
If you're speaking of scene modifications, then yes, that's the idea.  You can run it (you could even add additional local timers, triggers and actions) but you can't see or modify the timers, triggers, or actions that it has already and which are only operational (and only editable) on the Vera.

Quote
My main wish for openLuup would be that it could also handle it's own devices e.g. via a Zwave usb stick. This way I could have a mix of vera lite's and some raspberry pi's at strategic locations in my house to get the best possible zwave coverage and manage everything from one central openluup server.
Well yes, I understand.  That's one of the reasons why I actually have multiple Veras.  But for me, Vera IS the 'usb stick'.  For other hardware (eg. WiFi, or MySensors Arduino devices) there are plugins already that handle that.  I'm personally moving away from Zwave devices.

The serial protocol suported by most USB sticks is quite low-level and it would be hard to do, I think.  Some come with C libraries that implement the Zwave stack along with some HTML insterface.  This is a bit higher level.  If someone wanted to write a plugin for openLuup to handle one of those sticks then it would fit in just fine - it's exactly the same as writing a plugin for Vera, after all.
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline akbooer

  • Moderator
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +292/-70
  • "Less is more"
Re: openLuup: Suggestions
« Reply #16 on: November 16, 2015, 05:16:54 pm »
I'm mulling the possibility of cloning the ZWaveNetwork device (#1) into openLuup.  This would allow plugins, which manipulate the Zwave network directly, to run.   Most notably, this would include the RGBController with its colour wheel.

Obviously, this can only work for one remote Vera.  It wouldn't work for the second Vera if you had two VeraBridges running (or more.)
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline dreamcryer

  • Jr. Member
  • **
  • Posts: 56
  • Karma: +2/-2
Re: openLuup: Suggestions
« Reply #17 on: November 19, 2015, 01:36:50 am »
Would a scene migration tool/function be desirable? I haven't look deeper to understand how openLuup manage and execute its own scenes, but I guess it is using the same scene definition format on Vera? If so, a migration is simply to map the device IDs correctly?

Thinking further, is there a switch on VeraBridge not to show scenes on Vera?

Offline akbooer

  • Moderator
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +292/-70
  • "Less is more"
Re: openLuup: Suggestions
« Reply #18 on: November 19, 2015, 04:50:37 am »
Would a scene migration tool/function be desirable?
I have given it a bit of thought, but I do wonder how often it might be used.

Quote
I haven't look deeper to understand how openLuup manage and execute its own scenes, but I guess it is using the same scene definition format on Vera? If so, a migration is simply to map the device IDs correctly?
It DOES use the same scene definition format (otherwise a lot of things wouldn't work) although it doesn't use (or even store) Vera-style triggers, preferring instead to go with the device variable watch triggers of AltUI.

It is not, in fact, quite as easy as you might imagine to deal with changed device IDs.  This can be done for actions, but if if there's any Luup code involved then it is essentially impossible to do, since important numbers could come from global variables, functions, other device variables, ...

Quote
Thinking further, is there a switch on VeraBridge not to show scenes on Vera?
No, but it could easily be done, and I have thought about it.  My preference is actually to offer as few options on the bridge as possible, since every new option is something that complicates configuration.  All scenes from bridged Veras go into the same room as all of its devices, named after the machine ID.  By default, the scene page shows all scenes, but if you select "No Room" then you'll only see local scenes (assuming you haven't allocated them to a different room.)


If there's wide support for the idea, I could pursue this further, so thanks very much for the suggestion.  It would be possible to create these scenes in a separate room and initially disable them, but I'm worried that the scale of editing and further customisation required would completely negate the initial efficiency of automatically transferring them.
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline dreamcryer

  • Jr. Member
  • **
  • Posts: 56
  • Karma: +2/-2
Re: openLuup: Suggestions
« Reply #19 on: November 19, 2015, 02:15:55 pm »
I have given it a bit of thought, but I do wonder how often it might be used.

It DOES use the same scene definition format (otherwise a lot of things wouldn't work) although it doesn't use (or even store) Vera-style triggers, preferring instead to go with the device variable watch triggers of AltUI.

It is not, in fact, quite as easy as you might imagine to deal with changed device IDs.  This can be done for actions, but if if there's any Luup code involved then it is essentially impossible to do, since important numbers could come from global variables, functions, other device variables, ...
Ah, sounds like a messy road! Just trying to see if there is anything to help drive up openLuup usage.

Quote
If there's wide support for the idea, I could pursue this further, so thanks very much for the suggestion.  It would be possible to create these scenes in a separate room and initially disable them, but I'm worried that the scale of editing and further customisation required would completely negate the initial efficiency of automatically transferring them.
Good point. If there is a desire for this feature, I would be happy to help explore options.

Offline thegazelle

  • Jr. Member
  • **
  • Posts: 62
  • Karma: +1/-0
Re: openLuup: Suggestions
« Reply #20 on: December 07, 2015, 03:41:29 pm »
I think if you want more adoption of openLuup I think you have to make things slightly more user friendly.

I'm a casual Vera user and I came across OpenLuup today and tried installing it on an Ubuntu box. Some things just aren't very clear. For example... Step 3.  ALTUI installation. "Alt UI can be done now with a single HTTP request to a running factory reset openLuup system."

No where does it say that I need to install AltUI on my Vera first in order to install it with OpenLuup. Why is something as basic as this left out of the documentation?


Offline akbooer

  • Moderator
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +292/-70
  • "Less is more"
Re: openLuup: Suggestions
« Reply #21 on: December 07, 2015, 04:06:53 pm »
I think if you want more adoption of openLuup I think you have to make things slightly more user friendly.
I'm sure you're right.

Quote
No where does it say that I need to install AltUI on my Vera first in order to install it with OpenLuup. Why is something as basic as this left out of the documentation?
Because it's not true... you don't need AltUI installed anywhere to do that.
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline CudaNet

  • Beta Testers
  • Hero Member
  • *****
  • Posts: 1401
  • Karma: +42/-11
  • Chimichanga !
Re: openLuup: Suggestions
« Reply #22 on: December 07, 2015, 04:13:28 pm »
You might want to re-think the Ubuntu installation. I've performed openLuup on both Ubuntu Server(Jetway server) and Mate(rPi2) and my recommendation would be to move to OpenWRT. I've documented all the necessary steps to perform such an install (in detail) and it just makes life easier as this is what Vera is running on. Reason being, we discovered that plugins (custom or MCV based) had to be altered and various methods performed to make them behave properly. It was just too much work to deal with, hence why I never truly released documentation on Ubuntu.

I commend Akbooer's effort and it can be 'extremely' difficult to cover all bases of an install/platforms etc. when you're focused on making magic happen (the code). As someone who had never used openLuup, I was able to use a very early document and build a series working systems. The time put into getting this up-and-running is well spent and rewarding as you can now run on your own hardware. I'm running my production system on a quad core Intel (1.83Ghz) with 8 Gb of memory and a 30 Gb SSD. My test system is an rPI2. I hope the document I linked below helps and allows you to start enjoying openLuup.

http://forum.micasaverde.com/index.php/topic,34480.msg256123.html#msg256123
See post #12.

Again, hope this helps...

I think if you want more adoption of openLuup I think you have to make things slightly more user friendly.

I'm a casual Vera user and I came across OpenLuup today and tried installing it on an Ubuntu box. Some things just aren't very clear. For example... Step 3.  ALTUI installation. "Alt UI can be done now with a single HTTP request to a running factory reset openLuup system."

No where does it say that I need to install AltUI on my Vera first in order to install it with OpenLuup. Why is something as basic as this left out of the documentation?
openLuup, AltUI, Zway and HomeWave, enough said...

Offline thegazelle

  • Jr. Member
  • **
  • Posts: 62
  • Karma: +1/-0
Re: openLuup: Suggestions
« Reply #23 on: December 08, 2015, 10:12:27 am »
CudaNet, thanks for posting the guide. That is exactly what I was looking for. The only reason I chose an Ubuntu box was because I already had one setup up and running that I use to scrape/plot data for work. I took the plunge and ordered a RPi 2 this morning.

Offline CudaNet

  • Beta Testers
  • Hero Member
  • *****
  • Posts: 1401
  • Karma: +42/-11
  • Chimichanga !
Re: openLuup: Suggestions
« Reply #24 on: December 08, 2015, 10:35:47 am »
@thegazelle

You're very welcome. As for Ubuntu, nothing wrong whatsoever with it aside from plugins attempting to install requisite components using 'opkg'. Akbooer was a tremendous help in working and walking me through those issues. I just felt it would be far easier to use OpenWRT and it has.

The real thanks should go to Akbooer for all his time, efforts and patience. We cannot lose sight that it's the developers that give and ask for very little in return. I'm still enamored with how well this system runs, how stable it is and how I just leave it alone.

With all that said, let us know how the install goes and I'm sure you'll love the rPi2. I remember seeing memory utilization at around 500Mb for Ubuntu Mate on a fresh boot. When I moved to OpenWRT, I had somewhere in the realm of 900+ (being that were limited to 1Gb of memory). It's a win - win....


CudaNet, thanks for posting the guide. That is exactly what I was looking for. The only reason I chose an Ubuntu box was because I already had one setup up and running that I use to scrape/plot data for work. I took the plunge and ordered a RPi 2 this morning.
openLuup, AltUI, Zway and HomeWave, enough said...

Offline thegazelle

  • Jr. Member
  • **
  • Posts: 62
  • Karma: +1/-0
Re: openLuup: Suggestions
« Reply #25 on: December 08, 2015, 02:41:44 pm »
I think if you want more adoption of openLuup I think you have to make things slightly more user friendly.
I'm sure you're right.

Quote
No where does it say that I need to install AltUI on my Vera first in order to install it with OpenLuup. Why is something as basic as this left out of the documentation?
Because it's not true... you don't need AltUI installed anywhere to do that.

My mistake, sorry. I was pretty frustrated yesterday trying to plod through this. I couldn't (and still can't) figure out why AltUi listed in step 3 when you don't actually do a single thing with it until you get to the configuration part. I assume it's step 3 because you previously had to manually move files over for Alt UI to function. Given that it isn't the case anymore, why keep it in there?

I still plan on running it on RPi2 but I took another stab at it on the Ubuntu box for grins today and I was able to get it installed. The only device shown in AltUI is "AltUI" unfortunately. I specified my Vera IP in the startup.lua file and my Vera bridge files are in my /etc/cmh-ludl directory.

Offline akbooer

  • Moderator
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +292/-70
  • "Less is more"
Re: openLuup: Suggestions
« Reply #26 on: December 08, 2015, 03:44:56 pm »
I couldn't (and still can't) figure out why AltUi listed in step 3 when you don't actually do a single thing with it until you get to the configuration part. I assume it's step 3 because you previously had to manually move files over for Alt UI to function. Given that it isn't the case anymore, why keep it in there?
Actually, it's step 3 because you're almost certainly going to need it.  Steps 4 and beyond are really dependent on the configuration you're trying to build.

Quote
I still plan on running it on RPi2 but I took another stab at it on the Ubuntu box for grins today and I was able to get it installed. The only device shown in AltUI is "AltUI" unfortunately. I specified my Vera IP in the startup.lua file and my Vera bridge files are in my /etc/cmh-ludl directory.
Are the luup.create_device for the VeraBridge and the luup.ip_set lines still commented in the startup file?

3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline dreamcryer

  • Jr. Member
  • **
  • Posts: 56
  • Karma: +2/-2
Re: openLuup: Suggestions
« Reply #27 on: December 09, 2015, 02:33:53 am »
Just another couple of ideas:
1. HTTPS support
2. User authentication (Not Vera Home user integration)

Yeah, I am thinking about external access...

Offline akbooer

  • Moderator
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +292/-70
  • "Less is more"
Re: openLuup: Suggestions
« Reply #28 on: December 09, 2015, 09:07:01 am »
1. HTTPS support

What did you have in mind here?  HTTPS support in luup.inet.wget, or something different?  Plugins that need to do this can already use the Luasec library.

Quote
2. User authentication (Not Vera Home user integration)

Yeah, I am thinking about external access...

AltUI already provides external access, so what extra?
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline thegazelle

  • Jr. Member
  • **
  • Posts: 62
  • Karma: +1/-0
Re: openLuup: Suggestions
« Reply #29 on: December 09, 2015, 11:05:47 am »
I couldn't (and still can't) figure out why AltUi listed in step 3 when you don't actually do a single thing with it until you get to the configuration part. I assume it's step 3 because you previously had to manually move files over for Alt UI to function. Given that it isn't the case anymore, why keep it in there?
Actually, it's step 3 because you're almost certainly going to need it.  Steps 4 and beyond are really dependent on the configuration you're trying to build.

Quote
I still plan on running it on RPi2 but I took another stab at it on the Ubuntu box for grins today and I was able to get it installed. The only device shown in AltUI is "AltUI" unfortunately. I specified my Vera IP in the startup.lua file and my Vera bridge files are in my /etc/cmh-ludl directory.
Are the luup.create_device for the VeraBridge and the luup.ip_set lines still commented in the startup file?

Derp. That was the problem.. line was commented. Thanks.

Regarding the manual, I understand that you will almost certainly need AltUI, but Step 3 (AltUI install) is in what I would call the "prep work" area, when the actual AltUI install is done during the "commissioning process".  Does that make a little more sense?