How to make virtual reality glasses from your phone. How to make virtual reality glasses? Available features of the VR helmet

Learning microcontrollers seems to be something complicated and incomprehensible? Before the advent of Arudino, it was really not easy and required a certain set of programmers and other equipment.

This is a kind of electronic designer. The initial goal of the project is to allow people to easily learn how to program electronic devices, while paying minimum time electronic part.

Assembly the most complex schemes and the connection of the boards can be carried out without a soldering iron, but with the help of jumpers with detachable connections "father" and "mother". In this way, both attachments and expansion boards can be connected, which in the lexicon of arduinoschikov are simply called "Shields" (shield).

What is the first Arduino board to buy as a beginner?

The basic and most popular board is considered. This board is the size of credit card. Pretty big. Most shields that are on sale fit perfectly with it. There are sockets on the board for connecting external devices.

In domestic stores for 2017, its price is about 4-5 dollars. On modern models, its heart is Atmega328.

Image of the Arduino board and decoding of the functions of each pin, Arduino UNO pinout

The microcontroller on this board is a long chip in a DIP28 package, which means that it has 28 pins.

The next most popular board costs almost two times cheaper than the previous one - 2-3 dollars. This is a fee. The current boards are built on the same Atmega328, they are functionally similar to UNO, the differences are in size and USB matching solution, more on that later. Another difference is that plugs in the form of needles are provided for connecting devices to the board.

The number of pins (legs) of this board is the same, but you can see that the microcontroller is made in a more compact TQFP32 package, ADC6 and ADC7 are added to the package, the other two “extra” legs duplicate the power bus. Its dimensions are quite compact - approximately, as thumb your hand.

The third most popular board is, it does not have a USB port for connecting to a computer, I will tell you how the connection is made a little later.

This is the smallest board of all the ones reviewed, otherwise it is similar to the previous two, and its heart is still Atmega328. We will not consider other boards, since this is an article for beginners, and the comparison of boards is a topic for a separate article.

In the upper part, the USB-UART connection diagram, the “GRN” pin is wired to the reset circuit of the microcontroller, it can be called differently, you will find out why this is needed later.

If UNO is handy for breadboarding, then Nano and Pro Mini are good for final versions of your project because they take up little space.

How to connect Arduino to computer?

Arduino Uno and Nano are connected to the computer via USB. At the same time, there is no hardware support for the USB port; a level conversion circuit solution, usually called USB-to-Serial or USB-UART (rs-232), is used here. At the same time, a special Arduino bootloader is flashed into the microcontroller, which allows you to flash through these buses.

The Arduino Uno implements this connection on a microcontroller with USB support - ATmega16U2 (AT16U2). It turns out that an additional microcontroller on the board is needed to flash the main microcontroller.

In the Arduino Nano, this is implemented by the FT232R chip, or its CH340 counterpart. This is not a microcontroller - it is a level converter, this fact makes it easy to build an Arduino Nano from scratch with your own hands.

Usually the drivers are installed automatically when you connect the Arduino board. However, when I bought a Chinese copy of the Arduino Nano, the device was recognized, but it did not work, a round sticker with the release date was pasted on the converter, I don’t know if this was done on purpose, but when I peeled it off, I saw the CH340 marking.

Before that, I did not encounter this and thought that all USB-UART converters were assembled on the FT232, I had to download the drivers, they are very easy to find on the request "Arduino ch340 drivers". After a simple installation - everything worked!

The microcontroller can also be powered through the same USB port, i.e. if you connect it to a mobile phone adapter, your system will work.

What should I do if there is no USB on my board?

The Arduino Pro Mini board is smaller. This was achieved by removing the USB connector for firmware and the same USB-UART converter. Therefore, it must be purchased separately. The simplest converter on CH340 (cheapest), CPL2102 and FT232R, sells for $1.

When buying, pay attention to what voltage this adapter is designed for. Pro mini comes in 3.3 and 5 V versions, there is often a jumper on the converters to switch the supply voltage.

When flashing Pro Mini, just before starting it, you need to press RESET, but this is not necessary in converters with DTR, the connection diagram is in the figure below.

They are joined with special terminals "Mother-Mother" (female-female).

Actually, all connections can be made using such terminals (Dupont), they are both on both sides with sockets and with plugs, and on one side there is a socket, and on the other a plug.

How to write programs for Arduino?

To work with sketches (the name of the firmware in the language of arduino), there is a special integrated environment for the development of the Arduino IDE, you can download it for free from the official website or from any thematic resource, usually there are no problems with installation.

This is how the program interface looks like. You can write programs in a simplified C AVR language specially developed for Arduino, in fact it is a set of libraries called Wiring, as well as in pure C AVR. The use of which facilitates the code and speeds up its work.

At the top of the window there is a familiar menu where you can open a file, settings, select the board you are working with (Uno, Nano and many, many others) and also open projects with ready-made examples code. Below is a set of buttons for working with the firmware, you will see the assignment of the keys in the figure below.

In the lower part of the window there is an area for displaying information about the project, about the state of the code, firmware and the presence of errors.

Basics of programming in the Arduino IDE

At the beginning of the code, you need to declare variables and connect additional libraries, if any, this is done as follows:

#include biblioteka.h; // include the library called "Biblioteka.h"

#define variable 1234; // Declare a variable with value 1234

The Define command allows the compiler to choose the type of the variable itself, but you can set it manually, for example, an integer int, or a floating point float.

int led = 13; // created a variable "led" and assigned it the value "13"

The program can determine the state of the pin as 1 or 0. 1 is a logical unit, if pin 13 is 1, then the voltage on its physical leg will be equal to the microcontroller supply voltage (for arduino UNO and Nano - 5 V)

A digital signal is written using the digitalWrite(pin, value) command, for example:

digitalWrite(led, high); //record unit in pin 13 (we declared it above) log. Units.

As you could understand, the appeal to the ports goes according to the numbering on the board, the corresponding number. Here is an example similar to the previous code:

digitalWrite(13, high); // set pin 13 to one

An often requested time delay function is called with the delay() command, whose value is given in milliseconds, microseconds are reached with

delayMicroseconds() Delay(1000); //microcontroller will wait 1000ms (1 second)

Port settings for input and output are set in the void setup() function, with the command:

pinMode(NOMERPORTA, OUTPUT/INPUT); // arguments - variable name or port number, input or output to choose from

Understanding the first Blink program

As a kind of "Hello, world" for microcontrollers, there is a program for blinking an LED, let's look at its code:

At the beginning, with the pinMode command, we told the microcontroller to assign the port with the LED to the output. You have already noticed that the code does not declare the “LED_BUILTIN” variable, the fact is that in the Uno, Nano and other boards from the factory, a built-in LED is connected to pin 13 and it is soldered on the board. It can be used by you for indication in your projects or for the simplest check your blinker programs.

