]> git.gag.com Git - fw/altos/log
fw/altos
9 months agofirst cut at some code for EasyCamera v1p1
Bdale Garbee [Sun, 21 Jan 2024 00:17:22 +0000 (17:17 -0700)]
first cut at some code for EasyCamera v1p1

9 months agomap-server: Make sample map tile fetch script use valid zoom
Keith Packard [Sun, 11 Aug 2024 22:43:01 +0000 (15:43 -0700)]
map-server: Make sample map tile fetch script use valid zoom

Need to use an in-range value or the server will just ignore it.

Signed-off-by: Keith Packard <keithp@keithp.com>
9 months agoaltoslib: Ignore content-length when fetching map tiles
Keith Packard [Sun, 11 Aug 2024 22:40:49 +0000 (15:40 -0700)]
altoslib: Ignore content-length when fetching map tiles

Apache has been "fixed" to no longer respect any content-length
provided by a CGI script. This means we don't get the length of the
image from the server anymore. Ignore it and just keep fetching until
we hit the end.

Signed-off-by: Keith Packard <keithp@keithp.com>
9 months agodoc: Add EasyMega v3 to doc/specs.inc
Keith Packard [Mon, 5 Aug 2024 18:55:37 +0000 (11:55 -0700)]
doc: Add EasyMega v3 to doc/specs.inc

New IMU setup, otherwise the same

Signed-off-by: Keith Packard <keithp@keithp.com>
9 months agoAdd a note about specs.inc to Releasing
Keith Packard [Mon, 5 Aug 2024 18:54:52 +0000 (11:54 -0700)]
Add a note about specs.inc to Releasing

Yet another release process step we missed

Signed-off-by: Keith Packard <keithp@keithp.com>
9 months agoVersion 1.9.19
Keith Packard [Fri, 2 Aug 2024 15:58:44 +0000 (08:58 -0700)]
Version 1.9.19

Signed-off-by: Keith Packard <keithp@keithp.com>
9 months agoAdd easymega v3.0 firmware to fat images
Keith Packard [Fri, 2 Aug 2024 15:57:39 +0000 (08:57 -0700)]
Add easymega v3.0 firmware to fat images

Signed-off-by: Keith Packard <keithp@keithp.com>
9 months agodoc: Version 1.9.19 release notes
Keith Packard [Fri, 2 Aug 2024 15:53:56 +0000 (08:53 -0700)]
doc: Version 1.9.19 release notes

Signed-off-by: Keith Packard <keithp@keithp.com>
9 months agocapture link for EasyMini production scripts
Bdale Garbee [Fri, 2 Aug 2024 16:26:43 +0000 (10:26 -0600)]
capture link for EasyMini production scripts

9 months agoproduction bench scripts for EasyMega v3
Bdale Garbee [Fri, 2 Aug 2024 16:25:15 +0000 (10:25 -0600)]
production bench scripts for EasyMega v3

9 months agomake EasyMini v2.1 our "current" thing to flash/cal/test
Bdale Garbee [Wed, 29 May 2024 19:54:06 +0000 (13:54 -0600)]
make EasyMini v2.1 our "current" thing to flash/cal/test

9 months agoao-accel-cal: Validate ADXL375 sensitivity
Keith Packard [Wed, 31 Jul 2024 20:12:04 +0000 (13:12 -0700)]
ao-accel-cal: Validate ADXL375 sensitivity

If the accel device is an ADXL375, make sure the Z axis sensitivity is
within the data sheet range of 18.4 to 22.6 g. Allow for rounding as the
device only records the integer value (sigh).

Signed-off-by: Keith Packard <keithp@keithp.com>
9 months agosrc: Open up the ADXL375 self test range
Keith Packard [Wed, 31 Jul 2024 19:06:43 +0000 (12:06 -0700)]
src: Open up the ADXL375 self test range

Reading the datasheet more carefully, we discover that it mentions
that the self test magnitude can vary within a rather wide range.

