Commit 20758970 authored by Fernando Herrero's avatar Fernando Herrero
Browse files

TMP FIX: added delay to solve data transmission bug

parent e672a0b0
......@@ -216,6 +216,7 @@ CLidarLite::read(unsigned char addr, int len)
unsigned char data[len];
try {
this->adapter_->write(DEVICE_ID, &addr, 1);
usleep(500); // FIX: This delay should be removed when the data transfer bug is solved.
this->adapter_->read(DEVICE_ID, data, len);
} catch (CException& e) {
throw CLidarLiteException(_HERE_, e.what());
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment