A group to discuss the many ways to edit and compile the code for the Ardupilot Mega!

604 Members
Join Us!

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

Join diydrones

Comments are closed.

Comments

  • @david ramo, you need mission planner to load arduplane firmware on APM (ardupilot mega).

    ->Open mission planner

    -> Connect your APM board through telemetry, USB or zigbee but don't click on Connect button in Mission Planner yet.

    ->Goto Initial Setup Tab page

    ->Click on Ardu Plane firmware 

    ->Confirm yes

    You can manually add it too by first downloading latest firmware from http://firmware.diydrones.com/Plane/ and using Load Custom Firmware option present in right bottom corner of the Initial setup page. 

  • how to apply arduplane on arduino mega ??

  • hello guys, i would like to connect arduino mega to apm through i2c port. in which the mega will be slave and the apm will be master. any suggestion please?

  • Developer
    @AntoineL: post your question here https://groups.google.com/forum/m/#!forum/drones-discuss, its where the APM devs discuss developement topics. I'm sure we can help get your Library working
    Google Groups
    Google Groups allows you to create and participate in online forums and email-based groups with a rich experience for community conversations.
  • Hi Guys, 

    I've been working for a few days on implementation of CMUcam PIXY to Ardupilot. I have created AP_PIXY library which is available in my GIthub (here) and based on the original Pixy's arduino library  (here).

    My objectif is to use the Pixy as an "optical flow" to allow a copter to hover precisely over a target, to land precisely on it or event to recognise color codes and do actions accordingly.

    The library works well when I compile the "AP_PIXY_test.pde" example to my APM2.5 through the arduino IDE for Ardupilot.

    My problem is when I try to add it to the main code. When I just include all the files there is no problem and the APM works fine. But when I try to define a variable in the UserVariables.h such as : "static AP_OpticalFlow_PIXY Pixy_Flow" the APM doesn't work. It compiles with no errors but the APM doesn't restart, no lights are ON exept the "Alive" one. I've uncomment the "#define USERHOOK_VARIABLES UserVariables.h" in AP_Config.h and disabled the optical flow through "#define OPTFLOW DISABLED" . Nothing else was changed.


    what am I suppose to do to make it work? What are my errors?

    Thanks,

    Antonie

    Pixy (CMUcam5): a fast, easy-to-use vision sensor
    Pixy is a fast vision sensor you can quickly “teach” to find objects, and it connects directly to Arduino and other controllers.
  • Developer

    @Antonie,

         For arducopter you'll need a minimum of 4hz.  5hz is best though.  1hz definitely won't work I'm afraid.  Inertial nav will get very upset.

  • Thanks, Randy. Would it take the NMEA strings at 5Hz as the binary or is 1Hz OK?

    RE dual sensors - how are these managed? Are they identical sensors as the on-board IMU's managed through the I2C port or would other sensors be considered?

  • Developer

    @Antonie,

         Those are some big questions and I can't answer them all.

         For the NMEA messages you can find our NMEA driver here.  It seems to be looking for 3 specific messages, GPRMC, GPGGA and GPVTG.  I've never looked at the nmea driver before though.

         Re the IMU, the driver for each accel/gyro chip should convert the output to deg/sec for the gyro or m/s/s for the accelerometer.  In other parts of the code we deal in centi-deg/sec or centimeters/s/s but I don't think that's the case for the IMU sensors.

         Re multiple sensors, we're extending the AC/AP software so that it makes use of the extra sensors (dual-gyro, dual accel, dual compass even dual GPS) on the Pixhawk for AC3.2 and the latest version of plane already support this (except the dual-gps).  My guess is that instead of offloading the attitude processing it makes more sense to offload the higher level navigation processing to a separate processor.  I think this because the communication overhead of pushing all that data around is probably quite high.  Better to keep the attitude processing very close to the IMU.

  • Hi Guys, I have a question around the NMEA GPS input stream and the IMU sensor - I apologise if these have been covered, I cant find the answers I'm after.

    Firstly, there are many NMEA strings in the NMEA definition, it is not a single string that is generated, but can be a vast amount of string. This depends on the activated requirements on your GPS receiver. Here's my question - what are the minimum NMEA string specs that APM need to function properly and at what rate are these required(Hz)?

    Secondly, the IMU sensor. Are there standardised units of measure for the sensors on IMU's(Accel, Gyro, Mag, Baro). As GPS position is generally defined with a degree lat and long, is there a similar definition for IMU's? If so, would it be possible to adopt such a philosophy with the APM development - allow the attitude to be streamed to the flight controller via a port instead of using the on-board sensors. The benefits in having this would be:

    1. Moving the attitude processing off the flight controller.

    2. Multiple IMU's can be used to improve accuracy and have sensor redundancy. Continuous health polling with reading averaging and standard deviation testing before feeding to the filter can be managed by a attitude processor and a clean attitude stream can be fed to the main flight controller.

    Thanks,

    Antonie   

  •  Hello, Shyam

    You may look at this for information

    http://diydrones.com/group/learning-to-program-the-ardupilot-mega/f...

This reply was deleted.

Getting mission status on UserCode.cpp

Hello, everyone!I'm trying to count how many waypoints has my drone visited and if the mission has been sucessfully finished, and for that I'm planning on writing my code on the UserCode.cpp file, but I don't know if I can define some library to extract that data from, or if I should go directly to the EEPROM, or if I can declare my own parameters and read from them somehow... What is the "good practices" way to do this? Thanks in advance.

Read more…
0 Replies

Generate remote control commands from Arduino

Hello. We are currently working on a drone for a university project work. It is quadcopter and flight controller is APM 2.5. The point of the project is to implement A* algorithm (finding short path on a discretized terrain). So the flight of the drone should be described in advance according to algorithm work results, sent from GCS via a protocol (Mavlink I guess).THE QUESTION IS - is it possible to exctract what remote control sends (when drone is told to go forward, for instance), generate…

Read more…
1 Reply

MAVLink Manual Control via Arduino / Teensy

hi @all,Inspired on Burkards Sonar Boat project i want to build my own Sonar Boat. We have some discussion to implement the MAVLink functionality and use a APM or Pixhawk with ardurover firmware.Burkard has developed a little remote with a OLED to get some information live from the Boat. This remote has a 5 Way Switch (Joystick) to control manual...A 3DR Ground Modul, a five way switch and a Oled are connected to a Teensy (Teensyduino) So far so good :)I try to implement the MAVLink Protocol to…

Read more…
0 Replies