Signed-off-by: Keith Packard <keithp@keithp.com>
10 months agoMerge branch 'master' of ssh://git.gag.com/scm/git/fw/altos
Bdale Garbee [Wed, 31 Jul 2024 18:01:27 +0000 (12:01 -0600)]
Merge branch 'master' of ssh://git.gag.com/scm/git/fw/altos

10 months agoinclude EasyMega v3 firmware in that captured in LLC repo during release
Bdale Garbee [Wed, 31 Jul 2024 18:01:00 +0000 (12:01 -0600)]
include EasyMega v3 firmware in that captured in LLC repo during release

10 months agoao-bringup: Re-add cal-freq
Keith Packard [Sat, 27 Jul 2024 21:59:39 +0000 (14:59 -0700)]
ao-bringup: Re-add cal-freq

This got deleted by mistake

Signed-off-by: Keith Packard <keithp@keithp.com>
10 months agodoc: reflect move of mailing list from lists.gag.com to groups.io
Bdale Garbee [Tue, 16 Jul 2024 23:49:31 +0000 (17:49 -0600)]
doc: reflect move of mailing list from lists.gag.com to groups.io

10 months agodoc: EasyTimer v2.0 also has mag sensor
Bdale Garbee [Tue, 16 Jul 2024 23:44:51 +0000 (17:44 -0600)]
doc: EasyTimer v2.0 also has mag sensor

10 months agodocs: correct EasyMotor v3.0 battery in specs table
Bdale Garbee [Tue, 16 Jul 2024 23:41:32 +0000 (17:41 -0600)]
docs: correct EasyMotor v3.0 battery in specs table

11 months agodoc: clarify how EasyMotor gets put into idle mode
Bdale Garbee [Tue, 25 Jun 2024 18:11:31 +0000 (12:11 -0600)]
doc: clarify how EasyMotor gets put into idle mode

11 months agoMerge branch 'master' of ssh://git.gag.com/scm/git/fw/altos
Bdale Garbee [Mon, 24 Jun 2024 15:03:17 +0000 (09:03 -0600)]
Merge branch 'master' of ssh://git.gag.com/scm/git/fw/altos

11 months agodoc: add Terry Lee's TRA and NAR numbers to TeleLaunch doc as his request
Bdale Garbee [Mon, 24 Jun 2024 15:02:46 +0000 (09:02 -0600)]
doc: add Terry Lee's TRA and NAR numbers to TeleLaunch doc as his request

11 months agoaltoslib: Check for negative tick wrap when importing flight records
Keith Packard [Thu, 20 Jun 2024 22:35:38 +0000 (15:35 -0700)]
altoslib: Check for negative tick wrap when importing flight records

If the tick count wraps just as boost is detected, there may be some
data records on the device with large tick values which are recorded
after the AO_FLIGHT record. Check for these in two places which manage
16-bit tick values by wrapping tick values to negative numbers in
those cases.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 months agoaltosui: Don't add pyro table to graph UI when npyro == MISSING
Keith Packard [Thu, 20 Jun 2024 22:34:44 +0000 (15:34 -0700)]
altosui: Don't add pyro table to graph UI when npyro == MISSING

For some reason, npyro is set to MISSING in some flight records. Check
for that before adding pyro info.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 months agotelelco-v3.0: Support ambient light sensor
Keith Packard [Thu, 20 Jun 2024 06:02:30 +0000 (23:02 -0700)]
telelco-v3.0: Support ambient light sensor

A TEPT5700 ALS and 15k resistor from 3.3V to ground hooked to ADC10 on
PC0.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 months agoaltos/telelco-v3.0: Merge info into one screen
Keith Packard [Wed, 12 Jun 2024 03:53:25 +0000 (20:53 -0700)]
altos/telelco-v3.0: Merge info into one screen

Move all of the info bits from separate screens to a single
screen. Eliminate the contrast screen, plan on eliminating the
backlight screen once we've switched to an ALS.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 months agoaltos/telelco-v3.0: Swap version and serial on info page
Keith Packard [Tue, 11 Jun 2024 23:26:16 +0000 (16:26 -0700)]
altos/telelco-v3.0: Swap version and serial on info page

