X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=blobdiff_plain;f=altoslib%2FAltosIdleFetch.java;h=4b9a52542241c1cd3a6f1908bb842c80fd97fbe6;hp=884d87618b5ac0b52d846fb5d68d97bc0dd56eeb;hb=0072e9741719367a1f6748d242cd6195a1a7c6a5;hpb=0686a7b8aec524d81bda4c572549a3a068ce0eed diff --git a/altoslib/AltosIdleFetch.java b/altoslib/AltosIdleFetch.java index 884d8761..4b9a5254 100644 --- a/altoslib/AltosIdleFetch.java +++ b/altoslib/AltosIdleFetch.java @@ -29,7 +29,8 @@ class AltosIdler { static final int idle_gps = 0; static final int idle_imu = 1; - static final int idle_mag = 2; + static final int idle_imu_em_v2 = 2; + static final int idle_mag = 3; static final int idle_mma655x = 4; static final int idle_ms5607 = 5; static final int idle_adxl375 = 6; @@ -40,8 +41,9 @@ class AltosIdler { static final int idle_sensor_emini1 = 13; static final int idle_sensor_emini2 = 14; static final int idle_sensor_tmini2 = 15; - static final int idle_sensor_tgps = 16; - static final int idle_sensor_tmini3 = 17; + static final int idle_sensor_tgps1 = 16; + static final int idle_sensor_tgps2 = 17; + static final int idle_sensor_tmini3 = 18; public void provide_data(AltosDataListener listener, AltosLink link) throws InterruptedException, TimeoutException, AltosUnknownProduct { for (int idler : idlers) { @@ -50,7 +52,10 @@ class AltosIdler { AltosGPS.provide_data(listener, link); break; case idle_imu: - AltosIMU.provide_data(listener, link); + AltosIMU.provide_data(listener, link, AltosIMU.orient_telemega); + break; + case idle_imu_em_v2: + AltosIMU.provide_data(listener, link, AltosIMU.orient_easymega_v2); break; case idle_mag: AltosMag.provide_data(listener, link); @@ -82,8 +87,11 @@ class AltosIdler { case idle_sensor_tmini2: AltosSensorTMini2.provide_data(listener, link); break; - case idle_sensor_tgps: - AltosSensorTGPS.provide_data(listener, link); + case idle_sensor_tgps1: + AltosSensorTGPS1.provide_data(listener, link); + break; + case idle_sensor_tgps2: + AltosSensorTGPS2.provide_data(listener, link); break; case idle_sensor_tmini3: AltosSensorTMini3.provide_data(listener, link); @@ -136,6 +144,12 @@ public class AltosIdleFetch implements AltosDataProvider { AltosIdler.idle_ms5607, AltosIdler.idle_sensor_metrum), + new AltosIdler("TeleMetrum-v3", + AltosIdler.idle_gps, + AltosIdler.idle_adxl375, + AltosIdler.idle_ms5607, + AltosIdler.idle_sensor_metrum), + new AltosIdler("TeleMega-v0", AltosIdler.idle_gps, AltosIdler.idle_mma655x, @@ -168,11 +182,14 @@ public class AltosIdleFetch implements AltosDataProvider { new AltosIdler("EasyMega-v2", AltosIdler.idle_adxl375, AltosIdler.idle_ms5607, - AltosIdler.idle_imu, + AltosIdler.idle_imu_em_v2, AltosIdler.idle_sensor_mega), - new AltosIdler("TeleGPS", + new AltosIdler("TeleGPS-v1", + AltosIdler.idle_gps, + AltosIdler.idle_sensor_tgps1), + new AltosIdler("TeleGPS-v2", AltosIdler.idle_gps, - AltosIdler.idle_sensor_tgps), + AltosIdler.idle_sensor_tgps2), }; AltosLink link;