Difference between revisions of "PRO Tutorial"
(→Edit Data Set)
(→Find Data to be Corrected)
|Line 108:||Line 108:|
When reaching an hours all the minutes are listed as values to allow editing. Here we see that the false reading incident was at 14:33 (marked in orange when moving the mouse over it) and 14:34.
Latest revision as of 21:12, 21 July 2016
This page lines out some Meteobridge PRO specific how-tows
- 1 Optimize RF Reception
- 2 FTP Upload of CSV Exports
- 3 Doing Data Backups
- 4 Cleanup of History Data
- 5 New "Large" Weather Data Screens
Optimize RF Reception
Meteobridge PRO (red cap model) has a RF receiver included to directly pick-up data from Davis outdoor sensors. Compared to a Davis console where only very little computing stuff is happening, we have a high density of sensors, computing modules, Ethernet circuitry and even a WiFi module all together in a very compact housing.
To keep RF noise away from the reading Davis sensor data, we designed an external antenna. The antenna shipped with Meteobridge PRO is quite good in RF operation and picks up about 5 db more signal strength than the wire antenna of Meteostick does. However, if your sensors are far away some tweaking of RF reception might be necessary.
This section of the tutorial explains what you can do if you need improved RF sensitivity.
Turn the Meteobridge PRO into an RF strength meter and find a good place to rest
Before you start experimenting how to improve RF reach we recommend to run through the following steps:
- Configure your Meteobridge PRO to connect via WiFi with your network. As you might want to move the Meteobridge PRO and test for various locations, having an Ethernet cable hanging around will be annoying.
- Power your Meteobridge PRO temporarily with a USB power bank. I assume you have some 5V rechargeable battery with USB plug to feed the Meteobridge PRO laying around. Any cheap power bank for your mobile phone will do. You will need a USB cable that fits into the micro USB power socket of the Meteobridge PRO, but I am sure you have that somewhere in your household. Being on battery and WiFi you have total freedom in checking for a good place for the Meteobridge PRO to rest.
- PRO_Display. For the moment you don't need to know the details ;-)
Having done so the Meteobridge PRO display will show data like this:
Picture on the left shows reception when Meteobridge PRO is directly sitting on my desk with a lamp, some metal enclosures and the metal corpus underneath my desk in direct neighborhood. Values around -70db are not great, but still no problem to receive. When it reaches the -90 db reception will get tough. By moving the Meteobridge less than a meter away to a higher position on a shelf, reception situation improves significantly. You see that on the right picture. Signal strength in the mid -50db is much better and will allow the sensors to go further away without having the connection dropped. By the way, the display is white but my camera makes it look blue sometimes. If you like watching the numbers change, this 30 second movie might be of interest to you (moving black bars on display are just camera artifacts).
No one can tell you what best position will be in your location, but you are highly invited to check out yourself.
- replace small antenna by a larger one that better fits to the wave length of your sensors signals.
- connect an antenna that is not directly mounted to the connector but has some cable to bring the antenna further away from the RF noise the Meteobridge PRO is inevitable producing and by that giving the RF signals more head room by reducing the noise floor.
- connect to an antenna with some directional characteristic, which can be a small yagi or other form factors. This might be an option to consider when extreme reach needs to be achieved and if you can mount the antenna outdoors as a directional yagi antenna might not fit well to your indoor living style ;-)
Picture on the right shows how the Meteobridge RF SMA female connector looks like and how the antenna SMA male plug is formed. When the antenna plug is a bit too thick to have the power connector inserted underneath, you can cut 1 mm off the white plastic from the micro-USB power plug. Please watch out not to cut too deep. While testing with alternative antennas this works rather uncomplicated. Please realize, that you do this at your own risk and it will void your warranty, so better to choose an antenna with a fitting plug.
We conducted some antenna comparisons for you. We choose a not so good reception position and swapped through different kinds of antennas while checking RF reception level.
On the left you see the Meteobridge PRO with stock antenna, next to it with a 868 MHz "H-Tronic" HT110A antenna and on the right with a multi-band GSM/UMTS antenna 88414 from "delock" which has a rather thick SMA plug and therefore needs the white power plug underneath remodeled a bit with a knife (cutting off 1 mm went fine). As you see these antennas are very close to each other, with the multi-band antenna loosing some ground. From that perspective changing stock antenna with a larger one of the same kind does not make too much of a difference, at least in our test setup.
When nothing else helps, you can always ask your Davis console to retransmit packets and to let Meteobridge PRO sniff data from there. As packet retransmits mostly have a lager frequency drift, you need to change the Meteostick settings on "Weather Station" tab regarding bandwidth from "small" to "normal". Furthermore, you have to select the transmitter ID the Console is using for the retransmits. Having the console just a few meters away from the Meteobridge PRO even the worst antenna will do ;-)
FTP Upload of CSV Exports
There have been may requests to upload data of a day or month in some CSV like notation onto a server via FTP. Meteobridge PRO has the building blocks (export function and FTP upload capability) to make this reality. This section explains how to set this up:
Define CSV Schema
The structure of CSV exports is defined by export templates that are user-defined and can be found in PC network share "templates". Export templates have extension ".exp" while the generated exports are stored in "export" folder and have extension ".txt". We start with pre-defined standard template "standard-iso.exp". This template defines a schema where columns show date, time, temperature, humidity, dew point, pressure, wind speed, wind gust, wind direction, rain fall holds these data the following.
# Standard CSV template with data in metric units # $# date, time, temperature[C], humidity[%], dew point[C], sealevel pressure[hPa], avg wind speed[m/s], gust speed[m/s], winddir, rainfall[mm]<BR> [YYYY]-[MM]-[DD],[hh]:[mm],[th0temp-avg.1:],[th0hum-avg.0:],[th0dew-avg.1:],[thb0seapress-avg.1:],[wind0avgwind-avg.1:],[wind0wind-max.1:],[wind0dir-avg.0:],[rain0total-sum.1:]
Meteobridge PRO also allows for some pragmas to control how data is inserted:
- "#pragma fillgap=nn" automatically fills gaps up to nn seconds to avoid empty columns when there is no data within that specific minute. Default is 300 seconds.
- "#pragma emptyline=y" does even printout rows, when it is completely empty, which means it has no data. "emptyline=n" does not print out empty lines.
When you want to insert some header or footer lines into the output, these lines need to be start with a "$", where the "$" is omitted in the output text. Any other line starting with "#" is not reflected in the output and just handled as a comment.
Schedule Generation of Exports
2015-12-13,00:00,4.8,97,4.4,1005.2,0.0,0.0,248,0.0 2015-12-13,00:01,4.8,97,4.4,1005.2,0.0,0.0,248,0.0 2015-12-13,00:02,4.8,97,4.4,,0.0,0.0,248,0.0 2015-12-13,00:12,,,,1004.7,,,,0.0 2015-12-13,00:13,5.1,97,4.7,1004.9,0.0,0.0,180, 2015-12-13,00:14,5.1,97,4.7,1004.7,0.0,0.0,248,0.2 2015-12-13,00:15,5.2,97,4.8,1004.6,0.0,0.0,248,0.0 2015-12-13,00:16,5.2,97,4.8,1004.6,0.0,0.0,248,0.0 2015-12-13,00:17,5.2,97,4.8,1004.5,0.0,0.0,248,0.2 2015-12-13,00:18,5.3,98,5.0,1004.6,0.0,0.0,248,0.0 2015-12-13,00:19,5.3,97,4.9,1004.5,0.0,0.0,248,0.0
Define Upload Service
Doing Data Backups
Backups can be initiated immediately with the "Backup" button on "system" tab or can be programmed as a service as follows.
All backuop operations will be logged in messages section of "system" tab.
Restore from an inserted USB stick can be simply done by using the drop-down list "Restore from..." on "system tab. Operation will also be logged in messages section of "system" tab.
Cleanup of History Data
While Meteobridge just stores average, minimum and maximum values for the current day, yesterday, current month, current year and all time, the new Meteobridge PRO does store data from sensors in a per minute resolution from when you started using Meteobridge PRO. The "History" tab gives you access to all this data and allows you to change, create or delete data on this per minute time resolution. To make yo familiar with how to work with this data, we will run through the use case "How to delete a spike in rain fall caused by cleaning the rain sensors funnel by pouring water through it?".
Find Data to be Corrected
We still remember that rain funnel cleaning was done in December 2015, but not exact day and time. When looking at the year view on rain data (sensor "rain0total") we see that December indeed has a bit high rain readings (abt 60mm).
So we drill down into December 2015 and can see that December 7 has a peak with nearly 50 mm rain fall. Looks like this was the day the rain funnel was washed with water.
Next drill-down is on the hours of December 7 shows that we have a peak at 14h.
When reaching details of an hours all the minutes are listed as values to allow editing. Here we see that the false reading incident was at 14:33 (marked in orange when moving the mouse over it) and 14:34.
Edit Data Set
Editing is easy. Just click onto the value field you like to edit and you see a dialog opening where you can insert the right values. If you don't add a unit to your input, metric/ISO units are assumed. If you want to insert in imperial units, please add "in", "F", "inhg", "mph" to it. Meteobridge will then convert automatically. When you want the data to be displayed in imperial units as well, please set the "Use Imperial Units" mark on top of the "Edit Data" field. We decide to enter "0" for 14:33 into this dialog. File:Mbpro-rep5.png:right
When having inserted "0" and having pressed enter the screen updates and applies your correction. As you see, rain value has changed to "0.0mm" on 14:33.
As we are bored to repeat that with the false reading next to it (14:34) we decide just to delete this reading. Deletion can be done by clicking onto the time stamp. When moving the mouse over it a balloon help is shown.
After clicking the time stamp this dialog appears to prevent you from deleting data by accident.
When this is done, false reading for December 7 is corrected and monthly rain report looks like this.
New "Large" Weather Data Screens
Meteobridge PRO can make use of its display to show weather data. Yes, you know that, but I think you might be interested in the new, just rolled-out templates "BIG-scroll-IMP" and "BIG-scroll-ISO", which show data with larger digits. Video to the right shows a full run-through of the screens. Please ignore the flickering, which is a camera artifact only. This time we made a bit more used of the graphical capabilities of the display. Wind direction is illustrated by an oriented line in a circle. You might ask, when first temp curves show up? We'll see ;-) As you might expect having these 8 screens defined is not done before breakfast, but it is also no rocket science. When you are keen for all the details, please have a look at the wiki section "PRO Display". Code below shows the definition of one screen you see on the right.
It starts with a clean up of the screen, then "Helvetica 14pt bold" is selected as font, a white rounded box is drawn with black text "WIND" inside and the white text "mph" to the right.
*addloop b3 5 300 \ #clear\n\ #font helvB14\n\ #color 1\n\ #rbox 0 0 70 18 5\n\ #color 0\n\ #string 8 16 WIND\n\ #color 1\n\ #string 85 16 mph\n\ #font fub30\n\ #string 0 60 [wind0wind-avg1=mph.1:--]\n\ #circle 105 43 20\n\ #if#[wind0avgwind-act.1:0.0]#then##pline 105 43 20 [wind0dir-act.0:0]\n#else##fi##disc 105 43 4
Then font is changed to "Free Universal 30pt bold" (fub30) and average wind speed of last minute is displayed in mph and with one decimal resolution. On the right side of this a circle (center 105/43, radius 20) is drawn. If average wind speed of last minute is not zero then a line starting from the center of the circle with length 20 is drawn oriented by the current wind direction. The last step draws a small filled disc into the center of the circle. How #if# #then# #else# #fi# statements operate is explained at the end of "Templates" section of the wiki.