Next, we set the pin to which the LED is soldered to one (5 V), the next line makes the MK wait 1 second, and then sets the LED_BUILTIN pin to zero, waits a second and the program repeats in a circle, so when LED_BUILTIN is 1 - LED ( and any other load connected to the port) is enabled, when set to 0 it is disabled.

Read the value from the analog port and use the read data

The AVR Atmega328 microcontroller has a built-in 10-bit analog-to-digital converter. A 10-bit ADC allows you to read the voltage value from 0 to 5 volts, in steps of 1/1024 of the entire signal amplitude (5 V).

To make it clearer, consider the situation, let's say the voltage value at the analog input is 2.5 V, which means that the microcontroller will read the value from pin "512" if the voltage is 0 - "0", and if 5 V - (1023). 1023 - because the count starts from 0, i.e. 0, 1, 2, 3, etc. up to 1023 - 1024 values ​​in total.

Here's how it looks in code, using the standard "analogInput" sketch as an example.

int sensorPin = A0;

int ledPin = 13;

int sensorValue = 0;

pinMode(ledPin, OUTPUT);

sensorValue = analogRead(sensorPin);

digitalWrite(ledPin, HIGH);

delay(sensorValue);

digitalWrite(ledPin, LOW);

delay(sensorValue);

We declare variables:

    Ledpin - independently assign a pin with a built-in LED to the output and give an individual name;

    sensorPin - analog input, set according to the marking on the board: A0, A1, A2, etc.;

    sensorValue - a variable to store the read integer value and further work with it.

The code works like this: sensorValue saves the analog value read from sensorPin (analogRead command). - here the work with the analog signal ends, then everything is as in the previous example.

We write the unit to ledPin, the LED turns on and wait for the time equal to value sensorValue, i.e. 0 to 1023 milliseconds. We turn off the LED and wait again for this period of time, after which the code repeats.

Thus, by the position of the potentiometer, we set the blinking frequency of the LED.

map function for Arudino

Not all functions for actuators (I know of none) support "1023" as an argument, for example, the servo is limited by the angle of rotation, i.e. for half a turn (180 degrees) (half a turn) of the servo motor, the maximum argument of the function is "180"

Now about the syntax: map (the value we are translating, the minimum value of the input, the maximum value of the input, the minimum output, the maximum output value).

In code it looks like this:

(map(analogRead(pot), 0, 1023, 0, 180));

We read the value from the potentiometer (analogRead (pot)) from 0 to 1023, and at the output we get numbers from 0 to 180

Values ​​of the magnitude map:

In practice, we apply this to the code of the same servo, take a look at the code from the Arduino IDE, if you carefully read the previous sections, then it does not require explanation.

And a wiring diagram.

Arduino is a very handy tool for learning how to work with microcontrollers. And if you use pure C AVR, or as it is sometimes called "Pure C" - you will significantly reduce the weight of the code, and it will fit more in the microcontroller's memory, as a result you will get an excellent factory-made debug board with the ability to flash via USB.

I like arduino. It is a pity that many experienced microcontroller programmers scold her for no reason that she is too simplified. In principle, only the language is simplified, but no one forces you to use it, plus you can flash the microcontroller through the ICSP connector, and upload the code you want there, without any unnecessary bootloaders.

For those who want to play with electronics, as an advanced designer, it will be perfect, and for experienced programmers, as a board that does not require assembly, it will also be useful!

For more information about Arduino and the features of its use in various circuits, see e-book - .

At the latest I / O conference, Google showed its version of virtual reality glasses made of cardboard. In principle, schemes for such glasses have been circulating on the Internet for a long time (for example, FOV2GO). However, the scheme of the guys from Google turned out to be simpler than analogues, and they also added a chip with a magnet that works like an external analog button. In this post, I will share my experience of assembling smartphone-based virtual reality glasses: Google Cardboard from cardboard, OpenDive from plastic and glasses cut on a laser cutter from acrylic.

materials

  1. Cardboard. I used an unused laptop box. Another option is to order your favorite pizza or buy cardboard in a special store (you can search for microcorrugated cardboard E on request).
  2. Velcro. Buy at any sewing store. I took a sticky Velcro tape for 100r. Such a ribbon is enough pairs for 10 points.
  3. Magnets. In principle, this thing is optional if you do not plan to use the Google API. Google itself recommends taking 1 nickel and the second ferromagnet. In our Internet, there are a lot of such magnets in specialized stores, but I was too lazy to wait for an order. As a result, in the same store I took a set of magnets for fasteners, however, they did not work perfectly for me. Cost - 50r for 3 magnets.
  4. Lenses. In general, it is recommended to take lenses 5-7x, 25mm diameter, aspherical. The easiest way to get a magnifier with two lenses, like the Veber 1012A, is cheaper than buying 2 identical ones. I only had a 30x magnifier with two 15x lenses at hand (I took such a magnifier on the market for 600 rubles). Despite the exaggerated increase, it turned out well.
  5. Rubber band and carabiner. You will need it if you plan to use the Cardboard as glasses, and not hold them with your hand all the time. I bought in the same sewing store for another 100 rubles 2 meters of elastic and a pair of carbines.
  6. Foam rubber. So that the glasses do not crash into the face, it is worth pasting over the contact points with foam rubber. I used window tape. Another 100 rubles in the construction market.

The final price of materials: 400-1000r depending on the lenses.

Tools

  1. Stationery knife.
  2. Hot glue (gun). Better small.
  3. Stapler or thread with a needle.

Assembly

Here, in general, everything is trivial.
  1. We go to the Google Cardboard website and download the diagram for cutting. If you suddenly have a laser cutter on hand, you can cut on it. If not, then print on the printer and cut out along the contour.
  2. We attach Velcro. In addition to the two Velcro in the original, I added one on left side so that the structure does not move apart. And I also pasted two Velcro on the sides, on which we will later glue an elastic band for attaching to the head.
  3. We insert lenses, a magnet and fold the structure.
  4. We fasten 2 pieces of elastic band to Velcro. At one end, we insert a carabiner at a fixed distance (I fixed it with a stapler on an elastic band :)). On the other side, we take an elastic band with a margin and fasten the second part of the carabiner with the ability to adjust the length.
  5. Success!

However, after installing the application, I discovered that my button does not work in this form. To activate the press, I had to take the magnet in my hand and drive it right along the left side of the phone, however, even this way it works every other time. A sign that you are doing everything right - when touched, there should be a feeling magnetic field, which slightly pushes the magnet away from the phone.

Perhaps the reason is that I took too weak a magnet. Perhaps that my model (Galaxy Nexus) is not declared by Google as supported. Nevertheless, the demos are working, the button is pressed, hooray!

