byu-magicc / rosflight_plugins

Container for basic sensors needed for Gazebo simulation.
8 stars 9 forks source link

Roscopter fixes #17

Closed mmmfarrell closed 5 years ago

mmmfarrell commented 5 years ago

Some fixes I realized we need while I was working on the roscopter estimator

@BillThePlatypus, per our conversation about Gazebo WORLD vs RELATIVE frame, I couldn't find anything that convinced me either way if GetWorldLinearVel and GetLinearVel both would give me the same velocity or not. But I think that World is more intuitive than Relative when it comes to velocities in the Inertial Frame. And this seems to work correctly.

Also, I did not fix how the velocity is calculated for the NavSatFix message because there has been a belief that ROSPlane should match what is in the "Small Unmanned Aircraft" book as closely as possible. The method that is currently used to compute the GPS Velocity for the NavSat message comes straight from the book. This was probably pretty accurate when the book was published, but modern GPS receivers use Doppler shift for velocity. See https://insidegnss.com/wp-content/uploads/2018/01/marapr15-SOLUTIONS.pdf

superjax commented 5 years ago

I assume this is working. Do you mind if I steal it for rosflight_sim?

mmmfarrell commented 5 years ago

@superjax Of course, go for it. I wouldn't say this is the best way to simulate GPS, but it works with roscopter right now, so its a good first pass.