⬆️ ⬇️

Hexapod construction for those who do not want to make, but want to program

image



Hello. In this article I will try to share my little experience in building a budget but technologically good spider-robot.



Brief introduction:

')

One day, after reading a lot of interesting articles about how to build multi-legged walking robots, I got such an idea. But here are the articles that I came across more focused on how to make it. Filigree possession of a file, miracles with Plexiglas, a circle for those who had a laser cutter, a milling machine, etc., were lying around at home, something that most obviously would not find.



The other unpleasant side was the fact that STM32 was used as brains for the most part - if not arduino. I also wanted to do programming. Teach the robot to run after the ball, bypass obstacles, move around the open space. That is what it takes more than arduin. All desires rested in money, which is small, and hands that are crooked. I will try to tell how I avoided both of these obstacles.



Platform:



As a platform, I discovered ready-made kits for aliexpress or ebee. Type of such:



image



These are sets made from aluminum. Quite light, slightly heavier than plastic, but already metal. They are searched for on request "6 legs hexapod robot kit", can be found at a price of up to $ 100, and the kit will include not only large parts, but also small slewing bearings, bolts, nuts, in general, everything you need.



They go without servomotors, which I recommend to order separately. It is possible to order with motors, but I would recommend not to trust the Chinese in this choice. The form factor they have is unified, so you can go through a lot of servos, depending on tastes. Here I made the first mistake. Having previously learned that servos differ in that they may be:





I thought - well, of course, I need a robot on the strongest (12 kg / cm) iron gears with a digital controller (in my case they were Chinese TOWARD PRO 996M). And only when the robot could get on its feet only using at least 10 Amp stationary power supply unit, and it lacked any batteries - it just jerked its paws and the wires began to melt, I realized that I had to be modest.



image



Not only that I could not provide it with power (for some reason the idea of ​​multi-storey batteries did not appeal), so the weight of 20 iron-servomotor servos added a couple of kilograms. The next batch came to me from hobbiking analog servos, plastic for 5 kg. The robot cheerfully got up on a stationary power supply, but 5 nickel batteries did not lift it. Docking another 5, it turned out that this is quite (and quite a long time is enough).



image



Having sadly sighed about 100 dollars thrown to the wind not the first 20 servomotors, I began to think how now it would be convenient to manage all of this and what brains to use. For the first time, I used a board assembled on my knee with a stm32f4 Discovery stuck to check the servos.



image



But I didn’t have the desire to solder further, or to poison the boards It was necessary to something more ... comfortable.



Since it was machine vision for the purpose, I took the A + share, it is smaller in size and has low current consumption. The entire digital part of the robot consumes about 150 mA. By the way, the TP-Link mr3020 router, which has the same size and is very popular among fans of small pieces of hardware with built-in Linux, consumes exactly the same amount, having only 32 MB of RAM and 4 MB of ROM. What does not turn on it as it should. Raspberry has 256 MB of RAM and a memory card.



image



The current price of it is about 20 with a penny euro.



Then it was necessary to control the paws with something, and 2 boards with PWM controllers, controlled via I2C bus, and having 16 outputs each were purchased. On Aliexpress, they are sold for about 5 bucks a piece.



image



I2C modules of clocks, gyros, digital compass, barometer / thermometer were also bought there. As well as 2 boards - one charges a 5 volt lithium battery, and the second makes a 3 volt lithium battery 5 at the output. It was necessary to use a separate lithium battery (from an old mobile phone) to power the digital part in order to avoid interference from the motors.



In total for the money it came out of the calculation of 2-5 dollars per module.



All modules (sensors and servo controllers) hang on the same i2c bus, and so far they work without any special problems, requiring only 4 wires from the switch.



image



Another file was waiting for the camera selection stage. For 20 bucks was ordered "Raspberry PI camera noIr" - a camera that is plugged into a special socket Raspberry. The joy of what she sees in the IR range was immediately overshadowed by the fact that the color rendition was very dependent on the light source. About any computer vision, when the test ball is red in the afternoon and white in the evening, there could be no question. For the same 20 bucks a simple camera was purchased, which copes with tasks quite well.



I was particularly pleased that for all the boards it is very easy to find examples on the python, with which you can quickly check their work - pull the servo or look at the angle of inclination



Thus, for about $ 300, you can assemble a robot with 6 legs, Linux on board, powered by batteries, with sensors and a camera. Soldering is required only for the I2C cable and power cables. Of course, this is not all, in the plans to continue to load it with sensors and, verchtno, manipulators, but then the matter is beyond the imagination of the designers. The stock of useful weight is present - in this form, the robot keeps its weight on 3 legs.



Brain-feeding batteries (4.5 Ah) last for several hours, and nickel batteries (5 Ah) just walk back and forth through the office several times (until they failed to fit in a day) The first battery is charged from the USB adapter, the second one is universal charging for nickel batteries, which can be found in stores that specialize in radio models.



It was not possible to highlight many moments, since the journey on the rake lasted more than a year.



image



I hope my post will push someone to increase the number of robots.







PS: I do not specifically address software issues, since I consider this robot as a simulator and moderately universal isoptalny mechanism.

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



All Articles