Can the local server do 'blynk' stuff?

I was wondering. Currently I have two of my units checking the others to see whether they’re alive and act accordingly. This ‘act’ basically implies updating some virtual pins so designated units can act on that.
Now I had planned to add a dedicated unit that ONLY does this checking, however there is already a raspberry pi acting as server. Hence I was wondering whether that RPI cannot take up this function?
I’m rather clueless as to how to accomplish this.

I guess it potentially could do this with the API functionality which would require scripting (which I know nothing of) however is there another way to let the server check and update pins automatically?

Why not just getting a Node.js client library working on par on the same server and connected to itself (localhost)?

I’m not sure iofg you can run Node-Red on the same Pi sserver as Blynk, but if you can it’s a fairly easy way of getting that sort of thing done:


This simple flow pings an IP address at a predefined interval (every 5 seconds). If the result is a “Timeout” message (i.e the ping failed) then the Blynk LED widget is turned off, otherwise it’s turned on.

It’s an extremely powerful tool, and you can do quite a lot with it without too much effort. The programming language used to write the functions (that’s the orange thing in the middle box) is very similar to C+, so is easy to get to grips with.

Pete.

1 Like

thnx. I was not really yet familiar with node.js, I’ve heard it going around here though. I’ll check it out, thnx.