Raspberry PI companion for HE

My 2c worth - if you are maintaining your network and devices using a commercial UPS then NUTS is an essential setup on a companion pi.

Don't forget MQTT, CATT, zigbee2MQTT, Deconz too!

1 Like

I must admit I was sceptical at first with the proposal of a pre-defined setup for a raspberry pi. I tend to think something like a rpi is used in so many different ways, even if you just focused on those who use it as an add-on to HE, that a standard setup is probably a hard thing to achieve. I probably still have that same view, but proposing this idea has certainly lead to a healthy conversation, so credit to @maffpt for raising an interesting topic and to those who have contributed to the conversation.

In terms of my contribution....

While I have used Unix / Linux in a limited capacity in my professional career, I would put myself in the category of someone who is not completely at home in that environment, more so in a Windows PC world. That said, one of the main reasons I purchased my rpi was the fact a number of likely solutions for my home automation were going to include instructions involving a rpi, whether they be here on the community or more generally on the Internet. In terms of this thread, I think the major benefit that can be gained is from people fleshing out the details of their setup on a rpi for specific solutions, more so than a pre-defined technical setup. Just my opinion.... Certainly there could be benefits for specific applications / solutions, but I feel a broad "companion" setup may be too broad...

Again, great topic for discussion and great contributions by all, would love to see it continue.

Simon

I guess it is how you look at it. Like you mentioned an RPi can be used for many things on a local network not necessarily related to HE.

Some HE Companion Ideas:

  • Offload Rules/Apps for reduced HE overhead using systems like Node-RED.
  • Separate UI / Visual for alternate rule apps like WebCoRE.
  • External Logging Server.
  • External apps that work in conjunction with HE apps to provide missing functionality or connectivity like HubConnect [server], 3rd party dashboard apps, email notifications etc.

Tangentially related stuff that benefits a companion server (and the lan as well):

  • MQTT
  • NTP Server
  • VPN
3 Likes

I totally agree, and I didn't mention in my earlier post, but I did contemplate posting some of my thoughts early on, and am glad I didn't cloud the early conversation with my boundless pessimism :slight_smile:

My questioning of the proposal is really a pedantic one. I whole heartedly support making it easier for people to make use of the power you get from a rpi, I've even posted myself along similar lines. Coming from an IT project background, I guess my only concern is scope, which is a really boring an uninspiring one to bring up during the fostering of an idea. I think if we want to harness the collective efforts of those who use a rpi, then knowledge sharing is probably the most effective outcome, again IMHO....

I did mean to ask what you would use an NTP server for in a HA setting?

To prevent time "drift" when internet connectivity is erratic. There is an excellent custom HE driver called NTP Client that allows you to set the date/time using a server of your choice.

3 Likes

I've been meaning to set this up myself, had seen a thread a while ago mentioning the use if an NTP server on the same network.

Like you just linked :slight_smile:

1 Like

This I can get behind, a kind of wiki for raspi os software which can be used in conjunction with HE (and the pitfalls that go with getting it going) would have been really useful for me when I was putting my set up together. This is achievable, rather than asking developers to to do extra work to package their software just to cater for us HE users?

EDIT/PS: Plus isn't it about the fun and satisfaction of having gotten it to work yourself?

1 Like

It often is, but it can be a fine line sometimes... :slight_smile:

Bringing it back to the premise of the thread.... I think having HE specific instructions, if not a technical solution, will help people achieve what they want much faster, which can only be a good thing. So encouraging this type of discussion and getting people to share their knowledge along the way is something worth promoting. Any scripting or technical solutions are a bonus.

2 Likes

One point for me: at least I know that apt-get should be used! :grin:

This and other config details AFYK, can be addressed with some smart scripts - those who are Unix world experts can confirm it.

Another package/option to include as "optional" or "additional" - good point!

The proposal is to have a "bare"/"basic" configuration of a Raspbian with the main package manager installed - again "stealing" the idea of the Hubitat Package Manager (HPM) - congratulations again, @dman2306 - great piece of software! I invite all who use it to make a contribution to him !

Then, after the bare/basic Raspbian is installed, the user could use a local console or even a web based interface (which, IMHO, would be the best for the users) to install the packages/options desired.

By the way: for a web based package manager I can contribute - but I warn everybody that I only know to develop for web with C# and .NET (not even MVC ...) ...

This is not the proposal. The companion would be just a basic configuration preloaded with the tools to install other "companion" packages. And those "companion" packages would be developed by the community.

It's gaining traction ... let's hope that it come to fruition !

The list of "HE RPi companion packages" would be infinite!

As I said, infinite possibilities ... By the way, I would be interested in a VPN solution.

