fw/altos
7 years agomicropeak: Report recorded apogee instead of searching flight data
Keith Packard [Fri, 11 Jan 2013 05:37:18 +0000 (21:37 -0800)]
micropeak: Report recorded apogee instead of searching flight data

This makes sure we report the true apogee value instead of looking for
the maximum height value in the flight data, in case the flight
recording ended before the apogee was reached.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoFix up 'make fat' to build all libs and micropeak too
Keith Packard [Fri, 11 Jan 2013 05:34:24 +0000 (21:34 -0800)]
Fix up 'make fat' to build all libs and micropeak too

There are now three libraries to build for both altosui and micropeak.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agolibaltos: Need to check for tty/ttyACMx before ttyACMx
Keith Packard [Fri, 11 Jan 2013 05:26:20 +0000 (21:26 -0800)]
libaltos: Need to check for tty/ttyACMx before ttyACMx

Otherwise, we'll find 'tty' when looking for 'ttyACMx' and no good
will come from that

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge remote-tracking branch 'origin/micropeak-logging'
Keith Packard [Fri, 11 Jan 2013 05:48:12 +0000 (21:48 -0800)]
Merge remote-tracking branch 'origin/micropeak-logging'

7 years agoaltos: Time out reading packet data from cc1120 after 100ms
Keith Packard [Fri, 11 Jan 2013 05:27:32 +0000 (21:27 -0800)]
altos: Time out reading packet data from cc1120 after 100ms

Sometimes the radio will give a spurious wakeup indicating that a
preamble seems to have arrived, but no packet data will appear. In
this case, abandon the packet reception and go back to waiting for a
preamble again. This releases the SPI bus for other users and also
avoids missing packets.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltoslib: Clean up AltosRecord clone methods
Keith Packard [Wed, 9 Jan 2013 23:29:01 +0000 (15:29 -0800)]
altoslib: Clean up AltosRecord clone methods

Make the AltosRecord version abstract and then implement suitable
versions in each subclass by creating copying constructors for each
class.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltoslib: Don't smash existing GPS pad alt after boost
Keith Packard [Wed, 9 Jan 2013 23:23:46 +0000 (15:23 -0800)]
altoslib: Don't smash existing GPS pad alt after boost

Leave the existing GPS pad altitude value in place after boost by
checking to see if it was ever computed before resetting it to the
barometric pad altitude. This makes GPS height values relative to the pad.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Create .dmg file for Mac OS X installations
Keith Packard [Sun, 6 Jan 2013 21:20:25 +0000 (13:20 -0800)]
altosui: Create .dmg file for Mac OS X installations

Easier for users than a zip file

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Add ReadMe.rtf to Mac distribution
Keith Packard [Sun, 6 Jan 2013 21:00:00 +0000 (13:00 -0800)]
micropeak: Add ReadMe.rtf to Mac distribution

There are *two* steps to installing MicroPeak on Mac OSX. Best help
out the poor user by explaining that.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Create Mac OS X package
Keith Packard [Sun, 6 Jan 2013 20:52:25 +0000 (12:52 -0800)]
micropeak: Create Mac OS X package

Includes the FTDI driver and the MicroPeak app

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Suggest filenames for saving data
Keith Packard [Sat, 5 Jan 2013 18:59:26 +0000 (10:59 -0800)]
micropeak: Suggest filenames for saving data

Uses the format '<year>-<month>-<day>-flight-<number>.mpd'

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Create .dmg file for apple. Create micropeak-jdb script
Keith Packard [Sat, 5 Jan 2013 18:38:20 +0000 (10:38 -0800)]
micropeak: Create .dmg file for apple. Create micropeak-jdb script

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Use new libaltos entry point for FTDI devices
Keith Packard [Sat, 5 Jan 2013 18:37:30 +0000 (10:37 -0800)]
micropeak: Use new libaltos entry point for FTDI devices

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Move raw view caret to top. Make raw text uneditable
Keith Packard [Sat, 5 Jan 2013 18:36:50 +0000 (10:36 -0800)]
micropeak: Move raw view caret to top. Make raw text uneditable

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Remove debug printf for command line
Keith Packard [Sat, 5 Jan 2013 18:36:40 +0000 (10:36 -0800)]
micropeak: Remove debug printf for command line

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoAdd separate code path for listing FTDI devices
Keith Packard [Sat, 5 Jan 2013 18:35:20 +0000 (10:35 -0800)]
Add separate code path for listing FTDI devices