Rationale is that model and sn are part of the hardware, version is
fw, call and freq are config.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 months agoaltos/telelco-v3.0: Display good vs bad packets received
Keith Packard [Mon, 10 Jun 2024 21:31:11 +0000 (14:31 -0700)]
altos/telelco-v3.0: Display good vs bad packets received

Signed-off-by: Keith Packard <keithp@keithp.com>
11 months agoaltos/telelco-v3.0: Add "Scanning..." to startup screen
Keith Packard [Mon, 10 Jun 2024 20:47:41 +0000 (13:47 -0700)]
altos/telelco-v3.0: Add "Scanning..." to startup screen

Make it clear what's going on. Had to shrink the logo to make room, so
switched from 26 to 24 point text.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 months agoaltos/telelco-v3.0: Delete debug code
Keith Packard [Mon, 10 Jun 2024 20:37:47 +0000 (13:37 -0700)]
altos/telelco-v3.0: Delete debug code

Remove the display debugging code which is no longer used.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 months agosrc/telelco-v3.0: Increase LED test time to 1 second
Keith Packard [Mon, 10 Jun 2024 20:31:05 +0000 (13:31 -0700)]
src/telelco-v3.0: Increase LED test time to 1 second

Make it possible to verify all LEDs active during testing.

Signed-off-by: Keith Packard <keithp@keithp.com>
12 months agoaltos/easymega-v3.0: Add combined dfu and ihx targets
Keith Packard [Tue, 21 May 2024 04:22:33 +0000 (21:22 -0700)]
altos/easymega-v3.0: Add combined dfu and ihx targets

Build these for testing the boards at Seeed

Signed-off-by: Keith Packard <keithp@keithp.com>
12 months agoaltosui: Add config and pyro tabs to graph widget
Keith Packard [Sun, 12 May 2024 02:03:51 +0000 (19:03 -0700)]
altosui: Add config and pyro tabs to graph widget

Show the flight computer configuration in the graph when available.

Signed-off-by: Keith Packard <keithp@keithp.com>
12 months agoaltos/test: Get the flight software test code working again
Keith Packard [Sun, 12 May 2024 00:52:20 +0000 (17:52 -0700)]
altos/test: Get the flight software test code working again

This had gotten very stale; much hacking was required. I know the
TeleMega v4 code works, other things "might". At least it seems to
build without errors?

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agofirst cut at turnon scripts for EasyTimer v2
Bdale Garbee [Mon, 29 Apr 2024 17:41:48 +0000 (11:41 -0600)]
first cut at turnon scripts for EasyTimer v2

13 months agoremove garbage line from easymotor turnon script
Bdale Garbee [Mon, 29 Apr 2024 17:20:53 +0000 (11:20 -0600)]
remove garbage line from easymotor turnon script

13 months agoaltos/easymini-v2.0: Remove combined .dfu file
Keith Packard [Mon, 29 Apr 2024 04:19:58 +0000 (21:19 -0700)]
altos/easymini-v2.0: Remove combined .dfu file

This is delivered to seeed for testing the hardware.

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agocapture things learned during 1.9.18 release
Bdale Garbee [Mon, 29 Apr 2024 02:44:55 +0000 (20:44 -0600)]
capture things learned during 1.9.18 release

13 months agoVersion 1.9.18
Keith Packard [Sun, 28 Apr 2024 22:34:13 +0000 (15:34 -0700)]
Version 1.9.18

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agodoc: Add 1.9.18 release notes
Keith Packard [Sun, 28 Apr 2024 05:30:29 +0000 (22:30 -0700)]
doc: Add 1.9.18 release notes

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agoaltos/draw: Add 'install' target
Keith Packard [Mon, 29 Apr 2024 01:34:30 +0000 (18:34 -0700)]
altos/draw: Add 'install' target

Needed for building packages; install is a no-op in this directory.

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agoFix up fat build target
Keith Packard [Sun, 28 Apr 2024 22:49:29 +0000 (15:49 -0700)]
Fix up fat build target

