| Commit message (Collapse) | Author | Age |
... | |
|
|
|
|
|
| |
We just don't have enough RAM for 8 samples.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Oops. 16 bits won't hold position information...
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
And only set this for tracker products; other products place state in
separate state packets
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
It's customized for TeleGPS uses
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
All products placing config and erase marks in on-CPU EEPROM needs to
configure the erase code correctly.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Also, logs 8 pre-launch GPS packets so we can get the ground position.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This will be useful with TeleGPS which has no other packet containing
flight state.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is mostly like the mega format, but places the flight state in a
spare byte of the GPS data and writes the gps starting location to the
flight packet.
Log data is written by the main tracker thread; there's no reason for
a separate thread given the GPS update rate and the lack of flight
controls. This means ao_log_gps has an API to be called from there,
rather than a thread to run.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Flight erase records are supposed to be written after the ao_config to
eeprom in telemega. They were getting written in the middle of one of
the pyro channel config blocks. Put a bunch of space between the two
by making the config max 1024 bytes instead of 128 bytes.
Set the log erase marker to 0x55 -- eeprom comes from the factory as
0x00, so we use any value other than 0x55 to indicate 'unused' erase
slots.
Save space for more flight erase blocks; we've got plenty.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
| |
When writing config/erase to eeprom, there's no 'erase' operation as
on-chip eeprom is writable at a byte level. As such, we can't tell
when the erase blocks get reset when the config gets written. When
this happens, erase block 0 gets written explicitly, so just use that
call to trigger explicit erasing of the data.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
on-chip eeprom doesn't erase to 0xff, so let TeleMega use a different
value.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
TeleMega config is 200 bytes. AO_CONFIG_MAX_SIZE was 128. That didn't
work out well when logging erased flight information. Allow TeleMega
to use a larger value (1k), and then do a compiler hack to make sure
the defined value is at least as large as the ao_config structure.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Doesn't make sense to be in product
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
We've got logging enabled now
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
And adjust default radio cal to be a bit closer
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
These don't have a USB connect indicator, so just turn on telemetry by
default
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
The LPC stuff isn't actually very useful and TeleGPS uses a custom pin
instead, and was using HAS_USB_CONNECT to mean the same thing. That
wasn't good.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Not just devices with flight
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This encodes the flight number for tracking of data files.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This lets us test the move from pad to drogue state
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
ao_distance takes (lat, lon, lat, lon) not (lat, lat, lon, lon)
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
Make sure log can start by scanning existing logs
Enable RDF by default
Turn off telemetry until we decide whether to turn it on in the loop
Allow TeleGPS v0.3 to run without ADC
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Useful for TeleGPS
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Avoids early GPS noise right after lock
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Just adjust to avoid sensing motion from GPS noise
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Need to shift everyone right one bit to fit in 32 bits
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
TeleGPS just wants full power, so remove the configuration option
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This lets TeleGPS use the logging infrastructure without wasting a
task to log sensor data
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This replaces the flight code to monitor GPS state and switch flight
states between startup/pad/drogue
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This is not a great circle distance, but should be good enough for
points reasonably close together
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
These fields are uint8_t, not int16_t. Fetching and storing 16 bits is
a bad idea.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
"f>=" needs four bytes, not just three to store the whole string. If
we only store three, then we never manage to compare correctly as the
null terminating byte is missing.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Increase the command buffer from 48 to 128 bytes to hold the longest
pyro configuration commands
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
When the device hasn't moved for a while, stop logging data. Start as
soon as it moves again.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Verify fixed point version against naïve implementation
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
APRS altitude is logarithmically encoded, so this implementation
includes a fixed point log-base-2 function along with a bit of other
fixed point stuff. This eliminates all floating point from TeleGPS,
saving around 4kB of code space.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Redirects data input from local sensors to USB sourced data, leaving
USB enabled when the computer goes into pad mode.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
This switches from hand-coding the ao_config structure to using
ao_config.h and also updates the ADC structure for ao_flight_test_mega
to using the same one as telemega does natively
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
No sense leaving these in ao.h, and it's nice to make that file smaller
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This will let the fake flight code update it as necessary, without
creating a new interface in ao_ms5607.c
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
TeleGPS switches from 'pad' to 'drogue' states after the device moves
a specified distance from the initial starting point. These values can
be configured, and this is the configuration for them.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This gets ao_flight_test_mega working with eeprom files
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
APRS now includes sat info, so we have to fake that up to generate an
APRS test file
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This lets applications set the desired GPS update rate to reduce power usage
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
New compiler warning flags and moving to the nxp require a few minor
changes in the code to make it work.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Don't require apogee and main voltages as well
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|