This lets the library do different things for FTDI devices, as is
required on Windows (for instance)

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Use data.export for Raw display. Change to MPH
Keith Packard [Fri, 4 Jan 2013 02:14:40 +0000 (18:14 -0800)]
micropeak: Use data.export for Raw display. Change to MPH

data.export already knows how to format stuff, so use that to
construct the raw data presentation for the GUI too.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Export in lots of units
Keith Packard [Fri, 4 Jan 2013 01:40:19 +0000 (17:40 -0800)]
micropeak: Export in lots of units

meters, feet, mach and gs

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Add command line export option
Keith Packard [Fri, 4 Jan 2013 01:31:01 +0000 (17:31 -0800)]
micropeak: Add command line export option

micropeak --export <foo.mpd> will create <foo.csv> full of useful data.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Add Mac OS Info.plist file
Keith Packard [Fri, 4 Jan 2013 01:30:29 +0000 (17:30 -0800)]
micropeak: Add Mac OS Info.plist file

needed to build a Mac OS X application

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Change graph tooltip units on the fly
Keith Packard [Thu, 3 Jan 2013 00:30:44 +0000 (16:30 -0800)]
micropeak: Change graph tooltip units on the fly

Make sure the tooltips show the right units when they change

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Use JTextArea instead of TextArea
Keith Packard [Thu, 3 Jan 2013 00:19:33 +0000 (16:19 -0800)]
micropeak: Use JTextArea instead of TextArea

Looks nicer and doesn't appear to have the same weird clipping problem

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosuilib: Fix install issues on Linux
Keith Packard [Thu, 3 Jan 2013 00:07:49 +0000 (16:07 -0800)]
altosuilib: Fix install issues on Linux

altosuilib.jar wasn't getting installed
micropeak was using the wrong name

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Add view of raw data in GUI
Keith Packard [Wed, 2 Jan 2013 20:24:44 +0000 (12:24 -0800)]
micropeak: Add view of raw data in GUI

Looks just like the export file

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Add CSV export
Keith Packard [Wed, 2 Jan 2013 19:44:32 +0000 (11:44 -0800)]
micropeak: Add CSV export

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropoint: Add MicroDataPoint
Keith Packard [Wed, 2 Jan 2013 19:22:11 +0000 (11:22 -0800)]
micropoint: Add MicroDataPoint

This holds height/speed/accel data all in one place

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltoslib: Remove unused fake product_micropeak_serial
Keith Packard [Wed, 2 Jan 2013 18:48:56 +0000 (10:48 -0800)]
altoslib: Remove unused fake product_micropeak_serial

Code cleanups have made this no longer useful

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Remove duplicate AltosUSBDevice
Keith Packard [Wed, 2 Jan 2013 17:50:09 +0000 (09:50 -0800)]
altosui: Remove duplicate AltosUSBDevice

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Use shared AltosUIListener
Keith Packard [Wed, 2 Jan 2013 17:41:42 +0000 (09:41 -0800)]
altosui: Use shared AltosUIListener

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Use shared AltosUIFrame and AltosUIDialog
Keith Packard [Wed, 2 Jan 2013 17:40:13 +0000 (09:40 -0800)]
altosui: Use shared AltosUIFrame and AltosUIDialog

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Use shared AltosFontListener class
Keith Packard [Wed, 2 Jan 2013 17:33:36 +0000 (09:33 -0800)]
altosui: Use shared AltosFontListener class

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Use shared AltosDeviceDialog
Keith Packard [Wed, 2 Jan 2013 17:31:35 +0000 (09:31 -0800)]
altosui: Use shared AltosDeviceDialog

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Remove AltosVersion.java
Keith Packard [Wed, 2 Jan 2013 17:09:10 +0000 (09:09 -0800)]
altosui: Remove AltosVersion.java

Version data now stored in AltosUIVersion.java

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Use altosuilib for configuration
Keith Packard [Wed, 2 Jan 2013 17:06:41 +0000 (09:06 -0800)]
altosui: Use altosuilib for configuration

Start moving to shared UI code

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agolibaltos: Remove a couple of spurious debug printfs
Keith Packard [Wed, 2 Jan 2013 17:06:22 +0000 (09:06 -0800)]
libaltos: Remove a couple of spurious debug printfs

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoRename AltosConfigureUI to AltosUIConfigure
Keith Packard [Wed, 2 Jan 2013 07:15:14 +0000 (23:15 -0800)]
Rename AltosConfigureUI to AltosUIConfigure

