AP_Compass: init never fails; return void rather than bool

This commit is contained in:
Peter Barker 2018-07-03 17:36:32 +10:00 committed by Peter Barker
parent d53f787a14
commit f8be4efed4
2 changed files with 2 additions and 4 deletions

View File

@ -498,8 +498,7 @@ Compass::Compass(void)
// Default init method
//
bool
Compass::init()
void Compass::init()
{
if (_compass_count == 0) {
// detect available backends. Only called once
@ -518,7 +517,6 @@ Compass::init()
for (uint8_t i=_compass_count; i<COMPASS_MAX_INSTANCES; i++) {
_state[i].dev_id.set(0);
}
return true;
}
// Register a new compass instance

View File

@ -70,7 +70,7 @@ public:
/// @returns True if the compass was initialized OK, false if it was not
/// found or is not functioning.
///
bool init();
void init();
/// Read the compass and update the mag_ variables.
///