Depend on all-recursive so everything gets built before we attempt to
build the fat bits.

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agoAdd EasyTimer v2 firmware
Keith Packard [Sun, 28 Apr 2024 22:33:30 +0000 (15:33 -0700)]
Add EasyTimer v2 firmware

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agoaltosui: Support gps receiver setting
Keith Packard [Wed, 3 Jan 2024 20:31:54 +0000 (12:31 -0800)]
altosui: Support gps receiver setting

Create a combo box listing the available receiver models and allow the
user to select which one to use, including the builtin one.

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agoaltosui: Set the beeper to 0 to disable
Keith Packard [Wed, 3 Jan 2024 20:24:08 +0000 (12:24 -0800)]
altosui: Set the beeper to 0 to disable

Don't force the beeper to the default value when the frequency is set to 0.

Signed-off-by: Keith Packard <keithp@keithp.com>
13 months agoaltos/test: Add FEC test for simple 'hello' message
Keith Packard [Fri, 19 Apr 2024 21:07:50 +0000 (14:07 -0700)]
altos/test: Add FEC test for simple 'hello' message

This just tests the FEC code using a slightly different data source
that makes sure odd lengths work correctly.

Signed-off-by: Keith Packard <keithp@keithp.com>
14 months agoaltos/test: Adjust CRC error rate after FEC fix
Keith Packard [Thu, 28 Mar 2024 16:45:38 +0000 (09:45 -0700)]
altos/test: Adjust CRC error rate after FEC fix

The number of CRC failures during FEC testing is lower now that
the packet length bug has been fixed in the FEC encode bits.

Signed-off-by: Keith Packard <keithp@keithp.com>
14 months agoaltos: ao_fec_prepare using wrong value for input len
Keith Packard [Wed, 27 Mar 2024 04:38:48 +0000 (21:38 -0700)]
altos: ao_fec_prepare using wrong value for input len

The FEC code always sends a multiple of four bytes, padding by two
bytes for even inputs and one byte for odd. But the preparation step
was using the wrong value for the length, so the output was getting
mangled.

Signed-off-by: Keith Packard <keithp@keithp.com>
14 months agoaltos/easytimer-v2: Generate combined .ihx file for seeed testing
Keith Packard [Mon, 4 Mar 2024 00:37:09 +0000 (16:37 -0800)]
altos/easytimer-v2: Generate combined .ihx file for seeed testing

The test plan for seeed requires a combined loader and firmware image
for a single flashing step.

Signed-off-by: Keith Packard <keithp@keithp.com>
14 months agoaltos/stm32f1: Grab both TX/RX DMA mutexes while doing I2C
Keith Packard [Sat, 2 Mar 2024 23:23:57 +0000 (16:23 -0700)]
altos/stm32f1: Grab both TX/RX DMA mutexes while doing I2C

The I2C engine appears to trigger an extra RX DMA transaction which
scrambles anything sharing the same DMA units.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/easymega-v3.0: Update i2c pin usage
Keith Packard [Sat, 24 Feb 2024 20:46:17 +0000 (12:46 -0800)]
altos/easymega-v3.0: Update i2c pin usage

Found an errata which means we had to swap which i2c to use with the
mag sensor. Swap the mag sensor and fire_c/fire_d.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos: Build EasyMega v3.0 by defaul
Keith Packard [Sat, 24 Feb 2024 20:45:54 +0000 (12:45 -0800)]
altos: Build EasyMega v3.0 by defaul

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f103: Fix continuous ADC code
Keith Packard [Sat, 24 Feb 2024 20:45:09 +0000 (12:45 -0800)]
altos/stm32f103: Fix continuous ADC code

This needs the same hacks as the manual ADC code.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltoslib: Add EasyMega v3.0 support
Keith Packard [Sat, 24 Feb 2024 20:44:00 +0000 (12:44 -0800)]
altoslib: Add EasyMega v3.0 support

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agosrc/easymini-2.0: Add combined .dfu file for Seeed testing
Keith Packard [Tue, 13 Feb 2024 06:58:45 +0000 (22:58 -0800)]
src/easymini-2.0: Add combined .dfu file for Seeed testing

