Tag Archives: dew point

RMS integration with Met Office DataPoint. An experiment with APIs…

The latest Rotronic Monitoring System software has been designed specifically for the IoT and IIoT world. We have a wide and growing range of sensors, loggers as well as input and output modules but we will never keep up with the unique demands of our customers. That’s where integration is key for any successful continuous monitoring system!

iot

Hardware can already be integrated via analogue input modules such as our 8ADC and digital devices can be integrated via our RMS-Convertor that can be programmed with custom protocols and functions operate with virtually any device.

Want to cut out the waffle… login and see the live data now using the details below:

https://rms.rotronic.com/rms/
Company Name: rms demo cloud
User: guest
Password: guest1234

In addition to hardware, software integration is a must, and not easy when we consider RMS is a fully Gamp6 compliant system and therefore security and traceability is key.

Why not access the SQL DB?

All data on RMS is stored within an SQL database which with suitable rights can be queried easily to pull data out. However injecting data whilst possible triggers our system to report data manipulation. Also direct access to the database presents a security risk and uncontrolled changes to the system, and of course its not possible on shared systems.

That is why we also offer a Restful API through which data can be posted only when configured by users with appropriate permissions and each data stream is securely linked to a onetime token, by no means the best security but suitable for many applications (and of course the whole API function can be disabled if preferred). We of course have software wizards at our HQ that can develop professional integration solutions but as a hobbyist I wanted to see what I could achieve.

Example API Report

So my plan was to use Python and pull data from the Met Office DataPoint service and inject it directly into our RMS server software so it could visualised, reported and analysed accordingly. Just a few simple steps…

  • Step 1 Get the data from Met Office API
  • Step 2 Create API device in RMS and send your data
  • Step 3 Enjoy graphs, reports and custom alarms

Step 1 – Get the data from Met Office API.

The Met Office API is great you simply need to register to get an api key then get your head around the commands. Once you have that you can request the data you need via a simple url and the information is returned in xml or json format.

API Example
Met Office Datapoint API Response in XML

In Python requesting the last 24 hours of hourly data from location 3212 (Keswick) looks something like this…

Import json, requests
url = ‘http://datapoint.metoffice.gov.uk/public/data/val/wxobs/all/json/3212?res=hourly&key=YOURKEY’ #replace with your Met Office API key!
r = requests.get(url)
metoffice_data = json.loads(r.text)

This gives a Python dictionary with all the json data from which we can request specific values easily for example the latest conditions (no doubt there are more elegant solutions but this works for me).

Hum = (metoffice_data[‘SiteRep’][‘DV’][‘Location’][‘Period’][1][‘Rep’][-1][‘H’])
Temp = (metoffice_data[‘SiteRep’][‘DV’][‘Location’][‘Period’][1][‘Rep’][-1][‘T’])
Pres = (metoffice_data[‘SiteRep’][‘DV’][‘Location’][‘Period’][1][‘Rep’][-1][‘P’])
DewP = (metoffice_data[‘SiteRep’][‘DV’][‘Location’][‘Period’][1][‘Rep’][-1][‘Dp’])

Next we need to create our API device within RMS so it will accept our data

Step 2 – Create API device in RMS

Adding new API device in RMS is simple process, we create the device and define the Name and Serial number.

At this point RMS awaits an Post command in which the additional details are included. Using the Python code below I am able to create a device with 4 measurement points (measured values); Humidity, Temp; Pressure and Dew Point.

import json, requests

url = ‘http://rms.rotronic.com/wService/wService3.DeviceService.svc/UpdateDataJson’
headers = {‘Content-Type’ : ‘Application/json’, ‘Expect’ : ‘100-continue’, ‘Connnection’ : ‘Close’, ‘Host’ : ‘rms.rotronic.com’}

