Showing posts with label mission planner. Show all posts
Showing posts with label mission planner. Show all posts

Monday, August 3, 2015

First Successful Quadcopter Autonomous Mission

After all the adjustments to the Deadcat SK450, I took it out to the local "park" (remote muddy field) to try a mission.  It was a simple mission, fly to a few waypoints, circle at one waypoint, return to launch, then land.  It actually worked!  Here is the video:



Thursday, July 30, 2015

Getting Telemetry Working, A Short Review of Excelvan Radio Telemetry Kit 915Mhz

I recently purchased a small Telemetry module from Newegg.com for about $25, it runs on the unlicensed 900 MHz band.  It was quite easy to hook it up to my Hobbyking Micro APM and now I can monitor the Quadcopter while in flight, just as if it was connected to my PC via USB.  No need to connect USB on the ground, as this telemetry connection handles all communications.

A new cable must be made using the supplied telemetry cable from the telemetry module and the one supplied with the APM.  Also remember to connect as follows:
Telemetry Module with black antenna

Telemetry ModuleAPM
5V5V
GndGnd
TXRX
RXTX


The PC connection was also painless, stuck the module into a USB port and the driver loaded automatically onto my Windows 7 laptop.

The only other trick is to select 57.6Kbps in Mission Planner to get the link to work.

Note: Telemetry module is from Excelvan and is called "Radio Telemetry Kit 915Mhz Module for APM APM2.5 2.6 Pixhawk PX4 RC Multicopter Quadcopter" and is available on Newegg.com

Update-Pixhawk Test

I also purchased a unit for use with my Pixhawk-S500 quadcopter covered elsewhere on this blog.  This time, I could use the included cable to connect the telemetry unit to my Pixhawk, although I had to shave a little plastic on the Pixhawk end, as the Pixhawk uses unusual connectors.  As with the APM, I set the rate to 57600 and was connected to Mavlink on the Pixhawk.  Works like a charm.

Monday, July 20, 2015

Pixhawk Versus APM Comparison Review

This blog entry compares two flight controllers from the Ardupilot 3DR-Open-Source stream: the generic APM 2.X controller and the Pixhawk.  I am an intermediate multirotor builder and flyer, so this comparison will focus on functionality and useability, not on advanced features.  Also, this review is based on my experience with 5 different APM modules (none sourced from 3DR) in three different physical forms: standard, mini, and micro (also called mini by some) sourced from Hobbyking and generic Chinese manufacturers.  The Pixhawk is available from multiple domestic and Chinese sources and you should check the reviews to make sure you are getting one with decent build quality.  Each was used with corresponding GPS/Compass units from the same manufacturers.  I built three different quadcopters and used them with different controllers.

Feature/CharacteristicGeneric APM 2.X3DR PixhawkComment
Size/WeightSmallLargerAPM is available in 35x35x5 mm board.  Pixhawk is 81x50x16 mm
CostLowHigher, about 4XAPM with GPS ~$65
QualityVariableBetterInspect a generic APM after you get it for poor soldering, loose USB..
SupportGoodGoodThe best support is from peers on DIYdrones and APM forums
Flight StabilityGoodGoodThis is my experience with a well setup APM and Pixhawk, your experience may vary
AccuracyGoodBetterIt does depend on your GPS and its accuracy.  Pixhawk has a more powerful processor and more memory
Onboard indicatorsPoorGoodPixhawk has multiple LEDs and tones to tell you status, APM has a few LEDs
Ease of SetupModerateModerateMore components to interconnect on Pixhawk, but well documented. Cables and connectors often an issue with APM and documentation must be found on the Internet.
Ability to fly autonomous missionsYesYes
Mission Planner Ground Station CompatibilityYesYes
Flight logging CapabilityGoodBetterPixhawk logs more information and has a microSD for storage. APM has limited storage of most important variables.
UpgradeabilityNoneYesAPM code is now frozen to my knowledge, but Pixhawk software with improvements still being released
Debugging difficultyGoodMore difficultAPMs seem to always work, Pixhawk is more finicky about ESCs, setup, etc.

Overall, both controllers are excellent and have worked well for me.  The APM is a better fit for small quadcopters and is probably better for the beginner builder due to its simpler setup and low cost.  The Pixhawk is very good but it takes more time to set up and it is likely higher quality and performance, so it works well in larger camera quadcopters and similar expensive vehicles.

APM equipped SK450 "Dead Cat" Quadcopter
S500 Quadcopter with Pixhawk

Saturday, July 11, 2015

Don't Try Auto if You Cannot Loiter

Learned a new lesson yesterday, should not have needed to learn it, because it is obvious.

If your quadcopter cannot LOITER successfully, don't try an AUTO mission.

