ArduPilot / ArduPilot/ardupilot
Rover: increase main loop to 100hz or 400hz
- Dominant language
- C++
- Stars
- 15.9k
- Forks
- 21.4k
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 119
Description
Rover current updates at 50hz which is fine for most vehicles and matches the update rates of servos but increasing the rate has two advantages:
- for smaller vehicles and eventually balance bots, a higher update will likely lead to better performance.
- increasing to at least 100hz will mean the EKF runs at the same rate as plane and copter which could make EKF tuning easier (I think, @priseborough has told me something similar to this in the past).
I don't immediately know how to increase Rover's main loop rate but it will involve some configuration change to the scheduler. The task list for the scheduler can be found in [APMrover2.cpp](https://github.com/ArduPilot/ardupilot/blob/master/APMrover2/APMrover2.cpp#L45) and it's possible that simply increasing the Hz columns for the top 5 items to "100" may do it.
Contributor guide
Research direction
Start with the scheduler task list in APMrover2/APMrover2.cpp around line 45, and inspect how the top five task frequency columns control Rover’s main loop. Determine whether raising them to 100 Hz or 400 Hz gives the requested behavior, then verify the resulting update rate and EKF scheduling against the stated goals.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- embedded-iot, performance, robotics
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100