Commit Graph

198 Commits

Author SHA1 Message Date
Jared Boone
a5012427d8 Remove little bit of dead code. 2016-01-03 12:45:34 -08:00
Jared Boone
c179b9e1cd Move FIR filter configs to common/, so M0 can use it.
Planning to pass from M0 to M4 so M4 doesn't need to keep all these different filter configs in text section.
2016-01-03 12:45:15 -08:00
Jared Boone
39ca6fec62 Transform update spectrum event into message. 2016-01-03 12:05:47 -08:00
Jared Boone
c9f9d97d07 Move BasebandConfiguration message handling into baseband thread. 2016-01-03 11:49:01 -08:00
Jared Boone
fd612dc207 Baseband: Pass unhandled messages to baseband thread, processor. 2016-01-02 22:59:31 -08:00
Jared Boone
07cd99d85d Removing baseband MessageHandlerMap.
It's a bit heavy (362 bytes smaller with switch/case implementation), hard to access to add/remove handlers, doesn't bubble events like I'd like. (I'm going to bubble events to the baseband processor shortly.)
2016-01-02 22:54:09 -08:00
Jared Boone
fea5dd536f Move baseband working buffers from member variables to stack.
It's temporary, after all...
2016-01-02 12:08:21 -08:00
Jared Boone
e7be7c5121 Comments about IFIR filter taps design parameters. 2016-01-02 10:49:37 -08:00
Jared Boone
410d4d7fc3 Use IFIR decimator for TPMS. 2016-01-02 10:42:40 -08:00
Jared Boone
e720bfb054 Use IFIR decimation for broadcast FM receiver. 2016-01-02 10:35:23 -08:00
Jared Boone
a02bfe55d0 Decimators for wider IFIR output bandwidth. 2016-01-02 10:34:17 -08:00
Jared Boone
096ebe47d8 Turn almost-zeros in TPMS matched filter to actual zeros. 2016-01-02 10:24:49 -08:00
Jared Boone
0e04939439 Broadcast FM de-emphasis using 75us time constant. 2016-01-01 20:56:30 -08:00
Jared Boone
2e90edbf39 Add 30Hz high-pass IIR filter for wideband FM. 2016-01-01 20:55:00 -08:00
Jared Boone
9a0fb2cab7 Rename IIR filter for 300Hz high-pass. 2016-01-01 20:53:11 -08:00
Jared Boone
ff05833b02 Use new decimation filters in AIS processor. 2016-01-01 13:20:02 -08:00
Jared Boone
316d5d433b Move IIR code into .cpp file.
A few hundred more text section bytes saved.
2015-12-31 10:52:28 -08:00
Jared Boone
9fb22dfd1f Reduce type size for int16_t squared values. 2015-12-31 10:09:42 -08:00
Jared Boone
ef37bbd851 Small FM squelch simplification. 2015-12-31 10:08:41 -08:00
Jared Boone
0962343190 Use decimation variable, not hard-coded value.
Break in form from NBFM code.
2015-12-30 12:20:25 -08:00
Jared Boone
7de80edcd3 Move baseband FIR filter defs to common file.
They will likely be shared with multiple decimators/demodulators.
Also added normalized filter pass/stop values to each set of taps.
2015-12-30 12:19:42 -08:00
Jared Boone
bbfcca8ec0 Rebake of AM, NFM demodulators -- more flexible filtering/configuration.
Also make SpectrumCollector dynamically configurable.
Add deemphasis filter to NFM.
2015-12-29 11:02:07 -08:00
Jared Boone
549e5b9ddc Unrolled FIR filters for more flexible baseband filtering (using IFIR technique). 2015-12-29 10:48:29 -08:00
Jared Boone
8453741252 Saturate IIR filter output to int16_t. 2015-12-28 16:33:26 -08:00
Jared Boone
7ec1a1f85b Move comment about FM squelch IIR filter. 2015-12-28 16:24:43 -08:00
Jared Boone
ef7aeaafa9 Tweak (and document!) audio HPF IIR. 2015-12-28 16:01:26 -08:00
Jared Boone
4ee0385530 Add FM class default constructor.
For classes that configure FM demodulation at runtime.
2015-12-28 15:51:20 -08:00
Jared Boone
4910bacfa2 Un-comment angle_precise(). Not used, but no reason to comment out. 2015-12-28 15:50:19 -08:00
Jared Boone
49215c3ae6 Remove garbage DSP filter code. 2015-12-28 15:49:47 -08:00
Jared Boone
5ace32a1ee Fix inaccurate comment. 2015-12-20 13:33:08 -08:00
Jared Boone
bddd26d557 Perform frequency-domain windowing of spectrum.
Reduces sidelobes a bit, improves apparent resolution. Avoids windowing (more RAM and CPU) in baseband.
2015-12-20 13:31:00 -08:00
Jared Boone
b058d609eb Move packet timestamping into baseband.
Now reads the RTC peripheral at the end of each received packet.
TODO: Improve resolution to milliseconds or better.
TODO: Work back from end of packet to compute timestamp for beginning of packet.
TODO: Reuse ChibiOS RTC code, which isn't used now because ChibiOS on M0 core is responsible for RTC configuration, and including ChibiOS RTC API on M4 will also try to initialize/manage the peripheral.
2015-12-12 11:37:30 -08:00
Jared Boone
c825a027b2 Comments regarding threading concerns, future refactoring. 2015-12-11 17:29:58 -08:00
Jared Boone
d1637db2fc Reorder methods in source file to indicate call order. 2015-12-11 17:17:12 -08:00
Jared Boone
088f60f2bc Extract spectrum collector from BasebandProcessor.
Code size improvement, and less confused classes. :-)
2015-12-11 12:26:45 -08:00
Jared Boone
75b1cc25ff Missing lambda capture. 2015-12-10 21:21:42 -08:00
Jared Boone
211d1d19ea Move Thread WORKING_AREAs out of classes.
Limited where and how you could instantiate the classes.
2015-12-10 21:01:44 -08:00
Jared Boone
a3bab9126d Remove commented, dead code. 2015-12-10 20:13:27 -08:00
Jared Boone
ca7e0f1e20 Remove #include of ChibiOS test.h.
Would be appropriate if writing a test case project. Someday...
2015-12-10 18:28:19 -08:00
Jared Boone
d895a54078 Almost finished moving around baseband init/shutdown code. 2015-12-10 17:33:44 -08:00
Jared Boone
f90e5bab6b Push more init/shutdown code out of main(). 2015-12-10 17:29:16 -08:00
Jared Boone
f3979a1d65 Move event initialization code into EventDispatcher. 2015-12-10 17:25:55 -08:00
Jared Boone
95fe57c9aa Consolidate EventDispatcher client code. 2015-12-10 17:20:10 -08:00
Jared Boone
4b3fa25cef Move sending of ShutdownMessage into shutdown().
Crazy, I know.
2015-12-10 17:19:18 -08:00
Jared Boone
6328efb70b Move more baseband main() code into EventDispatcher.
EventDispatcher might be ripe for a refactor or rename.
2015-12-10 17:10:28 -08:00
Jared Boone
818790e734 Move init/configure details into RSSI/BasebandThread classes. 2015-12-10 16:33:40 -08:00
Jared Boone
ed25f65e8b Move BasebandThread init into main(). 2015-12-10 16:29:50 -08:00
Jared Boone
13e4b41c1e Trivial clean-up. 2015-12-10 16:15:18 -08:00
Jared Boone
255c568f9e Make some Baseband/RSSIThread members private/const. 2015-12-10 16:14:30 -08:00
Jared Boone
ded33ebabd Extract RSSIThread to separate files. 2015-12-10 16:07:21 -08:00