Page 1 of 1

Nodejs Plugwise driver code

Posted: Tue Sep 30, 2014 11:45 pm
by Bwired
Camilo Tapia made a Plugwise interface for Nodejs some years ago. Today Camilo updated the code with a function to also read the power buffer of a Circle.
This is a very nice wanted upgrade!

Code: Select all

Read the power buffer

// Returns todays power consumtion as an array of dates and {watt: [number], kWh: [number], pulses: [number] }
circle.powerbufferinfo(callback([array]);

// Returns the amount of hours back in time of  power consumtion as an array of dates and {watt: [number], kWh: [number], pulses: [number] }
circle.powerbufferinfo([number], callback([array]);

// Returns the dates power consumtion as an array of dates and {watt: [number], kWh: [number], pulses: [number] }
circle.powerbufferinfo([date], callback([array]);

// Returns the dates interval power consumtion as an array of dates and {watt: [number], kWh: [number], pulses: [number] }
circle.powerbufferinfo([[date], [date]], callback([array]);
Check the code on github https://github.com/camme/plugwisejs
also check out his interesting blog with more Nodejs solutions.http://www.1001.io/blog

Re: Nodejs Plugwise driver code

Posted: Sat Jan 07, 2017 9:17 am
by Edwin
How can a json call in the adresbar be done?
Or isnt it possibble?
Something like this:
http://<username:password@>plugwise-ip<:port>/json.htm?api-call
Or must it be done anotherway?
Sorry noob in this :-(
Thanks
Regards
Edwin

Re: Nodejs Plugwise driver code

Posted: Tue Jan 10, 2017 9:36 pm
by Bwired
No, this cannot be done with this nodejs module without adding the http server code
This python module has a Http server but it is in Python, but can run on Rasp like..
https://github.com/SevenW/Plugwise-2-py

Re: Nodejs Plugwise driver code

Posted: Tue Jan 10, 2017 11:03 pm
by Bwired

Re: Nodejs Plugwise driver code

Posted: Wed Jan 11, 2017 10:02 am
by Edwin
Bwired wrote:and here
viewtopic.php?f=39&t=9421
Thanks for your answer,
But
Is it possible to get it running on windows some how?

Re: Nodejs Plugwise driver code

Posted: Wed Jan 11, 2017 6:17 pm
by Bwired
ah, thats why you wanted to use the nodejs version, which can run on windows...
i dont know if Python can run on windows, i guess not. :(