mustafa-gokce / ardupilot-software-development

Source codes of Software Development for Ardupilot Powered Unmanned Systems course
https://www.udemy.com/course/software-development-for-ardupilot-powered-unmanned-systems/?referralCode=6CA87959368307D777B9
62 stars 41 forks source link

About setting vehicle speed #3

Closed forevery522 closed 1 year ago

forevery522 commented 1 year ago

Hi, I have a problem about setting vehcie speed, when I wanted to set vehcile speed as 15 m/s(which is faster than 10 m/s), but I failed, However, if I set speed below 10 m/s, anything worked ok. Is there any solution about it? Hope you reply me soon, Thanks!

mustafa-gokce commented 1 year ago

You can set the maximum speed and acceleration values with parameters starting with WPNAV, LOIT, and PSC. Of course, these values need to be adjusted according to the capabilities of your drone. You can find the maximum speed that the engines can fly while providing a stable flight at maximum thrust differences and bank angles, by trial/error or by mathematical modeling of the drone. Before that, the vehicle needs to be adjusted very precisely, first by AutoTune or manually, of ATC parameters (attitude controller PIDs). Afterward, the PSC_ parameters should be adjusted and the position controller (position PIDs) used in autonomous flight should be adjusted with log reviews. https://ardupilot.org/copter/docs/parameters.html#wpnav-parameters https://ardupilot.org/copter/docs/parameters.html#loit-parameters https://ardupilot.org/copter/docs/parameters.html#psc-parameters https://ardupilot.org/copter/docs/parameters.html#atc-parameters Once these adjustments are made, the drone can be given ground speed commands much faster than the default values within its capabilities. In terms of hardware, the drone must be chosen in the style of a racing drone (body, propulsion system, propeller), and the GPS module must be one of the models with a high sampling frequency (for example, F9P) that can allow these high speeds. In order to prevent the high-pressure air released at extra high accelerations from affecting the altitude hold mode, integrating an extra quality barometer can be used as a measure to reduce the sensitivity and the altitude loss at high acceleration. The max and min values must be parametrically drawn to the appropriate range for the vehicle. You can enter the max value as many times as you want, but the drone cannot allow this after a certain level. The stable flight begins to deteriorate. This situation will cause oscillation and accidental distortion even if the ATC PIDs are not very sensitive and are adjusted sensitively in cases where external factors are high. While stabilization problems are at low levels, they are only seen in flight records. High problems cause visible oscillations. For this reason, it is the most common use to pull the vehicle to the values that the drone can fly easily according to the task you will do, leaving a little safety margin for the vehicle, if the speed is not the most important output for you. For this reason, ardupilot developers offer the safest parameter values that appeal to most users as default values.