fw/altos
10 years agoWas missing v_batt in adc dump command 0.1
Keith Packard [Sun, 26 Apr 2009 23:04:07 +0000 (16:04 -0700)]
Was missing v_batt in adc dump command

10 years agoAdd manual ignition and igniter test commands
Keith Packard [Sun, 26 Apr 2009 22:38:28 +0000 (15:38 -0700)]
Add manual ignition and igniter test commands

10 years agoClean up commands a bit
Keith Packard [Sun, 26 Apr 2009 22:38:03 +0000 (15:38 -0700)]
Clean up commands a bit

10 years agoClear more files on make clean
Keith Packard [Sun, 26 Apr 2009 22:08:58 +0000 (15:08 -0700)]
Clear more files on make clean

10 years agoLabel binaries with product and serial info
Keith Packard [Sun, 26 Apr 2009 22:05:29 +0000 (15:05 -0700)]
Label binaries with product and serial info

10 years agoMake sure full log is written and flushed on landing.
Keith Packard [Sun, 26 Apr 2009 08:37:02 +0000 (01:37 -0700)]
Make sure full log is written and flushed on landing.

The final state change to landing is recorded in the logging thread, so have
that turn off logging once it has recorded that state. Then make it go to
sleep.

10 years agoClean up monitor output a bit
Keith Packard [Sun, 26 Apr 2009 08:36:53 +0000 (01:36 -0700)]
Clean up monitor output a bit

10 years agoAdd configuration support
Keith Packard [Sun, 26 Apr 2009 07:11:32 +0000 (00:11 -0700)]
Add configuration support

Current config variables:
Main deploy altitude above launch (in meters)
Acceleration zero g calibration (manual or automatic)
Radio channel (freq = 435.550MHz + channel * 100kHz)
Callsign (max 8 characters)

Supporting this involved shuffling code around so that the
non-telemetrum builds could include only the stuff they needed.

10 years agoAllow for slower ADC operation. Add power saving code.
Keith Packard [Sat, 25 Apr 2009 21:44:33 +0000 (14:44 -0700)]
Allow for slower ADC operation. Add power saving code.

This tries to make the flight computer use less power by disabling USB in
flight mode, lowering the telemetry rate after ascent. It also disables the
RDF beacon during ascent and re-enables it once descent has started.

10 years agoAllow ADC to be disabled
Keith Packard [Sat, 25 Apr 2009 21:44:04 +0000 (14:44 -0700)]
Allow ADC to be disabled

10 years agoPlace CPU in P0 state while idle
Keith Packard [Sat, 25 Apr 2009 21:43:23 +0000 (14:43 -0700)]
Place CPU in P0 state while idle

10 years agoAdd RDF beacon and callsign to telemetry
Keith Packard [Sat, 25 Apr 2009 21:42:20 +0000 (14:42 -0700)]
Add RDF beacon and callsign to telemetry

10 years agoAdd radio code to emit a 1kHz tone
Keith Packard [Sat, 25 Apr 2009 21:40:51 +0000 (14:40 -0700)]
Add radio code to emit a 1kHz tone

10 years agoAllow the USB system to be disabled/enabled at run-time
Keith Packard [Sat, 25 Apr 2009 20:18:37 +0000 (13:18 -0700)]
Allow the USB system to be disabled/enabled at run-time

10 years agoMake LED usage depend on target device
Keith Packard [Sat, 25 Apr 2009 20:16:27 +0000 (13:16 -0700)]
Make LED usage depend on target device

10 years agoMake some functions reentrant to save DSEG space
Keith Packard [Sat, 25 Apr 2009 20:13:24 +0000 (13:13 -0700)]
Make some functions reentrant to save DSEG space

10 years agoAdd monitor task to flight software
Keith Packard [Sat, 25 Apr 2009 02:17:37 +0000 (19:17 -0700)]
Add monitor task to flight software

Allows the use of telemetrum in teledongle mode.

10 years agoReport difference from ground to max altitude at landing
Keith Packard [Sat, 25 Apr 2009 02:17:19 +0000 (19:17 -0700)]
Report difference from ground to max altitude at landing

10 years agoDisplay data with units while running simulation
Keith Packard [Sat, 25 Apr 2009 02:16:29 +0000 (19:16 -0700)]
Display data with units while running simulation