plastic model

If you want to spend as little as possible with the assembly and you have a 3D printer (or enough money to order a print), then this option is for you. :) I printed the model from the Thingverse website. In the same place, for the query “virtual reality”, there are several more similar options.

I ordered printing from the 3D Printing Laboratory, it turned out about 3000 rubles.

All materials from Cardboard are also relevant for these glasses, so the final price tag reaches almost 3500 rubles.

Building a plastic model

We insert the lenses, glue the foam rubber, we take ordinary office rubber bands to mount the phone. You can also seal the entire surface outside the lenses with foam rubber, then you will not be disturbed by the light from the smartphone. Larger lenses can also be inserted into such glasses.

Another option: insert lenses from a Soviet stereoscope. To do this, you will have to slightly modify the mount by replacing round holes with rectangular ones. The option with a stereoscope is quite convenient, but it has a minus - the working area is smaller, the image is cropped from above and below.

Acrylic (or plywood) model

Even before collecting virtual reality glasses became a trend, a wonderful scheme of glasses cut on a laser cutter appeared on the net. Without thinking twice, I decided to order their cutting in the same laboratory. They didn’t have plywood at that moment and they offered me to cut it out of black acrylic. The cost of cutting together with the material turned out to be about 800 rubles.

In addition to lenses, rubber bands and foam rubber, for assembly you will need about 20 screws with 3-4mm nuts (the author of the model suggests using 4mm, but I had difficulty getting them in and I took 3mm).

Oddly enough, the final version turned out to be even better than on a 3D printer. First, the glasses are lighter and more compact. Secondly, the material is smooth and more pleasant to the touch. Of the minuses - acrylic is a rather fragile material, and such glasses may not survive a fall.

Conclusion

Unfortunately, there is still not enough content for such glasses. You can try to play around with streaming, as described in a recent

Virtual reality on your smartphone! It is under this slogan that Google offers craftsmen to make a virtual reality helmet out of cardboard and a smartphone. Let's see what it is and how it works.

For the first time this helmet was presented at the conference Google I/O 2014. View the presentation of the helmet at Google I/O 2014 you can, the helmet's official page is g.co/cardboard.

Anyone can make a helmet, provided that you managed to find all the components: cardboard and lenses for assembling the helmet itself, Velcro so that the design is collapsible, magnets to control virtual reality, an elastic band for fixing a smartphone and, an optional element , NFC tag so that the smartphone knows that it has been put into a virtual reality helmet.

Some of the helmet components will not be easy to find. It is noteworthy that after the publication of templates for self-assembly of the helmet on the Internet, a few hours later, a set called Google Cardboard VR Toolkit appeared in one of the American online stores, which includes pre-cut cardboard and all other parts. Too bad no one has figured this out before.

When all the components for the helmet are ready, you simply assemble it by inserting your smartphone inside, look inside the helmet and enjoy virtual reality.

So, what do you need to create a Google Cardboard virtual reality helmet?

The picture below shows all the necessary parts for making a helmet and a description with original links, mainly to the Amazon store.

1. Cardboard

It must be corrugated cardboard (it is recommended to use class E micro-corrugated cardboard - with the number of corrugations 295 +/- 13 per 1 meter and a thickness of 1.6 mm). You can read more about corrugation categories on Wikipedia (English version). Such cardboard can be found in art stores. For a good result, look for a strong, thin cardboard. The minimum sheet size is 22x56 cm, 1.5 mm thick. The guys from Google offer to buy cardboard and.

2. Lenses

This component is the hardest to find. The helmet requires lenses with a focal length of 45mm. Biconvex lenses work better because they prevent distortion at the edges. The developers of the helmet from Google used a set of lenses Durovis OpenDive Lens Kit available (USA) and (Europe).

3. Magnets

You need a neodymium magnet in the form of a ring, like or and one ceramic disc magnet, like or. Approximate size 19mm in diameter and 3mm thick.

4. Velcro

You will also need a ruler, glue, scissors, a paper cutter, or access to a laser cutter.

For cutting cardboard, the masters from Google offer two templates: one for cutting on a laser cutter (file laser_cut.eps in the archive) and the second for cutting with a paper knife (file print_yourself.pdf in the archive). In the second option, you need to print the template on paper, stick it on cardboard, aligning the numbers in the light and dark circles (the light one is glued on top of the dark one) and cut it out. Templates can be downloaded from the Google site or here.

Google Cardboard Templates Version:1.0

Templates for making a virtual reality helmet Google Cardboard. The laser_cut.eps file for cutting cardboard with a laser cutter and the print_yourself.pdf file for printing on a printer.

08/06/2014 611.02 KB 3557

After everything is ready, the helmet is assembled as shown on g.co/cardboard , your smartphone is inserted inside.

Beforehand, the Cardboard demo program must be installed on the smartphone, inside which you can choose one of the following demos:

- Earth where you can fly Google Earth;

- Guide where you can visit Versailles with a local guide;

- YouTube where you watch the video on a massive screen;

- Exhibition, where you can view cultural artifacts from all sides;

- Photosphere, where you can look around while inside the photospheres (I couldn't take a screenshot here because this demo didn't run for me);

- Vue street where you ride around Paris on a summer day;

- Windy day, where you watch a cartoon that takes place around you.

Unfortunately, that's all there is for now. But it is worth hoping that soon there will be more programs for the helmet Google Cardboard. True, you can try games for Durovis Dive, but for this you will need to attach a helmet to your head and connect some kind of gamepad to your smartphone.

Which smartphones are suitable for the Google Cardboard virtual reality helmet?

Now let's figure out which phone is suitable for a helmet. It must be a smartphone running Android version 4.1 or higher. Preferably with NFC support. Below is a list of phones that are compatible with the helmet.

Fully compatible smartphones:

Google Nexus 4 and 5;
- Motorola Moto X;
- Samsung Galaxy S4 and S5;
- Samsung Galaxy Nexus.

Partially compatible smartphones:

HTC One (magnet control does not work);
- Motorola Moto G (magnet control does not work);
- Samsung Galaxy S3 (magnet control not working, head tracking issues, rendering issues).

Development of your programs

If you are a programmer, then you can independently develop programs for a helmet from Google. To do this, Google offers an experimental VR Toolkit. Why experimental? Because Google is not going to support the VR Toolkit at the same level and with the same quality as android kernel SDKs and Libraries. This toolkit can change or break at any time, because work on it continues.

However, for those interested, there are tutorials and documentation for the VR Toolkit. In addition, there is the possibility of feedback from the developers.

Conclusion