payload = {‘Name’:’API_Test’,’Serial’:’12345′,’Values’:[{‘Index’:’1′,’Typ’:’1′,’Value’:’50’},{‘Index’:’2′,’Typ’:’2′,’Value’:’23’},\
{‘Index’:’3′,’Typ’:’16’,’Value’:’5′},{‘Index’:’4′,’Typ’:’48’,’Value’:’1000′}]}
print (payload)
r = requests.post(url, headers=headers, data =json.dumps (payload))

Finally RMS gives us the device ID and API token which must be included in any future post commands.

Combining Step 1 and Step 2 allows us to simply replace my example values above with the real Met Office API data! Run the script hourly or permanently with an hour delay and we have a simple tool proving live data weather data!

Step 3 – Enjoy graphs, reports and custom alarms

With the data in RMS we can easily graph values and create email, sms or phone alarms. Taking the API further I it is possible download live satellite imagery and dynamically update the layouts in RMS!

Example Report

So it turns-out getting data into RMS via the API is simple with a bit of basic code. Of course Met Office data is just an example in modern industrial applications there is so much unique data from devices or software that might be of use and RMS aims to offer a complete monitoring solution not simply for our products!

Be sure to get in touch if you have any questions on the above or have any monitoring requirements. Use the demo login above or visit out RMS website for more details.

Dr Jeremy Wingate
Rotronic UK

 

What is Dew Point Temperature

Our state side colleagues have put together a great FAQ technical note explaining dew point temperature in more detail!

chilled mirror / dew point mirror
chilled mirror / dew point mirror

The FAQ technical note can be accessed here and answers the following key questions!

  1. What is dew point temperature?
  2. What is frost  point?
  3. When should I choose dew point as the parameter I measure?
  4. What are the pros and cons of measuring dew point versus relative humidity?
  5. Does dew point change as the ambient temperature changes?
  6. How does pressure affect dew point measurement?
  7. What are the common technologies for measuring dew point?
  8. Isn’t dew point temperature the same thing as wet bulb temperature?
  9. How do I know which technology is best for my application?
  10. Where can I buy a dew point instrument?

Rotronic produce precision low dew point sensors for low moisture applications in addition Rotronic UK is the UK distributor for world class MBW chilled mirrors, please contact us for additional information!

Dr Jeremy Wingate
Rotronic UK

Meteorology: Numerical Weather Prediction

The Calculation of Weather Data

What is the weather going to be like tomorrow?

For a long time, people have tried to predict weather conditions using the hydrologic climate cycle.