Provide a combined .dfu for testing EasyMini at Seeed. This
checks the baro sensor (via POST) and SoC.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agostm32f1: Clean up some ADC definitions
Keith Packard [Sat, 3 Feb 2024 00:31:03 +0000 (16:31 -0800)]
stm32f1: Clean up some ADC definitions

The CR2 bit is called TSVREFE in the docs, use that consistently

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltosui: Make accel cal dialog say 'beeper' instead of 'antenna'
Keith Packard [Thu, 1 Feb 2024 06:05:13 +0000 (22:05 -0800)]
altosui: Make accel cal dialog say 'beeper' instead of 'antenna'

Quite the plumbing required, but it'll do.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/easytimer-v2: Fix product name
Keith Packard [Tue, 30 Jan 2024 02:40:30 +0000 (18:40 -0800)]
altos/easytimer-v2: Fix product name

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/easytimer-v2: Set default log size to 192kB
Keith Packard [Tue, 30 Jan 2024 02:40:06 +0000 (18:40 -0800)]
altos/easytimer-v2: Set default log size to 192kB

This leaves space for 4 flights.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltoslib: Add EasyTimer-v2 support
Keith Packard [Tue, 30 Jan 2024 02:39:27 +0000 (18:39 -0800)]
altoslib: Add EasyTimer-v2 support

Log parsing and idle monitor.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/easytimer-v2: Fix up ao_pins.h
Keith Packard [Tue, 30 Jan 2024 01:58:02 +0000 (17:58 -0800)]
altos/easytimer-v2: Fix up ao_pins.h

Fix M25 CS pin (PA10).
Fix BMI088 axes
Fix MMC5983 axes.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3: Minor UI tweaks
Keith Packard [Mon, 29 Jan 2024 05:14:06 +0000 (21:14 -0800)]
altos/telelco-v3: Minor UI tweaks

"Box"→"Bank" to match docs.
Auto-center text instead of pre-computing. Way easier.
Scroll found banks during startup.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/st7565: Set default contrast to 13
Keith Packard [Sun, 28 Jan 2024 08:17:27 +0000 (00:17 -0800)]
altos/st7565: Set default contrast to 13

This seems slightly better than 16. Might need to actually keep this
in config space.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco: Add RSSI display to older devices
Keith Packard [Sun, 28 Jan 2024 07:59:43 +0000 (23:59 -0800)]
altos/telelco: Add RSSI display to older devices

Show RSSI value on TeleLCO v2.0

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco: Add per-box RSSI display screen
Keith Packard [Sun, 28 Jan 2024 07:48:51 +0000 (23:48 -0800)]
altos/telelco: Add per-box RSSI display screen

Shows the last received RSSI value.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: Set beeper pin to 0 while off
Keith Packard [Sun, 28 Jan 2024 07:47:45 +0000 (23:47 -0800)]
altos/stm32f1: Set beeper pin to 0 while off

Make sure we don't let the timer leave it sitting high; the
magnetic beepers probably don't do the right thing in that case.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Show backlight/contrast value as percent
Keith Packard [Sun, 28 Jan 2024 07:13:17 +0000 (23:13 -0800)]
altos/telelco-v3.0: Show backlight/contrast value as percent

Provide a bit more feedback about the setting.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/st7565: Diff image during update
Keith Packard [Sun, 28 Jan 2024 07:12:05 +0000 (23:12 -0800)]
altos/st7565: Diff image during update

This minimizes the amount of data sent to the device. Mostly this is
useful to skip updates that don't change the display at all.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco: Update backlight/contrast display upon change
Keith Packard [Sun, 28 Jan 2024 07:11:15 +0000 (23:11 -0800)]
altos/telelco: Update backlight/contrast display upon change

