-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Produce more accurate odometer fixes by averaging multiple GNSS poses while standing #130
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good, looking forward to testing it
Today, when testing with a real robot I discovered that we run into an endless loop if we do not have a RTK fix. This can happen indoors, when no internet connection is available, when SAPOS is not correctly configured or a thousand other causes. How should we handle this? |
@rodja do you mean the while-loop in update_robot_pose? |
Yes |
The |
I agree. But before this PR, the default behaviour was simply to keep driving with odometry. Let's discuss this tomorrow in our all-hands meeting. |
As discussed we keep the old behaviour for now which does not require GNSS to be active. This allows us to drive by visual cues only. |
The worked today on U4/RB28, but one time there was the following error where the automation was stopped and couldn't be started again without restarting the software.
|
The tests with U4 worked very well after we fixed the |
@rodja the field navigation tests fail after 24d0da5. I narrowed it down to the |
The test doesn't wait for this sleep. We could forward for x seconds or move await super().activate() to the end of the function and then forward until the implement is activeawait forward(until=lambda: system.current_implement.is_active)
|
Works again, will merge now! |
As an alternative to a Kalman Filter, this PR leverages the fact that we are standing still while the implement is working:
We can collect multiple GNSS measurements and average them for a odometer pose update just before we start driving again. The new code also ensures that the navigation pauses it's advancements shortly to gather a some gps measurements every 10 seconds for scenarios where the implement does not request stopping on their own. And the AutomationWatcher was updated to generate GNSS pose updates if no automation is running and robot is standing.
ToDos
main
and thenmain
into this branch; otherwise some coordinate changes will not have the expected effectassert not self.is_paused
raised inupdate_robot_pose
-> missing super calls