A NodeJS API for Velbus (need TCP connexion)

I took some time to create an MVC application able to respond as a Restful API.
You may have some part to remove or change (MySQL server information in .env).
The program is able to listen to others UDP connexion (in my case Vents Modbus for airflow and TeleInfo protocol for french electric counter): if it hangs, remove them.

The idea behind this project is to test some proof of concept (I’ve tried Open Hab, but still to long to configure as I which).
Here, my app is able to scan the Velbus network and creating a list of modules (addresses) and submodules (key is address-part)

If someone want to send me feedback, I would be happy (even if it’s not working in your home). I use it on a Raspberry Pi 3 (32 bits) without problem now.

It’s between alpha and beta phase, so it’s recommend for developpers: feel free to use part as you want in your own programs.

1 Like

Hi

Great to hear from you.

Is this the kind of magic that’s behind NodeRed?

The current NodeRed pallette is no longer supported, as the chap has moved out of his Velbus equipped home.

Is there any chance you could adapt you NodeJS to become a NodeRed Pallette?

@rrajagopal

Any chance you can do something?
(I haven’t forgotten about sending you some kit, it’s still with another developer)

Hi Stuart,

I’m like Gandalf (pass from grey to white after a big challenge: mine was to access a better ranking in my teaching job. As you know, french teacher have lowest salary from all Europe).

Well, ArVel would be an API able to send full actualised list of Velbus modules/subMobules (JSON format)
My idea is a way to simplify starting project with Velbus (scanning, then asking name, then searching status, etc. through the bus).
It could send some order like http://localhost:8001/name/118/1 (RequestName for submodule address 118, part 1)
I would Arvel to be able to recognized modules/submodules automatically.

However, as it’s an API, you could code any program (C, C#, C++, Rust, Python, Java, PHP, etc.) to access it, without the need to analyze each message (althrough, I will try to keep a way to send/receive live trames in browser with socketIO).

It’s hard to create such a piece of program, but I think it’s structured enough to evolve in the time.
If I could, I’ll create some example in NodeRed to use it.

The main problem for me, is to create a kind of container (like flatpak or snap) easy to install…

1 Like

Interesting idea.

As you know, not my area of expertise.

Is it worth reverse engineering what the current NodeRed pallette does?

I’ll have a look at it.
For now, I used a different structure, that would allow me to recognize a module as two or three functions or more.
I could then use filter like http://localhost:8001/modules/cat=relay and have only relay capable submodules.

But I like NodeRed, so I’ll try to create something with it, thanks.

1 Like

That’s amazing news.

As always, please let me know how I can help you test

For now, I’m still working on the API: when it run, it’s able to learn (I will add features later, for learning memory from module) and add categories to already present modules.
As explain, my wish is autolearn, thanks to Velbus protocol: if a detected module from category “relay” send a temperature, then my API will add it “temp” capacity. I just need to know the number of part.

As it save automatically it status every hour (only if needed), it’s able to restart without having to scan all modules.
Node-Red was already installed on my Raspberry, with @GertSt library, so I’m trying it again, but I’m unsure about the way to use/reuse it.

However, I probably need to have a look to new modules (those who have a different behavior). Could you give me a list of them (those who gives problems to their owners)?

That sounds very intriguing and perfectly timed.

I’ll send you an email with a spreadsheet of modules.— or rather… I would if your email address I have on file still worked… can you send me your new details please

Thanks a million.