10 years agoEnabling apogee detect via speed: < 200m/s && < max_speed - 50m/s
Keith Packard [Sat, 25 Apr 2009 02:13:31 +0000 (19:13 -0700)]
Enabling apogee detect via speed: < 200m/s && < max_speed - 50m/s

This change ensures that we actually got going fairly fast, and then slowed
down a bunch before enabling apogee detect. Otherwise, we'll detect apogee
right off the pad as we're not going very fast at that point...

This also adds the 'f' command to show the current flight status on the USB
port.

10 years agoconfigure igniter ports, set values to measured ones
Keith Packard [Sat, 25 Apr 2009 02:12:28 +0000 (19:12 -0700)]
configure igniter ports, set values to measured ones

10 years agoMove ao_led_init to end of file to be consistent with other files
Keith Packard [Sat, 25 Apr 2009 02:11:40 +0000 (19:11 -0700)]
Move ao_led_init to end of file to be consistent with other files

10 years agoDefine ao_state_names in ao.h so other people can share
Keith Packard [Sat, 25 Apr 2009 02:10:20 +0000 (19:10 -0700)]
Define ao_state_names in ao.h so other people can share

10 years agoBump NUM_CMDS to 10
Keith Packard [Sat, 25 Apr 2009 02:09:31 +0000 (19:09 -0700)]
Bump NUM_CMDS to 10

10 years agoMove beep_init to end of file to be consistent with other files
Keith Packard [Sat, 25 Apr 2009 02:09:09 +0000 (19:09 -0700)]
Move beep_init to end of file to be consistent with other files

10 years agoUpdate flight algorithm based on data collected from SN-1 Flight 1
Keith Packard [Fri, 24 Apr 2009 17:19:31 +0000 (10:19 -0700)]
Update flight algorithm based on data collected from SN-1 Flight 1

This now correctly sequences through the flight data collected from the
first TeleMetrum test flight.

This also completes up the flight algorithm test harness (ao_flight_test),
which runs the flight algorithm on the Linux host from a captured data log.

10 years agoAdd igniters and update flight control algorithm
Keith Packard [Fri, 24 Apr 2009 05:17:44 +0000 (22:17 -0700)]
Add igniters and update flight control algorithm

10 years agoAvoid ram from 0xfda2 through feff, its funky
Keith Packard [Fri, 24 Apr 2009 07:15:09 +0000 (00:15 -0700)]
Avoid ram from 0xfda2 through feff, its funky

10 years agoremove ao_flight_test until its ready
Keith Packard [Fri, 24 Apr 2009 05:18:33 +0000 (22:18 -0700)]
remove ao_flight_test until its ready

10 years agoAdd teledongle module
Keith Packard [Fri, 24 Apr 2009 03:50:07 +0000 (20:50 -0700)]
Add teledongle module

10 years agoSet telemetry rate to 100ms
Keith Packard [Thu, 23 Apr 2009 21:26:01 +0000 (14:26 -0700)]
Set telemetry rate to 100ms

10 years agoWrong license on ao_monitor.c
Keith Packard [Thu, 23 Apr 2009 21:23:26 +0000 (14:23 -0700)]
Wrong license on ao_monitor.c

10 years agoCrank up radio to 10dBm
Keith Packard [Thu, 23 Apr 2009 21:23:00 +0000 (14:23 -0700)]
Crank up radio to 10dBm

10 years agoAdd COPYING file
Keith Packard [Wed, 22 Apr 2009 23:03:28 +0000 (16:03 -0700)]
Add COPYING file

10 years agoClean up TeleTerra files
Keith Packard [Wed, 22 Apr 2009 22:55:01 +0000 (15:55 -0700)]
Clean up TeleTerra files

10 years agosimplify ao_time function
Keith Packard [Wed, 22 Apr 2009 22:53:55 +0000 (15:53 -0700)]
simplify ao_time function

10 years agoOne line radio status
Keith Packard [Wed, 22 Apr 2009 22:53:46 +0000 (15:53 -0700)]
One line radio status

10 years agoAdd new binaries to .gitignore
Keith Packard [Wed, 22 Apr 2009 22:49:16 +0000 (15:49 -0700)]
Add new binaries to .gitignore

