Sunday, May 11, 2014

Dilemmas

In this post, we will go into detail about the general and specific problems we have encountered.

General Problems

One of the biggest problems we have had is not knowing the correct jargon. It's like trying to get help from that friend who only talks in acronyms and bird calls. We have some experience and knowledge of jargon from coding and working with robots through FIRST Robotics. There have not been any FRC challenges that involve building a flying robot though, so we have not needed to learn the jargon and skills related to flight up until this project. As a result, there are many times when we do not know what people are referring to in blogs, pictures, code, or forums. This can be problematic when it comes to figuring out what we need to do in order to get the quardrocopter up in the air. For example, there are many diagrams that show how to use “sticks” to calibrate the ESCs, accelerometer, gyroscope, and other sensors integrated in the Multiwii board. This seemed important to do, but without knowing what the "sticks" were, we had no clue how to proceed with this knowledge. Eventually, after looking through forums and private messaging people, we learned that “sticks” were the throttle sticks on the transmitter.

Even when we know what the correct terminology is for what we want to do, there is often a system integration problem. One person will show us how to use a joystick to communicate with the computer, but the method will not be easily compatible with the Xbees. Or we find out how to use the Multiwii GUI, but it only works if we are using a certain type of transmitter. It is like trying to take pieces from five different puzzles and putting them together into one picture with no edges. And unfortunately, the person who wrote the blog that we based our quadrocopter design off of did not use the open-source Multiwii code and never got the code he wrote to work fully, so he is not as great a resource for us as we initially hoped. And there is no guide on the interwebs specifically explaining how to build a quadrocopter with the setup he used, at least not that we have found. This means to stick with the setup we initially envisioned, we have to piece together many separate guides to get a functioning quadrocopter. And now we are back to the compatibility issue.

Another problem we have had is not knowing what the specific problem is. Right now the quadrocopter is assembled, and all we need to determine is how to communicate from the joystick to the Multiwii. There are quite a few steps, joystick to computer, computer to Xbee, Xbee to Xbee, Xbee to Multiwii and then Multiwii to motors, and the first three steps may not be configured properly. If any of them are not working, the whole system is compromised.

The next sections detail the problems we have been having with the Xbees and the Joystick. Because they are what differs most from the tyical quadrocopter and therefore has the least online support they have been the most problematic.

Xbees

Once we had the pins soldered into the Multiwii and connected to the Xbee, we were able to power it consistently. At first we had some problems as the signal kept flicking on and off. We discovered the problem when we shifted the Multiwii and a motor started running. The gold trim, which we had thought of as decorative, is electrically conductive! While it was exciting to see a motor run, we had to tape over the electrically conductive parts quickly as we did not want any more short circuits.

We also found that the Xbee DIN port had been plugged into the wrong pin on the Multiwii, there's an important difference between Specktrum Satellite Connector pins and Specktrum Satellite Connection pins. As you can see from this diagram, it's easy enough to get confused.

After we sorted that all out we were able to get a solid connection between the Xbee on the Multiwii and the Xbee on the computer. However, all of the useful guides to using the Xbees were based off of the old Xbee GUI, XCTU. While we were able to get a connection between the two Xbees, we were not able to do anything with this connection. We downloaded the older GUI and configured the Multiwii code according to this site's instructions.

In the end we did get the Xbees linked, but still were not able to get the quadrocopter off the ground. There were still problems getting any kind of input from from the joystick to the Multiwii, but that's information for the next section.

Joysticks

The open-source Multiwii code is configured for a standard radio receiver and transmitter set, which we do not have. Instead we bought Xbees for to communicating between the computer and the Multiwii. However we still need a method to generate a signal on the computer to be sent via the Xbee link to the Multiwii. So we planned to utilize a joystick and either Processing or Python code that we had found on the Multiwii forums. Although we got code from people who said that it worked for them, whenever we tried to compile it we found bugs, which got quite frustrating. We didn't understand why people would put code online saying it works when it doesn't. Perhaps we were doing something wrong, but there were enough errors in the code that we didn't think it was our mistake.

In our next post, we will explain how we have learned from these problems and what we are doing to proceed with our limited amount of time in the face of these complications.

We tried to write code that would only run the motors, which we thought would be quite simple. However, due to the way the Multiwii's pin numbers and access to those pins works we were unable to do that.

Stay tuned for the next post to see how we are solving these problems!

Wednesday, April 30, 2014

Building da 'Copter.



Hello,

This post is coming a bit late, we meant to have it out a few weeks ago, some things have changed since that time, but this is where we were then.

Our primary goal, after receiving all the parts, was to put them all together! Besides the short delay with the frame, it was pretty straightforward. Our main struggle will be trying to get it to fly and using Xbees to communicate wirelessly.