I headed over to the local "park" - more like a remote muddy field that the county calls a park - to fly my quad.  The plan was to check out AUTO mode with the program shown in the previous blog entry.  I forgot, or ignored the previous tests that showed that LOITER mode did not work well, the copter bobbed up and down and did not hold position.

So I try taking off in AUTO mode with no luck, then do a manual takeoff and flip the switch for Auto mode.  At first, things seemed OK, then the quad headed for the river, gaining altitude.  Before I could react, it was over the Potomac at about 75 feet, then it dipped below the tree line and I could not see it.  I flipped back to manual (Stabilize) control and thought "that quad is gone".  I hit the throttle to try and bring it back up above the trees and it appeared as a little speck in the distance.  I then was able to bring it back with some skillful (lucky) stick work and land it.  Was I ever lucky!

The saving grace is that it took some great video footage while on its semi-controlled mission.  Also, this is why you should not fly near people, as this could happen to you and someone could get hurt.

Here is the video:

Tuesday, July 7, 2015

Status of the DeadCat SK450

The Deadcat SK450 is working fine.  A few minor modifications:

  • packaged up the APM controller and mounted it on anti-vibration foam
  • added a LiPo batter monitor
  • tidied up some cables
A photo with some details is shown below.


I am also working on a new mission which includes takeoff and landing in the Mission Planner software, see below.


Friday, March 6, 2015

Drones Today = PC's in the Late 80's


I got the drone back up and running.  It turned out that Mission Planner, the PC software that interfaces with the drone, was loading quadcopter firmware with airplane parameters.  It could be that I mistakenly changed a drop down box that selects the default parameter file, or it could be that Mission Planner did not change the parameter file when I reset the drone software from drone to airplane to drone in order to get a "clean load" of drone software (this is the recommended method for resetting your APM/Pixhawk software).

In reflecting on all the hours spent debugging the problem, and the difficulty in identifying the problem, I think the "Drone Industry" is about where PCs were in the late 80's.  It is not a perfect comparison, but it is reasonably close, check out my table below:

CharacteristicDrones TodayLate 80's PCsPCs Today
Off The Shelf Complete UnitsYes (DJI, 3DR..), but many complaints about the white label productsYes (IBM PC, Apple MAC..), but many complaints about the white label productsAlmost all PCs bought off the shelf and work 1st time
HardwareSomewhat standardized, but incompatibilities are commonStandardized, but incompatibilities are commonPlug and Play for almost all hardware
SoftwareLots of variations, nice user interface over a command line operating system, lots of variables to customize, many bugsA few variations, nice user interface (Windows) over a command line operating system (DOS), lots of variables to customize, a few bugsA few variations, nice user interface (Win or OSX), a few variables to customize with wizards to help, few bugs
Growth RateVery highVery highShrinking as people use more mobile devices
Industry ParticipantsAll small companies (DJI, 3DR, Turnigy..), no leaderIBM, Apple, and Compaq are leaders, many small players as well (Packard Bell, Nortel, ..)A small number of huge well known companies: Apple, HP, Lenovo..

Photo credit: Flickr

Thursday, March 5, 2015

New Drone is Down, Debugging Now

The new Deadcat drone no longer works.  I cannot figure out why and have spent about 6 hours trying everything.  It seems to be related to the Pixhawk flight control unit interacting with the ESC (speed controllers).  Below is a summary of the problem that I sent to 3DR, the designers and manufacturers of the Pixhawk.  I will let you know what happens.

--------------------------------------------------------------------------------------------------------------------------
I might have a bad Pixhawk autopilot.  I bought it in December and it worked fine for about a month.

Here is my config:

SK450 frame
4 x Turnigy plush 30A ESC (red power lead is disconnected - Pixhawk is connected to signal and ground only)
4 x Turnigy Multistar 2216-800kv motors
Pixhawk
3DR GPS module
3DR battery sensing module
Spektrum DX6i Transmitter
Orange R615X receiver
Various turnigy 2200mah batteries
Mission Planner on a PC for ground station

It worked like a charm before, reference this Youtube video (excuse the lousy quality).  Deadcat SK450 Test Flight 1

No crashes, I was still test flying in the basement as it is 20 degrees outside with snow.  I was upgrading it as the R615X receiver has limited range.  So I  tried a new receiver, the Orange R800X, and never really got it to work, then I went back and did the following:

- reloaded arducopter 3.2.1 by first loading the plane software, then reloading the quadcopter software, also pressed the reset button on the pixhawk
- recalibrated all my ESC s manually one by one
- did many full setups: compass, accelerometer, radio, .. calibrations
- checked a lot of the parameters and adjusted them, then set them back if there was no improvement
- verified the radio was working by connecting servos to the receiver and also by doing the manual one by one calibration of the ESCs
- verified the pixhawk was seeing the radio inputs, and was putting out the correct outputs, such as increasing throttle on all 4 output channels when the radio throttle was advanced after arming