10 years agoSpeed up dbg port bit frobbing
Keith Packard [Wed, 22 Apr 2009 22:49:00 +0000 (15:49 -0700)]
Speed up dbg port bit frobbing

10 years agoUse sdcc from path
Keith Packard [Wed, 22 Apr 2009 22:48:28 +0000 (15:48 -0700)]
Use sdcc from path

10 years agoClean up task list formatting
Keith Packard [Wed, 22 Apr 2009 22:48:14 +0000 (15:48 -0700)]
Clean up task list formatting

10 years agoControl radio monitoring with the M command
Keith Packard [Wed, 22 Apr 2009 22:47:57 +0000 (15:47 -0700)]
Control radio monitoring with the M command

10 years agoClean up telemetry now that all packets are the same
Keith Packard [Tue, 21 Apr 2009 09:07:24 +0000 (02:07 -0700)]
Clean up telemetry now that all packets are the same

10 years agoAdd longer debug delays to reset/debug_mode entry
Keith Packard [Tue, 21 Apr 2009 09:07:08 +0000 (02:07 -0700)]
Add longer debug delays to reset/debug_mode entry

10 years agoFix up fancy dbg stuff. Add teleterra initial bits.
Keith Packard [Tue, 21 Apr 2009 08:17:03 +0000 (01:17 -0700)]
Fix up fancy dbg stuff. Add teleterra initial bits.

The dbg stuff needed a bit of help to actually walk the tables; it appears
that complex expressions confuse sdcc.

This also adds primitive teleterra bits, but no UI, etc.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd radio support. Build separate executables for TeleMetrum and the TI dongle
Keith Packard [Tue, 21 Apr 2009 06:33:41 +0000 (23:33 -0700)]
Add radio support. Build separate executables for TeleMetrum and the TI dongle

Ok, way too big a patch, but things were in rough shape.
This patch adds support for the radio, both transmit and receive.
Then, because I could no longer run the TeleMetrum code on the TI
dongle, I ended up building a separate image for the TI board, which
involved creating a mechanism for having multiple command sets and splitting
code for different functions into different files.

10 years agoStart using pdata area for less-frequently used data sn1-flight1
Keith Packard [Sun, 19 Apr 2009 06:19:24 +0000 (23:19 -0700)]
Start using pdata area for less-frequently used data

10 years agoSlow down panic presentation
Keith Packard [Sun, 19 Apr 2009 06:19:05 +0000 (23:19 -0700)]
Slow down panic presentation

10 years agoParse GPS data locally. Add 'g' command to display recent GPS results.
Keith Packard [Sun, 19 Apr 2009 06:17:45 +0000 (23:17 -0700)]
Parse GPS data locally. Add 'g' command to display recent GPS results.

This parses the GPS GGA message and stores it in a global variable,
protected by a mutex.

10 years agoAdd task names and 'T' command to show task status.
Keith Packard [Sun, 19 Apr 2009 06:16:01 +0000 (23:16 -0700)]
Add task names and 'T' command to show task status.

The T command shows the current wchan and PC for each task in the system.

10 years agoFix GPL version at 2
Keith Packard [Sun, 19 Apr 2009 02:32:18 +0000 (19:32 -0700)]
Fix GPL version at 2

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd gps, debug dongle support and pressure alt tables
Keith Packard [Sat, 18 Apr 2009 06:38:14 +0000 (23:38 -0700)]
Add gps, debug dongle support and pressure alt tables

GPS also pulled in serial support. The altitude tables take raw 11-bit
pressure sample numbers and convert them to standard pressure altitude
values.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoMove a bunch of variables from __data to __xdata
Keith Packard [Wed, 15 Apr 2009 21:25:26 +0000 (14:25 -0700)]
Move a bunch of variables from __data to __xdata

10 years agoSlow down panic code, disable interrupts
Keith Packard [Wed, 15 Apr 2009 04:25:15 +0000 (21:25 -0700)]
Slow down panic code, disable interrupts

10 years agoKeep reporting flight state while it changes
Keith Packard [Wed, 15 Apr 2009 04:24:25 +0000 (21:24 -0700)]
Keep reporting flight state while it changes

