Skip to content
Snippets Groups Projects
Commit c834940c authored by Sergi Hernandez's avatar Sergi Hernandez
Browse files

Saved the calibration once it is done for the next time.

parent 6c9414d7
No related branches found
No related tags found
No related merge requests found
......@@ -115,7 +115,7 @@ void bno055_erase_calibration(void)
{
uint8_t i;
for(i=0;i<24;i++)
for(i=0;i<2;i++)
eeprom_write_byte(&bno055_cal_data[i],0xFF);
}
......@@ -237,7 +237,10 @@ void bno055_loop(void)
else
ram_data[IMU_CONTROL]&=0xEF;
if((ram_data[IMU_CONTROL]&0x70)==0x70)
{
bno055_state=idle;
bno055_save_calibration();
}
else
bno055_state=get_calibrated;
}
......
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