altosui: Initial accel calibration UI
[fw/altos] / altosui / AltosConfigFC.java
index beff71b7279db119e094f10f8cae37688dfcae14..db998278bd16571227a01602890cf208b3c081d5 100644 (file)
@@ -268,6 +268,14 @@ public class AltosConfigFC implements ActionListener {
                                if (serial_line != null)
                                        serial_line.close();
                        }
+                       else if (cmd.equals("Accel")) {
+                               if (data.pad_orientation != AltosLib.MISSING) {
+                                       AltosUIAccelCal accel_ui = new AltosUIAccelCal(owner, serial_line);
+                                       if (accel_ui != null)
+                                               if (accel_ui.doit())
+                                                       config_ui.set_dirty();
+                               }
+                       }
                } catch (InterruptedException ie) {
                        abort();
                } catch (TimeoutException te) {