Home PageMeteotime with arduino

Meteotime with Arduino

The second method for decoding the meteotime data stream is to use an arduino. Using this method you need to construct the bits into a format that can be used in the DES decoder. With this method the DES decoder is just software within the arduino, so that no meteotime decoder chip is needed.
Meteotime is a commercial business located in Switzerland. Their business model involves charging a licence fee for the decoding chip.  Unfortunately by publishing this code this business model would be broken and this certainly is not my attention. So i will not be publishing the entire code. From an intellectual point of view the modified DES algorithm used is interesting so here are a few snippets. The first 14 bits from three consecutive minutes plus the final time makes a 82 bit string. From the 82 bits string you mis out bit 1 and 8. These are used by the civil defense system but are not needed for meteotime decoding. This leaves 80bits which make up the cipher and key. This is then processed by the arduino.

Cipher=[0]101111[0]00 0xBC 10101101 0xAD 01101001 0x69 11101001 0xE9 10010011 0x93
flip  =      00111101 0x3D 10110101 0xB5 10010110 0x96 10010111 0x97 11001001 0xC9
<-- This is Meteotime DES cypher
Key      = 01000000 0x40 00000000 0x00 00001100 0xC0 00100100 0x24 01001000 0x48
Key flip = 00010010 0x12 00100100 0x24 00110000 0x30 00000000 0x00 00000010 0x02
<-- This is Meteotime DES key

These are the two inputs that are needed by the DES algorithm. It then gives a plaintext output.
Plaintext =                     0x16 0x50 0x62 0x02 0x36     <– This is decoded plaintext from DES decryption algorithm.
It is then manipulated to give checksum and Meteo data
Plaintext = 0x[1]6 0x[50] 0x6[2] 0x02 0x36
Plaintext = 0x2501 –> Its OK. The 0x2501 is needed for the data to be valid. This can be used by the arduino program to correct wrong error bits.
This involves repeatedly flipping one bit and looking for this 0x2501 answer.  Assuming the 0x2501 is received then the other parts of the plaintext is the decrypted weather data. The time part of the 82 bits contain several parity checks and can also be compared to previous minute data so that you can assume this is accurate. The plaintext is manipulated first and then the 24 bits weather data is inverted bit by bit for each byte as follows.
result =                    0x26               0x60             0x63
result =              00100110    01100000    01100011
result flip =      01100100    00000110    11000110    –> Meteo data output from DECHIFFRIER-IC
Below you can find an output from the Arduino program i have used which is a Meteotime DES encryption and decryption program. The encryption part can be used to encrypt weather data for instance received from METAR weather data on the internet . With a simple transmitter one can then send the appropriate time and weather data to a Meteotime receiver station and “program” the weather forecast.

Meteotime DES



1 comment

  1. wimheb says: September 7, 2020

Trackbacks and pingbacks

No trackback or pingback available for this article

Leave a Reply