Summing up everything written, it is worth thanking a group of enthusiasts from the company Google, who created such an affordable virtual reality helmet and shared her idea with everyone absolutely free. Thanks to them, we can use our smartphone and special software to enjoy virtual world. It should be noted that this approach opens up far-reaching prospects. After all, it is enough to connect game controllers to a smartphone and you can not only contemplate virtual reality, but also participate in it. In addition, all interested developers can create their own software for helmet Google Cardboard, because for this Google provides tools VR Toolkit. We look forward to the development of the project.

So, you have downloaded and tried the methods described above, and have chosen the most suitable one for you personally for quick work. Let's agree that you have a smartphone or tablet with a 6-7 "diagonal, two pairs of lenses (you can try with one pair, but my scheme is still of two, there may be discrepancies, use it at your discretion), installed programs and purchased materials with tools.The first step is to make the first frame for the first pair of lenses.I made it out of foam, and in theory, it would be nice to have a centrifuge on hand, even for concrete, which sockets are cut into, but in general, any one, such as a sliding cutter for wood or even compasses. I didn’t have any of this at hand, so I had to cut out round holes with a Walter White clerical knife, which, with a lens diameter smaller than mine, would be completely untidy. So, the first blank is a frame for two lenses, as on picture below.

In order to make it, you will need to put the smartphone on the table with the screen up, bend over it, and pick up the lenses, bring them to your eyes, trying to find the focal length. You need to strive for the minimum distance between the face and the screen, so that it fits into the "lens" and the 3D effect is observed. If this effect is not observed, shifted or distorted, do not despair, for a start it will be enough to understand the focal length, or rather, the amount by which you need to remove the lenses from the smartphone. And what about the distance between the lenses in this pair? It's simple - find the value that is in the middle between the distance between the pupils and the distance between the centers of the halves of the frame (half the long side of the screen). Let's say we have 65 mm between the eyes, and the screen is 135 mm, half of it is 67.5 mm, so you need to place the centers of the lenses by about 66 mm, this is enough for a first approximation.

Now, after we have marked the required distances, we cut out the holes for the lenses. Roughly evaluating the density of the foam, I thought that it was enough to firmly install the lens, if you make a hole for it with a diameter slightly smaller than the lens itself, I reduced the cut circle by 2mm in diameter, which perfectly coincided with the assumption. Your parameters may be different, but the essence is the same - make the holes a little smaller. You need to drown the lens shallowly, I drowned it by 2 mm, below it will be clear why, and probably there is no need to mention that it would be nice to place the lenses in the same plane, that is, they should both be drowned evenly.

The first stage is over, now we have the screen-to-lens distance mock-up, and we can move on. Remember what I said about two pairs of lenses? They may not be that important in an optical sense (in fact, they are important), but they are invaluable for further tuning. Let's say you set up the first pair of lenses as described above, turned on a 3D image (game, movie, your choice) on your smartphone, and are trying to find three-dimensionality. One pair of lenses didn’t let me do it like that with a swoop. But when I brought the second pair to my eyes, and after playing with the distances I found the right position, a three-dimensional image immediately appeared on the screen. To achieve this, you need to simultaneously move the lenses relative to the screen, in a plane parallel to this screen and the first pair of lenses, up and down and to the sides. Find a detail in the image that you can trace the parallax effect, focus on it and try to connect the images in each eye so that they match. With some skill, this is done very quickly, but, unfortunately, I cannot suggest a way to speed up this process. I was helped by such a test stand, here the lower pair of lenses is already in foam and set to the screen, and the upper pair, framed in polyethylene, moreover, each lens is separate, I moved before my eyes, in search of "stereo", and under the whole structure - screen at the right height:

Sooner or later you will get fresh, juicy, fashionable youth 3D, but due to the introduction of the second optical pair into the circuit, the first focus setting will go a little wrong. There is no need to be scared, all that is required is to reconfigure the focus again. To do this, you first need to make a frame for the second pair of lenses that you just set up. My advice is to first copy your first frame, adjusting for the changed distance between the lenses, and then visually estimate the distance between the first and second pair of lenses after you have set up the 3D. It will be enough by eye, and this distance should be compared with the thickness of the material - well, literally, whether the distance between the pairs is greater, or less than the thickness of the foam. If it’s smaller, everything is simple, you will need to install the lenses in the second frame a little deeper, by the required amount, but if this distance is greater than the thickness of the foam, you can simply turn the first frame with the more recessed side towards you, so you don’t have to fence a garden of spacers between two frames. In my case, this is what happened, I turned the first frame upside down, folded these frames with the more recessed sides to each other, and slightly recessed the lenses inward on each side.

So, we got an optical device that allows us to view 3D on a smartphone screen. But, of course, we remember the focus, which was changed first by introducing the second pair of lenses, and then also by flipping the first pair with the other side, so the focus needs to be adjusted again. When you get the focus through some simple movements, you will need to notice this distance, and make foam supports so high that when you set your first frame above the screen, the image in the lenses will be in focus.

Here it is necessary to say the following, in my opinion an important property, I'm not exactly sure of its nature, but I observed it repeatedly in experimental subjects. Many actions in life require repeated approach, the use of approximation and iteration. This, apparently, is not clear to everyone, but almost always this method works, and gives a better result, if you follow a simple algorithm - try and improve. So in the case of this helmet - the same story, perhaps the first time you will not be able to do two correct pairs frames, for example, I redid one pair three times, and the second pair twice, and I already know that I will redo more, because there are ideas for improvements. But with each reworking, the quality increased and the picture got better, so if you did a couple of approaches, but you “didn’t succeed” - don’t despair, take a break and start again, keep going. The result is worth it.

A small hint - if the resulting eyepiece (as I will call a block of two pairs of lenses and their frames assembled together) has a good stereo image, but the focal length has grown significantly relative to the first approximations, disassemble the eyepiece in half into two frames and play with the distances, perhaps there is a more optimal one - it may be necessary to turn one of the eyepieces upside down, or maybe space them apart. Remember what needs to be done maximum number useful pixels (otherwise it will be uninformative) and the minimum distance from the screen (otherwise it will be cumbersome). If you have a wonderful, wonderful focal length, and for some reason the stereo base did not work out - carefully cut the foam plastic in the middle between the lenses with a knife and look - you need to move them apart, or bring them together, and there already act according to the situation. Roughly speaking, you will have two eyepieces, one for each eye, adjust them, and when it works, glue them together with double-sided tape.

At this stage, the story with lenses ends, and now it doesn’t matter if you did optical design according to my version, or based on my own considerations, then it will not be so important, the rest of the story is suitable for any option.

Breadboard helmet assembly

