| Commit message (Collapse) | Author | Age |
... | |
|
|
|
|
|
|
|
|
|
|
| |
Oops. TeleDongle was starting the packet slave code, which kinda
wrecked its ability to receive telemetry packets. This patch simply
removes the packet slave code from teledongle as it cannot be used
(yet), it also makes the packet slave code initialization take a
parameter which controls whether to start that by default; in the
future, perhaps TeleDongle will gain a command to start packet slave mode.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
The baro sensor generates too much noise to use small changes in
computed speed or acceleration to cause a false launch detect.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This is a lot more useful than the old filtered pressure data.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
This runs a long list of flights (there's a user-specific path
pointing at the flights) and squawks if the baro and dual flight
computers don't match.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Also, remove accel cal code from boards without accel
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This just uses the TeleMini bits, which should work fine for now.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
| |
Initialize the flight log for tiny systems by scanning the log area to
find the current flight number and log area bounds.
Stop logging data when the flight is over, or when the log area is
full.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
This adds a baro-only kalman filter to track the state of the rocket,
and then uses it to control flight events instead of the existing
ad-hoc mechanisms.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
| |
This splits the logging code into management of the log space within
storage and separate code to actually write suitable log entries. A
new log writing module, ao_log_tiny, is added which writes only
altimeter data at a fairly low data rate for devices using on-chip
storage.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
| |
|
|
|
|
|
|
|
|
|
| |
The docs say that if you are executing from flash, then the CPU will
stall after a flash write or erase command is started until the
operation is complete. Take advantage of that to simplify the flash
code.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
need to actually alternate the LED/tone with some space so you can
count.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
TeleMini has fewer sensors and uses P0 for igniters instead of P2.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
We're using the LEDs instead of tones, so make red mean 'low tone',
green mean 'middle tone' and both mean 'high tone'.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Require firmware to specify the end of its codespace in its Makefile,
and use this to determine where the start of available flash is. Should
give compile time errors if either there's no room left for storage, or
if there's not enough room for code.
|
|
|
|
|
|
|
| |
This adds initial code for the telemini board, a two channel
flight computer with digital telemetry and a barometric sensor.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Instead of turning slave mode on in idle mode, start with it running
and disable it in pad mode instead. This means packet mode is
available in startup mode too.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This builds the flight code in baro-only mode for testing.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Fix up ao_convert.c so that it can be used within the flight test code
instead of having a (broken) copy of the code there.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Not all boards will have these, so fix places that use them to deal
with that.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
| |
Makes any free pages at end of CC1111's internal flash available via
the ao_storage API.
|
|
|
|
|
|
|
| |
I didn't merge this carefully enough and managed to lose the 'f'
and 'e' commands, which are kinda useful.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Switch to using { func, "X args\0Desc" } to specify command, saving
a char field by looking at help[0] instead, and reduce help length by
doing alignment with printf instead of hardcoded spaces.
|
|
|
|
|
|
|
| |
This reverts commit b080e933a65d268aaaec8cfd5f617a13d5babc43.
10Hz data isn't any better than 1Hz data; it still doesn't like going
upwards rapidly.
|
|
|
|
|
| |
Send commands to skytraq to update baud rate to 57,600 bps, and
set NMEA output rate to 10Hz.
|
|
|
|
|
| |
Added macros to make correctly constructing skytraq commands easier.
Simplified code path for NMEA processing marginally.
|
| |
|
|
|
|
|
|
|
|
|
| |
The flight test code had static accelerometer configuration values,
making it impossible to use data from different boards without
recompiling. As the eeprom and telem log files both contain the
necessary data, parse that instead.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Yes, it would be nice to automate dependency generation here, but I
can't be bothered.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
New boards have no config space values at all, and so they need each
value to be set. Yes, this should be fixed so that there aren't two
copies of these assignments.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
When the 3.3V and 5V values shift relative to each other (usually due
to changes in power consumption), the measured acceleration will
appear to shift. This patch converts the 3.3V referenced acceleration
value into a 5V referenced acceleration, eliminating this error.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This stores the address of the desired sample in a local variable and
then fetches through that. Saves quite a few instructions.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This places the 5v reference samples in an array parallel to the basic
ADC values. It doesn't do anything with the values, just stores them.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Instead of having everyone wait on the raw ADC ring, have the flight
code wait on that and have everyone else wait for the flight code to
finish looking at the data and move its pointer forwards.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Use the provided ground acceleration average to set the two
accelerometer calibration values so that the flight code will
detect pad/idle mode correctly.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Slightly reduces code space.
Uncalibrated accelerometer now enters invalid state as well.
Signed-off-by: Mike Beattie <mike@ethernal.org>
|
|
|
|
|
|
|
| |
The flight test harness needs to expose every function used by the
flight code in some form, and this macro is about to become used.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Chose invalid flight mode instead of idle to give user feedback.
Signed-off-by: Mike Beattie <mike@ethernal.org>
|
|
|
|
|
|
|
| |
When detecting flight or idle mode, this should indicate
that accel cal values are out of whack.
Signed-off-by: Mike Beattie <mike@ethernal.org>
|
|
|
|
|
|
|
| |
This lets us use a simple shift instead of a divide, saving a huge
amount of code space.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
| |
Splitting this into several smaller functions appears to make SDCC
generate better code.
|
|
|
|
|
|
|
| |
When the log storage is full, make sure any pending writes are flushed
out so that the last bit isn't lost.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
| |
What a terrible mistake! The flight computer serial numbers were
recorded in only 8 bits, so serial numbers > 255 would get truncated.
There's really no fix other than bumping the field to 16 bits and
reflashing every TM and TD on the planet. Very unfortunate.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Zero is not a valid flight number, and ao_log_flight uses that to
indicate 'no flight in this slot'. Check the user-provided input for
zero before looking through the slots.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Just a silly off-by-one error when printing out the data received from flash.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
These are all initialized in the ao_flight_drogue state transition.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Presumably left-over debugging code.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Reports special tone along with the continuity checks.
Reports flight 0 in telemetry.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Make sure the amount of memory requested for a single log isn't more
than is available on the device.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This reduces the size of data and code needed to report the
flight states
Signed-off-by: Keith Packard <keithp@keithp.com>
|