Sunday, April 10, 2016

Robot Journal - Michelle

Let's make a robot
To defeat the robot is a robot ... Wait, you mean I did not win? Well, it was a nice try anyway.

How will a tiny, 6-inch battle bots are made for the curious, want to know more about the design process, or just want to know why I hate coding, then this tutorial is for you. I am running as a summary of the wheels on the two servos and a stepper with a round bot that there is rotation around a bar. Nothing like building your bot onto a wrecking ball.



Parts List
I'm the one with the maximum torque, which led me full rotation servos start by looking through the motor for the SparkFun (steppers way too heavy to even consider). I like servos because I do not need a motor controller, I just plug it in to them and their work can get my Arduino.

I knew I needed two servos; I had to use Xbee for wireless and Fio decided on, because I like them. I use a really old Fio I had lying around for most of prototyping the new FiOS was not ready until the end, but I ended up using the bots new ATMega32U4 Fio. It's nice to have two UART line to take command, so I still have my Xbee USB cable connection and debugging was over.
Robot Journal - Michelle
Robot Journal - Michelle
Chassis Design
Once I figured out the motor and wheels, I need to figure out how I wanted to design a bot. I knew I wanted a large weight swinging around, so I decided that a circular robot will be the least amount of line snags. Servos and by the time the wheel is taken into account, though, it did not give me much room to make changes to the design.
I have two servos, and an Arduino wheels I have some servers Mike (thanks Mike!) Was borrowed from, so I grabbed inkaspesa and got to work. The first prototype was printed only on paper, and then I took part and made sure fit. At this point I had a fairly finished design team stuff and need for laser printers to print. So I have a piece of cardboard (cardboard so it is easy to squeeze in a bit stiffer lineup) ended up with. Then it was time for acrylic ... I grabbed some screws and everything will fit. But I still need to find a way to mount the servos.
Tim, we have some lying around the mounting bracket is designed for servos recommended that came out of the calipers and a lot of math. Again, cardboard and acrylic and mounted. For the moment the acrylic pieces work well as a top piece. At this point I was a decently put-together bot code to work on it, so it was about time to get to work properly.

Code Part 1
A few years ago I was a small robot from my netbook W, A, S and D to use it for that great work can be controlled, but it did not work so well when I tried to port it to a joystick. A 45 degree angle, etc. What to do? So I decided to write new code. This code got a bit crazy, but it was essentially the idea, device, joystick and a few buttons presses the search angle and velocity (how far out I'm pushing the joystick based on) account, and then push them all the actions and sends out a fairly large number. I do worry about the value of each separately, but then you need to make things a bit better, so I decided against it.

So after playing around a bit, I had a joystick value calculating and mashing them together. But the United Nations will work mashing, and it was mashed together properly? How strange, I would like to know if the joystick, or 45 degrees if the bot just do not like driving? Well, I read in a data-processing script on my bot using Arduino as a decoding function, both numerically and graphically, and then decided to write to the standard display. Processing surprisingly easy to use. It is never used, and I gave it my graphics and an afternoon was able to print some information. int getting a string of serial data from a character array, and then, there was another story, though.

Once I found a bug in processing all of my script, I was able to see the data being sent. But it's still (and this is why I wrote the sketch) was not right. So I went back to the joystick code to see if I could get hard data. I did a bit of tweaking, and remember - you have only one byte, 256 is not a useful number. Now I have to work the joystick code!
Robot Journal - Michelle
Robot Journal - Michelle

More coding
I got the code for processing the work, but I do not want to obey resembling some bots. So I figured since I was a pro processing, and my information is a graphical representation of the code, I have my bot to send a quick program that will help me to want to de-bug. If the picture is similar to the last sketch, it is. But in this case, it reads the standard mouse pointer, and the angle and speed calculation, and can tell if you are hovering over a button. It's definitely there is some error, but it gets the job done; I tested several functions to manipulate the data, and I am able to see the actual values ​​are not.
Robot Journal - Michelle
Robot Journal - Michelle

I hate coding
So I figured I'd start on the arms - I finally driving Bots (business still does not work, at least in front, backwards, left and right) got. Servo or stepper, servers or stepper? Or maybe a DC motor. My original plan was for a move, but they are large, heavy like Overkill. Not to mention that they need to 12V; You can get away with less, but it's not going to 3.7V Lipo. Servos On the other hand, Arduino can cause problems when you are on the (originally more than PWM timer pins) to use them. I started coding, and decided to move on.
Then I remembered that you just can not turn steppers. A step, then another, then another short delay to take the code, tell them. This works great by itself, but not as well as other code that is delayed. On the other hand, I'm not picky about steppers. If a server is just going to turn you in to take a break, that's fine. Basically, I need to move servos my time delay function is to be set up. Work Code - so simple driver solder, batteries, and a breakout board for me to add all parts of the building.

Joystick
Then came joystick. A joystick, a few months ago with a hand cannon that was built into a piece of plastic manufactured from conductive yarn spools. It caught my attention and I decided to turn in a full joystick. I have a thumb joystick, a pro mini, a small battery charger and grabbed a Lilypad Xbee board, it will not fit in the round and the bottom of the well.
Then come crunch time. I like the idea of ​​using the thread spool, but I just did not have time. Not too long ago we had a bunch of boxes Witilt discontinued but are still sitting around. They looked like they would be good to controllers, but hopefully they were not too short. So I have some buttons, LED and mounting hardware for a quick printout of the inkaspesa with mounting holes, and I'd like to try. It works pretty well, so I 110mAh battery, a pro mini, and Xbee Breakout (and Xbee) and I have recently designed a board that was caught in a Lipo charger combines with an FTDI breakout. I LED, buttons, joystick and start welded to each of the board. Let's just say it was a tight fit and I work well with USB port side of the line-up and got a piece, but it adds to the charm.
Robot Journal - Michelle
Robot Journal - Michelle

Robot Journal - Michelle
Robot Journal - Michelle

Rally
Small protoboards your friends. I have two servos, a stepper, a simple driver, two batteries, and the Fio (Xbee connected) there. When I debug your bot's no fun driving all over your desk, and a power LED for that since, wanted to make a separate switch the motor on and off.

Small protoboards and some imagination, I got everything fit. This board can be just as easy to connect components, three of which sounds boring, but it was actually quite nice sets of pads are attached. You need to connect the holes, and you have the ability to share and ground, etc., there are things, the three pads are pretty nice. There's even a convenient mounting hole that I was able to use the server connection is mounted on the board.

I finally got something done and it was time to assemble. This laser cutter took a couple of trips, but rubbing against the top plate is cut and the stepper motor shaft is not. I'm fishing the heaviest weight I-Mart (3/8 oz) and grabbed a couple of them could not find the connected stepper. Everything spun, but just bass fishing line winding around until the end. Before the tournament, I designed some weapons to help spin the weapon.

Everything worked fine until the time when I realized that the competition is just too thin connector, and keep coming off the hand. The next competition will be redesigned before hand. Otherwise, it's about; I am the last minute of acrylic, which is tied standoffs pulling loose from the cable cut to prevent prying claws and arms, but that's about it. I hope you learned something, now it's time to go to your own design. Good luck and have fun!
Robot Journal - Michelle
Robot Journal - Michelle


Robot Journal - Michelle
Robot Journal - Michelle




No comments:

Post a Comment