8
I Use This!
Activity Not Available

News

Analyzed 3 months ago. based on code collected 3 months ago.
Posted over 3 years ago by rmackay9
https://www.youtube.com/embed/V8N3lA-20fs I’d like to share the results of an autonomous boat project I’ve been working on with AttracLab, Shimane University and a company called Lighthouse. This project is sponsored by DeSET and the ... [More] Nippon Foundation which promotes technologies to assist with their goal of mapping all the world’s oceans by 2030 with a resolution of at least one depth reading per 100m x 100m square. Currently only about 20% of the ocean has been mapped to this level of detail. The more specific goal of my team (Team2) is to lower the barrier to entry of creating drone boats. I’m not trying to sell this boat, instead it is a prototype to prove what is possible and provide a reference frame so others can replicate it. Here are some details: Frame provided by AttracLab and is about 185cm x 30cm x 80cm and is made from FRB. I wish this frame were readily available for anyone to buy but at least for the moment the original manufacturer (who is not AttracLab) needs convincing that there is enough demand for this exact frame before they produce more of them Power comes from a Torqeedo 1003c electric motor which produces about 2HP. There are two supported battery configurations, either the 0.915kWh Torqeedo battery that comes with the motor or 6x Panasonic ebike batteries (2.4kWh total) Hondex HS-E8 sonar with 200m range and custom firmware (provided by Hondex) to provided depth and backscatter data over NMEA. Surprisingly this sonar’s NMEA interface normally only provides the GPS data so I would recommend to anyone replicating this setup to use one of the other sonars ArduPilot supports The autopilot is a Cube Gold (same as CubeOrange) running ArduPilot Rover-4.2.0-DEV Telemetry and manual control is via HereLink Mission Planner was used for checking on the vehicle’s status in real-time, mission planning and moving the vehicle around in Guided mode We tested this boat for four days in Okinoshima Japan and it all went surprisingly smoothly. 73km of sea floor was mapped (measured by how far the boat traveled) which was totally acceptable considering the daily time constraints and that this was the first time the boat had touched salt water. Below is a the result after the data was processed by ReefMaster. Some impressions and things we learned during testing: Despite its higher cost, I’m very happy we switched from the original gas engine to the Torqeedo. Beyond its linear feedback, quiet operation and low “fueling” costs, this motor provides tons of information including RPM, voltage, current and any errors and the new AP driver takes advantage of this to keep the overall system working reliably while also keeping the pilot informed of what’s going on. The only thing I don’t like about the motor is the 2 or 3 seconds of lag when it first starts rotating. I’ve heard this is to protect the motor from a sudden increase in current but I’ve never seen another electric motor/ESC combo require this and it makes the speed control more difficult when the vehicle first starts moving. Still, I highly recommend using the Torqeedo over a simple DC motor or gas engine. Boats with displacement hulls consume a lot of energy at high speeds! Below is a rough graph produced from a back-and-forth test at various speeds with a half depleted battery (so it’s not super accurate). The increase in consumption above 2.0m/s (7.2km/h) was especially noticeable and we eventually settled on 1.8m/s (6.5km/h) as the best balance between energy consumption vs time available. I.e. too fast and you run out of battery, too slow and you run out of time. The boat handled rough conditions very well but its yaw control was worse than expected when traveling downwind. I suspect the problem is the throttle output was very low and the default motor thrust scaling does not match the nearly linear thrust of the motor. This frame is incredibly agile, probably more than is really required of a mapping boat that spends most of its time traveling in straight lines. A catamaran hull might have been a better choice because while not as agile it might be more efficient. Of course we hit some small issues during the week that we hope to resolve in the near-ish future: The boat’s mid and aft hatches are screwed down instead of being hinged meaning it requires a drill and a few minutes to open or close On Day2, one of the Panasonic ebike batteries shut down while the vehicle was being aggressively driven in Manual mode. The boat kept going and in fact we didn’t notice the failure until the end of the day but it meant the capacity for that day was only 2kWh instead of 2.4kWh. In general I like these batteries because they are a good size (0.4kWh each), easy to carry, easy to buy and easy to charge. They also have built in safety features like short-circuit protection but the flip side is they shutdown if the current draw increases too rapidly or the overall current flow is too high. Also because they don’t provide a digital interface there is no way to directly know if they have failed. The Panasonic batteries have a lower voltage (28V) than the Torqeedo batteries (32V) meaning the vehicle’s top speed is slightly lower than it could be. This issue is especially pronounced after the batteries start getting low. Finding an alternative battery of 32V seems nearly impossible but the Torqeedo motor appears to be able to accept up to 40V (only bench tested) so some other 36V batteries may be a good option (Makita power tool batteries maybe?). IMU Gyro calibration (run automatically soon after startup) often fails on boats if they’re already in the water (see issue here) Rover firmware support for DO_LAND_START mission commands would have made returning to “home” easier than using Guided mode or manually advancing the mission to the last few waypoints. ArduPilot’s support for boats is already quite good but here are some ways it will improve further: SCurve support for Rovers and Boats. This should improve cornering and allow reducing the aggressiveness of the corners by simply increasing the WP_RADIUS parameter Add support for the larger Torqeedo motors which use a CAN interface Add support for the ePropulsion motors. By the way if anyone has a contact at ePropulsion I would like to talk with them about how to get details of the protocol they use. Improved object avoidance using 3D AI cameras (like the OAK-D), radar or underwater scanning sonar Support side scan sonar I’d also like to replace this frame’s steering system with a 3D printed alternative so that others can more easily integrate the Torqeedo into their frames. The start of a design is here. … and finally eventually I’d like to add solar panels to improve range. This should actually be quite easy if the Torqeedo battery is used (just plug the panel in) but it is not clear to me how to do it if other batteries are used. All feedback and advice is greatly appreciated! 11 posts - 2 participants Read full topic [Less]
Posted over 3 years ago by rmackay9
https://www.youtube.com/embed/V8N3lA-20fs I’d like to share the results of an autonomous boat project I’ve been working on with AttracLab, Shimane University and a company called Lighthouse. This project is sponsored by DeSET and the ... [More] Nippon Foundation which promotes technologies to assist with their goal of mapping all the world’s oceans by 2030 with a resolution of at least one depth reading per 100m x 100m square. Currently only about 20% of the ocean has been mapped to this level of detail. The more specific goal of my team (Team2) is to lower the barrier to entry of creating drone boats. I’m not trying to sell this boat, instead it is a prototype to prove what is possible and provide a reference frame so others can replicate it. Here are some details: Frame provided by AttracLab and is about 185cm x 30cm x 80cm and is made from FRB. I wish this frame were readily available for anyone to buy but at least for the moment the original manufacturer (who is not AttracLab) needs convincing that there is enough demand for this exact frame before they produce more of them Power comes from a Torqeedo 1003c electric motor which produces about 2HP. There are two supported battery configurations, either the 0.915kWh Torqeedo battery that comes with the motor or 6x Panasonic ebike batteries (2.4kWh total) Hondex HS-E8 sonar with 200m range and custom firmware (provided by Hondex) to provided depth and backscatter data over NMEA. Surprisingly this sonar’s NMEA interface normally only provides the GPS data so I would recommend to anyone replicating this setup to use one of the other sonars ArduPilot supports The autopilot is a Cube Gold (same as CubeOrange) running ArduPilot Rover-4.2.0-DEV Telemetry and manual control is via HereLink Mission Planner was used for checking on the vehicle’s status in real-time, mission planning and moving the vehicle around in Guided mode We tested this boat for four days in Okinoshima Japan and it all went surprisingly smoothly. 73km of sea floor was mapped (measured by how far the boat traveled) which was totally acceptable considering the daily time constraints and that this was the first time the boat had touched salt water. Below is a the result after the data was processed by ReefMaster. Some impressions and things we learned during testing: Despite its higher cost, I’m very happy we switched from the original gas engine to the Torqeedo. Beyond its linear feedback, quiet operation and low “fueling” costs, this motor provides tons of information including RPM, voltage, current and any errors and the new AP driver takes advantage of this to keep the overall system working reliably while also keeping the pilot informed of what’s going on. The only thing I don’t like about the motor is the 2 or 3 seconds of lag when it first starts rotating. I’ve heard this is to protect the motor from a sudden increase in current but I’ve never seen another electric motor/ESC combo require this and it makes the speed control more difficult when the vehicle first starts moving. Still, I highly recommend using the Torqeedo over a simple DC motor or gas engine. Boats with displacement hulls consume a lot of energy at high speeds! Below is a rough graph produced from a back-and-forth test at various speeds with a half depleted battery (so it’s not super accurate). The increase in consumption above 2.0m/s (7.2km/h) was especially noticeable and we eventually settled on 1.8m/s (6.5km/h) as the best balance between energy consumption vs time available. I.e. too fast and you run out of battery, too slow and you run out of time. The boat handled rough conditions very well but its yaw control was worse than expected when traveling downwind. I suspect the problem is the throttle output was very low and the default motor thrust scaling does not match the nearly linear thrust of the motor. This frame is incredibly agile, probably more than is really required of a mapping boat that spends most of its time traveling in straight lines. A catamaran hull might have been a better choice because while not as agile it might be more efficient. Of course we hit some small issues during the week that we hope to resolve in the near-ish future: The boat’s mid and aft hatches are screwed down instead of being hinged meaning it requires a drill and a few minutes to open or close On Day2, one of the Panasonic ebike batteries shut down while the vehicle was being aggressively driven in Manual mode. The boat kept going and in fact we didn’t notice the failure until the end of the day but it meant the capacity for that day was only 2kWh instead of 2.4kWh. In general I like these batteries because they are a good size (0.4kWh each), easy to carry, easy to buy and easy to charge. They also have built in safety features like short-circuit protection but the flip side is they shutdown if the current draw increases too rapidly or the overall current flow is too high. Also because they don’t provide a digital interface there is no way to directly know if they have failed. The Panasonic batteries have a lower voltage (28V) than the Torqeedo batteries (32V) meaning the vehicle’s top speed is slightly lower than it could be. This issue is especially pronounced after the batteries start getting low. Finding an alternative battery of 32V seems nearly impossible but the Torqeedo motor appears to be able to accept up to 40V (only bench tested) so some other 36V batteries may be a good option (Makita power tool batteries maybe?). IMU Gyro calibration (run automatically soon after startup) often fails on boats if they’re already in the water (see issue here) Rover firmware support for DO_LAND_START mission commands would have made returning to “home” easier than using Guided mode or manually advancing the mission to the last few waypoints. ArduPilot’s support for boats is already quite good but here are some ways it will improve further: SCurve support for Rovers and Boats. This should improve cornering and allow reducing the aggressiveness of the corners by simply increasing the WP_RADIUS parameter Add support for the larger Torqeedo motors which use a CAN interface Add support for the ePropulsion motors. By the way if anyone has a contact at ePropulsion I would like to talk with them about how to get details of the protocol they use. Improved object avoidance using 3D AI cameras (like the OAK-D), radar or underwater scanning sonar Support side scan sonar I’d also like to replace this frame’s steering system with a 3D printed alternative so that others can more easily integrate the Torqeedo into their frames. The start of a design is here. … and finally eventually I’d like to add solar panels to improve range. This should actually be quite easy if the Torqeedo battery is used (just plug the panel in) but it is not clear to me how to do it if other batteries are used. All feedback and advice is greatly appreciated! 4 posts - 2 participants Read full topic [Less]
Posted over 3 years ago by rmackay9
Here are the slides from the monthly report for Nov 2021 presented by Tridge, Randy and a couple of other developers at this month’s Partners call. The image on the left is of Robert Gogloza’s impressively highquality quadplane while ... [More] the image on the right is of Holybro’s S500 frame that comes pre-loaded with ArduPilot. As always, thanks to our Partners for their support! 3 posts - 3 participants Read full topic [Less]
Posted over 3 years ago by rmackay9
Here are the slides from the monthly report for Nov 2021 presented by Tridge, Randy and a couple of other developers at this month’s Partners call. The image on the left is of Robert Gogloza’s impressively highquality quadplane while ... [More] the image on the right is of Holybro’s S500 frame that comes pre-loaded with ArduPilot. As always, thanks to our Partners for their support! 1 post - 1 participant Read full topic [Less]
Posted over 3 years ago by tridge
There have been some significant changes in the way github handles submodules that have impacted the ArduPilot project. The changes are described in this github blog post: The GitHub Blog – 1 Sep 21 ... [More] Improving Git protocol security on GitHub | The GitHub Blog We’re changing which keys are supported in SSH and removing unencrypted Git protocol. If you’re an SSH user, read on for the details and timeline. Est. reading time: 6 minutes What I’ll describe below is how this impacts ArduPilot and how you can fix your developer checkouts of ArduPilot to avoid the problem. The git:// protocol One of the earliest protocols supported by the git version control system was the git:// protocol. It is a read-only protocol and doesn’t require any authentication. ArduPilot made extensive use of the git:// protocol for submodules (repositories of code that ArduPilot depends on and are included in ArduPilot via a submodule reference). We used the git:// protocol because at the time we created these submodules github had very poor access control granularity, so if we wanted a developer to be able to label pull requests then we had to give them full write access. For developers who were new to git this was risky as a mistake in a git command could do a lot of damage. By using the git:// protocol the user was less likely to do accidental damage as the submodules were read-only until they explicitly changed them to read-write. What Happened As of yesterday github intermittently stopped supporting the git:// protocol via a deliberate set of “brownouts” designed to force projects to change to the https:// protocol. This resulted in a lot of failed CI jobs, and developers unable to work with their existing git clones. It also impacts all our old stable branches. These brownouts will become permanent next year (see the link at the top of this post for a schedule). What have we done We have applied patches to the master branch and the stable 3.6, 3.9, 4.0 and 4.1 branches to change our git submodules to use the https:// protocol. That avoids the issue but leaves vendors and developers who have their own branches with the issue still happening. You will know if you have the issue as you will get messages like this: The key line is this “The unauthenticated git protocol on port 9418 is no longer supported”. Quick FIx The quick fix is to configure git to automatically use https:// whenever it goes to use the git:// protocol. You can do that by running this command: git config --global url.https://github.insteadOf git://github what that will do is add the following to your .gitconfig file in your home directory: [url "https://github"] insteadOf = git://github This fix is great for individual developers. For a more complete fix which applies to your whole dev team see the next section. Fixing your branches If you have a git checkout of either your own branch or one of the ArduPilot stable branches then you can fix it by applying a single patch then running a “sync” script to fix your submodules. The patches you need are in the following pull requests: git: changed submodule protocols to https:// for master by tridge · Pull Request #19109 · ArduPilot/ardupilot · GitHub git: changed to https git protocol for copter4.1 by tridge · Pull Request #19118 · ArduPilot/ardupilot · GitHub git: changed to https protocol for plane 4.1 by tridge · Pull Request #19111 · ArduPilot/ardupilot · GitHub git: changed protocol to https for copter-4.0 by tridge · Pull Request #19113 · ArduPilot/ardupilot · GitHub git: changed protocol to https for copter-4.0 by tridge · Pull Request #19113 · ArduPilot/ardupilot · GitHub git: changed to https git protocol for plane3.9 by tridge · Pull Request #19114 · ArduPilot/ardupilot · GitHub git: changed to https git protocol for Copter-3.6 by tridge · Pull Request #19115 · ArduPilot/ardupilot · GitHub You can “cherry pick” the last patch from the appropriate branch in those PRs to fix the issue. submodule sync script After applying the patch you need to run this script: Tools/gittools/submodule-sync.sh which will run the git submodule sync command to fix your checkout. 6 posts - 2 participants Read full topic [Less]
Posted over 3 years ago by TomSeymour
https://www.youtube.com/embed/1oxTu_hO5wE The build process for my robot is now underway, starting with the unboxing video and a little introduction to some of its parts: Up next will be the assembly video and hopefully not too long ... [More] after that I’ll have some footage of the rover in action using standard RC. Previous post: Project: Rough terrain navigation using Deep Reinforcement Learning Part 1 Blog [tom-seymour-drlp1-image] Hi everyone, I am an Australian Mechatronics Engineering Student and kicking off the project for my undergraduate thesis. I’ll be incorporating Autopilot rover to control an eight wheeled rough terrain robot and develop a Deep Reinforcement Learning algorithm to train the robot to choose the optimal path when navigating in challenging environments like rubble. The plan is to use a standard GPS module to control the robot during normal operation and a RealSense depth … Hope everyone enjoys, Tom. 2 posts - 2 participants Read full topic [Less]
Posted over 3 years ago by TomSeymour
The build process for my robot is now underway, starting with the unboxing video and a little introduction to some of its parts:https://www.youtube.com/embed/1oxTu_hO5wE Up next will be the assembly video and hopefully not too long ... [More] after that I’ll have some footage of the rover in action using standard RC. Previous post: Project: Rough terrain navigation using Deep Reinforcement Learning Part 1 Blog [tom-seymour-drlp1-image] Hi everyone, I am an Australian Mechatronics Engineering Student and kicking off the project for my undergraduate thesis. I’ll be incorporating Autopilot rover to control an eight wheeled rough terrain robot and develop a Deep Reinforcement Learning algorithm to train the robot to choose the optimal path when navigating in challenging environments like rubble. The plan is to use a standard GPS module to control the robot during normal operation and a RealSense depth … Hope everyone enjoys, Tom. 1 post - 1 participant Read full topic [Less]
Posted over 3 years ago by TomSeymour
https://www.youtube.com/embed/1oxTu_hO5wE The build process for my robot is now underway, starting with the unboxing video and a little introduction to some of its parts: Up next will be the assembly video and hopefully not too long ... [More] after that I’ll have some footage of the rover in action using standard RC. Previous post: Project: Rough terrain navigation using Deep Reinforcement Learning Part 1 Blog [tom-seymour-drlp1-image] Hi everyone, I am an Australian Mechatronics Engineering Student and kicking off the project for my undergraduate thesis. I’ll be incorporating Autopilot rover to control an eight wheeled rough terrain robot and develop a Deep Reinforcement Learning algorithm to train the robot to choose the optimal path when navigating in challenging environments like rubble. The plan is to use a standard GPS module to control the robot during normal operation and a RealSense depth … Hope everyone enjoys, Tom. 3 posts - 2 participants Read full topic [Less]
Posted over 3 years ago by rmackay9
Here are the slides from the monthly report for Oct 2021 presented by Tridge, Randy and a couple of other developers at this month’s Partners call. The image on the left is one of ModalAI’s autopilot’s which we have added support for. ... [More] ModalAI also recently joined as a partner so we thank them for their support! The image on the right is from Think Flight’s efficiency testing of wingtip vs mid-wing motors (using AP of course). As always, thanks to our Partners for their support! It really is quite encouraging to see so many companies using AP and contributing to its progress! We really appreciate it! 1 post - 1 participant Read full topic [Less]
Posted over 3 years ago by andyp1per
https://www.youtube.com/embed/nYLTNbcP9sY I do a lot of smaller copter tuning and I know it’s hard. In fact many of the features I have developed have been primarily targeted at making smaller copters work better - why should BetaFlight ... [More] have all the fun. I therefore proposed to the investment committee that I do a series of standard builds so that people could basically copy the setup and quickly and easily get a really great ArduCopter experience. This is the result. The meat of the content is contained in a series of youtube videos that I will describe here. Parts list: iFlight Titan Chimera7 LR XING 2806.5 1300KV Motor x4 Lumenier LUX H7 HD Ultimate / Matek H743 Slim TBS UNIFY 5G8 PRO32 HV TBS Tracer RX Gemfan 7040 x4 RunCam Phoenix 2 JB Edition Matek M8Q-5883 TBS Triumph Pro LR TBS Tracer Sleeve Dipole x2 T-Motor F55A F3 Pro II 4-in-1 ESC Turnigy Graphene Panther 3000mAh 6S 75C Final tune here: Chimera7-Tuned4.1-FinalCutPro.param (25.7 KB) 1. Intro and Unboxing The first video at the top is unboxing the iFlight Chimera 7 frame, Matek M8Q-5883 GPS, T-motor F55A PRO II F3 4-in-1 ESC and Lumenier LUX H7 HD Ultimate Flight Controller 2. Base plate assembly Building the Chimera 7 base plate assembly https://www.youtube.com/embed/c7jRhLVUGgY 3. Frame and component placement Upper frame assembly of the Chimera7 and a dry run of component placement so that the cable runs can be of the right length and are connected to the right points on the flight controller. https://www.youtube.com/embed/YoH9haTBWjs 4. Initial firmware load Initial ArduCopter firmware load on the Lumenier Lux HD H7 using dfu-util and Mission Planner http://dfu-util.sourceforge.net/releases/ github.com ardupilot/Tools/bootloaders at master · ArduPilot/ardupilot master/Tools/bootloaders ArduPlane, ArduCopter, ArduRover, ArduSub source. Contribute to ArduPilot/ardupilot development by creating an account on GitHub. FRAME_TYPE=1 https://www.youtube.com/embed/BzkUALGgZ8Q 5. ESC setup Wiring and configuration of the T-Motor F55A F3 Pro II ESCs getfpv-media.s3.amazonaws.com LUX-H7-User_Manual_v1.pdf 7.39 MB SERIAL5_PROTOCOL=16 # ESC telemetry PWM_TYPE=6 # DShot600 SERVO_BLH_AUTO=1 # BLHeli passthrough Use BLHeliSuite to make sure BLHeli32 32.8 or later is installed SERVO_DSHOT_ESC=1 # DShot commands NTF_LED_TYPES=2305 # DShot LEDs https://www.youtube.com/embed/Zna8GFNMt3I 6. Flight Controller and Peripheral Wiring Wiring all the peripherals (GPS, Camera, VTX, Tracer) to the flight controller https://www.youtube.com/embed/TAWyA3lqSrM 7. Peripheral configuration Configuring all of the peripherals with Mission Planner Put the VTX into CRSF mode, could also use AgentX to configure team-blacksheep.com tbs-unify-pro32-manual.pdf 3.29 MB Put the camera into UART control mode https://shop.runcam.com/runcam-phoenix-2/ Use AgentX to configure Tracer outputs 1(TX) & 2(RX) and 3(RX) & 4(TX) as CRSF, switch to 12-channel mode and update RX Configure serial ports: SERIAL1_PROTOCOL=23 # RC input (UART7) SERIAL3_PROTOCOL=5 # GPS (UART2) SERIAL2_PROTOCOL=26 # RunCam (UART1) CAM_RC_TYPE=1 # RunCam 5-key OSD camera Calibrate radio and compass https://www.youtube.com/embed/2JrM_cd9VCA 8. VTX and Yaapu configuration Configuring VTX power and Yaapu telemetry passthrough Setup VTX to be controlled by flight controller (RX) VTX_ENABLE=1 # VTX control RC11_OPTION=94 # VTX power RC_OPTIONS=288 # Yaapu passthrough https://www.youtube.com/embed/SfxYJ3-TrDw 9. GPS, VTX and camera mounting Mounting the GPS, VTX and Camera to the Chimera 7 frame https://www.youtube.com/embed/xDvsxZsIsIk 10. Power train unboxing and plan Unboxing the 6S 3000mAh 75C battery, iFlight 2806.5 1300KV motors and planning the motor and ESC installation. Neopixel and buzzer installation. https://www.youtube.com/embed/sbWxodTsXrw 11. Motor dry mount ESC pigtail soldering. 6S power test. Fixing motors temporarily to enable soldering. https://www.youtube.com/embed/69VxJarOneQ 12. Motor soldering and motor test Soldering the motors to the ESCs and then testing the motors https://www.youtube.com/embed/jkBOygnBFWI 13. Final frame assembly Conformal coating of exposed connections. Heatshrink protection of tracer and installation of immortal T antenna. Final installation of ESCs, motors, flight controllers and peripherals into the frame. Addition of foam to protect barometer. See video 22 for antenna adjustments using sleeve dipoles for much better radio range https://www.youtube.com/embed/oPvx06cBvWI 14. Initial configuration, ready to arm Reset level in mission planner. Configured custom compass orientation setup and calibration: COMPASS_CUS_YAW=180 # custom compass yaw of 180 COMPASS_CUS_PIT=-15 # custom compass pitch of -15 COMPASS_ORIENT=100 # custom compass orientation COMPASS_AUTO_ROT=0 # turn off compass auto rotation Performed a compass calibration and checked that EKF status indicator in mission planner did not get too high. Checked motor order and direction and configured correctly by setting frame type to betaflight: FRAME_TYPE=12 # set motor order to betaflight/X SERVO_BLH_RVMASK=6 # reverse motor channels 2 and 3 Radio calibration. Setup motor emergency stop, initial flight modes and radio failsafe: RC9_OPTION=31 # motor estop FLTMODE1=1 # acro mode FLTMODE5=2 # althold mode FLTMODE6=16 # poshold mode FS_THR_ENABLE=3 # land on radio failsafe SD card installation. First arming and motor test checking that MOT_SPIN_MIN/MOT_SPIN_ARM is low enough: MOT_SPIN_MIN=0.03 # minimum output when throttle raised MOT_SPIN_ARM=0.02 # output when armed Verify motor emergency stop. https://www.youtube.com/embed/boxFANhwvdo 15. Current Calibration and Bi-Directional DSHOT Setup Calibrate current sensor using an in-line ammeter. Set BAT_AMP_PERVLT. Setup bi-directional dshot using SERVO_BLH_BDMASK. Reduce SERVO_BLH_TRATE since rpm information is now coming from bi-directional dshot. Update - my friend @juzzle1 kindly did a proper full range current calibration of the ESC and flight controller and came up with a very linear response: The updated settings are given below. Note that the offset means that the current sensor always reads 2.3A at zero throttle, but the rest of the response is very good. BAT_AMP_PERVLT=52.706 # better current estimate BATT_AMP_OFFSET=-0.04308 SERVO_BLH_BDMASK=15 # enable bi-directional dshot on all four channels SERVO_BLH_TRATE=5 # lower telemetry update rate https://www.youtube.com/embed/R2YyDseBDQI 16. Initial tune and notch configuration Initial tune setup using Mission Planner setup wizard (Alt-A). Checking INS_GYRO_FILTER and ATC_RAT_RLL/PIT_FLTD. Check initial PIDs and enable the harmonic notch filter using ESC telemetry. INS_HNTCH_ENABLE set and INS_HNTCH_MODE to ESC telemetry. Make sure harmonic notch ratio of INS_HNTCH_FREQ amd INS_HNTCH_BW is correct. Set INS_HNTCH_REF. Setup INS_HNTCH_OPTS to track individual motors and loop rate. Increase SCHED_LOOP_RATE. Set SERVO_DSHOT_RATE to multiple of loop rate. BATT_ARM_VOLT=22.1 # 6S setup BATT_CRT_VOLT=21 # 6S setup BATT_LOW_VOLT=21.6 # 6S setup MOT_BAT_VOLT_MAX=25.2 # 6S setup MOT_BAT_VOLT_MIN=19.8 # 6S setup MOT_THST_EXPO=0.6 # expo for 7" props INST_GYRO_FILTER=70 # gyro filter for 7" copter ATC_RAT_RLL_FLTD=35 # d-term filter for 7" copter ATC_RAT_PIT_FLTD=35 # d-term filter for 7" copter INS_FAST_SAMPLE=3 # fast sampling on both IMUs INS_HNTCH_ENABLE=1 # harmonic notch on INS_HNTCH_FREQ=60 # lowest harmonic notch frequency INS_HNTCH_BW=30 # bandwidth half of notch frequency INS_HNTCH_MODE=3 # ESC notch updates INS_HNTCH_REF=1 # required for ESC updates INS_HNTCH_OPTS=6 # notch updates at loop rate and notch-per-motor SCHED_LOOP_RATE=800 # gives finer control SERVO_DSHOT_RATE=2 # dshot output at 1.6Khz https://www.youtube.com/embed/ZQ08Bumb0fE 17. Pre-flight checks and first flight Props on and initial hover test. Check copter does not have too much thrust at MOT_SPIN_ARM/MOT_SPIN_MIN. Reverse pitch. Reduce PIDs by 50% to remove hover oscillation. First log download to verify that the harmonic notch is tracking the motor RPM correctly. Check that motors outputs are similar and the copter is balanced. Check motor pole count. Check RATE output is below 10% oscillation. It’s also worth checking VIBE. Hover thrust is measured as a percentage of MOT_SPIN_MIN - MOT_SPIN_MAX. Ground effect compensation is switched on by default. RC2_REVERSED=1 # reverse pitch input iFlight motor configuration: XING X2806.5 FPV NextGen Motor WARNING: IT’S GENERALLY NOT A GOOD IDEA TO DO THE INITIAL HOVER TEST INDOORS ON A COPTER OF THIS SIZE https://www.youtube.com/embed/-BKYCc6V7II 18. Precise IMU and compass calibration Accel calibration with board mounted in frame. Temperature calibration of IMUs using INS_TCAL_*. Temperature calibration of barometer. Compass calibration with battery attached. Compass motor calibration with smaller props on upside down and rotated one position round. INS_TCAL1_ENABLED=2 # enable first IMU temperature calibration INS_TCAL1_MIN=5 # calibrate from 5C INS_TCAL1_MAX=45 # calibrate until 45C reached INS_TCAL2_ENABLED=2 # enable second IMU temperature calibration INS_TCAL2_MIN=5 # calibrate from 5C INS_TCAL2_MAX=45 # calibrate until 45C reached TCAL_ENABLED=1 # enable baro temperature calibration Note that its probably better to put the copter in the fridge for temperature calibration to avoid temperature stress. The compass interference proved very problematic in practice and in the end I opted for a second external compass at the front of the vehicle. The rear compass interference can be reduced by holding the lead vertically away using a battery strap. https://www.youtube.com/embed/wkXxlYkwTuE 19. First flight - Stabilize, AltHold, PosHold and Autotune First flight. Determined suitable hover thrust value (MOT_THST_HOVER) from log. Enabled autotune on RC8. Reduced AUTOTUNE_MIN_D. Set battery capacity. Set low battery capacity to 20% of full charge. Turned off battery failsafe. Cycled through stabilize/althold/poshold in flight. Autotuned roll/pitch first followed by yaw using AUTOTUNE_AXES. Post-tune increased filter values and set better althold parameters. Ran autotune again on all axes. RC8_OPTION=17 # autotune on channel 8 AUTOTUNE_AXES=3 # only tune roll and pitch AUTOTUNE_MIN_D=0.0003 # lowest d-term BATT_CAPACITY=3000 # battery capacity BATT_LOW_MAH=600 # battery failsafe low capacity at 20% BATT_FS_CRT_ACT=0 # don't do anything on failsafe BATT_FS_LOW_ACT=0 # don't do anything on failsafe MOT_THST_HOVER=0.14 # hover thrust INS_ACCEL_FILTER=10 # IMU accelerometer filter PSC_ACCZ_P=0.14 # vertical P gain at hover thrust PSC_ACCZ_I=0.28 # vertical I gain at double hover thrust https://www.youtube.com/embed/PBsoGZXTY6Y 20. RTL, RC failsafe and propwash testing RTL and throttle failsafe testing: Setup RTL on a switch via RC8_OPTION = 4; Changed the RTL altitude to 20m via RTL_ALT; Setup throttle failsafe to RTL via FS_THR_ENABLE = 1 Hovered in PosHold and then switched to RTL via switch Hovered in PosHold and then did radio failsafe test by switching off the transmitter RC8_OPTION=4 # RTL on a switch RTL_ALT=2000 # RTL at 20m FS_THR_ENABLE=1 # RTL on radio failsafe LOG_FILE_DSRMROT=1 # start new log on arming INS_LOG_BAT_OPT=1 # sample-rate FFT logging INS_LOG_BAT_MASK=3 # FFT logging on both IMUs LOG_BITMASK=178175 # fast attitude logging Propwash testing: Checked for propwash by gunning the throttle so that the copter goes straight up and then dropped the throttle to zero and allowed the copter to fall in the propwash looking for instability Vibration and log analysis: Did a hover test for with LOG_BAT_OPT=1 to get pre-filter sensor rate logging for FFT analysis Set LOG_FILE_DSRMROT to get a log per flight Look at ATT values for quality of the tune and RATE values for noise in the control loops. Looking - for less than 10% noise Look at VIBE to check that vibrations and clipping are not too high Looked at FFT graph to check on raw noise coming into the IMUs https://www.youtube.com/embed/xObpxLnwbR0 21. FPV and Acro tuning Setup for Acro: Airmode on via ACRO_OPTIONS = 1 Increase roll and yaw rates via ACRO_RP_P = 10 and ACRO_YAW_P = 10 Increase rate at stick edges via ACRO_RP_EXPO = 0.4 Enable flips and rolls via ACRO_TRAINER = 0 Setup for OSD: Enable parameter configuration screens via OSD5_ENABLE = 1 and OSD6_ENABLE = 1 Enable switch between three screens on 3-pos switch by setting OSD_CHAN = channel, OSD_SW_METHOD = 1 (PWM), OSDn_CHAN_MIN and OSDn_CHAN_MAX Enable RSSI display via RSSI_TYPE = 3 Flew in acro and it flew pretty well Did some log analysis on the quality of the tune by looking at compass interference, RATE outputs and friends. Concluded that I needed another external compass mounted away from the battery pigtails ACRO_OPTIONS=1 # enable airmode in acro ACRO_RP_EXPO=0.4 # faster rotation at stick edges ACRO_RP_P=10 # 450 degrees/s on roll and pitch ACRO_YAW_P=10 # 450 degrees/s on yaw ACRO_TRAINER = 0 # allow copter to fully roll past 45 degrees lean ATC_INPUT_TC=0.08 # super crisp feel on pilot input OSD5_ENABLE=1 # enable first OSD parameter screen OSD6_ENABLE=1 # enable second OSD parameter screen OSD_CHAN=7 # RC7 to switch OSD screens OSD_SW_METHOD=1 # switch OSD screen on PWM values OSD1_CHAN_MIN=900 # OSD1 around PWM 1000 OSD1_CHAN_MAX=1100 OSD5_CHAN_MIN=1400 # OSD5 around PWM 1500 OSD5_CHAN_MAX=1600 OSD6_CHAN_MIN=1900 # OSD6 around PWM 2000 OSD6_CHAN_MAX=2100 RSSI_TYPE = 3 # RSSI from radio receiver https://www.youtube.com/embed/gyC01eQ8gZ4 22. Acro flips and rolls, antenna adjustments Selected MPU 6000 by setting EK3_PRIMARY = 1. Switched immortal T’s for monopoles at the back. Re-tested acro with flips and rolls. All worked fine and range was much improved. Analysis of the logs showed low vibrations and reasonable RATE levels. After test flights installed sleeve dipoles to increase the range. EK3_PRIMARY=1 # use MPU600 as the primary IMU https://www.youtube.com/embed/CRuh6Q8mqEA 23. Measuring frame resonance with on-board FFT Enabled on-board FFT via FFT_ENABLE=1. Set the FFT frequency range using FFT_MINHZ=16 and FFT_MAXHZ=950. Enabled disarmed logging via LOG_DISARMED=1. The flight controller and frame was mounted on a vibration speaker and then multitone pro was used to generate a sin sweep signal from 5Hz to 1Khz. The log was then analyzed to find high Y energy (FTN2.0.EnY) at 167Hz with 20Hz bandwidth and 236Hz with 60Hz bandwidth. Thus it makes sense to configure a static notch at 167Hz via INS_NOTCH_ENABLE=1, INS_NOTCH_FREQ=167, INS_NOTCH_BW=20. Leonard castigated me for doing this test without the battery attached as that dramatically affects the resonance. So I repeated it and this time got resonance at 250Hz. However, after a lot of in-flight testing I settled on 150Hz to kill the rate output resonance that I was seeing. FFT_ENABLE=1 # enable onboard FFT engine FFT_MINHZ=16 # lowest FFT detection frequency FFT_MAXHZ=950 # highest FFT detection frequency INS_NOTCH_ENABLE=1 # enable static notch INS_NOTCH_FREQ=150 # notch at 150Hz INS_NOTCH_BW=75 # bandwidth of 75Hz https://www.youtube.com/embed/XV1t2Y1KrcM 24. Getting The Perfect Tune A long one this, but hopefully worth it! Getting a perfect tune requires two things: Successive autotunes at different filter settings to determine optimal filter for roll and pitch Manual tune of yaw D Successive autotunes Try different values of INS_GYRO_FILT, ATC_RAT_RLL_FLTD and ATC_RAT_PIT_FLTD, e.g. 40/20, 60/30, 80/40, 100/50, 120/60, 150/75 Want highest filter setting that does not introduce significant noise and lowest filter setting that does not affect control. Control can be determined by looking at ATC_RAT_RLL_P/ATC_RAT_PIT_P values from autotune - higher is better. Once noise is dominating higher filter settings will not increase _P Noise can be determined by looking at RATE.POut/RATE.ROut in logs, needs to be below 0.1 Final autotune On the Chimera7 150/75 was found to be the best balance of noise and latency/control Final autotune at 0.075 AUTOTUNE_AGGR to produce very stable PIDs with high control INS_GYRO_FILT=150 # Gyro low pass filter ATC_RAT_RLL_FLTD=75 # Roll D-term filter ATC_RAT_PIT_FLTD=75 # Pitch D-term filter AUTOTUNE_AGGR=0.075 # Auotune aggressiveness Yaw manual tune autotune does not touch ATC_RAT_YAW_D, it has to be tuned manually Set ATC_RAT_YAW_FLTD to optimal value from final autotune for roll/pitch Try values for ATC_RAT_YAW_D from 0.0001 in steps of 1000% until oscillation observed - so 0.0001, 0.001, 0.01, 0.1 At oscillation reduce in steps of 10% until no oscillation - 0.1, 0.09, 0.08, 0.07, 0.06, 0.05, 0.04, 0.03 and then reduce another 25% - 0.02 Tune ATC_RAT_YAW_FLTD by changing and repeating manual process On the Chimera7 ATC_RAT_YAW_FLTD = 60 / ATC_RAT_YAW_D = 0.02 was found to give best balance ATC_RAT_YAW_FLTD=60 # Yaw D-term filter ATC_RAT_YAW_D=0.02 # Yaw D Yaw maximum acceleration Remove acceleration constraints - ACRO_YAW_P = 15 or ACRO_YAW_RATE = 600 and ATC_ACCEL_Y_MAX = 0 Do a fast yaw maneuver In the log measure the observed RATE.Y acceleration. Calculate acceleration from MAX(RATE.Y) - MIN(RATE.Y) / T. Multiply by 100 to get centidegrees/s/s and set ATC_ACCEL_Y_MAX to this value For the Chimera7 this resulted in ATC_ACCEL_Y_MAX = 72000 ATC_ACCEL_Y_MAX=72000 # Maximum Yaw acceleration The final tune parameters are attached at the top of this post. A couple of extra goodies: ATC_RAT_YAW_FF=0.0043 # Feed forward for yaw. Don't ask me how to calculate this ACRO_Y_EXPO=0.6 # higher yaw expo ACRO_RP_EXPO=0.6 # higher roll/pitch expo https://www.youtube.com/embed/KNzOMk1-SQI 25. Fun With Compasses Show how to mount and configure an external compass: aliexpress.com 1.75US $ 15% OFF|HMC5883 GY 271 3V 5V Triple Axis Tri axis 3 Axis Compass... Smarter Shopping, Better Living! Aliexpress.com or aliexpress.com 5.31US $ 10% OFF|150 BMM150 Magnetic sensor magnetometer compass... Smarter Shopping, Better Living! Aliexpress.com Only use one compass, only use one IMU/EKF and make sure the current sensor is properly calibrated for best results https://www.youtube.com/embed/-O2BfTEwBP4 26. Final Flight(s) https://www.youtube.com/embed/mz5zdql8ENE 43 posts - 15 participants Read full topic [Less]