diff options
author | Keith Packard <keithp@keithp.com> | 2017-12-11 14:08:32 -0800 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2017-12-11 14:08:32 -0800 |
commit | fa3ff3a089e4af88dd0cc9a9e92511a0ba4a8e0f (patch) | |
tree | c2b8c1065d56fe1a344bad18d46af28642c0fb11 /src/stm | |
parent | 962df1f8c7f7ffbebe9b32d6ac363b333af606b3 (diff) |
altos: Actually store current MPU9250 data in data ring
The ring is updated when the ADC finishes; all of the other sensor
data needs to be copied in at that point.
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src/stm')
-rw-r--r-- | src/stm/ao_adc_stm.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/stm/ao_adc_stm.c b/src/stm/ao_adc_stm.c index c3cca5e4..24912bb2 100644 --- a/src/stm/ao_adc_stm.c +++ b/src/stm/ao_adc_stm.c @@ -58,6 +58,9 @@ static void ao_adc_done(int index) #if HAS_MPU6000 ao_data_ring[ao_data_head].mpu6000 = ao_mpu6000_current; #endif +#if HAS_MPU9250 + ao_data_ring[ao_data_head].mpu9250 = ao_mpu9250_current; +#endif ao_data_ring[ao_data_head].tick = ao_tick_count; ao_data_head = ao_data_ring_next(ao_data_head); ao_wakeup((void *) &ao_data_head); |