diff options
| author | Keith Packard <keithp@keithp.com> | 2010-07-28 12:24:53 -0700 |
|---|---|---|
| committer | Keith Packard <keithp@keithp.com> | 2010-07-28 12:24:53 -0700 |
| commit | e76b9cc32bbcc5176d9bdd6f8d79778024627382 (patch) | |
| tree | 331a16ed7d14f8362dc85af04dcf1693b3b1ee6e /ao-tools/altosui/AltosDeviceDialog.java | |
| parent | 172a2817dde6718724f2b5fad5a7761801446fa0 (diff) | |
altosui: Catch errors opening USB devices. Limit list to relevant devices
Avoids a segfault when failing to open a device. Limit listed telemetry
devices to just TeleDongle units.
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'ao-tools/altosui/AltosDeviceDialog.java')
| -rw-r--r-- | ao-tools/altosui/AltosDeviceDialog.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ao-tools/altosui/AltosDeviceDialog.java b/ao-tools/altosui/AltosDeviceDialog.java index eb70877c..08921c3d 100644 --- a/ao-tools/altosui/AltosDeviceDialog.java +++ b/ao-tools/altosui/AltosDeviceDialog.java @@ -41,6 +41,10 @@ public class AltosDeviceDialog { devices[0]); return (altos_device) o; } else { + JOptionPane.showMessageDialog(frame, + "No AltOS devices available", + "No AltOS devices", + JOptionPane.ERROR_MESSAGE); return null; } } |
