Building robotics ground vehicle. Part 1 - mechanics.


There are a lot of small robotics platforms available on the market. However, they are usually not very robust and it is hard to place additional mechanics or senors on them. There are also good platforms which are big and robust enough but they are usually quite expensive. With this project we want to build robust, easily customizable, yet affordable robotics platform.

Fortunately, nowadays building small robotics ground vehicle is not that difficult. However, it might not be easy for beginners to figure out how to put everything together. This series of articles address exactly this problem. After building our 3D-printed Veterobot vehicle we have learned a lot and decide to make the new one taking in account our previous experience. We provide the guide through the complete process of building small (420mm x 297mm DIN A3 page size) robust ground vehicle. Having hobby makers as our target audience we select the set of technologies and components which are maker- and budget-friendly (like 3D-printing, Raspberry Pi, Python, etc.). All the CAD models, schematics and software is open-source and available on GitHub. Articles in this series will cover three  main topics: mechanics, electronics and software.This article is about mechanics.

Mechanics

In general, it is a good idea to think thoroughly before you start doing something. Building mechanical parts is not an exception. Fortunately, open-source community offers more or less usable CAD tools which can help by mechanical design. Since we are using Linux, there are basically two choices - OpenSCAD and FreeCAD. Both of them are not perfect. OpenSCAD becoming extremely slow in visualization if models are of moderate complexity. It also does not easily support some useful features like for example filets and chamfers. There is also no support for constraints. FreeCAD in turn is feature rich but extremely buggy and lack some nice parametric modeling features offered by OpenSCAD. Latest stable FreeCAD version (0.15 at the time of writing) is more stable but still buggy enough to make me pulling out my hairs several times. I was switching several times between OpenSCAD and FreeCAD driven by lack of features and performance problems of OpenSCAD and annoying bugs of FreeCAD. For this particular vehicle we decide to stick with OpenSCAD.
Mechanics designed in OpenSCAD. Semi-transparent rectangle is DIN A3 size for reference.
While thinking about mechanical design, there are two main questions to answer: a) how to steer, and b) how to propel the vehicle.

Steering

In hobby domain there are two popular solutions. The first one is car-like steering where front wheels could be rotated around vertical axis.
Car-style steering
The second one is so called differential steering where wheels or tracks on the left and right side of the vehicle can rotate with different speed to steer the vehicle.
Differential steering
Since the car-like steering requires slightly more complicated mechanics, we decide here to use the differential steering.

The next question to answer is whether to use tracks or wheels. Tracks have their advantage in case of heavy vehicle which is supposed to drive on the soft surfaces such as sand, dirt, snow, etc. The disadvantage of the tracks is large friction they cause by turning. It means there are higher requirement for the motors torque and correspondingly higher energy consumption (shorter battery life). Since we are building small light vehicle, we decide to use wheels instead of trucks.

Having decided for wheels, now we need to decide how many and how to position them. There are again two popular solutions in hobby domain. The first one is to use three wheels with two active and one passive support wheel which can freely rotate around vertical axis (caster wheel). The second option is to use two active wheels on each side. The advantage of the three wheels option is very low friction by turning. The disadvantage is lower stability of the whole platform due to only three wheels. Four wheels version has much better stability but similar to trucks can expose high friction by turning. This problem could be reduced by placing two wheels on the same side as close as possible to each other. This is the way we decide to go with this project.

Locomotion

The first fundamental decision here is which technology to use for propulsion. We can decide between electric motors, combustion engines, jet turbines, etc.  For simple ground vehicle, electric motors are the choice. The question is however how many of them to use. To make our vehicle able to drive something more challenging then parquet, we want all four wheels to be active, i.e driven by the motor.

Unfortunately, reasonable motors are expensive, they take quite some space and might increase requirements for hardware to handle encoder signals (more about them later). So we need to find the trade-off here. In this particular project we decide to use one motor per side but ensure that two wheels on the side are driven by the motor.

Speaking about motor selection - in hobby domain there are mainly 6V, 12V and 24V motors. Depending on the weight and desired speed, makers can decide which one to use. Since our vehicle is not too small, will have some weight and we want it to be more or less fast, we decide to use 12V motors. In addition we want feedback from motors for precise control. Consider the simplest task - drive straight forward. Despite it's simplicity it is not easy to achieve in real-life. Just applying exactly the same voltage to left and right motor will not work. The problem is that motors, bearings, springs and wheels are mechanically slightly different. There is different friction by moving parts. That is why, even exposed by the same voltage, motors and wheels will rotate with different speed causing the vehicle to deviate from straight line. To overcome this problems we need constantly observe wheel rotation speed and adjust voltage correspondingly to achieve equal rotation speed at the left and right side. Such a feedback could be obtained from encoders - special sensors which generates several electrical pulses per revolution. Ideally our motors should already have such encoders. In fact, even with encoders it is not possible to drive absolutely straight forward because of imprecise placement of wheel shafts, differences in underlying surface, tires, etc. One possibility to deal with these problems is to use visual odometry, but it is definitely out of scope for this article.

Back to motor choice - we decide to use these motors.

They are already equipped with quadrature encoders and there are different gear rations available to trade between power and speed. In this particular vehicle we use 50:1 200 RPM 12V motors http://www.exp-tech.de/50-1-metall-getriebemotor-37dx54l-mm-mit-64-cpr-encoder. It means that the maximum theoretical speed will be  RPM * 60 * (D / 1000 / 1000) * 3.1415 , where D is wheel diameter in millimeters. For our vehicle D is 125mm and RPM is 200 which gives 4.7 Km/h. In fact, the top speed will be lower because under load the motor will not be able to reach 200 RPM. But this is good speed for indoor usage.

