I recently got my hands on an Aercus Weathersleuth Weatherstation. This is a fairly nice piece of kit.
One of its benefits is it can talk to the internet or an arbitrary server. A bit of poking around revealed it communicates by way of an HTTP post request which looks as follows –
On the back of this I wrote a trivial script (which does not yet do authentication) –
# Script to take data from Aecus weather station and convert to MQTT
# Stations is an array which defines the devices we accept.
# Format of each sub-array is “Name”,”Password”,”IP address”
# This script requires php-mqtt – see https://github.com/php-mqtt/client
# Acquired with “composer require php-mqtt/client”
$mqttserver = ‘MQTTSERVER’;
$mqttport = 1883;
$mqttClientID = ‘WeatherStnToMQTT01’;
$mqtttopic = ‘WeatherStation’;
# List of attributes not to send to MQTT
$DontPublish = array (‘ID’,’PASSWORD’);
$mqtt = new \PhpMqtt\Client\MQTTClient($mqttserver,$mqttport,$mqttClientID);
# Clean up array
echo “<hr />”;
foreach ($PostedVals as $PostKey=>$PostVal)
# Ignore the following keys:
This script needs to be placed in (documentroot)/weatherstation/updateweatherstation.php – and (from the same path” composer require php-mqtt/client” needs to be run to install the MQTT library
On the version I got – software version 2.1 The security on this device is pretty much non-existent. The web interface for the device can be accessed without a username or password, and telnet access username and password are both, by default admin. Communication takes place on http (no obvious option for https). The password to the publish to the webserver is sent as part of a request which will turn up in the servers log files.
I guess publishing this to a local server at least means that to access the url someone needs to have breached the local network.