10 years agouse red LED to indicate system startup
Keith Packard [Wed, 15 Apr 2009 04:23:55 +0000 (21:23 -0700)]
use red LED to indicate system startup

10 years agoUse ao_ee_flush_internal while holding mutex
Keith Packard [Wed, 15 Apr 2009 04:23:13 +0000 (21:23 -0700)]
Use ao_ee_flush_internal while holding mutex

10 years agoLeave beeping and lights to the flight code
Keith Packard [Wed, 15 Apr 2009 04:22:56 +0000 (21:22 -0700)]
Leave beeping and lights to the flight code

10 years agoMake mutex functions reentrant
Keith Packard [Wed, 15 Apr 2009 04:22:31 +0000 (21:22 -0700)]
Make mutex functions reentrant

10 years agoAdd in existing flight pieces: flight/report/log
Keith Packard [Wed, 15 Apr 2009 02:08:01 +0000 (19:08 -0700)]
Add in existing flight pieces: flight/report/log

These pieces come from the old telemetrum firmware.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd eeprom driver and command loop
Keith Packard [Tue, 14 Apr 2009 21:21:56 +0000 (14:21 -0700)]
Add eeprom driver and command loop

This involved adding dma control and a mutex implementation.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoSwitch from --model-large to --model-small
Keith Packard [Tue, 14 Apr 2009 18:04:09 +0000 (11:04 -0700)]
Switch from --model-large to --model-small

This shrinks the application quite a bit, and should make it faster as well.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd comments, clean up white space, etc.
Keith Packard [Tue, 14 Apr 2009 17:02:19 +0000 (10:02 -0700)]
Add comments, clean up white space, etc.

Various clean ups now that the basic code appears to work.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoSwitch USB to double-buffered
Keith Packard [Tue, 14 Apr 2009 04:58:07 +0000 (21:58 -0700)]
Switch USB to double-buffered

10 years agoFix USB input/output by reloading packet limits.
Keith Packard [Tue, 14 Apr 2009 04:51:59 +0000 (21:51 -0700)]
Fix USB input/output by reloading packet limits.

The USB controller is reset during the connection process, which clears the
packet limits set in the controller at initialization time. Reload those
values when the configuration is set.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoUSB working up through reading strings
Keith Packard [Tue, 14 Apr 2009 03:39:46 +0000 (20:39 -0700)]
USB working up through reading strings

10 years agoAdd USB support.
Keith Packard [Mon, 13 Apr 2009 20:51:08 +0000 (13:51 -0700)]
Add USB support.

This offers a single CDC ACM device over USB.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd beep/led support.
Keith Packard [Mon, 13 Apr 2009 06:53:55 +0000 (23:53 -0700)]
Add beep/led support.

Support our P2_0 connected buzzer, and formalize LED output support.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd A/D sampler
Keith Packard [Mon, 13 Apr 2009 06:17:16 +0000 (23:17 -0700)]
Add A/D sampler

Sample A/D at the timer tick, placing data in a ring
of samples.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 years agoAdd 100Hz timer
Keith Packard [Mon, 13 Apr 2009 05:52:47 +0000 (22:52 -0700)]
Add 100Hz timer

Use Timer 1 to generate a 100Hz timer interrupt

10 years agoUpdate README
Keith Packard [Mon, 13 Apr 2009 04:58:49 +0000 (21:58 -0700)]
Update README

10 years agoGPL Version 2 only
Keith Packard [Mon, 13 Apr 2009 04:52:56 +0000 (21:52 -0700)]
GPL Version 2 only

10 years agoMake test more complicated
Keith Packard [Mon, 13 Apr 2009 04:33:55 +0000 (21:33 -0700)]
Make test more complicated

10 years agoSP points at last pushed byte
Keith Packard [Mon, 13 Apr 2009 04:33:46 +0000 (21:33 -0700)]
SP points at last pushed byte

10 years agoAdd .gitignore
Keith Packard [Mon, 13 Apr 2009 03:27:03 +0000 (20:27 -0700)]
Add .gitignore

10 years agoInitial AltOS import
Keith Packard [Mon, 13 Apr 2009 03:25:39 +0000 (20:25 -0700)]
Initial AltOS import