summaryrefslogtreecommitdiff
path: root/src/ao_radio.c
Commit message (Collapse)AuthorAge
* altos: remove monitor disable stubs from altimeter codeKeith Packard2011-08-11
| | | | | | | | | | | | Monitor mode in the ground-station boards must be disabled when the radio is going to be used for another purpose, or the radio parameters changed. That places monitor-mode disable calls in other parts of the system which are shared with the altimeter code. Elide the ao_set_monitor calls for builds which do not include any monitoring code. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add ability to set arbitrary radio frequencyKeith Packard2011-08-08
| | | | | | | | This adds a separate config parameter to control the raw radio frequency setting, allowing the user to select an arbitrary frequency instead of being forced to choose one of the 10 pre-defined 'channels'. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: teledongle does not need ao_packet_slave.cKeith Packard2011-07-04
| | | | | | | TeleDongle doesn't provide slave interfaces, so remove ao_packet_slave from the TD build Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Rename telemetry to telemetry_origKeith Packard2011-06-27
| | | | | | | This makes room to create a new multi-packet telemetry format without changing anything yet. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Configure packet size from send/recv parameters.Keith Packard2011-03-19
| | | | | | | | | | Instead of setting the packet size at configuration time, use the provided packet size to the send/recv functions to configure the radio. This eliminates many configuration calls, leaving us with 'RDF' mode and 'packet' mode, the latter working for telemetry and the bi-directional link. Signed-off-by: Keith Packard <keithp@keithp.com>
* src/ao_cmd: Shave off bytes from doc stringsAnthony Towns2011-03-07
| | | | | | Switch to using { func, "X args\0Desc" } to specify command, saving a char field by looking at help[0] instead, and reduce help length by doing alignment with printf instead of hardcoded spaces.
* ao_radio: generalise setup of packet sizeAnthony Towns2011-02-18
|
* altos: eliminate ao_wake_taskKeith Packard2010-12-22
| | | | | | | Waking up a task waiting on some random object is a bad idea. Fix the waiters to look for suitable signalling. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: clean up radio abort paths. Share radio code.Keith Packard2010-12-22
| | | | | | | | | | | | | Instead of aborting the DMA and radio operation and expecting that to be handled reasonably by the radio receiving task, rewrite things so that the abort function just wakes the receiving task while that terminates the DMA and cleans up the radio. This eliminates all kinds of nasty bugs dealing with radio abort smashing the radio registers at the wrong time, or interrupting a radio transmission. Signed-off-by: Keith Packard <keithp@keithp.com>
* Revert "altos: Don't abort radio transmissions with ao_radio_abort"Keith Packard2010-11-25
| | | | | | This reverts commit 54468e5dc567aaac5c5c20e921859b7cec28bb88. With this patch in place, TD could not be placed in 'packet' mode.
* altos: Make radio test command careful with the radio mutex.Keith Packard2010-11-23
| | | | | | | | Remember whether the radio test mode is on or off and don't try to do either of them twice to prevent the mutex from being acquired or released twice. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Don't abort radio transmissions with ao_radio_abortKeith Packard2010-11-23
| | | | | | | | | | We only want to abort pending radio reception to release the radio for other use, or to change the radio channel. Let radio transmission proceed. This fixes a problem with using packet mode to configure the radio channel; if the packet transmission is aborted, the TM ends up wedged. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: Add on/off modes to 'C' commandKeith Packard2010-11-21
| | | | | | This lets the user turn the radio on/off and then invoke other commands. Signed-off-by: Keith Packard <keithp@keithp.com>
* altos: prepare for sdcc 2.9.1Keith Packard2010-08-27
| | | | | | | A few minor language changes -- non-standard keywords are now prefixed with __, such as 'at', 'interrupt', 'naked'. Signed-off-by: Keith Packard <keithp@keithp.com>
* Make ao_radio_idle keep trying to get the radio to idle.Keith Packard2010-04-04
| | | | | | | Attempting to abort a radio operation could lead to a hang if the user of the radio jumped in and started using it again before the task attempting to abort woke up. This change just keeps smacking the radio until the radio goes idle long enough to detect it.
* Disable monitor mode before attempting radio test.Keith Packard2009-12-19
| | | | | | | If monitor mode is left active, then the radio lock will not be able to be acquired for the radio test. Signed-off-by: Keith Packard <keithp@keithp.com>
* Use ao_radio_get/ao_radio_put in packet code.Keith Packard2009-12-19
| | | | | | | | The ao_radio_get function both acquires the mutex *and* configures the radio channel and frequency. Failing to use this in the packet code would leave the radio frequency unconfigured. Signed-off-by: Keith Packard <keithp@keithp.com>
* Re-order config values. Change frequency to calKeith Packard2009-12-05
| | | | | | | Place more often used values at top, and consistently call the radio value 'calibration' instead of 'frequency'. Signed-off-by: Keith Packard <keithp@keithp.com>
* Add radio calibration configuration.Keith Packard2009-12-04
| | | | | | | | | The crystal we use is only good for 20ppm, which generates a fairly significant error bounds at our RF frequency. This commit adds a configuration variable that sets the RF frequency control variable so that the output frequency can be adjusted. Signed-off-by: Keith Packard <keithp@keithp.com>
* Remove reason from ao_dma_abortKeith Packard2009-10-30
|
* Wait for TX to finish sending dataKeith Packard2009-10-30
|
* Add radio carrier commandKeith Packard2009-10-30
|
* Initial packet bits. Just testing transmissionKeith Packard2009-10-30
|
* Set all of the values to reset the radio for telemetryKeith Packard2009-09-04
| | | | | | | | | | Was sizeof(rdf_setup) instead of sizeof(telemetry_setup) when resetting the radio back to telemetry data mode from rdf mode. With the length value removed from the rdf config, these two arrays are no longer the same length, and so the last config value was not set leaving the radio sending garbage. Signed-off-by: Keith Packard <keithp@keithp.com>
* Make RDF beacon only run on pad and after landing.Keith Packard2009-09-04
| | | | | | | | | | | | It's pretty much impossible to RDF the rocket during flight, and it interferes with the telemetry data stream. Leave it enabled on the pad so that radios can be tested, and then re-enable it once the rocket has landed. This patch also turns the rdf 'on' time into a parameter so it can be changed, and then sets that parameter to 500ms, once every 5 seconds. Signed-off-by: Keith Packard <keithp@keithp.com>
* Add back the RDF tone generatorKeith Packard2009-09-04
| | | | | | | | | Tracking the rocket on the ground may be easier using tones than using the digital data stream, so we'll try that and see what we think. This reverts commit 3a3bfd471a868d546d83cdc431b53c8f5208edb9. Signed-off-by: Keith Packard <keithp@keithp.com>
* Use autotools, move altos to src subdirKeith Packard2009-06-04
Signed-off-by: Keith Packard <keithp@keithp.com>