Having found the total focal length from the eyepiece to the screen, we have to make a box on its base, and here there are even more options than at the lens stage. But, now you have in your hands the “heart”, or rather the “eyes” of the device, and its most complex detail, which means that it will be easier further. Let's say you managed to do all of the above correctly, and you can confidently observe a 3D image by placing eyepieces on your eyes and leaning over your smartphone. After playing around with this demo layout, you will probably notice some features of the lens placement and eyepiece comfort that you personally will find the most in need of optimization. Do not limit yourself too much, optimize and improve something for yourself, for your eyesight, the shape of the nose and skull, and so on.

For example, after making the eyepiece, I put it on my face and realized that I was kissing a foam brick. Convenience is exactly zero, and this helmet is still worn on the head for some time! Therefore, in the manufacture of the box, I tried to increase the comfort of wearing at the same time as a reliable and convenient location of the smartphone inside. I had to get rid of the inner side of the foam, and replace it with polyethylene foam, it is yellow in the picture. It is more flexible and allows you to twist the shape over a wide range, so the inner surface of the helmet is made of it. It should fit snugly to the face in the area of ​​​​the eyes and around the nose, otherwise you will constantly observe fogging of the lenses from breathing, immediately consider this point. There was an idea to make this part from a construction or swimming mask, but they were not at hand, so I did it myself, however, the option with a ready-made mask may seem preferable to you, and I advise it with pleasure. I myself also decided to make the sides for the helmet adjacent to the head.

Another point to keep in mind is the weight of the smartphone and the lever on which it will work, exercising pressure on the support. My xperia ultra weighs 212 grams, and the required distance from the face is 85 mm, plus own weight boxes - all this together, I would say, makes the helmet comfortable with reservations. He has one strap behind him, this will be seen in the picture at the end of the section, this strap is made of a rubber band, 40mm wide, which pulls him quite tightly to the back of the head, but whether the screen is heavier, or the lever is larger (read the focal length is longer) - wearing a helmet was would be much more difficult. So for owners of devices with a larger diagonal or weight, I advise you to immediately think over the attachment scheme on the head with a second, transverse strap from the bridge of the nose to the back of the head, and it’s more convenient and safer.

Also, at this stage, you will need to think about another nuance - sound output. I have several pairs of headphones, both closed and open types, there are earplugs and so on, but on reflection, I did not build a helmet around large and comfortable Sony MDR with large ear cushions, but chose simple earplugs. It may be critical for you to make a helmet with a cool sound, in which case you need to immediately imagine exactly how you will articulate the headphones, their arc and the helmet with its mount. I had such a temptation, which quickly evaporated at the stage of prototyping, but I will definitely return to it in the next, improved version of the helmet, if I decide to do it. In any case, you will need a hole in the helmet shell that matches the position of the audio output of your smartphone.

So, I have such a device on my table - an eyepiece with a head slightly fitted to the shape inner surface. It already sits comfortably on the face, fits in width, and for its manufacture I only needed such a template, cut from a piece of foam, curved in the shape of the head, it will fit with some edits to both the top and bottom of the helmet:

Earlier, we found out the focal length of the eyepiece in several approaches. Now you need to position the smartphone screen at the right distance. Remember that the screen must be positioned so that its horizontal axis of symmetry coincides in height with an imaginary line between the pupils, but the fact that it must be positioned symmetrically relative to the face is already clear to you. In my case, the distance between the screen and the side of the eyepiece closest to it was 43 mm, so I made the top and bottom surface foam, as well as two side inserts. The result was a foam box, which, having put it on the screen, could already be used for its intended purpose, and this is where the template shown above was needed.

At this stage, there were several minor adjustments to the focus and location of the smartphone, after that - an accurate measurement of the results obtained and cutting out the outer, cardboard case. It serves two purposes - protecting the rather delicate foam from mechanical damage, I pushed it quite easily with my fingers at the stage of initial experiments, I had to follow this, and the second and main goal is that the cardboard will hold the screen in the right position, pressing it to the foam.

As a result, we got such a box, with a lid on the upper front part, under which the smartphone is hidden.

Having tried on the helmet to the head, and having seen enough of all kinds of 3D, I corrected minor inconveniences inside the helmet, and made a mount - an elastic band to the head. It is simply sewn together with a ring, and glued with double-sided tape to the cardboard, plus it is seized on top with a silver oracal, which was used to replace the tape. The result was something like this:

By the way, this image shows another technical hole, which is used to connect the USB cable, which we will need a little later. And this is what the helmet looks like on the head of the experimental person who donated lenses for this helmet:

So what happened in the end.
Dimensions: 184x190x124 mm
Curb weight: 380 grams
USB input/output
3.5mm headphone jack
Useful screen area 142x75 mm
Resolution 1920x1020 pixels

It's time to move on to the program part of our journey.

Available features of the VR helmet

Viewing 3D video

The very first thing that comes to mind is watching movies in 3D. This is a very simple and understandable entry point into virtual reality, although, more strictly speaking, it is rather a threshold not far from it, the previous step. But, in order not to belittle the merits of this type of entertainment, I inform you that watching 3D movies in the resulting helmet is a very interesting and fun activity. I've only seen two films, so I'm not tired yet, but the feeling is very good: imagine that you are a meter and a half from the wall that you are looking straight at. Without turning your head, try to look around the area with your eyes - this will be the screen available to you. Yes, there is a small resolution - each eye gets only 960x540 pixels from a fullHD movie, but nevertheless, this leaves a quite tangible impression.

To watch movies in this form, you will need a free MX Player with a codec installed for your processor, I have it ARMv7 Neon, well, actually, a video file. It is easy to find them on all kinds of torrent trackers, the technology is called Side-By-Side or SBS for short, that's why keywords boldly seek. The player has the ability to adjust the aspect ratio of the video being played, which is extremely useful for SBS files that otherwise stretch vertically to fill the screen. In my case, I needed to go to the settings - "screen" - "aspect" and selecting "manually" set the aspect ratio to 18 to 4, otherwise you will get vertically stretched images. I tried to look for other players with similar functionality, but I didn’t find it, if you know, add it to the knowledge box.

In general, I have nothing more to add to this point - an ordinary 3D cinema is in front of your eyes, everything is very similar to going to the cinema, or watching on a 3D TV with polarized glasses, for example, but at the same time there are differences, in general, if you like 3D, you should try a VR helmet.

Android apps for Durovis Dive and similar systems

The whole story actually started from this point. In principle, the following three links show almost all possible programs for android at the moment:
www.divegames.com/games.html
www.refugio3d.net/downloads
play.google.com/store/apps/details?id=com.google.samples.apps.cardboarddemo

What do we need to enjoy virtual reality comfortably? Obviously - a joystick, or any other controller, for example - a wireless keyboard. In my case with a Sony smartphone, the natural and logical choice is the native and natively supported PS3 controller, but since I didn’t have this at hand, but turned out to be the good old Genius MaxFire G-12U, I added a microUSB to USB adapter to it , hooked it up to a smartphone, and was not even surprised that it immediately began working both in the device interface and in individual programs without any questions.

