Mqtt Weather collect Data from Weather Underground, and publish the Data to a local MQTT Broker
mqttWeather is a OSGI Application that comes as Bundle for the KARAF Application Container
mqttWeather fetch Data from Weather Underground
Register here
Goto your Karaf installation KARAF_BASE_DIR/etc Create a file named mqttWeather.cfg
############################################################################
# MQTT Configuration
mqtt.host=tcp://{MQTT_BROKER}:1883
mqtt.topic=/filiberry/weather
mqtt.client.id=mqttWeather
# Weather Underground Call Intervall in Minutes
weatherUnderground.intervall=20
weatherUnderground.url=http://api.wunderground.com/api/{API_KEY_HERE}/conditions/q/pws:{PWS_ID_HERE}.json
Dont forget to replace {API_KEY_HERE} with your API Key.
and Your favourite Weather Station ID with {PWS_ID_HERE}
Set the Name or IP Adresse from your MQTT Broker here {MQTT_BROKER}
Simply copy mqttWeather.jar to KARAF_BASE_DIR/deploy
Startup or Log into your Karaf installation.
And check the Bundle ist up and running.
The Result in MQTTLens
Checkout the Blog on my Website
Sorry, only in German