3D Robotics

ArduPilot code now in beta!

Jordi's finished the first beta of ArduPilot, in anticipation of the board's commercial release. Changes and improvements include:
  • The code is now hosted in a proper code repository (Google Code) for version control and to allow others to contribute to the project. You can find it here.
  • RTL (return to launch) and waypoint modes are user selectable
  • Waypoints have altitude as well as lat/lon
  • GPS parser now returned to ASCII NMEA, for compatibility with any GPS module, 1Hz or 5Hz. Very efficient code will allow it to run at any baud speed the module can support.
  • PID loops used in all control functions
  • Lots of bug fixes and error-trapping inserted
E-mail me when people leave their comments –

You need to be a member of diydrones to add comments!

Join diydrones

Comments

  • Hi Chris, i have a cuestion about code, ithink you dont include the reverse throttle variable?
    i only see the reverse rudder but not the throttle, i think i can try to modify the code and add this because some chineeses BEC working in reverse mode. But If you want to add in your code is right for me.

    Sorry for my poor english :(
  • 3D Robotics
    @Michal: Yes we caught that today in flight testing. New code coming tonight.
  • Still bug in this statement:
    angle = constrain(angle, 180, 0);
    function constraint writes that 2nd param is low end, 3rd param is high end, so correct is:
    angle = constrain(angle, 0, 180);
    otherwise you'd always get resulting value 180 => very fast plane turning to one side ;)
  • Power is relatively slow way to control altitude. Blindly adding a little elevator to climb without direct closed loop feedback on pitch or climb rate only works for tiny additions to elevator, otherwise plane can continue to increase pitch angle beyond desired rather than what I think you guys are talking about, which is a slight pitch increase and self-dampening at a slightly nose-up equilibrium. Many systems are self-dampened to some extent if you don't push them too far, otherwise you can push the system to instability.
  • Just to complete the thought, with models generally being overpowered, we don't often relate speed to altitude control. Up elevator usually gets the job done just fine.
  • Real pilots can correct me if I'm wrong, but I believe with full scale aircraft power=lift, i.e. altitude is controlled with speed, particularly during landing approaches. Use of elevator at lower speeds to gain altitude can lead to stalls.
  • About waypoint definition - it would be nice to make some file parser from Google Earth's KML file. One would design path in Google Earth, and simply put it to chip.

    But the ATmega chip has no file system (to hold KML file), as well as limited memory, so entire executable needs to be rebuilt each time when waypoints change.

    Solution may be to develop a PC tool for converting KML file into C header file holding waypoints, and then rebuild AVR code (ideally automatically), so one would get new mission file from KML file by single click.
  • 3D Robotics
    @Michal. Good catch on the bug. Will delete applet folder, which keeps getting automatically generated for some reasons. Still a little fuzzy on using Subversion.
  • Bugs in code:
    1) in Servo_Control.pde, both pulse_servo_throttle and pulse_servo_yaw have bug in 1st statement:
    constrain(angle,180,0); makes simply nothing, should be:
    angle = constrain(angle,180,0);

    2) applet folder in google code repository seems to be redundant, since this is compiler-generated folder and files; I recommend to remove from cvs to avoid confusion

    3) I'm preparing the code for use in Microsoft Visual Studio (freeware Visual Studio edition is available here), and making it real C++ project. Anyone interested to get it, or maybe putting to official CVS? It should be backward compatible with Arduino IDE for non-Windows users.
  • Hi Chis,
    While were writing, i was doing the same, so i couldn't read...
    Thanks for the answer
    -e
This reply was deleted.