Based on our decision to use one motor per side but drive both wheels we need to figure out how to transmit the motor power to wheels. There are thousands possibilities here. We decide to connect the motor shaft directly to one wheel and use timing belt with corresponding gears to drive the second wheel.
Active and slave wheel connected with timing belt.

Timing belts should be always in tension to prevent slipping. For this purposes we place the gear and bearing holder on two aluminum rods in such a way that they can freely slip. The required tension is achieved with two springs which are pushing holders in opposite directions.
Springs are keeping timing belt in tension.
Gears and bearing holder has not trivial shape. Thus we decide to 3D-print it. Even with 30% filling they are strong enough (actually more then enough) to hold the weight of this particular vehicle.
3D-printable bearing and gear holder
Electric motors obviously require battery. We were considering three battery technologies: a) LiPo - they have highest energy density but require special attention by charging and rather expensive; b) NiMh is not that sensible as LiPo and in general a good choice; c) lead (Pb) is the heaviest but the easiest to handle and cheapest compared to LiPo and NiMh. For this particular project we decide for Pb battery mainly because price and simplicity by charging. There are a lot of 12V Pb batteries available on the market. We are using similar to this one:
12v sealed lead acid battery

Assembly

To hold all mechanical parts together we decide to use two horizontal plates and mount them together using two vertical panels on front and back side of the vehicle.

Taking in account the dimensions of the vehicle, horizontal plates are quite big and it is not practical to 3D-print them. It would be hard to find 3D-printer with large enough working area. In addition it will take quite some time on hobby-level printers. That is why we decide to use plywood to produce them. The very first version was made with fretsaw and file. Later, we used laser cutter to speed up the process.

Front and back panels are smaller and can be printed for example on Ultimaker. However, it takes quite some time, so we are considering small redesign to make these panels also producible with laser cutter or simply fretsaw and drilling machine.

Additional stability is achieved with sliding rods we used for wheel holders. They are fixed on the vertical panels with nuts.
Actually, both sides of the rods have screw-threads. It is not shown in the CAD model.
Sliding rods are relatively easy to produce. We just cut corresponding size and make screw-thread manually. There are a lot of instructions in the Internet how to do it. Here is just one example out of many:


Rods are made intentionally a little bit longer. We can use them later to mount some tools or sensors. For example, front and back blade for sumo competition.

Wheel shafts might be tricky to make depending on mounting technique used for gears and stoppers. To prevent slipping of the gears, the areas where fixing screws touching the shaft should be made flat or kind of deepening should be drilled. The most tedious way would be to fix the shaft with vise and use file to flatten corresponding places. In this case using something softer then steel would be advisable :-) . However, if you have access to milling-machine that would be the simplest way to make shafts.
Flattened surfaces are preventing slipping of the gear and motor coupling.
One end of the shaft should also have screw thread. It is not that difficult to make it even with cutting die. What is important however to use some kind of locking nut to mount wheels. Otherwise, after some driving vibrations will cause nuts to become not tight.

Regarding wheels - RC cars guys already collected bunch of experience with mechanical parts. So we just decide to use standard RC car wheels with their standard mounts. For this purposes it is necessary to drill the perpendicular hole in the shaft. This is the only step which you can not really do without proper drilling machine. Hand drilling machine would not work (unless you are drilling top gun :-) ). The problem is to make the hole really perpendicular to the shaft. Otherwise the wheel will wobble which is not good.

So now if you you put everything together, it will looks like this:
Assembly without battery
 The place in the middle is where the battery will be placed. To fix the battery we decide to make holders and use hook-and-loop fasteners:
Battery with holders
So finally, placing the top cover will provide additional stability for the battery and convenient access to the power pads. In addition, there are corresponding holes for hook-and-loop fasteners as well as for wires to connect motors to the on-board electronic which will be placed on this top cover.
Placing top deck.
So now the mechanic is ready for the first test-drive. However, some control electronic is missing. This is what will be covered in the next article.

The following pictures are from the real vehicle we have made according to the description above. There are some details which might be useful if you decide to try to build it yourself.


When we reached this stage in the project, we were so keen to test-drive the platform that we hook up motor controller with RC receiver just to remotely control it with standard RC device. It resulted in absolutely unmanageable cable salad, but we did not care :-) . So here is the video of the very first RC-controlled test-drive.



Comments

  1. Nice detailed post, thanks! I'm an OpenSCAD user myself and as you described it's not practical for medium/large projects. I usually do parts as separate small modules which are quick to render and then combine them into larger subassembly modules (which require some patience). While designing I keep the number of facets in cylinders to a minimum and only set it up when I need to do a rendering/export.
    Otherwise I can recommend you to try OnShape. It works on Linux directly from your browser and you can have up to 5(?) "free" projects at a time. Even if it is still beta is already pretty solid.

    ReplyDelete
    Replies
    1. Glad that you like the article. I am currently writing next parts on electronics and software. Hope it will be also useful. Thanks for the tip about OnShape. I will take a look on it.

      Delete
  2. Nice project, I look forward to future updates. Maybe I'll build one.
    Another good CAD package to checkout is Fusion360 from Autodesk. They make it very easy to share your models and they have excellent support on their forum. I've been using it for a couple months now and love it.

    ReplyDelete

Post a Comment