Sorry, but I must disagree with you: your comments - at least as I see them - are not pessimistic. We are brainstorming here, don't everybody agrees? Your worries can, and probably are, the worries of other users. Discussing them here IS a great contribution.

Me too - that's why the proposal is of a "HE RPi Companion" basic configuration plus "HE RPi Companion packages", developed by the community.

Going back to the Hubitat Package Manager (HPM) - @dman2306, have I said before that you HPM is great??.

I've developed two apps/drivers to use with HE and I promptly jumped into that HPM wagon! The HPM greatly simplifies the task of maintaining the apps/drivers up to date (and remove, etc), both for the developers and the users. The "HE RPi Companion" solution would be something similar, but for the RPi environment.

This is another good idea - a wiki to explain what each companion package is for.

The idea would be that the HE users that are more knowledgeable of Linux environment help the community to "encapsulate" the work necessary to implement a solution (eg. WebCORE or Node-RED or VPN and so on) to install it at the "HE RPi Companion".

This would be something along the lines what who has developed an app/driver for HE has been doing - contributing for the community. And with the advent of the HPM, maintaining the apps/drivers we use on our HEs become extremely easy (@dman2306 ... thanks, thanks, thanks!!!).

Doubtless doing it yourself is satisfying ... I've done a lot of "bit scrubbing" myself during my career - however, now I'm more interested in having the overall solution going on. Having to install everything I need for the solution I want (eg. WebCORE) is a big bump on the road for me - a hassle that I'd be very glad to avoid, And I think that many users here would agree with me - both who "consumes" of eg WebCORE and the ones who are able to make it easier to install it at a RPi.

Roughly, it would be something like this:

@dman2306, any resemblance with HPM is not a coincidence !

Lets the ideas flown!

Thanks to everybody!

Marco

1 Like

Thanks @maffpt for such a detailed reply, particularly to my late night ramblings.... much like these....

Obviously I hadn't read all the detail on your suggestion :slight_smile: I can now see to the two key aspects of what you are promoting; an initial and ongoing setup / configuration for a new rpi's, as well as access to a repository of community developed utilities for rpi's. Those two use cases do make sense and I can understand the desire to have them available, particularly for new owners of a HE hub and a Raspberry PI.

With the list of requested apps / utilities growing I guess the next step would be to prototype a solution. The most popular aspect of what you are promoting would appear to be a standardised setup using existing, widely available utilities and apps, i.e. those not necessarily developed by HE owners. I would think an existing utility would provide at least a starting point for this...

Again, great work in promoting the idea and seeing it through.

Simon

1 Like

I think this could be a very useful resource. IMO though it would take someone dedicated, who knows what they are doing leading the charge and putting in most (all) of the work. Much like @dman2306 and HPM.

2 Likes

You're welcome! :grin:

It would not be quite utilities for RPi, but already available packages (eg WebCORE), but somehow "encapsulated", "tailored" for our environment (HE). Such "encapsulation" or "tailoring" would be developed by someone from the community, as a RPiC4HE "package". Something along those lines.

That's where I hit a wall: I really donĀ“t know how we could implement it. Maybe creating our own apt-get packages ?? I'm really lost here. :thinking:

I can't agree more, since IĀ“m definitively donĀ“t know how to do it ... :cry:

What I would like to see - and many of other here already agreed - is an easier way of configuring a RPi with software that would work in tandem with the HE.

Maybe Iā€™m wrong, but arenā€™t you pretty much just talking about docker containers?

The idea of having everything preloaded, for example, to install WebCORE in a Docker container is really interesting - not mention an elegant solution too.

Recommendations could be made suggesting a minimum Pi configuration that could support a given set of containers, avoiding frustration from users trying to load a bunch of containers in a tiny Pi Zero ... :grinning:

@dman2306 ... this is becoming very interesting !

I guess what Iā€™m thinking is you have many containers. Thatā€™s kind of the idea of docker. One container per app. If you donā€™t want node red, donā€™t load the container. Then there are already things like dockerhub to find them.

1 Like

Sorry @dman2306, I edited my previous post - it was not clear at all. I'm all in for your suggestion.

No doubt a single container should hold a single "package": WebCORE one container, MQTT other container and so on.

2 Likes

Youā€™ll find many common tools already exist as containers. It also doesnā€™t limit you to an rpi. Docker works on Linux, Mac, windows. Pretty much whatever.

Yes, I was reading about it right now.

If all containers share a name prefix, would be easy to find all related to HE or, if there is a possibility of creating a separate "directory" with HE containers, it would make it easier for the users.

1 Like

You can setup a public repository and everyone can be a collaborator on it to contribute containers.

2 Likes