Leave AltosConfigureUI for AltosUI

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Check CRC on downloaded
Keith Packard [Wed, 2 Jan 2013 07:10:04 +0000 (23:10 -0800)]
micropeak: Check CRC on downloaded

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoBuild micropeak by default
Keith Packard [Wed, 2 Jan 2013 07:03:29 +0000 (23:03 -0800)]
Build micropeak by default

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoBuild installable versions of MicroPeak GUI
Keith Packard [Wed, 2 Jan 2013 02:20:23 +0000 (18:20 -0800)]
Build installable versions of MicroPeak GUI

Makes windows/mac/linux versions. Windows version appears to work on
Wine at least.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Add 'Close' menu item. Fix start location
Keith Packard [Wed, 2 Jan 2013 01:10:55 +0000 (17:10 -0800)]
micropeak: Add 'Close' menu item. Fix start location

Let the window system pick a spot to place the application
windows. This avoids having them all sit on top of one another.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Fix chart colors
Keith Packard [Wed, 2 Jan 2013 00:57:31 +0000 (16:57 -0800)]
micropeak: Fix chart colors

Need to apply custom colors after setting the theme

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak is code complete now.
Keith Packard [Tue, 1 Jan 2013 23:30:11 +0000 (15:30 -0800)]
micropeak is code complete now.

Added save and download functionality. Removed 'new' from file menu.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge remote-tracking branch 'origin/master' into micropeak-logging
Keith Packard [Mon, 31 Dec 2012 22:24:59 +0000 (14:24 -0800)]
Merge remote-tracking branch 'origin/master' into micropeak-logging

7 years agoAllow CC1120 to sit on other SPI busses
Keith Packard [Mon, 31 Dec 2012 22:22:37 +0000 (14:22 -0800)]
Allow CC1120 to sit on other SPI busses

Reading the incoming data bypasses the SPI API and touches the SPI
data register directly; which port that is needs to be specified in
the pins file

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Add flight stats pane
Keith Packard [Mon, 31 Dec 2012 22:17:26 +0000 (14:17 -0800)]
micropeak: Add flight stats pane

Shows graph or stats in alternate panes

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agomicropeak: Use altosuilib
Keith Packard [Mon, 31 Dec 2012 19:42:57 +0000 (11:42 -0800)]
micropeak: Use altosuilib

This removes a pile of code stolen from altosui

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltoslib: Add units change notification list
Keith Packard [Mon, 31 Dec 2012 19:38:53 +0000 (11:38 -0800)]
altoslib: Add units change notification list

This allows the UI to automatically respond to changes in the
preferred units.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoCreate altosuilib to share code between altosui and micropeak
Keith Packard [Mon, 31 Dec 2012 19:32:56 +0000 (11:32 -0800)]
Create altosuilib to share code between altosui and micropeak

Need to convert altosui to using it, but that shouldn't be hard

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: megadongle radio int is C13, not C14
Keith Packard [Sat, 29 Dec 2012 06:05:31 +0000 (23:05 -0700)]
altos: megadongle radio int is C13, not C14

Hard to get interrupts when listening to the wrong pin

Signed-off-by: Keith Packard <keithp@gag.com>
7 years agoMerge remote-tracking branch 'origin/master' into micropeak-logging
Keith Packard [Sat, 29 Dec 2012 05:50:13 +0000 (21:50 -0800)]
Merge remote-tracking branch 'origin/master' into micropeak-logging

7 years agoaltos: Fix MegaDongle CC1120 chip select pin
Keith Packard [Sat, 29 Dec 2012 02:35:46 +0000 (19:35 -0700)]
altos: Fix MegaDongle CC1120 chip select pin

It's on A0, not C5

Signed-off-by: Keith Packard <keithp@gag.com>
7 years agoaltos: Fix cc1120 debug code to build on megadongle
Keith Packard [Sat, 29 Dec 2012 02:34:33 +0000 (19:34 -0700)]
altos: Fix cc1120 debug code to build on megadongle

RDF function had changed, and APRS isn't available on megadongle.

Signed-off-by: Keith Packard <keithp@gag.com>
7 years agoLots more work on the MicroPeak application
Keith Packard [Sat, 29 Dec 2012 00:34:48 +0000 (16:34 -0800)]
Lots more work on the MicroPeak application

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoAdd file chooser for MicroPeak
Keith Packard [Tue, 25 Dec 2012 22:45:49 +0000 (14:45 -0800)]
Add file chooser for MicroPeak

