-
Notifications
You must be signed in to change notification settings - Fork 9k
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
simulator: sensors aren't filled #33721
Comments
I'm wondering what to do with the gyroscope value for IMUState. Metadrive does neither offer a simulated value for gyroscope nor for direction. We can just get the bearing value in this function and store it in the state.imu.bearing variable. I guess the acceleration can also be calculated based on the last timestamp and last stored velocity and current velocity. But the gyroscope has to be kinda hacked, to be calculated based on the acceleration and direction the car is heading and even then it is really inaccurate. Or is it just that the value should stay zero? |
The IMUState is never updated, so locationd is getting 0s for the sensor data, and then paramsd learns a bad offset, preventing from merging a fix to the steering angle: #33718
openpilot/tools/sim/lib/common.py
Lines 30 to 34 in 72e19cc
We may be able to fake these sensors with the vehicle state:
metadrive_vehicle_state(velocity=vec3(x=3.250601291656494, y=10.504247665405273, z=0), position=(217.0621795654297, 82.05776977539062), bearing=72.51176834106445, steering_angle=7.866117000579834)
The text was updated successfully, but these errors were encountered: