CameraRealSense2: increased wait time from 10 msec to 100 msec

This commit is contained in:
matlabbe
2018-06-28 16:55:33 -04:00
parent 675da6201a
commit 62a64cd156

View File

@@ -3536,10 +3536,10 @@ SensorData CameraRealSense2::captureImage(CameraInfo * info)
try{
auto frameset = syncer_.wait_for_frames(5000);
UTimer timer;
while (frameset.size() != 2 && timer.elapsed() < 2.0)
while (frameset.size() != 2 && timer.elapsed() < 2)
{
// maybe there is a latency with the USB, try again in 10 ms (for the next 2 seconds)
frameset = syncer_.wait_for_frames(10);
// maybe there is a latency with the USB, try again in 100 ms (for the next 2 seconds)
frameset = syncer_.wait_for_frames(100);
}
if (frameset.size() == 2)
{