Needs reasonable directory tracking

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoStart building MicroPeak GUI tool
Keith Packard [Tue, 25 Dec 2012 22:23:29 +0000 (14:23 -0800)]
Start building MicroPeak GUI tool

Download, save and analyze MicroPeak flight data

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'master' into micropeak-logging
Keith Packard [Tue, 25 Dec 2012 22:20:42 +0000 (14:20 -0800)]
Merge branch 'master' into micropeak-logging

7 years agoMove libaltos to top level
Keith Packard [Tue, 25 Dec 2012 22:19:19 +0000 (14:19 -0800)]
Move libaltos to top level

This will let it be shared by the new MicroPeak gui

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Actually record ground averages for 6dof sensor
Keith Packard [Wed, 19 Dec 2012 07:15:20 +0000 (23:15 -0800)]
altos: Actually record ground averages for 6dof sensor

This gets the long-term averages for the 6dof sensors recorded into
the first flight log record.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Clean up graph a bit, remove shapes, improve tooltips
Keith Packard [Wed, 19 Dec 2012 06:59:36 +0000 (22:59 -0800)]
altosui: Clean up graph a bit, remove shapes, improve tooltips

Sometimes graphs would get shapes at each datapoint which was
annoyingly cluttered. And, the tooltips used a format that was
difficult to interpret.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Add distinct LED pattern before writing log data
Keith Packard [Tue, 18 Dec 2012 08:39:37 +0000 (00:39 -0800)]
altos: Add distinct LED pattern before writing log data

Otherwise, the whole log looks like a an extra altitude digit.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Make micropeak 'serial' interface work
Keith Packard [Tue, 18 Dec 2012 06:58:49 +0000 (22:58 -0800)]
altos: Make micropeak 'serial' interface work

I prototyped the mpserial interface on a breadboard and tuned the
circuit to register the LED correctly. Then adjusted the serial code
to send bits at the right speed and format.

The logging contents are now in hexdecimal with a CCITT CRC-16
computed to verify correct reception.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Average MPU6000 values on ground for later use
Keith Packard [Tue, 18 Dec 2012 01:03:41 +0000 (17:03 -0800)]
altos: Average MPU6000 values on ground for later use

Having long-term ground averages recorded to the eeprom file will make
post-flight analysis of the data better.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Re-enable beeper on megametrum
Keith Packard [Mon, 17 Dec 2012 00:52:15 +0000 (16:52 -0800)]
altos: Re-enable beeper on megametrum

I turned it off during radio testing and forgot to fix that before committing...

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Add new MARC status pin interrupt bits to megadongle
Keith Packard [Mon, 17 Dec 2012 00:08:33 +0000 (16:08 -0800)]
altos: Add new MARC status pin interrupt bits to megadongle

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'aprs' into 'master'
Keith Packard [Mon, 17 Dec 2012 00:06:41 +0000 (16:06 -0800)]
Merge branch 'aprs' into 'master'

7 years agoaltos: Wire up another CC1120 GPIO to get MARC status changes
Keith Packard [Mon, 17 Dec 2012 00:04:05 +0000 (16:04 -0800)]
altos: Wire up another CC1120 GPIO to get MARC status changes

When the radio drops out of RX or TX mode due to an error, it changes
the MARC status, and sends pulse down a configured GPIO. Use this to
tell when something 'bad' happened during TX or RX so that we can
recover from losing the SPI bus in the middle of transmission or
reception.

Without this, the radio would change state and we'd never know,
leaving the radio code waiting for an interrupt that would never arrive.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Test APRS rounding by using coordinates near the boundary
Keith Packard [Sun, 16 Dec 2012 21:31:45 +0000 (13:31 -0800)]
altos: Test APRS rounding by using coordinates near the boundary

This selects lat/lon and altitude near the rounding boundary to check
that the resulting APRS data is correctly computed.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Document what HAS_BOOT_RADIO does in the m25 driver
Keith Packard [Sun, 16 Dec 2012 21:30:20 +0000 (13:30 -0800)]
altos: Document what HAS_BOOT_RADIO does in the m25 driver

HAS_BOOT_RADIO causes the m25 driver to abort any ongoing receive in
case that is holding the SPI bus.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Round APRS data correctly
Keith Packard [Sun, 16 Dec 2012 21:29:31 +0000 (13:29 -0800)]
altos: Round APRS data correctly

Apply rounding once at the start of the computation, then truncate
after that.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltoslib: unconfigured radio frequency data is now -1, not 0
Keith Packard [Sun, 16 Dec 2012 21:25:54 +0000 (13:25 -0800)]
altoslib: unconfigured radio frequency data is now -1, not 0

This changed when AltosConfigData was cleaned up, so now frequency
settings must check for positive numbers rather than non-zero.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agodoc: Add warning about matching battery voltage.
Keith Packard [Sat, 15 Dec 2012 23:07:07 +0000 (15:07 -0800)]
doc: Add warning about matching battery voltage.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agodoc: Add paragraph noting differences in JST polarity
Keith Packard [Sat, 15 Dec 2012 22:47:22 +0000 (14:47 -0800)]
doc: Add paragraph noting differences in JST polarity

Looks like the 'standard' polarity for 3.7V lipos using JST connectors
in RC aircraft is swapped from what Spark Fun uses. Note that in the
docs to try and keep people from wrecking hardware.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'micropeak-1.1'
Keith Packard [Sat, 15 Dec 2012 03:29:50 +0000 (19:29 -0800)]
Merge branch 'micropeak-1.1'

7 years agoaltoslib: Discard previous flight state on SN change
Keith Packard [Sat, 15 Dec 2012 03:28:49 +0000 (19:28 -0800)]
altoslib: Discard previous flight state on SN change

A previous change discarded previous *telemetry* state, but failed to
discard any previous overall flight state. This would reset some of
the data fields, but wouldn't reset the GPS state and max measurements.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltoslib: Only list flight logs for boards that we know have them
Keith Packard [Sat, 15 Dec 2012 03:27:56 +0000 (19:27 -0800)]
altoslib: Only list flight logs for boards that we know have them

Boards that don't have flight logs will generate a nice 'Syntax Error'
and fail to initialize.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Log baro readings for MicroPeak
Keith Packard [Fri, 14 Dec 2012 19:11:39 +0000 (11:11 -0800)]
altos: Log baro readings for MicroPeak

This logs barometric data every 192ms (more or less) to the 504
remaining bytes of internal EEPROM storage in the ATtiny85. This
provides 48.192 seconds of logging.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Note that Lithium battery may be included with MicroPeak micropeak-1.1
Keith Packard [Thu, 13 Dec 2012 06:53:36 +0000 (22:53 -0800)]
altos: Note that Lithium battery may be included with MicroPeak

I'm not willing to say that we'll always be able to include a battery,
but we can certainly try, and they're certainly cheap enough that we
should.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'micropeak-1.1'
Keith Packard [Thu, 13 Dec 2012 06:36:59 +0000 (22:36 -0800)]
Merge branch 'micropeak-1.1'

7 years agodoc: Update MicroPeak doc to include EEPROM and programming info
Keith Packard [Thu, 13 Dec 2012 06:35:05 +0000 (22:35 -0800)]
doc: Update MicroPeak doc to include EEPROM and programming info

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'micropeak-1.1'
Keith Packard [Wed, 12 Dec 2012 19:10:14 +0000 (11:10 -0800)]
Merge branch 'micropeak-1.1'

7 years agoaltos: Log in-flight data for MicroPeak
Keith Packard [Wed, 12 Dec 2012 19:01:48 +0000 (11:01 -0800)]
altos: Log in-flight data for MicroPeak

This logs the low 16 bits of the pressure value to the remaining
on-chip eeprom. It can be read out with a standard AVR programming
dongle.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Add load-slow target for MicroPeak
Keith Packard [Wed, 12 Dec 2012 18:57:03 +0000 (10:57 -0800)]
altos: Add load-slow target for MicroPeak

This sets the programming clock to 1/4 of the 250kHz clock used by the
MicroPeak firmware, allowing the device to be reprogrammed.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Tim Van Milligan suggestion for µP -- delay before showing last flight
Keith Packard [Wed, 12 Dec 2012 07:43:30 +0000 (23:43 -0800)]
altos: Tim Van Milligan suggestion for µP -- delay before showing last flight

This gives the user time to move their finger out of the way of the LED.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'micropeak-1.1'
Keith Packard [Tue, 11 Dec 2012 22:42:43 +0000 (14:42 -0800)]
Merge branch 'micropeak-1.1'

7 years agoaltos: Increase MicroPeak blink times a bit
Keith Packard [Tue, 11 Dec 2012 22:41:53 +0000 (14:41 -0800)]
altos: Increase MicroPeak blink times a bit