Don't wait for the 1-second poll interval.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/draw: Add ao_text_width
Keith Packard [Sun, 28 Jan 2024 07:10:28 +0000 (23:10 -0800)]
altos/draw: Add ao_text_width

Computes the total advance of the given string, not the width of the
resulting ink.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3: Add logo to 'info' page
Keith Packard [Sun, 28 Jan 2024 06:03:00 +0000 (22:03 -0800)]
altos/telelco-v3: Add logo to 'info' page

Make the info page a bit more fun

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agotelelco-v3.0: Add info page
Keith Packard [Sun, 28 Jan 2024 00:35:33 +0000 (16:35 -0800)]
telelco-v3.0: Add info page

Show model, version, serial, call and freq

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Control LCD backlight with PWM
Keith Packard [Sun, 28 Jan 2024 00:03:35 +0000 (16:03 -0800)]
altos/telelco-v3.0: Control LCD backlight with PWM

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos: Add support for backlight control in ao_lco_bits
Keith Packard [Sun, 28 Jan 2024 00:03:20 +0000 (16:03 -0800)]
altos: Add support for backlight control in ao_lco_bits

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: For some reason the DBG registers aren't always available
Keith Packard [Sun, 28 Jan 2024 00:01:20 +0000 (16:01 -0800)]
altos/stm32f1: For some reason the DBG registers aren't always available

Attempts to discover the device model during flash loading appear to fail
for unknown reasons. Switch to basing the memory page size on the total
memory size, which should be just as reliable.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Configure SPI GPIO pins to 50MHz
Keith Packard [Sat, 27 Jan 2024 23:31:04 +0000 (15:31 -0800)]
altos/telelco-v3.0: Configure SPI GPIO pins to 50MHz

Need enough bandwidth to run at 20MHz

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos: Bump ST7565 speed to 20MHz
Keith Packard [Sat, 27 Jan 2024 23:30:27 +0000 (15:30 -0800)]
altos: Bump ST7565 speed to 20MHz

Go as fast as we can manage

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Add contrast setting
Keith Packard [Sat, 27 Jan 2024 01:35:43 +0000 (17:35 -0800)]
altos/telelco-v3.0: Add contrast setting

Provide a UI for setting the LCD contrast.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos: Build TeleLCO v3.0 bits by default
Keith Packard [Sat, 27 Jan 2024 01:35:21 +0000 (17:35 -0800)]
altos: Build TeleLCO v3.0 bits by default

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agotelelco-v3.0: Minor setup fixes
Keith Packard [Sat, 27 Jan 2024 00:06:44 +0000 (16:06 -0800)]
telelco-v3.0: Minor setup fixes

Change beeper to lower tone. Switch LCD SPI to mode 3. Fix the
quadrature device ID.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos: Fix pretend pad range for TeleLCO
Keith Packard [Sat, 27 Jan 2024 00:05:45 +0000 (16:05 -0800)]
altos: Fix pretend pad range for TeleLCO

Off-by-one when setting up the pretend pads.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos: Add wiring docs to st-7565 header
Keith Packard [Fri, 26 Jan 2024 22:03:40 +0000 (14:03 -0800)]
altos: Add wiring docs to st-7565 header

Write down what worked today.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos: Add SPI bus parameter to ao_spi_speed
Keith Packard [Fri, 26 Jan 2024 19:07:55 +0000 (11:07 -0800)]
altos: Add SPI bus parameter to ao_spi_speed

The stm32f1 series has two SPI busses and they operate from different
base clocks, so the computation of the clock divider to get a
particular frequency depends upon which SPI bus is being used.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agostm32f1: make spi speed per-bus
Keith Packard [Fri, 26 Jan 2024 18:59:19 +0000 (10:59 -0800)]
stm32f1: make spi speed per-bus

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoswitch to mode 3 for LCD
Keith Packard [Fri, 26 Jan 2024 18:57:56 +0000 (10:57 -0800)]
switch to mode 3 for LCD

15 months agosrc/stm32f1: Disable extra JTAG pins in ao_clock_init
Keith Packard [Wed, 24 Jan 2024 23:36:34 +0000 (15:36 -0800)]
src/stm32f1: Disable extra JTAG pins in ao_clock_init

