Browse Source

Added missing ADC start command, fixed return value / error behavior of ADC init

sbg
Lorenz Meier 12 years ago
parent
commit
c94076f673
  1. 1
      ROMFS/scripts/rc.sensors
  2. 4
      apps/sensors/sensors.cpp

1
ROMFS/scripts/rc.sensors

@ -8,6 +8,7 @@ @@ -8,6 +8,7 @@
#
ms5611 start
adc start
if mpu6000 start
then

4
apps/sensors/sensors.cpp

@ -640,8 +640,8 @@ Sensors::adc_init() @@ -640,8 +640,8 @@ Sensors::adc_init()
_fd_adc = open("/dev/adc0", O_RDONLY | O_NONBLOCK);
if (_fd_adc < 0) {
warn("/dev/adc0");
errx(1, "FATAL: no ADC found");
warnx("/dev/adc0");
warnx(1, "FATAL: no ADC found");
}
}

Loading…
Cancel
Save