Node-Red + Plug WiFi

Hello,
I am looking but can not find.
I have a Wifi plug connected (Wifi Smart Plug), I am able to see his ip and mac address when I do an arp -va woth SSH.
I see it in Node-Red with its IP and the node that assigned it.
What do I have to do to set up an on / off button so I can turn on and off it from Node-Red a lamp plugged into this socket?
I found many examples on the net but none for this case.
Someone can help me ? to orient myself?
Thanks in advance for your help !
Florent

A few more clues would be useful. Like what is the API ? What is the make/model ? Are any of the examples in node.js?

Hi, thanks for your return.
The model is FK-PW801U

Application with Android is BrightFun (API, i think)
Witht application I can find MAC address of the plug.

With ssh (RPI Pi 3), when I type ARP -va I can see the mac address and IP address (192.168.1.2) of the plug

With Node-Red, I can ping the IP address and it reply to me

How can i make to do a button on/off from Node-Red to turn on/off a lamp connected on this plug without to use the BrightFun application ?

I be sure that i can do it with Node-red, it's just a signal on/off i have to send but how can I do?

I don't find anything on the Web and in the examples in Node.js.
But peurhaps my search is bad ?

Thanks for your help

image

image

Can you log into the plug with a web browser maybe?

I don't think so, the only thing I can do is to connect it with the Android Software Brihtfun.

Is there any flow can interct with an ip adress and activated a on/off function ?
Or, is this impossible in this case ?

Have you tried? It's worth a go.

Have u checked if is compatible with IFTTT? Is is not or neither with some other service like this one or google home or similar then you most probably are done..... the only option then will be to fhash ESPeasy or similar and control ot via websockets or MQTT but the you will lose the original functionality with the native software.

Regards

Hi ghayne and sorry for ma late.

I don't know verry well how I can do that..

I have to verify a point, somebody tell me thatI will ablle to find the API on the web site for this plug.

I do not had time until now, but I will do and i keep you in touch with that.

A big thanks for your help

Hi Davidcgu, and sorry too for ma late.

As I told to ghayne, it seems that I can have an api from the web site and this API will tell me wich code is use to turne on/off the plug (peurharps its in Rest).
I do not want to use IFTTT or other service, I just would like to manage it from my Node-Red plateforme.
Flash ESPeasy is verry interesting, i didn't know that it was possible.
Do you have more informations about that ? some guide line or specials tutorials ?

Many thanks for your help
Florent

All those plugs are based on a ESP8266 and should be possible to flash any firmware you wanted to use instead of the original that has, however if you never did some job like this and as seems not to be any docu on the net I think is not going to be an easy job for you....

I have seen that this is compatible with Alexa & google home what most probably means you can control it through node-red triggering IFTTT to google assistant to send finally the command to your plug.

Is not going to be too dificult but u will have to screw your head a bit, frankly speaking there are many smart plugs cheap and very well documented on the net like sonoff S20 by 12$.....

AS example....

With this one you can find many tutorials even on youtube on how to flash tasmota firmware or ESPeasy and make it yours to be fully controlled by websockets or MQTT with node red.

I have some and highly recommend u to take it into consideration....

I have checked on the net and your seems simple unknown what means you will have to make your own the full investigation and job.

Maybe if you really are able to find the API......

Regards

Ok, thanks very much for theses details.
I have one or two ESP8266 and I will try to flash firmware (with Arduino / C) I think.

You confirm me that depend what you want to do, you have to experiment by yourself.

Thank you for your example, I will see and i will make my invetigation.

I will tell you when i found a way to use this Wifi smart smart plug like as I want :wink:

Best regards

Take a look on this (there are many like this one that will guide you)

Thank you very much davidcgu,

I will see.

I use a number of Sonoff S20 mains-plug WiFi switches.
I used to flash them with ESPeasy (as per the video above) but for the last month or two I've been using the firmware called Tasmota. It works really well with S20 and you can perform Over The Air (OTA) updates.

Cheers from David.

PS: Sorry this post should have been directed to @florent - pressed the wrong "Reply" arrow (oops)

2 Likes