summaryrefslogtreecommitdiff
path: root/altoslib
Commit message (Collapse)AuthorAge
...
* altoslib: Initialize GPS data to MISSING for Monitor Idle modeKeith Packard2015-02-06
| | | | | | | Make sure any un-set values are flagged correctly for the Monitor Idle UI by using the init() method. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Use 'stateless' for Monitor IdleKeith Packard2015-02-06
| | | | | | | | This reflects the lack of flight state progression during Monitor Idle and ensures that the GPS 'ready' indicator will light after 10 solid GPS fixes. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Support TeleGPS for Monitor IdleKeith Packard2015-02-06
| | | | | | | TeleGPS has ADC and GPS values, so build the necessary ADC parser and then hook up GPS parsing. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosuilib: Don't show 'Sats in view' for TeleGPS eeprom graphingKeith Packard2015-02-06
| | | | | | | | We don't log the visible sats from TeleGPS, only the basic GPS info. Have AltosFlightStats track whether sat info is present, then use that to elide the Sats In View graph entry as needed. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosuilib: EEProm download from TeleGPS doesn't have statesKeith Packard2015-02-06
| | | | | | | | | | | | | As TeleGPS doesn't have flight states, the EEProm download progress bar shouldn't show 'state invalid', and it should use a different scale for each block. Fix this by having AltosConfigData know which devices have state based on their log format, then mark the progress bar state limits as 'invalid/invalid' instead of 'boost/landed'. Then have the progress bar use that to set a more reasonable scale for each block. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Store MS5607 data in AltosConfigData for use by AltosMs5607Keith Packard2015-02-06
| | | | | | | | | When doing 'Monitor Idle', we fetch new config data each iteration and pass that to each of the readers, including ms5607. Instead of re-fetching the config data there, just store the ms5607 parameters when we fetch it the first time and copy it over. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Add usbtrng, usbrelay and mpusb USB idsKeith Packard2014-12-06
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: add AltosPreferences state save/restore interfacesKeith Packard2014-11-15
| | | | | | | | This serializes an entire AltosState object and stores it in the preferences database for later retrieval. AltosDroid uses this to recover the old state data when restarting. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Add getBytes/putBytes interface to AltosPreferencesBackendKeith Packard2014-11-15
| | | | | | This lets us store arbitrary binary data in the preferences database Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Make AltosState serializableKeith Packard2014-11-15
| | | | | | This involved making every class it references serializable as well Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Missing headers for mag sensor in CSV outputKeith Packard2014-11-10
| | | | | | | Kelsey Black <nmonic@gmail.com> reported that the TeleMega CSV output was missing the header labels for the mag sensor data. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosui: Pop up 'Connecting' dialog during Monitor IdleKeith Packard2014-10-30
| | | | | | | This was a bit harder than expected as I had to wire up a way to shut down the whole monitor idle window when you clicked on the cancel button. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: synchronize access to serial debug output listKeith Packard2014-10-24
| | | | | | | This list is access by both the receiver and the monitor task, so it needs to be locked to prevent collisions. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Compute tilt angle from eeprom dataKeith Packard2014-10-04
| | | | | | | | | | | | | | | | This copies the computation of tilt angle from the firmware so that post-flight analysis can also show the data. This change also renames all of the imu values to make them easier to understand: accel gyro axis along roll length of the board across pitch across the board through yaw through the board. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Deal with new Mega log format that has 32-bit gyro calKeith Packard2014-10-04
| | | | | | | This adds parsing for the new log format type to get all 32 bits of the gyro calibration data. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Stop re-loading previous flight when starting telemetry monitoringKeith Packard2014-09-11
| | | | | | | | | | | | This feature is necessary on AltosDroid because there's no other UI for reloading an old flight. It's not useful on the desktop where you really just want to see new telemetry; old telemetry is availbale through the 'graph flight' or 'replay' mechanisms. AltosDroid uses a different class for reading telemetry data, so we can just remove this feature from altoslib at this point. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib/altosuilib: clean all versions of the .jar fileKeith Packard2014-09-09
| | | | | | | When we switch libary versions, we want to remove the old ones; just have 'make clean' remove all versions of the libaries. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib/altosuilib: Add EasyMega supportKeith Packard2014-09-09
| | | | | | | This makes flashing find the right files, and Monitor Idle show all of the state data. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Fix idle monitor parsing of MMA655x stateKeith Packard2014-09-09
| | | | | | | | | There's no ':' after 'MMA655X value' in the output, and the parser returns 'true' on success, not false. With this, 'Monitor Idle' now reports correct accelerometer readings. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Increase timeouts when using low baud rate remote protocolKeith Packard2014-09-06
| | | | | | | | When using 2400 or 9600 baud remote link rates, we need to increase the packet timeout from 500ms to much longer values to avoid annoying the user with timeout warnings. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Update local callsign/baud rate when using remote protocolKeith Packard2014-09-06
| | | | | | | | We've had code to synchronously update the local and remote radio frequencies when doing configuration over the remote link. This patch adds the same code when changing the call sign and baud rate. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosdroid: Add imperial unit supportKeith Packard2014-09-06
| | | | | | | Provides a menu entry to switch units, changes all value displays to use the AltosLib units conversion code. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Ignore extra AO_LOG_FLIGHT records from TeleGPSKeith Packard2014-09-01
| | | | | | | TeleGPS was inserting a spurious AO_LOG_FLIGHT record each time it turned on, which confused altoslib quite a bit. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: create logfiles preference object. check link in existing_dataKeith Packard2014-08-31
| | | | | | | | | The logfiles preference hash wasn't getting created, resulting in crashes. When there was no link, don't try to load existing data. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: TeleMega telemetry pyro voltages are uint8Keith Packard2014-08-29
| | | | | | Using int8 means that voltages over about 6V are reported incorrectly. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosdroid: start restoring from log data on startupKeith Packard2014-08-29
| | | | | | Remember which flight was last being received and reload that file Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Remove some debug printfsKeith Packard2014-08-17
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Improve performance of AltosLib.hexbytesKeith Packard2014-08-17
| | | | | | | On an android device, this function was spending quite a bit of time calling hexbyte. Open code the conversion to improve performance. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Close serial port when AltosFlash fails to detect a targetKeith Packard2014-08-17
| | | | | | | | AltosDebug.check_connection raises an exception when the link fails, but the AltosFlash constructor didn't close the serial port in this case, causing the serial port to appear to be busy. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Handle link timeout in AltosDebug.read_memoryKeith Packard2014-08-17
| | | | | | | link.get_reply returns null on a link error; don't crash in read_memory when this happens. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Parse 'Log fixed:' configuration valueKeith Packard2014-08-17
| | | | | | | | | TeleGPS holds a single flight record and constantly appends data to it instead of having separate flight records on the board. It reports 'Log fixed: 1' to let AltosLib know that the size of the per-flight log is not configurable. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Handle TeleGPS files for KML exportKeith Packard2014-07-16
| | | | | | | TeleGPS files had state values that couldn't be converted to colors, which resulted in a truncated file that wasn't much use for anything. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Parse eeprom 'altitude-32' fieldsKeith Packard2014-07-14
| | | | | | | This lets us tell if the altimeter supports 32-bit GPS altitudes in the eeprom log. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Extend telemetry heights from 16 to 32 bitsKeith Packard2014-07-10
| | | | | | | Uses the GPS data and/or previous kalman data to compute the upper 16 bits of the truncated telemetry altitude value. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Handle wide GPS altitude values in eeprom and telemetryKeith Packard2014-07-10
| | | | | | Detect when the wider data is present and handle it correctly Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Ensure CSV output is consistentKeith Packard2014-07-10
| | | | | | | Scan entire flight to figure out which columns to include before outputing header or data. Limit data output to values which are valid. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Clean up GPS DOP support in AltosStateKeith Packard2014-07-10
| | | | | | | | | Parse out hdop/pdop/vdop from telem and eeprom. Deal with legacy eeprom files that have dop/100 instead of dop/10 values. Clear state DOP values to MISSING at startup Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Support multiple telemetry ratesKeith Packard2014-07-05
| | | | | | | Altos now supports 2400 and 9600 baud in addition to the classic 38400 baud rate. Add support to altoslib for these as well Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Preserve receiver_serial across state reset for new transmitterKeith Packard2014-07-05
| | | | | | | | When the transmitter serial or flight number changes, we re-init the state information, but we want to preserve the receiver serial number so that the log file has that in the name Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Disable telemetry while getting config dataKeith Packard2014-07-05
| | | | | | | | | | We're seeing some log files created without a suitable -via- number included. My hypothesis is that incoming telemetry is getting interleaved with the configuration data containing the serial number. This change simply disables telemetry while retrieving the configuration data to try and keep that from happening. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosui/telegps: Expose configurable APRS SSIDKeith Packard2014-06-22
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* java: Bump java library versions for next releaseKeith Packard2014-06-16
| | | | | | Prepare for future release by bumping java versions now Signed-off-by: Keith Packard <keithp@keithp.com>
* altosui/telegps: Use menus for frequency list and telemetry formatsKeith Packard2014-06-16
| | | | | | | This will let us move them into the Mac OS X menu bar, as well as making them look a bit nicer. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: When GPS disappears, set range and elevation to MISSINGKeith Packard2014-06-14
| | | | | | | Use MISSING instead of bogus values so that displayers can tell what to do. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Add units converters for latitude and longitudeKeith Packard2014-06-14
| | | | | | Makes display of these values consistent across all instances Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Correctly save firmware version in AltosStateKeith Packard2014-06-13
| | | | | | It wasn't getting cloned Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Add conversion class for voltagesKeith Packard2014-06-13
| | | | | | Provide a common presentation for voltage values Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Remove telem monitoring when closing log fileKeith Packard2014-06-13
| | | | | | | If we don't remove the telemetry monitor, the telemetry device will still be sending telemetry, which isn't good. Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Call state.set_serial first for telemetry parsingKeith Packard2014-06-13
| | | | | | | If we ever get around to supporting multiple simultaneous remote devices, we'll need to notice that the serial changed right away Signed-off-by: Keith Packard <keithp@keithp.com>
* altoslib: Report GPS height when baro height is not availableKeith Packard2014-06-11
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>