Thank you

Am Mittwoch, 7. Dezember 2016 14:47:58 UTC+1 schrieb mwall:
>
> On Tuesday, December 6, 2016 at 8:37:36 PM UTC-5, Bill Morrow wrote:
>>
>> I built a system where an Arduino reads sensors using I2C, and sends the 
>> data to a Raspberry Pi as a small packet using RF24Mesh radios. Then a 
>> process running on the Pi, modeled after one of the RF24Mesh examples, 
>> publishes to an MQTT broker. A weewx driver subscribes to the publication 
>> and writes to the weewx database. The broker and weewx are running on a 
>> different computer, but they could be on the Pi.
>>
>> In your case, where the Pi already has the data, you could make something 
>> similar but simpler. Change the /home/pi/weather-station/interrupt_daemon
>> .py script to publish to MQTT, run mosquitto or some other MQTT broker, 
>> and use my MQTT subscribing driver to read from the broker and generate 
>> loop packets (snapshopts of your readings) inside weewx.
>>
>> *https://github.com/morrowwm/weewxMQTT.git, *look for 
>> <https://github.com/morrowwm/weewxArduino/tree/caf848ffc12233757cddd3e7f023f15d8468e2dd>
>>  
>> <https://github.com/morrowwm/weewxArduino> weewxMQTT 
>> <https://github.com/morrowwm/weewxMQTT>/bin 
>> <https://github.com/morrowwm/weewxMQTT/tree/master/bin>/weewx 
>> <https://github.com/morrowwm/weewxMQTT/tree/master/bin/weewx>/drivers 
>> <https://github.com/morrowwm/weewxMQTT/tree/master/bin/weewx/drivers>/
>> *wxMesh.py* 
>>
>> I'm new to github, so hope I've done that right.
>>
>
>
> bill,
>
> very nicely done!  using mqtt as a standard protocol for a variety of 
> sensor types is an excellent approach.
>
> standard practice is to put a new driver in the user folder (not the 
> weewx/drivers folder) so that you can update weewx without losing your 
> modifications.  unless you're working on core weewx code, this approach 
> tends to be easier than maintaining a separate fork or branch.
>
> you could make it easier to manage (for yourself) and share (for others) 
> if you put the mqtt driver into its own repository (i.e., just the 
> wxMesh.py file).  that way you don't have to duplicate the entire weewx 
> codebase.
>
> even better, package the mqtt driver as a weewx extension so it can be 
> easily applied to any weewx installation.  packaging should be pretty easy 
> - see the fileparse driver as one example, and the customization guide for 
> details:
>
> http://weewx.com/docs/customizing.htm#extensions
>
> if any of that is unclear or difficult to understand, please let us know 
> so we can make it better!
>
> m 
>

-- 
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.

Reply via email to