Skip to content
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

IMU uses wrong error value for checking errors #12

Open
drdeaton opened this issue May 15, 2023 · 0 comments
Open

IMU uses wrong error value for checking errors #12

drdeaton opened this issue May 15, 2023 · 0 comments

Comments

@drdeaton
Copy link

Describe the bug
When using the okapi::IMU, sometimes pros::c::imu_get_euler gives an error value, setting errno. This results in the euler containing PROS_ERR_F values, but okapi::IMU::get() instead checks for PROS_ERR values, leading to the error not being handled properly.

Steps To Reproduce
Reset an IMU and try to use it before it finishes resetting.

Expected behavior
IMU::get() should return PROS_ERR_F

Versions
The bug was discovered while running OkapiLib 4.8.0 and PROS kernel 3.7.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant