Browse Source

Merge branch 'master' of github.com:PX4/Firmware

sbg
Lorenz Meier 12 years ago
parent
commit
3edd38c5db
  1. 8
      ROMFS/scripts/rcS
  2. 7
      apps/drivers/l3gd20/l3gd20.cpp

8
ROMFS/scripts/rcS

@ -21,9 +21,9 @@ set MODE autostart @@ -21,9 +21,9 @@ set MODE autostart
set USB autoconnect
#
# Start playing the startup tune
#
tone_alarm start
#
# Try to mount the microSD card.
@ -32,8 +32,12 @@ echo "[init] looking for microSD..." @@ -32,8 +32,12 @@ echo "[init] looking for microSD..."
if mount -t vfat /dev/mmcsd0 /fs/microsd
then
echo "[init] card mounted at /fs/microsd"
# Start playing the startup tune
tone_alarm start
else
echo "[init] no microSD card found"
# Play SOS
tone_alarm 2
fi
#

7
apps/drivers/l3gd20/l3gd20.cpp

@ -684,9 +684,10 @@ L3GD20::measure() @@ -684,9 +684,10 @@ L3GD20::measure()
* 74 from all measurements centers them around zero.
*/
report->timestamp = hrt_absolute_time();
/* XXX adjust for sensor alignment to board here */
report->x_raw = raw_report.x;
report->y_raw = raw_report.y;
/* swap x and y and negate y */
report->x_raw = raw_report.y;
report->y_raw = ((raw_report.x == -32768) ? 32767 : -raw_report.x);
report->z_raw = raw_report.z;
report->x = ((report->x_raw * _gyro_range_scale) - _gyro_scale.x_offset) * _gyro_scale.x_scale;

Loading…
Cancel
Save