make the 0 longer (1 sec now), and make the time between digits longer
(also 1 sec now)

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'micropeak-1.1'
Keith Packard [Mon, 10 Dec 2012 02:33:31 +0000 (18:33 -0800)]
Merge branch 'micropeak-1.1'

7 years agoaltos: Use alt_t value to hold displayed height in micropeak micropeak-build-2012-12-09
Keith Packard [Mon, 10 Dec 2012 02:28:33 +0000 (18:28 -0800)]
altos: Use alt_t value to hold displayed height in micropeak

Heights are 32 bits (to get .1 meter resolution) in micropeak; make
sure we have enough bits while blinking out the computed value.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Make sure pa to altitude conversion is done with 32 bits
Keith Packard [Mon, 10 Dec 2012 02:27:49 +0000 (18:27 -0800)]
altos: Make sure pa to altitude conversion is done with 32 bits

We need 32 bits to hold intermediate values, even if the final
altitude is reported in only 16 bits.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Store altitude in 32-bits for MicroPeak
Keith Packard [Sun, 9 Dec 2012 22:32:35 +0000 (14:32 -0800)]
altos: Store altitude in 32-bits for MicroPeak

Needs all 32 bits to store .1 meter resolution

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Stop including profiling and stack guard code in megametrum
Keith Packard [Sat, 8 Dec 2012 06:49:34 +0000 (22:49 -0800)]
altos: Stop including profiling and stack guard code in megametrum

These take CPU time and memory and are intended only for debugging

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Fix aprs test to not allow callsign configuration
Keith Packard [Sat, 8 Dec 2012 01:38:17 +0000 (17:38 -0800)]
altos: Fix aprs test to not allow callsign configuration

There's no configuration to take a callsign from...

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Add APRS interval configuration to UI
Keith Packard [Sat, 8 Dec 2012 01:35:15 +0000 (17:35 -0800)]
altosui: Add APRS interval configuration to UI

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'master' into aprs
Keith Packard [Sat, 8 Dec 2012 01:34:10 +0000 (17:34 -0800)]
Merge branch 'master' into aprs

7 years agoaltosui: Call config UI from AltosConfigData directly
Keith Packard [Sat, 8 Dec 2012 01:27:48 +0000 (17:27 -0800)]
altosui: Call config UI from AltosConfigData directly

Don't make AltosConfig have a pile of config code, stick that in
AltosConfigData instead. This uses a new interface, AltosConfigValues
to get from AltosConfigData to the UI.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Use configured callsign in APRS packets
Keith Packard [Sat, 8 Dec 2012 01:20:02 +0000 (17:20 -0800)]
altos: Use configured callsign in APRS packets

Instead of hard-coding my own call sign...

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Make APRS interval configurable
Keith Packard [Sat, 8 Dec 2012 01:18:32 +0000 (17:18 -0800)]
altos: Make APRS interval configurable

This provides a separate configuration value for APRS, allowing the
interval between APRS reports to vary.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltos: Fix up APRS packet sending code in cc1120 driver
Keith Packard [Fri, 7 Dec 2012 18:15:25 +0000 (10:15 -0800)]
altos: Fix up APRS packet sending code in cc1120 driver

This fixes the FIFO management, ensuring that the data are streamed
into the radio fast enough to keep the packet continuous. Sounds like
it works, but testing with an actual APRS receiver is required.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoMerge branch 'master' into aprs
Keith Packard [Fri, 7 Dec 2012 18:14:11 +0000 (10:14 -0800)]
Merge branch 'master' into aprs

7 years agoaltos: fix functions calling pollchar to use 'int' to hold the value
Keith Packard [Fri, 7 Dec 2012 18:05:51 +0000 (10:05 -0800)]
altos: fix functions calling pollchar to use 'int' to hold the value

AO_READ_AGAIN doesn't fit in a char anymore now that stdio is 8-bit
clean, everyone using pollchar must use an 'int' variable to capture
the whole value from pollchar.

Signed-off-by: Keith Packard <keithp@keithp.com>
7 years agoaltosui: Use AltosConfigData for altosui configuration dialog
Keith Packard [Fri, 7 Dec 2012 16:32:22 +0000 (08:32 -0800)]
altosui: Use AltosConfigData for altosui configuration dialog

Instead of a separate config language parser, share with altoslib

Signed-off-by: Keith Packard <keithp@keithp.com>