Here are the problems that I am seeing:

1. The USB connection fails 50% or more of the time.  I have to power cycle the pixhawk and/or plug and unplug the USB cable.  I tried two different USB ports on my laptop, no difference.  This is pretty consistent for the past 5 days.  It worked fine before.
2. The ESCs continuously complain that the initial throttle input coming from the Pixhawk is not low enough.  Here is a phenomenon I saw today regularly:
  1. I calibrate the ESC by connecting it directly to the throttle output of the receiver, and go through the calibration procedure.  The ESC responds with OK tones.  
  2. I try the motor still connected to the receiver, and it revs up and down with the throttle input.
  3. I move the ESC input over to the Pixhawk, arm the Pixhawk, and then the motor responds properly after arming.  Note that I did not power down the pixhawk or receiver.
  4. I power down the quad (radio, pixhawk etc.), and start it back up.  I get normal startup tones from pixhawk and the ESCs complain that they have no throttle input (this is normal as the safety switch is off)
  5. I turn on safety switch, arm the pixhawk and get OK tone, but the ESC complains that the throttle input is not low enough again.  Motors will not function.
  6. WEIRD!
  7. I also tried calibrating one ESC through the pixhawk instead of connecting to receiver (step 1).  The ESC seems to calibrate successfully.  I execute step 3 successfully.  I get the same problem at step 4.
3. Parameters do not seem to be reliably stored in the Pixhawk.  It keeps resetting the battery failsafe settings and sometimes when I try to write a parameter change via mission planner I get an error "Bad Number", which is not very useful.
4. Now, I cannot get the Pixhawk to connect to either receiver, the previously used and flown R615X or the new R800X.  The radio calibration screen shows no activity, but the receiver is definitely connected to the transmitter as I test it with a servo or connect it to an ESC and can throttle the motor up and down.

I am stumped.  If I had my trusty Tektronix oscilloscope from EE school, I would check the signal on the pixhawk ouputs but alas, I don't have one.

Sunday, December 7, 2014

DC Area Drone User Group Meetup


I went to a "Meetup" of the DC Area Drone User Group yesterday.  It is essentially an informal meeting of like-minded individuals organized through the Meetup application.

The meeting was very useful as we had a great mix of beginners like me, experienced folks, large drones, small drones, different radio setups, etc.  I was able to ask questions of some of the experienced folks about how to set up my controller and radio, what props to use, where to buy parts, etc.  There was also an opportunity to see what other people had done with their drones - construction techniques, equipment, and so on.  You also get to meet people and exchange contact information.

If your community has a similar club or users group, I encourage you to attend as it is a great way to meet folks, get questions answered, and learn.

Tuesday, December 2, 2014

Mission Planner, Google Earth, and Logs

A plot of a drone flight over my house

I am starting to play with the Mission Planner software which allows you to program your drone-quadcopter, read logs, and program autonomous "missions".  One of the interesting aspects is the ability to download logs from the flight controller and plot your flight paths on google earth.  Mission planner outputs a KMZ file which can be read by Google Earth and viewed in the application.  The roller-coaster-like plot in red above shows my flight of November 29th over my house.  The video from the onboard camera was posted in a previous blog entry.  You can see the takeoff from the driveway, flight over the house, then back climbing, then doubling back, followed by a collision with the roof and a crash landing in the bushes.

Wednesday, November 19, 2014

Building and Flying Quadcopter Part 11

Quadcopter Drone ready for tethered test flight



Making progress, I found the link to set up the motors, speed controls, etc and got the wiring for the ESCs and motors set up properly.  Then I mounted the propellers and spent a while trying to figure out how to arm the drone, which I found at this link on the wiki.

I also needed a way to test-fly the drone, given my propensity to crash quadcopters.  I came up with a system using an old piece of plywood, with holes to allow rope to be attached to the drone landing gear.  The rope is wrapped around some tall screws on the plywood to allow adjustment.  This is shown in the photo above and actually worked out well.

Then our first test flight shown above.  The drone worked, although the controls need adjustments, particularly the throttle.  You can see me testing throttles, forward motion, yaws left and right, and left and right movement - all the basic movements.  So now it is back to the wiki and Mission Planner to find out how to tune the controls.


Tuesday, November 18, 2014

Building Quadcopter Part 10


Further Progress.  I reloaded Mission Planner onto my laptop and it seems to work with the controller now.  The rats' nest of wiring is somewhat tamed and the receiver and controller are mounted using double sided foam tape (get it at Home Depot where they call it "mounting tape").  The extended landing gear are installed and I found an appropriate non-metallic shell to cover the electronics.  Yes, it is a 6 inch flower pot, and it is perfect for the job.