Hi all,
for my internship I’m doing a project for autonomous indoor flight. I’m already familair with the Arduino, so that side is mostly covered. I have build a Quadcopter before, but that wasn’t as advanced as this.
http://ardupilot.org/copter/docs/common-pozyx.html
The project so far:
Setup and configured the Pozyx beacons and tag.
Updated beacons and tag refresh rate to high, so I don’t have the EKF_IMU failed error all the time.
Changed all the parameters in Mission Planner.
I currently have my PixHawk 2.4.8 with foam on the PCB, where a lot of wires are placed underneath from the motors and power module with BEC. Beside that I’m using the enternal compass of the PixHawk. If I check my auto analysing report it says the following message:
Size (kb) 2649.48046875
No of lines 32375
Duration 0:00:00
Vehicletype ArduCopter
Firmware Version V3.6.8
Firmware Hash 2f409678
Hardware Type
Free Mem 0
Skipped Lines 0
Test: Autotune = UNKNOWN - No ATUN log data
Test: Brownout = GOOD -
Test: Compass = WARN - WARN: Large compass offset params (X:134.30, Y:-277.60, Z:-46.40)
WARN: Large compass offset in MAG data (X:134.00, Y:-277.00, Z:-46.00)
Moderate change in mag_field (31.80%)
Test: Dupe Log Data = GOOD -
Test: Empty = GOOD -
Test: Event/Failsafe = FAIL - ERR found: GPS_GLITCH
Test: GPS = UNKNOWN - No GPS log data
Test: IMU Mismatch = UNKNOWN - ‘GPS’
Test: Motor Balance = GOOD - Motor channel averages = [1328, 1326, 1365, 1364]
Average motor output = 1345
Difference between min and max motor averages = 39
Test: NaNs = FAIL - Found NaN in CTUN.TAlt
Found NaN in CTUN.DSAlt
Test: OpticalFlow = FAIL - FAIL: no optical flow data
Test: Parameters = FAIL - ‘THR_MIN’ not found
Test: PM = GOOD -
Test: Pitch/Roll = GOOD -
Test: Thrust = GOOD -
Test: VCC = UNKNOWN - No CURR log data
The large compass offset warning worries me, because I think its partially responsible for the drone behaviour. The drone dives down when I try to loiter. This was during my third real testflight. At my second testflight, I had the compass variance error, but that disappeared after another compass calibration. In the meantime the test location has changed into another corner of the hangar. Where I had to replace the anchors/beacons and drone cage (made of truss). I figured that I could change the altitude of the beacons to have better coverage. Also I turned the beacons with the antenna’s pointing up. Also I reconfigured all he parameters of the beacons in mission planner and in the arduino.
I also “set EKF Origin here” into the map. My “fake” GPS/ GeoLocation returned into the screen. Checked my gauges before flight, especially the compass gauge had strange behaviour. It sometimes turned the wrong way entirely, but after a while it seemed it re-established itself by making the right calculations. Ok, was ready for a flighttest and armed my which gave me the following messages:
“EKF3 IMU1 in-flight yaw alignment complete
EKF3 IMU0 in-flight yaw alignment complete
EKF3 IMU0 ground mag anomaly, yaw re-aligned
EKF3 IMU0 in-flight yaw alignment complete
EKF3 IMU1 in-flight yaw alignment complete
EKF3 IMU1 ground mag anomaly, yaw re-aligned
EKF3 IMU0 ground mag anomaly, yaw re-aligned
EKF3 IMU0 in-flight yaw alignment complete
EKF3 IMU1 in-flight yaw alignment complete
PreArm: Hardware safety switch
PreArm: Hardware safety switch
PreArm: Hardware safety switch
PreArm: Throttle below Failsafe
PreArm: Hardware safety switch
PreArm: Throttle below Failsafe
PreArm: Hardware safety switch
PreArm: Throttle below Failsafe
GPS Glitch
EKF3 IMU0 initial beacon pos D offset = 1.1 (m)
EKF3 IMU0 initial pos NE = -9.9,4.6 (m)
EKF3 IMU0 is using range beacons
EKF3 IMU1 initial beacon pos D offset = 1.1 (m)
EKF3 IMU1 initial pos NE = -9.9,4.5 (m)
EKF3 IMU1 is using range beacons
PreArm: Hardware safety switch
PreArm: Throttle below Failsafe
Frame: QUAD
Pixhawk1 00310019 3138510E 35363631
ChibiOS: d2030d88
ArduCopter V3.6.8 (2f409678)”
During the flight we have been checking the altitude on the bottom screens and the z-axis seemed way of, sometimes it was over 3meters, while the the cage height is max. 3 meters high. When we tried to loiter it went into a dive and my colleague who was piloting had to safe it.
The compass had some spikes when we turned up the throttle.
Also it seems that my arduino gets powered from time to time by the motors. For example before arming we checked the ESC’s which were getting warm, this is behaviour you normally don’t want. But after digging into a little further in the Ardupilot documentation we understood when the arduino drains power from there, when there is not enough at his main power supply. Hmmm not much harm done there, but we are thinking of another solution for that matter. our main priority is the compass. Monday we are testing it again with more room between the controllers and the cables. If we have compass issues by the, we are going to use an external compass instead. To be sure I’m getting it at the right end, I thought of sharing my .tlog file and maybe you guys can tell me something what we have overlooked.
Kind regards,
Sander