Skip to content
Snippets Groups Projects
Commit 1b9bbc81 authored by Fernando Herrero's avatar Fernando Herrero
Browse files

Reduced the timeout.

Get the internal driver configuration mode.
parent 11cfb373
No related branches found
No related tags found
1 merge request!1Kinetic migration
......@@ -91,10 +91,7 @@ bool Bno055ImuDriver::stopDriver(void)
op_mode_t Bno055ImuDriver::get_operation_mode(void)
{
if(this->imu_device!=NULL)
return this->imu_device->get_operation_mode();
else
return config_mode;
return (op_mode_t)this->config_.mode;
}
void Bno055ImuDriver::config_update(Config& new_cfg, uint32_t level)
......
......@@ -48,7 +48,7 @@ void Bno055ImuDriverNode::mainNodeThread(void)
try{
this->events.clear();
this->events.push_back(this->driver_.get_new_data_event_id());
this->event_server->wait_all(events,2000);
this->event_server->wait_all(events,100);
op_mode=this->driver_.get_operation_mode();
if(op_mode==mag_only_mode || op_mode==acc_mag_mode || op_mode==mag_gyro_mode || op_mode==acc_mag_gyro_mode || op_mode==compass_mode || op_mode==m4g_mode || op_mode==ndof_off_mode || op_mode==ndof_mode)
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment