Hello, This is my first post so first off want to thank all the Guru's on here for their great knowledge. This is my first build of anything RC related. I reached the point of my project where searching went in circles and I need to ask for help. I will include as much information regarding my setup and my research results so far.
My setup:
DJI F450 frame/motor/ESC, Pixhawk controller (firmware AC3.2) with 3DR GPS module, Spectrum DX6 (PWM converter), 3DR telemetry, 3S 5000mAh. No camera or gimble setup. I'm using APM Planner 2.0 and recently installed version 2.0.15-rc5 for MAC.
Currently, the quad copter is successfully tuned in Acro and Stab modes. Alt hold however seems to want to climb vertically while I hold onto it in hand. This is kind of separate issue. I've been trying to install a an MB1020 LV MaxSonar EZ2 sensor for altitude and loiter hold. I found many posts about this, followed suggestions to use analog ADC3.3v input pin 2. I tried to use RSSI and set S.Bus as input A0. There are posts that mention setting input by "RNGFNDR_PIN" but there is no such variable in full parameters list. Also according to http://copter.ardupilot.com/wiki/sonar/ there should be a SONAR_PIN but this also does not exist in full parameter list. The only thing I can find is SONAR_ENABLE, SONAR_TYPE, and SONAR_GAIN. Also, under "Flight Data" in status tab, there are no parameters related to "sonar" or "range finder".
Just a tad bit. basically default code was using barometer and for indoor flights it was not at all close to good. So i did some hack to use sonar augmented data and well the results are in the video. Notice at 11:25 I switch from manual to alt hold and it just catches itself midair, :D
Since upgrading APM Planner to v2.0.15-rc5 I noticed the setup "optional" then "Range Finder" section is added. The option to select Sonar type (analog) works but nothing else seems to function on that page. There's even a nice box on the right for monitoring the current sonar readings (range, voltage).
Can someone please guide me to setup range finder setting correctly in APM or do I need to modify code like the video example? I appreciate any help and will do my best to document my results.
Cheers!
Dustin
Replies
This set of wiki pages has info on setting up the various sonars we support in AC3.1.5 and AC3.2 in case this helps.
Sorry for long post, but actually referenced the wiki links in my original post. Also I found most of the threads/discussions you participated in regarding this topic. Still, non of the parameters (ie: RNGFND_PIN, RNGFND_SCALING, etc) mentioned in wiki are found in my full parameter list or flight status.
Appreciate any help!
@Dustin,
It sounds like the issue is that the vehicle has AC3.1.5 on it or the AP Planner 2 isn't showing the parameters for AC3.2 for some reason. If you can download and attach a dataflash log i can tell you which version of arducopter is on the board.
Randy,
It works! You are right the wrong firmware was loaded to pixhawk. APM Planner says V3.1.5 when selecting "stable" version. Then if I select "Beta" then it changes to V3.2. However the actual v3.2 was not loaded. The issue was I had to select Arducopter-3.2 branch in Github application (MAC), then sync the branch. After that, reload "Beta" code on the copter and now it has all the "RNGFND" parameters discussed in the wiki links you shared. So now I can confirm sonar sensor is working with the convenient range/voltage reading under "initial setup" --> Range Finder.
Thank you for your support and quick response!
Dustin