Commit Graph

1332 Commits

Author SHA1 Message Date
Robert Jördens 77ae4363fd miniconf: update example usage 2021-06-04 11:05:49 +02:00
bors[bot] 5e2c2c8f30
Merge #367
367: dma: don't swap buffers r=jordens a=jordens

* This uses a new closure-based method to the DMA HAL implementation which
  gives access to the inactive buffer directly.
* It removes changing addresses, the third buffer for DBM, the inactive
  address poisoning, and allows the cancellation of the redundant repeat
  memory barriers and compiler fences.
* This is now around 20 instructions per buffer down from about 100 cycles
  before.
* Also introduces a new `SampleBuffer` type alias.
* The required unpacking of the resources structure is a bit annoying
  but could probably abstraced away.
* Reduced pounder capture rate to the batch rate using the prescaler.
* Removes the Pounder Timestamper DMA (close #260)

TODO:

* [x] Tested that dual-iir still works
* [x] Tested that DMA overflows are signaled as panics (batch size 1 at full rate)
* [x] Adapt `lockin`
* [x] Tested on FLS without pounder timestamp DMA.

Co-authored-by: Robert Jördens <rj@quartiq.de>
2021-06-04 08:57:32 +00:00
Robert Jördens d84c79af2e apps: spi isrs are spi errors 2021-06-04 10:50:09 +02:00
Robert Jördens 73491fcb75 pounder/timestamp: docs updatew 2021-06-04 10:45:22 +02:00
bors[bot] f1b305e13c
Merge #377
377: pll: merge advance into update (like rpll) r=jordens a=jordens



Co-authored-by: Robert Jördens <rj@quartiq.de>
2021-06-03 17:28:54 +00:00
Robert Jördens 3c574b3519 pll: update tests and benches 2021-06-03 19:24:25 +02:00
Robert Jördens 10da2d38ae pll: merge advance into update (like rpll) 2021-06-03 19:20:13 +02:00
bors[bot] 21776d1845
Merge #376
376: pll: add advance() r=jordens a=jordens



Co-authored-by: Robert Jördens <rj@quartiq.de>
2021-06-03 15:41:59 +00:00
Robert Jördens 971bc1109d pll: add advance() 2021-06-03 17:33:57 +02:00
Robert Jördens 2ba9e9c2f7 pounder_timestamper: use input capture prescaler 2021-06-03 10:31:23 +02:00
Robert Jördens 35536c0623 Revert "Revert "pounder timestmper: don't use DMA""
This reverts commit d97ee3f0c4.
2021-06-03 10:31:11 +02:00
Robert Jördens af874c2eef miniconf: add some checks, simplify 2021-06-01 18:32:33 +02:00
Robert Jördens 28aef35d87 miniconf.py: make retain an option 2021-06-01 18:32:33 +02:00
Robert Jördens 93081c25c2 refactor flatten_closures 2021-06-01 17:55:42 +02:00
Robert Jördens 3b73783635 clippy recursion 2021-06-01 17:45:14 +02:00
Robert Jördens 18b6e99b10 fix a few clippy lints on files that are touched 2021-06-01 17:32:06 +02:00
bors[bot] 5be7d175c1
Merge #373
373: Rj/dsp tweaks r=jordens a=jordens

* saturating_scale fixes and docs

Co-authored-by: Robert Jördens <rj@quartiq.de>
2021-06-01 15:01:13 +00:00
Robert Jördens 60715303e7
Merge branch 'master' into rj/dsp-tweaks 2021-06-01 17:00:40 +02:00
Robert Jördens d97ee3f0c4 Revert "pounder timestmper: don't use DMA"
This reverts commit 26b261364f.

First needs to reduce capture rate to batch interval. Otherwise it's
jittery due to polling alignment.
2021-06-01 16:57:51 +02:00
Robert Jördens 26b261364f pounder timestmper: don't use DMA
* One sample per batch is typical and sufficient.
* DMA has more overhead than direct read for one sample.
2021-06-01 16:33:47 +02:00
Robert Jördens f8fa297b20 lockin: dma fence 2021-06-01 14:49:51 +02:00
Robert Jördens b90f4ad185 lockin: port to fast double buffered DMA 2021-06-01 13:17:40 +02:00
Robert Jördens c5a2704c41 dma: implement overflow checking 2021-06-01 13:11:16 +02:00
Robert Jördens 63716111df Merge branch 'master' into rj/fast-dbm
* master:
  pounder: clippy
  pounder: add comment on channel enum
  ad9959: refactor pad()
  pounder: enum for gpio ext pins
  pounder: fix attenuator indices (latch and shiftreg)
  pounder io extender: hack around some bug
  rf_power: fix measurement
  attenuators: use robust latching sequence
  deps: use mcp23017 release
  pounder: simplify attenuator spi interface
2021-06-01 12:52:58 +02:00
Robert Jördens 73187ba053 Merge branch 'master' into rj/fast-dbm
* master:
  adapt to new heapless/serde-json-core after const-generics
  Bump serde-json-core from 0.3.0 to 0.4.0
  build(deps): bump heapless from 0.6.1 to 0.7.1
  setup: cleanup
  itcm: add some comments, make it safe
  build(deps): bump ndarray from 0.15.1 to 0.15.2
  Updating dependencies
  Updating the embedded-nal
  Removing spurious settings updates
  deps: add rationales for git dependencies
  itcm: implement in rust and execute during setup()
  remove duplicate linker option
  gha: install gcc
  fmt
  dependencies: align with master
  bump cortex-m-rt to 0.6.13+git
  memory.x: remove comment about old cortex-m-rt
  enable itcm/dtcm explicitly
  load process into itcm
2021-06-01 12:52:05 +02:00
bors[bot] e35421d561
Merge #371
371: rj/pounder fixes r=jordens a=jordens

- pounder: simplify attenuator spi interface
- deps: use mcp23017 release
- attenuators: use robust latching sequence
- rf_power: fix measurement
- pounder io extender: hack around some bug
- pounder: fix attenuator indices (latch and shiftreg)
- pounder: enum for gpio ext pins
- ad9959: refactor pad()

One big issue was the apparently broken mcp23017 `digital_write`. I couldn't get it to work.
For now, and since (a) we aren't handling the other pins in any configurable way, and (b) the readback-style modification is slow let's just to whole-port writes of constants.

Co-authored-by: Robert Jördens <rj@quartiq.de>
2021-05-31 18:50:11 +00:00
Robert Jördens 4c01a8f929 pounder: clippy 2021-05-31 20:41:18 +02:00
Robert Jördens da7fc08c15 pounder: add comment on channel enum 2021-05-31 18:25:34 +02:00
Ryan Summers 14bfbbe2a1 Refactoring link status polling 2021-05-31 14:28:57 +02:00
Ryan Summers 04f61db6f2 Adding functional prototype 2021-05-31 14:06:02 +02:00
Robert Jördens fb4ed888ee dsp/saturating_scale: fix range 2021-05-30 20:12:02 +02:00
Robert Jördens 2ba49258f9 dsp/staurating_scale: fix math 2021-05-29 22:51:13 +02:00
Robert Jördens 21ab988239 atan2: tweak for speed 2021-05-29 22:51:13 +02:00
Robert Jördens 8ccc2f2275 Merge branch 'master' into rj/visibility-cleanup
* master:
  adapt to new heapless/serde-json-core after const-generics
  Bump serde-json-core from 0.3.0 to 0.4.0
  build(deps): bump heapless from 0.6.1 to 0.7.1
  setup: cleanup
  itcm: add some comments, make it safe
  build(deps): bump ndarray from 0.15.1 to 0.15.2
  Updating dependencies
  Updating the embedded-nal
  deps: add rationales for git dependencies
  itcm: implement in rust and execute during setup()
  remove duplicate linker option
  gha: install gcc
  fmt
  dependencies: align with master
  bump cortex-m-rt to 0.6.13+git
  memory.x: remove comment about old cortex-m-rt
  enable itcm/dtcm explicitly
  load process into itcm
2021-05-28 21:50:53 +02:00
Robert Jördens 5ee7ef388e Merge branch 'master' into rj/pounder-fixes
* master:
  adapt to new heapless/serde-json-core after const-generics
  Bump serde-json-core from 0.3.0 to 0.4.0
  build(deps): bump heapless from 0.6.1 to 0.7.1
2021-05-28 21:44:07 +02:00
Ryan Summers 5e2d2beeac Updating lockfile 2021-05-28 19:38:03 +02:00
Ryan Summers eb968fb503 Adding subsampling factor 2021-05-28 19:37:28 +02:00
Ryan Summers 2edbcf1c92 Merge branch 'master' into feature/livestream 2021-05-28 19:01:24 +02:00
Ryan Summers 72637bebc0 Updating stream 2021-05-28 18:57:23 +02:00
bors[bot] c6965bd8e0
Merge #372
372: rj/const gen r=ryan-summers a=jordens

- build(deps): bump heapless from 0.6.1 to 0.7.1
- Bump serde-json-core from 0.3.0 to 0.4.0
- adapt to new heapless/serde-json-core after const-generics


Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Robert Jördens <rj@quartiq.de>
2021-05-28 16:50:50 +00:00
Robert Jördens b8da9961b8 adapt to new heapless/serde-json-core after const-generics 2021-05-28 18:34:25 +02:00
Robert Jördens d493867c76 Merge remote-tracking branch 'origin/dependabot/cargo/serde-json-core-0.4.0' into rj/const-gen
* origin/dependabot/cargo/serde-json-core-0.4.0:
  Bump serde-json-core from 0.3.0 to 0.4.0
2021-05-28 18:24:58 +02:00
Robert Jördens 4f9113cb45 ad9959: refactor pad() 2021-05-28 16:46:39 +02:00
Robert Jördens 2368a4f6ed pounder: enum for gpio ext pins
This is currently unused but it's better to have enums than
a set of assorted constants.
2021-05-28 16:46:06 +02:00
Robert Jördens 3616f1fa5a pounder: fix attenuator indices (latch and shiftreg)
Before the discriminant was used despite being a compiler implementaiton
detail. This now fixes the discriminant to match byte index in the attenuator
shift register and latch-enable index of the gpio extender.
2021-05-28 16:44:58 +02:00
Robert Jördens 94f60c100c pounder io extender: hack around some bug 2021-05-28 16:44:11 +02:00
Robert Jördens 79f8838104 rf_power: fix measurement 2021-05-28 16:44:11 +02:00
Robert Jördens fc78b087ee attenuators: use robust latching sequence
To ensure that eatch call to latch() generates a rising edge, first
assert low, then high, not the other way round.
2021-05-28 16:43:29 +02:00
Robert Jördens a9f5943296 deps: use mcp23017 release 2021-05-28 16:42:42 +02:00
Robert Jördens f1a58b7811 pounder: simplify attenuator spi interface 2021-05-28 16:41:58 +02:00