Need to enable AFIO before trying to adjust bits there.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Use timer 2 for fast timer
Keith Packard [Sun, 14 Jan 2024 04:57:38 +0000 (20:57 -0800)]
altos/telelco-v3.0: Use timer 2 for fast timer

We need timer 1 for PWM on the backlight

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: Support timers 2,3,4 for fast timer
Keith Packard [Sun, 14 Jan 2024 04:57:00 +0000 (20:57 -0800)]
altos/stm32f1: Support timers 2,3,4 for fast timer

Make the code deal with differences between timer 18 and 234

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Battery voltage is on PA2
Keith Packard [Thu, 11 Jan 2024 23:17:32 +0000 (16:17 -0700)]
altos/telelco-v3.0: Battery voltage is on PA2

Which is ADC input #2

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Don't connect PA6 to SPI
Keith Packard [Thu, 11 Jan 2024 23:16:58 +0000 (16:16 -0700)]
altos/telelco-v3.0: Don't connect PA6 to SPI

MISO is not used, and we need the pin for other stuff.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: Allow PA6 to be left alone in the SPI code
Keith Packard [Thu, 11 Jan 2024 22:12:34 +0000 (15:12 -0700)]
altos/stm32f1: Allow PA6 to be left alone in the SPI code

This is MISO, which the LCD driver doesn't use. Leave it alone so we
can use it for other stuff.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: Poke the ADC harder to get it to sample
Keith Packard [Thu, 11 Jan 2024 22:11:06 +0000 (15:11 -0700)]
altos/stm32f1: Poke the ADC harder to get it to sample

The ADC requires a bunch of poking to get it started.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: Turn on ADC during initialization sequence
Keith Packard [Thu, 11 Jan 2024 07:49:00 +0000 (23:49 -0800)]
altos/stm32f1: Turn on ADC during initialization sequence

The ADC needs to be left 'on' so that it will actually
run the conversion sequence when started.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Add USB pull up
Keith Packard [Thu, 11 Jan 2024 00:27:33 +0000 (17:27 -0700)]
altos/telelco-v3.0: Add USB pull up

And move the ARM LED to PA9

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: Add STM_RCC_CFGR_PLLXTPRE_MASK value
Keith Packard [Thu, 11 Jan 2024 00:26:12 +0000 (17:26 -0700)]
altos/stm32f1: Add STM_RCC_CFGR_PLLXTPRE_MASK value

Necessary when setting the PLLXTPRE value

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: Set PLLXTPRE value
Keith Packard [Thu, 11 Jan 2024 00:24:32 +0000 (17:24 -0700)]
altos/stm32f1: Set PLLXTPRE value

This is the pre-PLL divider value which is needed when we want to
use a 16MHz crystal and a 72MHz sysclk

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/stm32f1: Support beeper on tim3
Keith Packard [Thu, 11 Jan 2024 00:22:57 +0000 (17:22 -0700)]
altos/stm32f1: Support beeper on tim3

Add a bit more flexibility to the beeper code

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco*: Make LCO voltage display work on 2.0 and 3.0
Keith Packard [Mon, 8 Jan 2024 04:13:04 +0000 (20:13 -0800)]
altos/telelco*: Make LCO voltage display work on 2.0 and 3.0

Fix up the common code to handle LCO voltage display via box 0

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Fix up search UI
Keith Packard [Mon, 8 Jan 2024 03:57:03 +0000 (19:57 -0800)]
altos/telelco-v3.0: Fix up search UI

Present a progress bar. Show the detected box numbers.

Signed-off-by: Keith Packard <keithp@keithp.com>
15 months agoaltos/telelco-v3.0: Add ao_adc_single usage to get battery voltage
Keith Packard [Mon, 8 Jan 2024 03:14:03 +0000 (19:14 -0800)]
altos/telelco-v3.0: Add ao_adc_single usage to get battery voltage

Poll the ADC to acquire battery voltage data.

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