question

porcini avatar image
porcini asked

Feature Request: "Virtual Switch" for Venus OS - solved with Node-red

Hello,


the virtual switch in the MultiPlus is a very useful and powerful tool. I'm wondering if this would also be possible to integrate in VenusOS similar to scheduled charging.


Some independent examples:

- Turn Multi off at 10:00 PM. Turn Multi on at 6:00 AM

- Switch critical loads on for 2h every 48h OR if Battery SOC is >90% AND PV Power is >100W

- Don't turn Multiplus on sundays

- Use Multiplus Charger only between 10:00PM and 06:00AM (probably because Energy is cheaper then)

- Switch Solar Charger off when DC-Loads were <5W for more than 24h (don't know why) and VE.Bus state is off

- Set Absorption-Voltage to 14,2V if Battery-SOC hasn't fallen below 90% for more than 72h

- Set Absorption-Voltage to 14,7V if Battery-SOC has fallen below 60%

- Ignore temperature and turn off compensation if voltage is above/under example-voltage

- Limit Output to 500W as soon as SOC reached <60% and AC-In is connected.

- Stop Discharging if PV-Power is lower than 200W for 1h and SOC has fallen under X%

- DON'T limit charge current if loads are higher than X

- Switch 230V to 220V on overload


and so on ..


regards,


Porcini

Venus OSNode-REDvirtual switch
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

6 Answers
mvader (Victron Energy) avatar image
mvader (Victron Energy) answered ·

Hey Porcini, coincidence or not, last night I discussed exactly such project internally. The current plan is to implement Node-Red on Venus. See google for more about node-red, I think it’s going to make for an excellent solution.


One thing needed for the development is a list of examples; so thank you! Welcome to add more.

Some from myself:

- control an external fan. For example for a system installed in a container, to blow fresh air into the container (or suck warm air out)

- load shedding

- controlling dumploads: enable water heater or pool heater when batteries are full and sun is still shining.


The idea is that for very often used features we have a dedicated solution, that doesn't require `fiddling` in Node-red. An example of this is the Generator Start/Stop feature in Venus GX. And we might add more in the future, dump loads is one that comes to mind.

And for more advanced / less often used requirements, like all the rest mentioned above, people can use node-red; and we'll have documented examples.

10 comments
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

ben avatar image ben ♦ commented ·

Regarding dedicated solution vs node-red examples, better still: implement the dedicated solutions in node-red, so that when the dedicated solution doesn't work for someone, they can use it as a starting point and extend (via fiddling).

That might be what you were already describing, but I'm not sure.

2 Likes 2 ·
mvader (Victron Energy) avatar image mvader (Victron Energy) ♦♦ ben ♦ commented ·

Hi Ben, no I didn’t have that in mind. We can try; though I don’t inmediately see how to the involve settings. But it’s probably possible.


Key to the dedicated solutions is that the installer doesn’t see or hear about node-red.



1 Like 1 ·
Tim from Eat Sleep Van avatar image Tim from Eat Sleep Van commented ·

I have exactly 2 of those situations already:

- My EasySolar box is in a cabinet. I have a fan to suck warm air out. It would be nice if this was controlled automatically. Although I suspect a simple temp sensor on the fan would be easiest!

- Hot water heater - I want my Colour Controller to turn it on/off automatically when the batteries are full and there's spare solar. Currently I have it controlled by a home automation system power plug switch. I was going to programme my raspberry pi to query the colour controller, and control it.

1 Like 1 ·
paulio avatar image paulio commented ·

Not sure if this is the same function but I control the heater on my van through relay 1 on the gx. Further functionality of this relay (timer etc) would be really usefull.

1 Like 1 ·
wkirby avatar image wkirby ♦♦ commented ·

Node-Red on Venus sounds like an excellent plan Matthijs. Exciting times ahead!

0 Likes 0 ·
porcini avatar image porcini commented ·

Hi Matthijs. Great! I think this is going to make the victron system really powerful! Hopefully the community will add some useful ideas as soon as they come to mind. Unfortunately most of my examples were only added symbolically and don't make sense at all.

I totally support the dedicated solution for less complex functions like the dumpload or time-controlled switching. Probably it would also be useful to have the selection between things should happen only once and periodic.

Working together with its community is the best a company can do. It brings the innovation capacity to its max!

0 Likes 0 ·
Michael Riley avatar image Michael Riley commented ·

We also already have several of these 'requirements' on our sailing catamaran. Dump loading, load shedding based on SoC (not 100%), various location temp monitoring (in addition to LiFePo4), AC load monitoring (using Generator) to maximise, but not overload, generator whilst its running, Water maker (desalinator) on/off when 'energy' available' and day/night (time = tide etc.) (prioritised with battery charge etc); based on If - then - pull down options to activate .... relay(nn) and NMEA 2000 (SeaTalkng) / SignalK output message all highly desirable from VenusGX.

0 Likes 0 ·
geomz avatar image geomz commented ·

I'll just add to the chorus of excited, yays :)

I have use for a great deal of the examples presented above. Kudos Victron!

Might be a silly question, but will any of this functionality be portable to a CCGX, or is a Venus module the only intended target direction?

0 Likes 0 ·
mvader (Victron Energy) avatar image mvader (Victron Energy) ♦♦ geomz commented ·

No silly question at all. Ccgx wont be able to run it; too limited wrt disk; and also cpu & ram by the way.

Full details are here: https://github.com/victronenergy/venus/issues/378


Ps; see comment I posted there a second ago at the bottom.

0 Likes 0 ·
geomz avatar image geomz mvader (Victron Energy) ♦♦ commented ·

Thanks @mvader.

Somewhat disappointing, but not too surprising considering the rich feature-set offered.

I'll continue to monitor this project and I'll dust off my GitHub login. Perhaps this'll motivate me to hack together a raspberry :)

0 Likes 0 ·
mvader (Victron Energy) avatar image
mvader (Victron Energy) answered ·

Hey! Here’s a small sneak peek on where we’re at with the Node-RED. There are two types of nodes: measurement nodes and control nodes.

At the top of the screenshot, you can see an example node-red flow (automation) that changes the MultiPlus mode based on the time of the day in order to maximise cheaper night-time electricity.


The switch node ‘Filter by SoC’ has four thresholds for SoC; 25%, 50%, 95% and ‘no-data available’. The incoming messages are guided to one of the corresponding outputs of the node.

The example is by no means perfect, but I think it demonstrates the power of Node-Red pretty well. Expand that with additional logic, push/email notifications and apple homekit / google home integration :wink: Oh, and every service absolutely requires Twitter integration.


(Copy paste of a msg from Peter, the main developer working on this)


1 comment
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

porcini avatar image porcini commented ·

That's exactly as I imagined! Couldn't be more simple and extensive. Great!!

0 Likes 0 ·
mvader (Victron Energy) avatar image
mvader (Victron Energy) answered ·

Hi all,

Implementation is nearly done; only testing and polishing is left; as well as proper integration into Venus OS.

And you can help (and enjoy the feature already :-). )

