summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
...
* altos: Clean up test scriptsKeith Packard2012-04-14
| | | | | | | | The flight test scripts were using invalid bash syntax. Clean that up and also switch the default flight directory to my new ~/misc/rockets/flights directory. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Correct STM USB driverKeith Packard2012-04-14
| | | | | | | Configure endpoint registers correctly now. Restructure code to make sure we send the right IN packets. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Check all USE_SERIAL_*_STDIO when computing AO_NUM_STDIOSKeith Packard2012-04-14
| | | | | | | | AO_NUM_STDIOS is allocated based on the total number of possible stdio values. Now that multiple serial stdio are possible, make sure to check all of them. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Set USB Interrupt endpoint interval to maximum allowedKeith Packard2012-04-14
| | | | | | | We don't ever send anything over this channel, so there's no sense asking the host to poll it very often. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Pull more interfaces out of ao.h and move to separate filesKeith Packard2012-04-14
| | | | | | This moves the aes, btm, companion, lcd and packet interfaces out of ao.h Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: ao_telelaunch.c got left in src directoryKeith Packard2012-04-14
| | | | | | Should live in product/ao_telelaunch.c Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Massive product config cleanupKeith Packard2012-04-14
| | | | | | | | Support multiple serial ports more cleanly Split out parts of ao.h into separate feature header files Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Start adding apogee lockout supportKeith Packard2012-04-14
| | | | | | Remove radio channel support too. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Switch stm-demo to HSE clock, add USBKeith Packard2012-04-14
| | | | | | | Requires that SB17 be soldered shut so that the MCO from the STlink CPU is available the target for HSE input. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Rework how STM clocks are initialized.Keith Packard2012-04-14
| | | | | | | | | | 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>
* altos: Use new USB driver in megametrum-v0.1 productKeith Packard2012-04-14
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add STM USB driverKeith Packard2012-04-14
| | | | | | Emulates the usual CDC-ACM device Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add STM ao_arch_reboot implementationKeith Packard2012-04-14
| | | | | | Uses the AIRCR register to force a reset Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add register definitions for STM syscfg and usbKeith Packard2012-04-14
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add support for multiple SPI busses and sharing device driversKeith Packard2012-04-14
| | | | | | | | | | | | | | | | 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>
* altos: make megametrum beeper test keep beepingKeith Packard2012-04-09
| | | | | | Used to measure the beep frequency. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Check for cc1111 flash overflowKeith Packard2012-04-09
| | | | | | | 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>
* altos: Increase STM SPI speed to PCLK/4Keith Packard2012-04-09
| | | | | | The pressure sensor seems happy at this speed. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Move MS5607 configuration to ao_pins.hKeith Packard2012-04-09
| | | | | | Which SPI port and where chip select is to be found are product specific. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add missing parens in ao_ms5607.hKeith Packard2012-04-09
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Reduce MS5607 reset delay, increase conversion delayKeith Packard2012-04-09
| | | | | | | Reset doesn't take very long, while doing a conversion seems to take more than 10ms. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Make STM clock configuration per-product. Fix 32MHz CPU speedKeith Packard2012-04-09
| | | | | | | | | | 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>
* altos: Add beeper driver to STM archKeith Packard2012-04-09
| | | | | | Drives the MegaMetrum beeper Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Test I2C code on discovery board.Keith Packard2012-04-09
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: ARM -O0 flag appears to generate buggy codeKeith Packard2012-04-09
| | | | | | Use -Os always, which is annoying... Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Make ms5607 driver do somethingKeith Packard2012-04-09
| | | | | | | 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>
* altos: add STM I2C driver.Keith Packard2012-04-09
| | | | | | Not well tested yet... Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Slow STM SPI down a bit so the MS5607 returns valuesKeith Packard2012-04-09
| | | | | | | It's still not working right, but at least it returns something other than all zeros... Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Allow STM DMA channels to be reserved for one useKeith Packard2012-04-09
| | | | | | | | | 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>
* altos: Show temperature in stm-demoKeith Packard2012-04-07
| | | | | | Use the ADC to show current temperature Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Use 384 cycle ADC sample timeKeith Packard2012-04-07
| | | | | | This is plenty fast, and provides nice stable readings. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add STM temperature sensor calibration dataKeith Packard2012-04-07
| | | | | | | 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>
* altos: Add ADC support to megametrum firmwareKeith Packard2012-04-07
| | | | | | Measures all MM igniter and battery voltages. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add ADC tests to stm-demoKeith Packard2012-04-07
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: STM SPI is not using interrupts itselfKeith Packard2012-04-07
| | | | | | All SPI transfers are done via DMA, so the DMA interrupts suffice. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add support for STM ADCKeith Packard2012-04-07
| | | | | | DMA-based driver for the STM analog to digital converter. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosui: remove debug printf from AltosFlightStatsKeith Packard2012-04-07
| | | | Signed-off-by: Keith Packard <keithp@keithp.com>
* altosui: When computing flight stats, auto-detect boost timeKeith Packard2012-04-07
| | | | | | | | Detect when boost actually starts by looking for the last low acceleration value before the recorded boost time. This improves the computation of the boost state data. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosui: Integrate accel speed from very start of eeprom recordKeith Packard2012-04-07
| | | | | | | | Don't wait for the flight computer to have detected boost--that's often several samples after boost actually occurred, which can leave a bunch of acceleration out of the speed computation. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add ability to change radio frequency in TeleTerraKeith Packard2012-04-07
| | | | | | Provide a way to set the frequency locally. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Make ao_config_set_radio publicKeith Packard2012-04-07
| | | | | | Allows other bits of code to reset the radio parameters. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Force radio channel to zero when setting frequencyKeith Packard2012-04-07
| | | | | | | Otherwise, the actual radio frequency will include the channel offset, which is not useful. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Make ao_freq_to_set reentrantKeith Packard2012-04-07
| | | | | | Save a bunch of data space this way. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Shorten help stringsKeith Packard2012-04-07
| | | | | | Save a bit of code space Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Save memory in ao_config.cKeith Packard2012-04-07
| | | | | | | Shorten help messages. Stop setting aes_key on products not using aes key. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Save memory in ao_cmd.cKeith Packard2012-04-07
| | | | | | | Shrink a couple of help strings move a variable in ao_cmd from data to pdata. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add fake install/uninstall targets for stm-bringupKeith Packard2012-04-07
| | | | | Keep global 'make install' from failing. Signed-off-by: Keith Packard <keithp@keithp.com>
* altosui: Radio channel gets set to zero by altos when frequency is setKeith Packard2012-04-07
| | | | | | Just remember what the channe is going to get set to. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Shuffle stm-demo SPI test code around a bitKeith Packard2012-04-06
| | | | | | | | | 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>
* altos: Declare stm DMA address registers as volatile void *Keith Packard2012-04-06
| | | | | | Eliminates a cast when assigning to them. Signed-off-by: Keith Packard <keithp@keithp.com>