Page 1 of 1

Sending powerreading to ESP

Posted: Tuesday 26 December 2017 0:54
by jandoedel99
I want the power reading in my raspberry sent to a ESP8266 with a display2004 to display my powerconsumption.
Is this possible ?

Re: Sending powerreading to ESP

Posted: Tuesday 26 December 2017 13:27
by rhendriks
I think this is possible , look at this:
https://www.letscontrolit.com/wiki/index.php/LCDDisplay

Re: Sending powerreading to ESP

Posted: Tuesday 26 December 2017 20:01
by jandoedel99
Thanks i have read that. But now how to do?

Re: Sending powerreading to ESP

Posted: Wednesday 27 December 2017 20:18
by jandoedel99
I have now:

Code: Select all

[--
commandArray = {}
 DomDevice = 'Power';
 IP = '192.168.0.53';
-- if devicechanged[DomDevice] then
   DomValue = otherdevices_svalues[DomDevice];
   print(DomValue)
 --  print(string.sub(DomValue, string.find(DomValue, ;)))   
-- end
 
 runcommand = "curl http://" .. IP .. "/control?cmd=LCD,1,1," ..DomValue.. " ";
 os.execute(runcommand);
 
return commandArray
/code]
This is working.