📜 ⬆️ ⬇️

Sensors from Yoctopuce - the weather at home

Some time ago I was looking for a pressure sensor for one site . The requirements were simple - a USB connection and a minimum of a soldering iron, since I have experience using this tool only in cryptanalysis. It turns out that, unlike temperature and humidity, the Chinese have not yet mastered this market, and the simplest and cheapest option: buy any barometer, send a webcam to it and analyze the readings.
Despite the delusional nature of this undertaking, it was seriously considered, but in the end it was swept away for a banal reason - at night we need lighting. Those. the system will not work at night, and if it does, it will require additional adjustment efforts.

Of the other options, the Sparkfun Arduino-based Meteo Board , or the homemade system based on the Arduino or Netduino, was the most suitable.

But by chance I stumbled upon Yoctopuce , and realized that this is it. Their sensors and sensors impressed me so much in trifles that I cannot be silent and want to share with these Habra community about these wonderful sensors.

')

About yoctopuce

This is a Swiss company with a cute octopus on the logo. The name is just derived from the octopus (octopuce) and the prefix yokto- ( 10-24 ). They start all their devices and APIs with the Yocto prefix. However, for convenience, I call them ektopukami, and I really like this option. :)

As I understood, quite a few people who are engaged in all sorts of smart things work there, and with a bonus they decided to organize the production and store of all sorts of sensors. At the same time, they are guided by 2 important criteria: workmanship and ease of use.

Sensors

There are not so many available sensors:


I now have 4 of them: Yocto-Meteo, Yocto-Temperature and Yocto-Light and Yocto-Demo.

General


All sensors have common properties and are built on the same base:

In general, the devices are striking attention to detail. A very good base is made and comfortable, on which various sensors are now hung.

API

Ekopukov has an excellent API (remember, I was talking about simplicity): it is divided into high-level and low-level ones. High-level: the http-server on port 4444 rises, and it can be accessed via JavaScript or PHP. Low-level: everything is classically: Objective-C, Delphi, C ++, C #.
There are versions for Windows, Mac and Linux.

All devices have standard functions (module name, current consumption, operating time, firmware version) and specific (find out the temperature, turn on the light, etc.).

You can subscribe to the connection event of a new device or disconnect. Actually telling about the code is somehow wrong, it is better to show:

static void Main() { string errmsg = ""; //   if (yAPI.RegisterHub("usb", ref errmsg) != yAPI.SUCCESS) { Console.WriteLine(errmsg); return; } yAPI.DisableExceptions(); //      YPressure ypr = YPressure.FirstPressure(); YHumidity yhu = YHumidity.FirstHumidity(); YTemperature yte = YTemperature.FirstTemperature(); while(true) { //     double pres = ypr.get_currentValue(); double hum = yhu.get_currentValue(); double temp = yte.get_currentValue(); Console.WriteLine("{0:0}\t{1:00}\t{2:0.0}", pres, hum, temp); Thread.Sleep(5000); } } 

This code takes the temperature, humidity and pressure from the first available sensors. As you can see, it is difficult to write more banal code. Naturally, if you wish, you can define the device names and select the right one, in general, I send it to the site , there is elegant documentation for all the functions for each device.

Virtualhub

In addition to the API, you can always refer to http://127.0.0.1:4444/ and see the list of connected devices, reflash them, see current data, and possible functions. Those. even without programming, everything can be quite convenient to use.


Bonuses

Most devices can log data without connecting to a computer. Naturally, there are no miracles here, and the food they need to give out, but nevertheless, such an additional nice opportunity. At the same time, according to the developers, in case of memory overflow (~ 500,000 readings), logging will not stop, everything will not be rewritten in a circle, instead, the old data will gradually overrun (once a minute, once an hour, once a day). So there will be enough opportunities for a long time.

The devices themselves (the ones that I have available)

Yocto-meteo


Measures humidity, pressure and temperature. Humidity from 0 to 100%, temperature from -40 ° to 125 ° (sensor accuracy ± 0.2 °, readings with an accuracy of 1/16 degree, API rounds to 0.1), pressure in millibars, in mm Hg. You can bring your own if desired.

The board can be broken down into 2 parts - the base and separate sensors, connecting them with 4 wires to transmit information. You can break in two places - under the connectors or direct soldering.
The humidity sensor can be covered with a special cap (sold separately) to protect it from dust. Because humidity sensor does not make sense to pack hermetically, unlike temperature and pressure.
Yocto-Temperature


The simplified and cheaper version of Yocto-Meteo, measures only the temperature.
The temperature sensors from the meteoric board and this one, put together, show an almost identical temperature of ± 0.2-0.4 ° (within the limits of the declared error).

The board was cut, soldered wiring, it turned out somehow like this:

Subsequently, the heat shrink tube on the sensor was treated with a hairdryer and tape. The board itself was packed for isolation, and the sensor was packed in its own anti-static bag. Final result:


Yocto-Light


Measures the illumination in suites, breaks only in one place (there are no holes for the connectors). The developers used to create a smart mailbox (they shone with a laser and determined the presence of a letter by interrupting the signal).

Yocto-demo


The most stupid device for testing the size of 2 by 2 cm. You can control one green diode, change its brightness, turn it on / off, blink in different ways. The purpose of the device is to demonstrate the capabilities and functionality. You can understand the API and decide how to use other, more functional and useful devices.

Purchase

Everything is simple. Payment by card (PayPal is not supported), in dollars, euros or Swiss francs. Delivery by regular mail (tracking provided), took a month (the package left Switzerland for a day, then everything is on the conscience of our mail). From 100 francs delivery is free.
The sensors are not very cheap, for example, Yocto-Meteo ~ $ 67, but in principle, the usability and simplicity is worth it.

Analogs

There are not so many of them:


Source: https://habr.com/ru/post/138502/


All Articles