Through Flyport and the SHT71 Sensirion sensor it is possible to project a weather wireless station. In particular SHT71 allows to acquire the environmental temperature and humidity, data that will then be sent to ThingSpeak for the storage.
ThingSpeak.com is a free service offering (upon registration) multi-functional database to backup any data. Each time you create a database, you receive a “Write API Key“, an access password that identifies the database.
To start, we need two API libraries (thingspeak.c and SHT.c) to import on OpenPicus IDE 2.0. The system, once programmed and started, connects to the desired WLAN and initiates the sensor. The main routine includes the acquisition of environmental data (float) through SHT71 sensor, the Flyport processes them converting the temperature in °C and humidity as a percentage, all with the unique API SHTRead (). The routine then continues with the “WdataF” which takes as parameters: the write the API key, an array of float type and the number of elements of that array. The function correctly set, automatically connects Flyport to the server thingspeak.com through TCPClient.
In addition to sending a POST that accesses the database, specified by the “Write API Key“, and sends the data of temperature and humidity for the storage. The data, now stored in the remote database, will be available to users through colourful graphics(downloadable from thingspeak originated) or downloaded to any device of XML-like files.