Browse Source

Apply AStyle to fixup formating

sbg
Robert Dickenson 9 years ago committed by Lorenz Meier
parent
commit
cb3c625ea4
  1. 9
      src/drivers/lis3mdl/lis3mdl.cpp
  2. 2
      src/modules/attitude_estimator_q/attitude_estimator_q_main.cpp

9
src/drivers/lis3mdl/lis3mdl.cpp

@ -503,6 +503,7 @@ void LIS3MDL::check_conf(void) @@ -503,6 +503,7 @@ void LIS3MDL::check_conf(void)
perf_count(_comms_errors);
}
}
break;
case 50:
@ -512,6 +513,7 @@ void LIS3MDL::check_conf(void) @@ -512,6 +513,7 @@ void LIS3MDL::check_conf(void)
perf_count(_comms_errors);
return;
}
if (reg_in != _cntl_reg4) {
perf_count(_conf_errors);
ret = write_reg(ADDR_CTRL_REG1, _cntl_reg4);
@ -520,6 +522,7 @@ void LIS3MDL::check_conf(void) @@ -520,6 +522,7 @@ void LIS3MDL::check_conf(void)
perf_count(_comms_errors);
}
}
break;
case 100:
@ -529,6 +532,7 @@ void LIS3MDL::check_conf(void) @@ -529,6 +532,7 @@ void LIS3MDL::check_conf(void)
perf_count(_comms_errors);
return;
}
if (reg_in != _cntl_reg5) {
perf_count(_conf_errors);
ret = write_reg(ADDR_CTRL_REG5, _cntl_reg5);
@ -537,6 +541,7 @@ void LIS3MDL::check_conf(void) @@ -537,6 +541,7 @@ void LIS3MDL::check_conf(void)
perf_count(_comms_errors);
}
}
break;
case 150:
@ -555,6 +560,7 @@ void LIS3MDL::check_conf(void) @@ -555,6 +560,7 @@ void LIS3MDL::check_conf(void)
perf_count(_comms_errors);
}
}
break;
default:
@ -1244,6 +1250,7 @@ int LIS3MDL::set_excitement(unsigned enable) @@ -1244,6 +1250,7 @@ int LIS3MDL::set_excitement(unsigned enable)
if (((int)enable) < 0) {
warnx("WARN: set_excitement negative not supported\n");
} else if (enable > 0) {
_cntl_reg1 |= 0x01;
}
@ -1392,12 +1399,14 @@ start_bus(struct lis3mdl_bus_option &bus, enum Rotation rotation) @@ -1392,12 +1399,14 @@ start_bus(struct lis3mdl_bus_option &bus, enum Rotation rotation)
if (OK != ioctl(fd, SENSORIOCSPOLLRATE, 50)) {
warn("FAILED: SENSORIOCSPOLLRATE 50Hz");
}
printf("set poll rate to 50Hz\n");
/* Set to 4 Gauss */
if (OK != ioctl(fd, MAGIOCSRANGE, 4)) {
warnx("FAILED: MAGIOCSRANGE 4 Ga");
}
printf("set range to 4 Ga\n");
close(fd);

2
src/modules/attitude_estimator_q/attitude_estimator_q_main.cpp

@ -334,7 +334,7 @@ void AttitudeEstimatorQ::task_main() @@ -334,7 +334,7 @@ void AttitudeEstimatorQ::task_main()
} else if (ret == 0) {
// Poll timeout, do nothing
// RobD debugging - quiet this for now
// TODO: RobD debugging - quiet this for now
// PX4_WARN("Q POLL TIMEOUT");
continue;
}

Loading…
Cancel
Save