Server in the clouds: getting ready for launch

Π’ post about the regatta we mentioned that in August a competition with prizes awaits all habrazhites. It's time to lift the veil of secrecy. Somehow we got the idea that the phrase "server in the clouds" can be taken literally. And let's really launch a working server into the sky, which can be pinged! At first, the idea looked crazy, but after twisting it this way and that, discussing it in every way, we still came up with a way to send the server towards the birds. A landmark launch will take place at the end of August, but for now we are working on the hardware part of the project. Details under the cut.

Server in the clouds: getting ready for launch

  1. The server will be based on Raspberry Pi 3

    It would be interesting to lift a one-unit server into the air, but its weight + the weight of the UPS ... All this would require a lot of lifting force. And why, if on the basis of a compact Raspberry Pi 3 you can deploy a quite decent server, with a computing power several hundred times greater than the machine on which Tim Berners-Lee had fun in 1991.

  2. Let's launch the server in a balloon

    We had ideas to raise the server on a helium probe, but then the server would not ping for long before the balloon burst at high altitude in a rarefied atmosphere and the whole structure fell to the ground. I wanted to expand the "window" of air time to one and a half hours. And then we decided to use a balloon. Flight duration is two hours. In addition, although the flight is not completely controlled, our engineer can be in the basket, who can quickly, right on the spot, β€œturn it on and off” in the event of a malfunction.

  3. We will use cellular communication as a transport network

    Modern WiFi antennas can β€œpunch through” quite large distances, but for this it would be necessary to build a communication complex that is not much inferior in terms of its parameters to a military radar station. And for the sake of 1,5-2 hours of communication, it makes no sense to build such a system, because at the height of the flight of a balloon, cellular communications must work stably.

After formulating these "postulates", the project ceased to seem impossible, and soon we began to work in all three directions at once.

First of all, we turned to the guys from nearspace.ruwho ate a dog on launches into the air of all sorts of pieces of iron (with subsequent search and rescue).

Then we got the Raspberry Pi 3 lying around in our admin's nightstand and started setting it up.

Server in the clouds: getting ready for launch
Camera connected:

Server in the clouds: getting ready for launch
And they tested it on our "Seed":

Server in the clouds: getting ready for launch
Semyon is very comfortable as a model and assistant - he doesn’t ask for food, he doesn’t get distracted by the phone, he is always in a great mood and with a big smile in his helmet. Of course, we won’t need such a spacesuit for the flight, but it creates the right atmosphere in the office.

The project scheme is as follows:

Server in the clouds: getting ready for launch
Powerbank is used for ground testing, something more reliable is needed to run.

Perhaps the most interesting piece of hardware is a board for receiving data from all sensors:

Server in the clouds: getting ready for launch
The guys from nearspace.ru they suffered for a long time with different analogues, and then they themselves made an on-board computer, because reliability is crucial, the fate of the entire project depends on telemetry data. The on-board computer is responsible for receiving data from all connected sensors and transmitting them to the Raspberry Pi.

We launched it, set it up, and after a couple of weeks of programming and squats with tambourines, we managed to get telemetry data and a photo of Semyon from a wide-angle camera:

Server in the clouds: getting ready for launch
Telemetry data is transmitted in one line in the following form:

Server in the clouds: getting ready for launch
This code then converts the string to an array and outputs the data to the site:

$str = 'N:647;T:10m55s;MP.Stage:0;MP.Alt:49;MP.VSpeed:0.0;MP.AvgVSpeed:0.0;Baro.Press:1007.06;Baro.Alt:50;Baro.Temp:35.93;GPS.Coord:N56d43m23s,E37d55m68s;GPS.Home:N56d43m23s,E37d55m68s;Dst:5;GPS.HSpeed:0;GPS.Course:357;GPS.Time:11h17m40s;GPS.Date:30.07.2018;DS.Temp:[fc]=33.56;Volt:5.19,0.00,0.00,0.00,0.00,0.00,0.00,0.00';
parse_str(strtr($str, [
	
':' => '=',
	
';' => '&'
]), $result);
print_r($result);

Description of some data:

  • N:2432; β€” data packet number, always increasing
  • T:40m39s; - time since the flight controller was turned on
  • MP Stage:0; - flight stage (0 - on the ground or below 1 km, 1 - ascent, 2 - hovering at altitude, 3 - descent)
  • MP Alt:54; - barometric altitude in meters from sea level - it should be displayed
  • MP.VSpeed:0.0; β€” vertical speed in meters per second with median filter
  • MP.AvgVSpeed:0.0; β€” vertical speed in meters per second with averaging filter
  • Baro.Press:1006.49; - barometer pressure in millibars
  • Baro.Alt:54; - barometer altitude
  • Baro.Temp:36.99; is the temperature of the barometer itself
  • GPS.Coord:N56d43m23s,E37d55m68s; - current coordinates
  • GPS.Home:N56d43m23s,E37d55m68s; - starting point coordinates
  • GPS Alt:165; β€” GPS altitude in meters
  • GPS.Dst:10; β€” distance from the starting point in meters
  • DS.Temp:[fc]=34.56; - temperature sensor on the board

What the output looks like:

Array 
(
       [N] => 647
       [Π’] => 10m55Π·
       [MP_Stage] => 0
       [MP_Alt] => 49
       [MP_VSpeed) => 0.0
       [MP_AvgVSpeed] => 0.0
       [Baro Π rΠ΅ss] => 1007.06
       [Baro_Alt] => 50
       [Baro_Temp] => 35.93
       [GPS_Coord] => N56d43m23s,E37d55m68s 
       [GPS_Home) => N56d43m23s,E37d55m68s 
       [Dst] => 5
       [GPS_HSpeed] => 0
       [GPS_Course] => 357
       [GPS_Time] => 11h17m40s
       [GPS_Date] => 30.07.2018
       [DS_Temp] => [fс] Π—Π—.56
       [Volt] => 5.19, 0.00,0.00,0.00,0.00,0.00,0.00,0.00 
)

But what if the cellular connection "drops"? In this case, we have a second card, two SIM cards are inserted into the modem (into one slot in turn):

Server in the clouds: getting ready for launch
He knows how to automatically switch to a spare channel if the main one suddenly stops responding.

And what happens if both cellular networks become unavailable?

Server in the clouds: getting ready for launch(Boy from Issue "Yeralash" No. 45 not in vain reads "Probability Theory")

In this case, we will have an independent GPS tracker that sends a signal about its location. Please note that he does this not through a cellular network, the availability of which is not guaranteed by anyone over a long distance, but through a satellite.

Server in the clouds: getting ready for launch
Yes, the GPS tracker is somewhat larger than the one that was implanted under the skin of James Bond. Since our competition depends on the coordinates of the flying server, this part of the data received from the board will be the most important. But we will talk about this in the next post. Coming soon, follow our blog!

We believe in the success of the whole enterprise so much that we even announced a competition for those who suddenly want to guess the place where the ball will land. Details in our new post.

Source: habr.com

Add a comment