test images are available. See here: https://github.com/victronenergy/venus/issues/378#issuecomment-471338620

For issues; there is a issue tracker on github here:

https://github.com/victronenergy/node-red-contrib-victron/issues

Or drop notes here on this thread.

Enjoy!

2 comments
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

Really love the node-red implementation. IMO this should go hand-in-hand with influxdb and Grafana within the Venus OS image. So yes, this is another feature request :-)

0 Likes 0 ·
Mark avatar image Mark ♦♦ commented ·

As things have been a bit quiet on this topic lately, I was just wondering how things have been progressing & the current expectation for when node-red integration might become available?

I'm still investigating options to properly control a water heater dump load in my off grid setup.

0 Likes 0 ·
spark88 avatar image
spark88 answered ·

I installed the latest version ... install worked well. No issues.

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

zl2fae avatar image
zl2fae answered ·

Has Node Red died a death? I am in a similar position grappling with the inadequacies of the current VS options. I really really need SOC and time of day options in the VS. Battery voltage triggers (except when nearly exhausted) don't work for me as BV shifts according to load on PbC batteries (affordable large capacity storage). SOC is the important one for extending batteries life.

3 comments
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

mvader (Victron Energy) avatar image mvader (Victron Energy) ♦♦ commented ·
Hi not all. Venus OS Large is alive and kicking.


Even better, its planned to be official per next Venus OS version, Venus OS v2.90.

0 Likes 0 ·
pau1phi11ips avatar image pau1phi11ips mvader (Victron Energy) ♦♦ commented ·
This is great news. I've been putting off installing it but having it in the official version will make it so easy.
0 Likes 0 ·
Warwick Bruce Chapman avatar image Warwick Bruce Chapman mvader (Victron Energy) ♦♦ commented ·
Incredible news! Will be a boost to keep Victron is ahead of the rest of the pack.
0 Likes 0 ·
zl2fae avatar image
zl2fae answered ·

Thanks... I installed Node Red and am happy to report that I now have mastered automated control over when the grid power is used. I have enabled draw from the grid on Overload Warning, low Battery SOC at any time, and at the Night Rate for supplementary charging.

Next project is develop Node Red diversion of excess PV to Hot Water heating (in half hr blocks) when the battery is already full between peak solar hours (10am-2pm). Wanting to avoid Daylight Savings issues (New Zealand has an extended unique DS period) I tried using GMT to keep a fixed solar schedule but could not master using other time zones but I will persist.

Victron has proven to be the right choice!

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.