Answering my own question, this seems to be the way to go.
I don't know how I never found this before ..
https://www.domoticz.com/wiki/Extracting_status_and_measuring_values_with_PHP
and
http://www.domoticz.com/wiki/Domoticz_API/JSON_URL's
Answering my own question, this seems to be the way to go.
I don't know how I never found this before ..
https://www.domoticz.com/wiki/Extracting_status_and_measuring_values_with_PHP
and
http://www.domoticz.com/wiki/Domoticz_API/JSON_URL's
Sorry if this has been answered but I have searched and not found anything.
I am quite new to MySensors but I have a slowly growing system of sensors, a serial gateway and Domoticz on a Raspberry Pi, all working fine.
I want to integrate my existing weather station which currently uses an Arduino Uno with hard-wired sensors (temperature, humidity, rain gauge, wind speed, wind direction) and an ethernet shield by adding a MySensors node to each sensor, collecting data into Domoticz.
As part of this I want to keep the ability of my station to upload my weather data to Weather Underground, but this means that I will need to somehow access the 'live' data from my network (or extract it from Domoticz, which I realise isn't anything that can be discussed here).
Does anyone have any ideas of how I could accomplish this? Can I build a 'listening' sensor which can extract and process data 'heard' on the network, or should I be looking at exporting it from the controller side?
Thanks in anticipation!
@Eawo If you look at the excellent original post from @mfalkvidd above:
The 3.3V power on the Raspberry Pi is rated for a maximum of 50mA. A regular NRF24L01+ only needs 15mA, but if you are using a power amplified version you might exceed what the Raspberry Pi can output. In that case, an external power supply might be required.
I don't believe that you will need to make any changes to code.
@TimO To confirm this I just 'rebuilt' my actuator node as the example humidity sensor (swapped a few links on my breadboard) and now the Pin13 LED behaves just like the other sensor node, mostly off with just a tiny flicker on each transmit.
I'm also seeing my ESP8266 gateway crash when the controller requests its version.
I had not seen this thread so I started a new topic here: http://forum.mysensors.org/topic/2493/esp8266-wifi-gateway-crashes-and-reboots-when-controller-connects
If you mean that there is no code in setup{} or loop{} then yes, that is correct.
The new development branch code works differently.
@mfalkvidd These are not extra LEDs added to monitor tx/rx/err (which is what I believe that the MY_WITH_LEDS... compiler directive controls), this is the inbuilt pin13 LED on the arduino board. I do wonder why the library has been written to use this pin as in a battery powered configuration any extra LED current will impact on battery life.
@TimO I agree - the actuator has to listen all the time for incoming messages, whereas the sensor can (and does) sleep for most of the time.
Aaargh! I just downloaded the latest release and now when I try to compile I get this. (In the meantime my Arduino IDE has updated the ESP8266 board definitions). I tried to go back to the previous ESP8266 config but that fails with lots more errors than this!
Arduino: 1.6.6 (Linux), Board: "NodeMCU 1.0 (ESP-12E Module), 80 MHz, Serial, 115200, 4M (3M SPIFFS)"
Build options changed, rebuilding all
arduino.ar(core_esp8266_postmortem.c.o): In function abort': /home/george/.arduino15/packages/esp8266/hardware/esp8266/2.0.0/cores/esp8266/core_esp8266_postmortem.c:177: multiple definition of
abort'
sketch/MySensorsGatewayESP8266.ino.ino.cpp.o:MySensorsGatewayESP8266.ino.ino.cpp:(.text.abort+0x0): first defined here
collect2: error: ld returned 1 exit status
exit status 1
Error compiling.
I have a small system working OK with 2 nodes and a USB gateway to Domoticz.
I just built an ESP8266 WiFi gateway (using the development branch code and libs).
It all compiled and loads OK, but when I try to link it to my Domoticz controller the 8266 crashes.
Here is the output from the serial port of the ESP8266... Prior to the controller connecting I can see the outputs from my temperature/humidity/pressure sensor being received OK
0;0;3;0;9;Radio init successful.
scandone
f 0, scandone
.add 0
aid 5
pm open phy_2,type:2 0 0
cnt
connected with ***********, channel 5
ip:192.168.0.16,mask:255.255.255.0,gw:192.168.0.1
.IP: 192.168.0.16
0;0;3;0;9;Init complete, id=0, parent=0, distance=0
0;0;3;0;9;read: 1-1-0 s=0,c=1,t=1,pt=7,l=5,sg=0:55.0
0;0;3;0;9;read: 1-1-0 s=2,c=1,t=4,pt=7,l=5,sg=0:1018.2
0;0;3;0;9;read: 1-1-0 s=1,c=1,t=0,pt=7,l=5,sg=0:19.8
0;0;3;0;9;read: 1-1-0 s=0,c=1,t=1,pt=7,l=5,sg=0:55.0
0;0;3;0;9;read: 1-1-0 s=2,c=1,t=4,pt=7,l=5,sg=0:1018.2
0;0;3;0;9;read: 1-1-0 s=1,c=1,t=0,pt=7,l=5,sg=0:19.8
0;0;3;0;9;read: 1-1-0 s=0,c=1,t=1,pt=7,l=5,sg=0:55.0
0;0;3;0;9;read: 1-1-0 s=2,c=1,t=4,pt=7,l=5,sg=0:1018.1
0;0;3;0;9;read: 1-1-0 s=1,c=1,t=0,pt=7,l=5,sg=0:19.8
0;0;3;0;9;read: 1-1-0 s=0,c=1,t=1,pt=7,l=5,sg=0:55.0
0;0;3;0;9;read: 1-1-0 s=2,c=1,t=4,pt=7,l=5,sg=0:1018.2
0;0;3;0;9;read: 1-1-0 s=1,c=1,t=0,pt=7,l=5,sg=0:19.8
0;0;3;0;9;read: 1-1-0 s=0,c=1,t=1,pt=7,l=5,sg=0:55.0
0;0;3;0;9;read: 1-1-0 s=2,c=1,t=4,pt=7,l=5,sg=0:1018.3
0;0;3;0;9;read: 1-1-0 s=1,c=1,t=0,pt=7,l=5,sg=0:19.8
0;0;3;0;9;Client 0 connected
0;0;3;0;9;Client 0: 0;0;3;0;2;
Fatal exception (28):
epc1=0x4000bf80, epc2=0x00000000, epc3=0x00000000, excvaddr=0x00000000, depc=0x00000000
Exception (28):
epc1=0x4000bf80 epc2=0x00000000 epc3=0x00000000 excvaddr=0x00000000 depc=0x00000000
ctx: cont
sp: 3ffea570 end: 3ffea820 offset: 01a0
stack>>>
3ffea710: 3fff1b98 4021964c 3ffea904 402039e8
3ffea720: 4021396d 3fff4a88 3ffea9f0 3ffea750
3ffea730: 3ffea740 00000004 3ffeab00 00000000
3ffea740: 00000003 00000000 00000001 00000000
3ffea750: 3ffeaa02 00000001 0000000a 00000001
3ffea760: 3ffeaac4 3ffea9f8 00000000 40203f38
3ffea770: 00000000 00000025 3fff4ad8 40206b02
3ffea780: 3fffdc20 00000000 3ffea9e7 3ffeab26
3ffea790: 00000000 00000002 3ffeaaf4 4020433d
3ffea7a0: 3ffe8ec0 00000000 000003e8 40202501
3ffea7b0: 00000000 3fff4ad8 3ffea8c4 3ffea7e0
3ffea7c0: 00000000 00000000 00000001 00000007
3ffea7d0: 00000001 0000002a 00000000 3ffea9f0
3ffea7e0: 3fffdc20 00000000 3ffea9e7 40204be0
3ffea7f0: 40203c59 00000000 3ffea9e7 402043b1
3ffea800: 00000000 00000000 3ffea9e7 402049de
3ffea810: 00000000 00000000 3ffe9800 40100118
<<<stack<<<
�HL!��@H��0;0;3;0;9;Starting gateway (1.6.0-beta)
0;0;3;0;9;Radio init successful.
scandone
f 0, ....scandone
.add 0
aid 5
pm open phy_2,type:2 0 0
cnt
I've built 2 sensors so far, one a relay actuator using an arduino pro mini and the other with temperature and humidity sensor using an Arduino Nano. On the nano the Pin13 LED just flickers occasionally (I guess when the radio transmits) but on the Pro Mini the LED is permanently on, with just an odd visible flicker occasionally.
Both nodes work fine, so I'm intrigued as to why the LEDs should behave differently?