In the early 1920`s scientists were able to compile a six-hour forecast. Back then it took six weeks to calculate by hand the weather data collected at two points in Europe and create a useful illustrative model.

Today, supercomputers are used to predict the weather for a period of several weeks. The complex modelling programs require several million data points for parameters such as temperature, humidity, pressure, vertical & horizontal wind velocity with time stamps and absolute coordinates. To create a correlation between the data and the environment, scientists “slice” the atmosphere virtually into smaller horizontal & vertical parts – this process is called discretization. It is more useful to compute the chronological change of the parameters using this model.

Meteorological events that are too “small” such as a single thunderhead, layer clouds or smaller turbulences will be parameterised through variables. This parameterisation is a science of its own that aims to reduce uncertainties as best as possible.

754334main_GOES-7Jun2013-0831EDT
Every forecast calculation starts with the current weather conditions. The quality of this input is crucial for the accuracy of the final forecast. Meteorologists link the forecast of yesterday’s weather with the actual measured parameters. Only large data centres are capable of computing this data assimilation. The overall result is a best possible calculation basis to predict the weather for the next day. If this groundwork is flawed the forecast may be incorrect, for example it could report rain at the wrong location.

Today’s meteorological mathematicians also take parameters into account that change extremely slowly compared to the other factors. Growth and the reduction of polar ice, or the temperature of the oceans are summarised as boundary values

After a model is run using all the available data, meteorologists’ process and customize reports for a wide range of target groups such as public authorities, flight control centres, energy producers, industries and many more, including the issue of specific warnings.

Facts & figures:

17.8 cm is the diameter of the largest hailstone ever recorded.

Sukkur City in Pakistan is one of the most humid places in the world with 30 °C dew point & a felt air temperature of 65 °C.

A study showed that a small thunderstorm system holds more than 10 million tons of water.

No two weather patterns are completely alike.

Some weather models assimilates data obtained from more than 25,000 weather stations.

Why The need to Measure Humidity?

As described above, the daily weather fore-cast relies on the precise measurement of weather parameters. The science of numerical weather prediction aims to describe the daily hydro-logic cycle in numbers – humidity plays an important role in this – data errors will multiply during calculations.

Humidity values influence weather calculations e.g. through the water vapor balance equation – this formula expresses the influence of humidity through rain & condensation, and vice-versa.

Incorrect measurement or incomplete humidity data directly leads to wrong predictions of a huge number of weather phenomena; this can include the condensation altitude of clouds, locations of hyetal regions, fog layers and storms.

In 1999, incorrect data sent by a weather station in Nova Scotia, Canada led to an incorrect forecast for Hurricane Lothar two days before it hit Central Europe. Authorities were insufficiently prepared to alert people in time.

hurricane-ivan_200_600x450
What is the Rotronic Solution?

Rotronic products are used in weather stations around the globe. They provide temperature & humidity data continuously with high accuracy even in demanding environments.

Rotronic manufactures a range of meteorological probes and weather shields to meet the standards required by meteorological organizations.

Philip Robinson

Rotronic UK

New states of matter… making a mess of my slide pack

How many states of matter are there?… Hold that answer, first I’ll explain why…

We regularly provide formal and informal training, in fact it is something we  feel differentiates us, helps us learn and is a great  way to keep in contact with the industry. With a team including ex-NPL staff, Oxford graduates, PhDs, one of the best UKAS laboratories in Europe and years of combined experience in the fields of humidity, dew point and temperature  we feel we are well placed to offer these expertise.

One of the first things we discuss when learning about the principles of humidity, are the states of matter. It s vital to understand solids, liquids and gases before we can go on to vapour pressure, dew point, frost point and triple points etc.

I have yet to find someone who doesn’t know the three states but this light introduction acts as a good starting point to the deeper subject.

However, I am regularly corrected that plasma is the forth state of matter (not relevant for our discussions as such but still valid all the same). So I have corrected my slides accordingly.

What happened next, I struggled to believe at first when I was told… Apparently within chickens we can find another state of matter!! Seriously… chickens. To be exact the chickens eyeball. It is called ‘disordered hyperuniformity’ and in simple terms it is a state that has some crystal like properties and some liquid like properties.

A state of chicken
A state of chicken; Courtesy of Joseph Corbo and Timothy Lau, Washington University in St. Louis

The  arrangement of cells was discovered by researchers at  Princeton University and Washington University in St. Louis. Full details can be found here on the Princeton site. http://www.princeton.edu/main/news/archive/S39/32/02E70/

What next I thought, and where best to look but wikipedia… A quick search highlights that the four fundamental states of matter are just the tip of the iceberg.

There are; Non-classical states, Low-temperature states, High-energy states, Very high energy states … the list goes on and this is just a glance at wikipedia!

The latest (unless another has just been discovered) is the quantum droplet and apart from being the most recently discovered comes with a great picture.

Quantum Droplet
Quantum Droplet; Credit: Baxley/JILA

Part particle, part liquid, it is termed a “quasiparticle”. I wont attempt to explain it here but if you are interested is it nicely explained on the Scientific American website, which includes a link to the original Nature paper. http://www.scientificamerican.com/article/dropleton-quantum-droplet-quasiparticle/

So back to the question; how many states of matter are there? I will stick to answering that with” there are four fundamental states of matter…” I think the rest we’ll leave out of our training courses for now!

Dr. Jeremy Wingate
Rotronic UK