You will also need headphones, because immersion in virtual reality without sound will be incomplete. I have these ordinary plugs, and you figure out for yourself how more convenient.

What should and should not be expected from the applications presented in this section? The fact is that all applications in general that are written for android on the topic of virtual reality are very scarce, to put it mildly. If you run them without a helmet and try, well, to see what kind of virtuality it is, then there is a chance that you will not want to buy or make a helmet. They are frankly very raw and miserable, and do not represent anything super-interesting.

But. When you put your head in a helmet, everything becomes completely different, and personally, I, who am skeptical of everything, would never believe it, nevertheless it is true.

The main thing to consider is head tracking. Even with its poor implementation, or braking, this is a completely new and unexplored field for sensations, believe me, before the appearance of the helmet, you have not felt anything like this for a very long time, since adventures with rock climbers in the mountains, walking along the bottom of the oceans, spending the night in the forest and other mass murders that we all love so much. The helmet provides a completely unrealistic feeling of reality, I'm sorry for the pun, and any, even the most miserable graphics will seem like candy inside it, in general, I must say - if you like to play games, or feel new - the helmet is the device for you.

From my own experience: imagine you are in 1998 and, say, a Polish production studio computer games made a demo in which you landed on the moon, exited the module, saw the canonical American flag, which looked like a piece of cardboard nailed to a stick, stuck into the ground, and above the flag in the sky there was an inscription in extremely poor font “collect tools, 3 pieces left”. At the same time, graphics from very, extremely simple elements, where the monotonously accumulated starry sky and square-repeating ground under your feet occupy 98% of the usable screen area, and somewhere you can see a couple of pixels of those “tools” that you have to find. Actually no. You can already see them, you just need to walk to them for 10 minutes. Just go. By the moon. Soundless. By repeating sprites. No action at all.

Tell me, after how many seconds would you remove this game from a computer or even a smartphone? That's it. And in a helmet, this miracle allows you to experience (!) devastation and loneliness the only person on the planet. No kidding. I found myself after 15 minutes of the game desperately afraid that I was alone on the moon, under the cap of the stars, and I didn’t know what to do.

More or less the same story with all other games and applications. They are miserable, they are creepy as hell, but at the same time inside the helmet - they send you back 15-20 years ago, and some before, to the very games that you played, and not for which you spent time. So far, the only question I have for the developers is why is there not a single game with a full-fledged story for this alignment? A single game would have saved the state of affairs simply incredibly, because now, showing people virtual reality on android, there’s nothing special to show, everything with the reservations “this is a demo, you can’t shoot here”, yes, “everything, the whole game is completed, yes, in 4 minutes." By the way, almost all these applications are written in Unity, all the more surprising is their low level, or I don’t know how to search.

But you still don’t listen to me, try it yourself, and tell your version, I’m interested. And season with references, I will be immensely. For example, I even installed a demo with the frantic title of Toilet Simulator. Because.

small easter egg

Actually there is a link on the durovis-dive website to quake-2, a demo version of the game that is installed on android and has the ability to display mode SBS, at the bottom of this page - detailed instructions how to do it. The only thing that did not work in automatic mode was that a separate archive was not unpacked, so it will be there in the settings running game links to mirrors, you need to retype one of them into the browser on the desktop, download the self-extracting archive, pull out the pak0.pak file from there and put it in the directory of the game installed on the phone, I have it called baseq2.

After that, the same Q2 started up for me without any problems - it works very quickly, and everything is perfectly visible. It became scary literally after 30 seconds, just a chill down the spine, but I won’t describe it further, try it yourself. Unfortunately, it was not possible to take a screenshot, and the joystick works so far only in the "wander" mode, it does not know how to shoot, you have to pick the settings.

Thus, all this sluggishness of android developers (attention android developers!) led me to think - well, there are no games for android - let's try a desktop computer, remembering the main advantages virtual helmet- a huge screen with immersion in the image and tracking of the position of the head, and we will try not to lose them.

Connecting to a computer as a VR device

To be honest, the idea of ​​such a connection appeared immediately, but there was not a single idea how, what and in what order to do. Therefore, while I was drawing, cutting and gluing the parts, I thought along the way where to get information on how to display an image from a computer video card, while simultaneously transmitting head tracking, that is, gyroscope and accelerometer data to a computer. And all this, preferably, with a minimum delay.

And you know, the solution was found. It consists of three stages, each of which we will consider separately, moreover, first I will describe the options that work, and then I will go over those that turned out to be inoperative in my case, but may be useful to you.

We create a 3D output on a computer.

It turned out to be relatively simple, but not knowing right away, you can get lost. So, an ideal computer that allows you to play full-fledged 3D games in stereo output format has a video card based on conventional NVidia or ATI chips, the more modern the better, and, what is very important, the ability to set arbitrary resolution in the drivers. If you have a laptop (my case) or a video card whose drivers do not support arbitrary resolutions, the image in the helmet will be stretched vertically, and Possible Solution, unsafe and rather dreary - to delve into the registry and prescribe permissions there. Your suggestions, again, are warmly welcome!

In general, you will need to install a version of your graphics card drivers that supports arbitrary resolutions. If your smartphone and your monitor have 1920x1080 pixels on the screen, then everything is very simple - in the video card settings you need to create an arbitrary resolution of 1920x540, and then apply it to the monitor. You will see how the working area of ​​the screen has become smaller in height and is located in the middle of the screen. If the picture on your screen is something like this, then you did everything right:

So, everything was tested on a regular, but powerful desktop computer with an NVidia video card and latest version drivers. It is important that the conditions are met - when you start the game in stereo mode, the image on each half of the frame is not stretched.

The second thing you need is to download a 3D driver - which has a full trial version for a period of two weeks, and allows you to output 3D images to peripheral devices in arbitrary configurations, and side-by-side, and top-bottom, and anaglyph, in in general, whatever you want.

Install in the usual way, run the TriDef 3D Display Setup utility and select the Side-by-side option, now when you start games from under this driver, they will be in stereo mode “half a frame to each eye”. If you have games installed, then you can open the TriDef 3D Ignition utility and search for installed games, a shortcut to your game will appear in the window - voila, you can use it.

I didn’t have games installed, so I installed Steam and bought Portal 2 for 99 rubles on sale, but this is advertising. And here comes the moment you need to be aware of - a driver that serves stereo output can output stereo for any game that has the ability to run in fullscreen, but cannot create output for a window whose area is smaller than the size of the desktop. Remember this moment, below it will become critical, like a red rag from a bull.

