mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-06-01 11:06:04 +08:00
remove usleep in gyrosim
This commit is contained in:
@@ -1070,23 +1070,17 @@ GYROSIM::measure()
|
|||||||
/*
|
/*
|
||||||
* Report buffers.
|
* Report buffers.
|
||||||
*/
|
*/
|
||||||
accel_report arb;
|
accel_report arb;
|
||||||
gyro_report grb;
|
gyro_report grb;
|
||||||
|
|
||||||
/*
|
// for now use local time but this should be the timestamp of the simulator
|
||||||
* Adjust and scale results to m/s^2.
|
|
||||||
*/
|
|
||||||
grb.timestamp = hrt_absolute_time();
|
grb.timestamp = hrt_absolute_time();
|
||||||
arb.timestamp = grb.timestamp;
|
arb.timestamp = grb.timestamp;
|
||||||
|
|
||||||
// this sleep is needed because the timing of the drivers is not yet working
|
|
||||||
usleep(1000);
|
|
||||||
|
|
||||||
// report the error count as the sum of the number of bad
|
// report the error count as the sum of the number of bad
|
||||||
// transfers and bad register reads. This allows the higher
|
// transfers and bad register reads. This allows the higher
|
||||||
// level code to decide if it should use this sensor based on
|
// level code to decide if it should use this sensor based on
|
||||||
// whether it has had failures
|
// whether it has had failures
|
||||||
grb.error_count = arb.error_count = 0;
|
grb.error_count = arb.error_count = 0; // FIXME
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* 1) Scale raw value to SI units using scaling from datasheet.
|
* 1) Scale raw value to SI units using scaling from datasheet.
|
||||||
|
|||||||
Reference in New Issue
Block a user