AutoModelCar / AutoModelCarWiki

59 stars 25 forks source link

Incorrect values for /model_car/yaw #10

Closed arieleo2690 closed 7 years ago

arieleo2690 commented 7 years ago

Hi.

I'm trying to read the yaw value through Arduino serial port in /model_car/yaw topic. However I'm getting incorrect values from -180 to 180 since model car is static. I reviewed the source code in heading package, but it seems to me it's only reading the value over Arduino serial port. Regards.

noelcortes commented 7 years ago

Arduino UNO only reads the IMU data from the serial port, so maybe you have a problem with the sparkfun IMU or just a drift error..... You can read the yaw signal trhough the "serial monitor" of arduino IDE in order to check the correct operation of the sparkfun IMU, just remember to adjust the baud rate to read this measurements properly..

Regards.

Noel Cortés - CINVESTAV Saltillo

ZahraBoroujeni commented 7 years ago

Hi , @arieleo2690 : Do you use version 2? Could you turn off the lidar and test again?!

Then if it is stable without lidar.

IMU_Zero code: https://github.com/AutoModelCar/arduino_nano_v2/tree/master/MPU6050/examples/IMU_Zero

@noelcortes : In arduino main code, using MPU6050 library, the yaw angle is calculated and then it sends through serial port. Best, Zahra

arieleo2690 commented 7 years ago

It works. Thanks Zahra.