In general, if the drivers are installed and configured, the game is purchased and launched, and it all looks like this on the screen:

You can move on to the next step.

Transferring an image from a computer to a smartphone screen

There are several ways, and judging by the numerous icons in the market, there are not so few programs that allow you to transfer what you need. I was "lucky" before I found a convenient and workable application, I tried several other, depressing and frustrating google play crafts, and I'm sorry that any slag is allowed there. I spent more time searching for and configuring applications than making a device. Moreover, one of the applications had to be bought, and everything would be fine with him if everything was not bad. But first things first: you will definitely need a local wi-fi connection between your computer and smartphone.

You will also need a good and fast "remote desktop" that does not log out of your desktop account when you log in via remote. The free Splashtop turned out to be such a program, and the half-paid iDisplay was also found.

The one that is paid - everything is fine with it, only it did not allow the screen cut off from above and below to be placed exactly in the middle of the display, so I had to abandon it, but in general it works well, there was even a review on Habré, where I got it from. But Splashtop worked as it should, so put it on.

All programs of this type work in approximately the same way - you need to download and install the host version for your desktop, and the receiver version for your smartphone. I think there won’t be any problems with this, so I won’t describe these processes, there it’s a five-minute tambourine - downloaded, installed, registered, configured, connected. The only thing I will mention is that you will need to go into the settings and indicate that your wireless connection should be used locally, for which you will need to explicitly specify the IP of your computer in the android version, you can find this address with the ipconfig utility on the command line. Actually, these are all the settings, everything should already work, here, for example, is a screenshot from the smartphone of the current moment:

If you run the game from under the 3D Ignition utility, it will appear on the screen of your smartphone at the same time as it happens on the monitor. Or not. Because here lies the hottest pitfall of our history, and yes, you will laugh as much as I laughed. Watch out for sleight of hand: the driver that returns the stereo image from the game requires a full screen (if you select the “in window” mode, the stereo will not work, the game will start normally), and the desktop access program from your smartphone screams “I can’t run fullscreen, sorry, yes, absolutely”, and can only show the desktop and windows on it.

Therefore, the most delicate moment. Most likely, you will be able to play any games that run in borderless window mode. I don’t know for sure why and where such a mode comes from in games, for this reason, or for some other reason - but it turned out to be a salvation: on the one hand, it deceives the desktop, and tells it that it launched the game in full screen, and on the other hand, it formally gives the smartphone just a window, though without frames and expanded to full screen. The same case when the wolves are full and the sheep are safe.

So I was lucky, the portal-2 that I downloaded from Steam turned out to be exactly the game that supports all three launch modes. So it's up to you to check at your own discretion which games will start this way and which won't.

Already now you can start the game and drive it in a helmet. But, as they say, the picture would be incomplete if there were no head tracking.

Enable head tracking

You have read up to this point, with which I congratulate you. I do not want to deceive you, this point is the most difficult and little studied, nevertheless, do not despair. So.

The first thought was to "disassemble" the Oculus Rift SDK or Durovis Dive SDK, since the source code is in the public domain. Perhaps this should have been done, but I'm not a programmer, and I don't understand anything about it. Therefore, my eyes were turned to ready-made solutions that transmit the position of the smartphone in space to the desktop. As it turned out, there is just a huge number of programs that supposedly can do this. Judging by the descriptions - so do almost everything. And again, I sorted through dozens of programs with sweet promises, but in reality it was even more terrible, disgusting and miserable than sorting through programs for displaying images on a smartphone screen, what’s there, even more miserable than those demo games for durovis dive, which I described above. If at this stage you catch a wave of frustration, then that’s it, “goodbye helmet”. Nevertheless, the necessary (with reservations) program was found. But first, a fly in the ointment - Monect, UControl, Ultimate Mouse, Ultimate Gamepad, Sensor Mouse - all this did not fit. Especially the first one on this list - the description says that Monect Portable provides a mode

FPS mode - Using gyroscope to aim the target just like a real gun in your hand, perfect support COD serial!

As a result, I bought it for a fabulous 60 rubles, but this turned out to be untrue. There is simply no such mode in the application! I was angry.

But, let's move on to successful options. You will again need to download the host and client version of the program called DroidPad. It was she who, when setting up one of the modes, made it possible to do the necessary, and transmit the parameters of the sensors in real time via wireless access. The algorithm is as follows - install the program on the desktop and on the smartphone, run it on the smartphone, select the "Mouse - Mouse using device tilting" mode, and then launch its desktop version.

If everything is done in this order, the connection should work, and voila - you control the mouse cursor on the computer screen! So far, it's messy and messy, but wait, now we'll set it up. In my case, in the android version of the application, the screenshot of the settings window looks like this:

You can set the name of the device, but it's better not to touch the port - it works by default, but it's better not to touch the working one yet. In the desktop version, everything is a little more complicated, I have the following settings, but they still have to be optimized, so use only as a guide, no more:

Here are the settings for the X and Y axes on the computer screen, and the strength of the sensor from the phone. How exactly it all works for me is still a black box, because the application developers do not provide any documentation, therefore, I provide the information “as is”. I completely forgot to add that I have a program installed on my smartphone that controls the launch of applications in landscape or portrait orientation, and all applications that were tested for this venture = were tested in album mode. The application is called Rotation Manager, and the screen auto-orientation is globally disabled in the smartphone.

Having configured your applications accordingly, you will need to connect your smartphone to the computer according to the algorithm described earlier (for me, any discrepancy with the specified order leads to the application shutting down), and, holding the smartphone in your hand as it will be located inside the helmet, try to configure the settings - Alternately adjusting the desktop sliders and clicking on the "Calibrate" button in the android version window. I will say right away - after a rather short attempt, I managed to adjust the angles and turns relatively decently, but then, adjusting more precisely, I knocked down those settings without thinking to photograph them, and those that are now in the screenshot are already only an approximation to the previous ones that were still feel better. Another point - all these sliders are very sensitive, and holding a smartphone in one position so that it does not arbitrarily remove the cursor is inconvenient, so you constantly have to disconnect and configure, then connect and check. After a while, the information in the article on this subject will be updated, but even with the current settings - inside the game world it looks very impressive.

So what are the feelings? At the moment, for lack of time, I have installed the Portal 2 games and the free HAWKEN robot shooter offered by Steam. As for the portal, you are quickly enslaved by the surrounding atmosphere and sound, and the immersion is so strong that there is nothing to compare with, except that sitting in front of the computer 10 years ago at four in the morning, everything is perceived about as sharply. But if there it was fatigue and darkness around, then in a helmet it is a slightly different, brighter effect of the same presence. But the second game, where you sit in the canonical "huge humanoid robot" - surprised. In the presence of a helmet on the head, the reality projected as if on the surface of the helmet in the game becomes closer, warmer and more lamp-like, and very quickly. Surprisingly fast.

You should not assume that the sensations caused by a VR helmet will be the same for everyone, but for everyone " guinea pigs"I can confidently say that absolutely everyone appreciated this device, the reviews are extremely positive and interested. Therefore, I boldly recommend it to you too, spend one day making this helmet, and evaluate it yourself. My personal goal was just that - to quickly satisfy curiosity, without special spending money and time waiting, I spent about three days of searching and setting up everything about everything, and now I pass the baton to you, already in a compressed form.

Personally, I decided that I would most likely make a second version of this helmet, with minor modifications and improvements, and subsequently purchase a fresh consumer version of the Oculus Rift. It turned out to be very interesting and informative.

I really look forward to new applications for android, and partly this article was written with the hope that one of the developers will become interested and give out some kind of interest for the general public to see. And, a small wish - if you know any programs and solutions that I did not mention, but which would increase the quality of the article and improve the performance of the device - write about them in the comments, and I will definitely add valuable information to the article, for future generations.

TL;DR: the article tells about a fast and high-quality way to make a virtual reality helmet based on an HD smartphone or tablet with an android on board, a complete step-by-step instruction and general principles this process, and also describes the main available ways applications of the received helmet: watching movies in 3D format, games and applications for android, and connecting the helmet to a computer to immerse yourself in the reality of desktop 3D games.

  • sbs
  • Add tags August 7, 2014 at 07:07 pm

    Virtual reality glasses made of cardboard, acrylic and plastic

    • Mail.ru Group Blog

    At the latest I / O conference, Google showed its version of virtual reality glasses made of cardboard. In principle, schemes for such glasses have been circulating on the Internet for a long time (for example, FOV2GO). However, the scheme of the guys from Google turned out to be simpler than analogues, and they also added a chip with a magnet that works like an external analog button. In this post, I will share my experience of assembling smartphone-based virtual reality glasses: Google Cardboard made of cardboard, OpenDive made of plastic, and laser-cut acrylic glasses.

    materials

    1. Cardboard. I used an unused laptop box. Another option is to order your favorite pizza or buy cardboard in a special store (you can search for microcorrugated cardboard E on request).
    2. Velcro. Buy at any sewing store. I took a sticky Velcro tape for 100r. Such a ribbon is enough pairs for 10 points.
    3. Magnets. In principle, this thing is optional if you do not plan to use the Google API. Google itself recommends taking 1 nickel and the second ferromagnet. In our Internet, there are a lot of such magnets in specialized stores, but I was too lazy to wait for an order. As a result, in the same store I took a set of magnets for fasteners, however, they did not work perfectly for me. Cost - 50r for 3 magnets.
    4. Lenses. In general, it is recommended to take lenses 5-7x, 25mm diameter, aspherical. The easiest way to get a magnifier with two lenses, like the Veber 1012A, is cheaper than buying 2 identical ones. I only had a 30x magnifier with two 15x lenses at hand (I took such a magnifier on the market for 600 rubles). Despite the exaggerated increase, it turned out well.
    5. Rubber band and carabiner. You will need it if you plan to use the Cardboard as glasses, and not hold them with your hand all the time. I bought in the same sewing store for another 100 rubles 2 meters of elastic and a pair of carbines.
    6. Foam rubber. So that the glasses do not crash into the face, it is worth pasting over the contact points with foam rubber. I used window tape. Another 100 rubles in the construction market.

    The final price of materials: 400-1000r depending on the lenses.

    Tools

    1. Stationery knife.
    2. Hot glue (gun). Better small.
    3. Stapler or thread with a needle.

    Assembly

    Here, in general, everything is trivial.
    1. We go to the Google Cardboard website and download the diagram for cutting. If you suddenly have a laser cutter on hand, you can cut on it. If not, then print on the printer and cut out along the contour.
    2. We attach Velcro. In addition to the two Velcro in the original, I added one on the left side so that the structure does not move apart. And I also pasted two Velcro on the sides, on which we will later glue an elastic band for attaching to the head.
    3. We insert lenses, a magnet and fold the structure.
    4. We fasten 2 pieces of elastic band to Velcro. At one end, we insert a carabiner at a fixed distance (I fixed it with a stapler on an elastic band :)). On the other side, we take an elastic band with a margin and fasten the second part of the carabiner with the ability to adjust the length.
    5. Success!

    However, after installing the application, I discovered that my button does not work in this form. To activate the press, I had to take the magnet in my hand and drive it right along the left side of the phone, however, even this way it works every other time. A sign that you are doing everything right is that when you touch it, there should be a sensation of a magnetic field, which slightly repels the magnet from the phone.

    Perhaps the reason is that I took too weak a magnet. Perhaps that my model (Galaxy Nexus) is not declared by Google as supported. Nevertheless, the demos are working, the button is pressed, hooray!

    plastic model

    If you want to spend as little as possible with the assembly and you have a 3D printer (or enough money to order a print), then this option is for you. :) I printed the model from the Thingverse website. In the same place, for the query “virtual reality”, there are several more similar options.

    I ordered printing from the 3D Printing Laboratory, it turned out about 3000 rubles.

    All materials from Cardboard are also relevant for these glasses, so the final price tag reaches almost 3500 rubles.

    Building a plastic model

    We insert the lenses, glue the foam rubber, we take ordinary office rubber bands to mount the phone. You can also seal the entire surface outside the lenses with foam rubber, then you will not be disturbed by the light from the smartphone. Larger lenses can also be inserted into such glasses.

    Another option: insert lenses from a Soviet stereoscope. To do this, you will have to slightly modify the mount by replacing round holes with rectangular ones. The option with a stereoscope is quite convenient, but it has a minus - the working area is smaller, the image is cropped from above and below.

    Acrylic (or plywood) model

    Even before collecting virtual reality glasses became a trend, a wonderful scheme of glasses cut on a laser cutter appeared on the net. Without thinking twice, I decided to order their cutting in the same laboratory. They didn’t have plywood at that moment and they offered me to cut it out of black acrylic. The cost of cutting together with the material turned out to be about 800 rubles.

    In addition to lenses, rubber bands and foam rubber, for assembly you will need about 20 screws with 3-4mm nuts (the author of the model suggests using 4mm, but I had difficulty getting them in and I took 3mm).

    Oddly enough, the final version turned out to be even better than on a 3D printer. First, the glasses are lighter and more compact. Secondly, the material is smooth and more pleasant to the touch. Of the minuses - acrylic is a rather fragile material, and such glasses may not survive a fall.

    Conclusion

    Unfortunately, there is still not enough content for such glasses. You can try to play around with streaming, as described in a recent
    Similar posts