Ralph, this line in the log file:
Apr 7 18:59:33 ru-pi weewx[19737]: wxMesh: Working on queue 0 payload :
temperature
means that your sketch has published a message of the string "temperature".
Looking at your sketch, it looks like it might have
if((temp > -20) && (temp <110))
dataString = String("{\"temperature\":") + temp + String("}"); <--
not in a format which wxMesh can parse
dataString.toCharArray(charBuf, 150);
{
client.publish(topic,charBuf );
}
There's also some problems with that if block. Try changing dataString to a
message that wxMesh can parse, for example
if((temp > -20) && (temp <110))
{
dataString = String("{\"temperature\":") + temp + String("}");
dataString.toCharArray(charBuf, 150);
client.publish(topic,charBuf );
Serial.print("Published: "); Serial.println(charBuf);
}
Also weewx can do data quality
control: http://weewx.com/docs/usersguide.htm#StdQC. I would recommend
passing whatever you get from the sensor on to weewx, and set it up to
decide if the data are good.
wxMesh does not quite read JSON format, it reads key:value pairs separated
by commas, with the key and value separated by a colon.
Here are the last two publications to my mosquitto broker, which will be
consolidated into weewx by the wxMesh driver.
TIME:0,INTE:20.03,INHU:33.00
TIME:0,AMBT: 0.59,BARP:1022.26,RHUM:64.87,HUMT:
0.57,IRRA:16,BATV:1010,PHOV:383,SYST:32.20,WIND: 0.0,WDIR: 0.0
The first was published by an ESP8266 which is indoors, the second is from
my outside homebrew station, relayed by a 2.4GHz radio to ethernet broker.
I have indefinite plans to change the message format to JSON.
--
You received this message because you are subscribed to the Google Groups
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.