| Commit message (Collapse) | Author | Age |
... | |
|
|
|
|
|
|
|
|
|
| |
Clean all of the RCC configuration up after turning on the clocks.
Use the MSI clock during initialization to avoid messing around with
the HSI clock temporarily.
Allow for an external clock on the HSE line.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Emulates the usual CDC-ACM device
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Uses the AIRCR register to force a reset
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The STM32L151 has several SPI busses, and we want to use more than
one, so add a 'bus' parameter to the SPI interfaces. To avoid wasting
time on AVR and CC1111 processors which only use one SPI bus, elide
those parameters from the actual functions by wrapping them with
macros.
Configuring chip select is now all macroized so that each chip can
have its own version, allowing the STM to share the various SPI device
drivers with the cc1111 and avr processors. Note that only the M25
driver has been ported; porting the others is 'trivial', but not
necessary at this point.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Used to measure the beep frequency.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
The linker is supposed to do this, but it ignores the static
initializer data added after the code.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
The pressure sensor seems happy at this speed.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Which SPI port and where chip select is to be found are product specific.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Reset doesn't take very long, while doing a conversion seems to take
more than 10ms.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
|
| |
This moves all of the STM clock configuration into ao_pins.h so that
each product can configure it separately. While doing this, I
discovered that the flash memory mode (64-bit, prefetch, latency 1)
wasn't actually getting set, which is why the CPU refused to work at
32MHz.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Drives the MegaMetrum beeper
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Use -Os always, which is annoying...
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
It's loading prom values and converting sensor data, but it's getting
the wrong answer at present.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Not well tested yet...
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
It's still not working right, but at least it returns something other
than all zeros...
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
This allows a single user of a DMA channel to reserve it for use
without needing to lock the mutex; this is required for DMA from the
ADC to work on megametrum as it wants to start DMA from an interrupt
handler, which cannot block on a mutex.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Use the ADC to show current temperature
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
This is plenty fast, and provides nice stable readings.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Each stm32l has two-point factory temperature calibration data.
Provide access to that for displaying temperature data.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Measures all MM igniter and battery voltages.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
All SPI transfers are done via DMA, so the DMA interrupts suffice.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
DMA-based driver for the STM analog to digital converter.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Provide a way to set the frequency locally.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Allows other bits of code to reset the radio parameters.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Otherwise, the actual radio frequency will include the channel offset,
which is not useful.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Save a bunch of data space this way.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Save a bit of code space
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Shorten help messages.
Stop setting aes_key on products not using aes key.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Shrink a couple of help strings
move a variable in ao_cmd from data to pdata.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
| |
Keep global 'make install' from failing.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
|
| |
Move a debug printf beyond the chip select boundary to
allow for more accurate timing.
Send four bytes instead of just one.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Eliminates a cast when assigning to them.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Should save a bit of power
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Should save a bit of power.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
Name it appropriately.
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
|
| |
Some architecture specific stuff needs to use core altos code, so
create new ao_arch_funcs.h files per architecture that get pulled in
at the end of ao.h
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
|
| |
Was accidentally always setting usart1 instead of the per-usart
register. Didn't work too well for other usarts...
Signed-off-by: Keith Packard <keithp@keithp.com>
|
| |
|
| |
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
It's hardware specific
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
| |
Signed-off-by: Keith Packard <keithp@keithp.com>
|
|
|
|
|
|
| |
I think this will be needed to compute radio settings on the cc1120
Signed-off-by: Keith Packard <keithp@keithp.com>
|
| |
|