A lot of the assembling was simply plugging parts into other parts. The motor leads plugged into the speed controllers, which plugged into the power distribution board, which plugged into the battery. All we needed was this pin diagram to know where the PWMs plugged into our Multiwii. Besides plugging stuff in, we had to drill through the propellers to make the inner hole big enough to fit the motor mounts. Here you can see it all nicely assembled.    
                                                       


Since putting together the body of our quadrocopter isn't too difficult, we decided to split off and do different jobs. While Kazmir put together the body, I attempted to test the Xbees. The first step was to solder pins for the Xbee extension board, so we could power our Xbee. We were able to get them connected using the XCTU software. We weren't sure where to go past that and the next time we tried to connect the Xbees, it didn't work.




Currently we are working on the code for the quadrocopter. We found open-source code for the Multiwii and the accompanying GUI and are currently going through the code in an effort to fully understand it. The motors may still be wired backwards because there were no positive or negative markings on the leads, but this will only cause them to run in the wrong direction.


 We have also added a switch to the battery for ease of turning on and off the quadrocopter! Stay tuned to see what else we do!


Friday, April 4, 2014

All The Parts!

Hello Again!
In the last few weeks all of our parts arrived, fully intact! Below are pictures of most of them.


The motor controllers and power distribution board
The propellers
The Xbee

The battery

Battery charger
Frame Number One

This frame was a bit of a disappointment. Being the first part we received, we were eager to start screwing it together. Sadly though, we ran into a few problems which we equated to the quality of the frame. A few of the screws did not fit in the screw holes, which meant we either had to buy new screws or drill new holes. Then we realized that this model is incompatible with the motors we had ordered due to weight. So, we went back to HobbyKing, figuring that was the best solution. We found a much much better quality frame with a fancy fiber glass (instead of aluminum) body. And here it is! Isn't it lovely!



This frame is the same as the one that Daniel suggests using on his guide, except that it is slightly larger. We made sure to look into the specs of our motors first though to make sure the weight increase would not render our motors useless. We did not go with the frame Daniel suggested  because there was still a lot of back-log and we only have a semester to build this quadrocopter. It just wouldn't have been worth the wait for a slightly more compatible frame. About a week after ordering, the new frame arrived! As you see, we have jumped ahead, plugging everything in. You'll hear more about that in our next update!


Monday, February 24, 2014

Taking Senior Year to New Heights

Hello. We are Kazimir and Zahara. Welcome to our Capstone Blog.

At the end of our junior year of high school, we decided that we wanted to build a robot. Originally we were going to build a line-following robot which is what we told the school in our capstone project proposal. We have had some difficulty committing to an idea though, as we imagined building everything from transforming to drawing to stair climbing robots. Four weeks ago, we finally settled on building a quadrocopter because they can fly, would require us to learn a lot (remote communication, programming, aerodynamics etc.), are simple enough to build in a semester, can be enhanced with sensors, cameras, and flashy lights, and did I mention they can fly?

This blog is the log of our experience building and enhancing the quadrocopter. We will try to be as detailed as possible. If there is anything you do not understand though, feel welcome to email us questions as at rearingrobots@gmail.com. Or you could just send us a "hello." Neither of us have kept a blog before, so any advice or critique you might have would be useful to hear. No matter the subject matter, it is nice to receive emails from blog visitors. 

We decided to share our robot building escapade in hopes that someone out there will be inspired to build or explore robotics and beyond. To quote the wise words of Dr. Suess: 
"The more that you read, the more things you will know. The more that you learn, the more places you'll go."
And this is the beginning of our story of the places we'll go. Our preferred method of travel: flight. While we were looking for ideas and guides all over the interwebs on building quadrocopters, we stumbled across Daniel Gonzalez's Yet Another Mechanical Engineering Blog (YAMEB). He has a detailed guide to assembling a quadrocopter around the size we want (small enough to be flown around in the school) and sourced all of the parts. The parts we ordered are mostly the same as listed on Daniel's blog. Here is the list:


From HobbyKing
    • MultiWii 328P Flight Controller w/FTDI & DSM2 Port
    • Four Turnigy Aerodrive SK3 - 2826-1130kv Brushless Outrunner Motor
    • ZIPPY Compact 1800mAh 3S 25C Lipo Pack (Battery)
    • Turnigy balancer & [Battery] Charger 2S-3S 
    • Five 8X4R Propellers (Standard and Counter Rotating) (6pc)
    • Four Turnigy Multistar 15 Amp Multi-rotor Brushless ESC 2-3S (speed controller
    • Hobby King Quadcopter Power Distribution Board 
From Maker Shed
    • XBee Wireless Series 1 Starter Kit
From Amazon 
    • NEEWER® Useful HJ MWC X-Mode Alien Multicopter Quadcopter Frame Kit Red/White

The frame we bought from Amazon is a different version of the frame that Daniel suggested, because the one he used was out of stock everywhere.

This post is a bit late. We have already gotten all of the parts and put much of them together. It's hard to pull away from the robot and write about it, but we'll be posting more about all the parts and electronics soon.