When aggregate = individual, I am expecting it to NOT send in JSON format, 
and instead send it just the individual metric to the topic of 
/weewx/<mesurement>. I believe that is how yours is working today. If we 
want to test with your instance, you can add -v to your mosquitto_sub query 
and that will then show us the individual topics that are underneath the 
topic of "weather" and that likely each measurement is a different subtopic.

When weewx sends the JSON string, I am utilizing the loop bindings. With 
loop bindings, the JSON strings will differ with each transmission since it 
doesn't get everything on every reading. As a result of this, it makes it 
rather difficult for my other application to interpret these JSON strings 
since each one is different and not consistent.

Other options will include defaulting back to archive bindings, but they 
aren't real time enough for my application. If I do that, the JSON string 
should be mostly uniform each time the archive runs. But once again, if I 
select "individual" measurements when doing archive, I have the same issue, 
where it will only parse the first reading of the JSON string. So instead I 
have to use "aggregate" and parse the JSON string again, back to square 
one, but at least now the JSON string should be a little more uniform.

Overall I am pushing these measurements into MQTT so that I can set them up 
as sensors within my home automation platform. I can probably do some 
hackery to make my home automation platform properly decipher the JSON if I 
need to. But overall this smells like a bug or configuration issue within 
the MQTT extension for WeeWX.

On Friday, March 8, 2019 at 1:44:46 PM UTC-5, HoracioDos wrote:
>
> Hi.
> I think I didn't fully understand your problem. When aggregate = 
> individual mqtt extension does not send data to the broker in json format. 
> Is that correct? I think that's how it works.
> If you want to select a specific data you must to subscribe to the proper 
> topic. Why do you need individual values? Perhaps we can help you better if 
> we know your needs. I'm sorry if I missed that in a previous question.
>

-- 
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 weewx-user+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to