| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
| |
This uses the companion port chip select pins, which happen to be
connected to tim4.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This is needed to configure the PWM timer correctly
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix the CCMR1_OC1PE and CCMR2_OC3PE values.
Disable clock when no PWM outputs are running.
Fix the apb1enr value for the timer.
Set ARR value to PWM_MAX - 1 -- ARR is off by one.
Sets the GPIO pins to 40MHz bandwidth for sharper edges.
Tested on EasyMega, but that code is not included as it breaks the
companion protocol.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
The pad number was getting reset back to one when signal was lost,
causing pad one to get fired in this case even when already set to arm mode.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
Enter/leave drag race is done by rotating the box selector knob
to a new 'dr' position and then holding down the firing button; this
avoids a potential accidental firing if you somehow don't realize
you've armed the box before selecting drag race mode.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With the unit disarmed, press and hold the fire button for five
seconds to enable drag race mode.
The display will show 'dr' for five seconds and beep five times to
indicate that drag race mode is enabled. The decimal points in the
display will all be displayed as an additional visual aid. Once every
five seconds, it will beep.
With drag race mode enabled, you can select a box/pad pair and press
the 'fire' button to add it to the drag race group. For the current
box, all members of the drag race group will have their continuity
LEDs blink slowly. There will be no indication of continuity in this
mode; you'll want to check that before enabling drag race mode. If you
want to de-select a member of the group, just press the fire button
again. Each time you push the fire button, it will beep out the pad
number added or removed.
Arm the box and you will not be able to add or remove members from the
drag race group. Firing will simultaneously fire all members of the
drag race group.
To disable drag race mode, press and hold the fire button for two
seconds. It will beep twice and turn off the decimal points in the display.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This makes the lco management code support arming multiple pads and
firing all of them at once. The UI code does not expose this yet.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This exposes a simple bit-mask for setting the seven segments instead
of just allowing hex-decimal values.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This will let us do drag races by letting the LCO arm multiple boxes
and fire them all with a single command.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Thanks much to Rob Derstadt for discovering this bug!
TeleMetrum v2.0, TeleMega, EasyMega, TeleBalloon v2.0 all have
companion connectors and yet HAS_COMPANION was not defined. This
disabled companion telemetry packets on these products, but otherwise
didn't have any effect.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
There was an extra %d, and an extra ':' in the output, making the UI
not parse the voltage correctly
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Turn left past '1' and see the firing box battery voltage instead of
pushing the firing button with the box disarmed. This seems like a
safer UI.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
When the firing button is pressed while unarmed, show the telefire
battery voltage in the display.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
This ignores spurious packets for the purpose of showing the RSSI
value in telelco/telefire, avoiding warning about 'low RSSI' when the
radio receives noise.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Different radios will have different 'good' RSSI values, so let each
product configure it, leaving the default set to -90dBm, which is
a solid signal value for the CC1111.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Speed up flashing in default config
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This dumps the resulting binary and -load script into the Binaries
directory of the altusmetrumllc repo
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
I ended up building some cc1200-based boards with 32MHz xtals, so just
make this an option when building the driver.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
Instead of requiring that the whole set of returned values fit
precisely in the ring, allow for wrap-around so that we can fetch an
odd number of ADC values. The previous version required that the fetch
amount always be a factor of the ADC buffer size.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
These are allocated from the OpenMoko USB vendor ID page and offer a
more 'official' number than from using the 0xfffe space.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
ChaosKey will use an OpenMoko vid/pid, so we need the ability to
configure a different USB vendor ID for each product.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
The old eeprom format used different stoarge for the accel calibration
data, which doesn't matter to this code, but the change in the format
value does.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Adding the compressed/uncompressed config option broke the APRS test harness.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Flash loader uses pin configuration to set up GPIOs for boot selection
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
| |
The normal ARM padding would have filled this in correctly, but it's
best to be explicit about the structure.
This also adds a test to make sure the resulting telemetry declaration
is exactly 32 bytes,
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
| |
If AltosDroid manages to connect to the BT module before we've
configured it, we won't be able to talk to it as we can't force the
module to ignore connection attempts. Wait for AltosDroid to give up
and let us configure the device. Eventually, we'll manage, if
AltosDroid's delay interval is longer than the time it takes to
configure the unit.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
This provides a choice of compressed vs uncompressed when sending APRS
packets to deal with receivers that still do not have support for the
more useful compressed format.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This lets the extra allocations used from ao_usb_alloc_buffers be
allocated before the first USB connection happens.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Extra semicolon
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This was configuring the hardware wrong, and wasn't keeping the output
ring full.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
This lets some boards offer non-CDC class USB interfaces so that the
modem driver doesn't pick them up.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
While fixing the cc1200 configuration, I added some debug printfs to
this code. They were accidentally committed with the fix...
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The default bit timing adjustment mechanism allows for only a 0.2%
deviation from the programmed bit timing. I found one TeleMini device
which is beyond that tolerance as it was built with an older crystal
with more error.
Switch to the more expensive synchronization mechanism which allows up
to 2% timing error, but requires a multi-byte preamble (which we
have). This fixes packet mode nicely.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
sdcc won't embed these itself, and thus consumes too much flash for
telemetrum-v1.0
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Having arbitrary alarms firing in the middle of complicated device
logic makes no sense at all. Therefore only correct use of ao_alarm
and ao_clear_alarm was around a specific ao_sleep call, with correct
recovery in case the alarm fires.
This patch replaces all uses of ao_alarm/ao_sleep/ao_clear_alarm with
ao_sleep_for, a new function which takes the alarm timeout directly.
A few cases which weren't simply calling ao_sleep have been reworked
to pass the timeout value down to the place where sleep *is* being
called, and having that code deal with the return correctly.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Tom discovered that this was missing
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
With ao_packet_getchar returning 'char', AO_READ_AGAIN would get
converted to 0xff instead of -1 on return, making ao_packet_echo
either produce a bogus character on output, breaking command
responses, or wedge and never exit when the link was dropped.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Allow enabling telemetry when USB is connected without also enabling
the motion debugging output.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
There are just too many limitations in when interrupts are delivered
to make them useful. Instead, just drive the SPI directly with the
CPU. At higher spi speeds (6Mhz or more), it's probably faster to do
it this way anyways.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
The datasheet says that the maximum for back-to-back data is 6.5MHz.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
| |
This allocates twice the space in the USB memory so that transactions
can be double buffered without using separate CPU memory.
Signed-off-by: Keith Packard <keithp@keithp.com>
Conflicts:
src/lpc/ao_usb_lpc.c
|