Commit Graph

17 Commits

Author SHA1 Message Date
Jeff Epler b482a732c6
StateMachine: add swap flag
Always use DMA if swap flag is enabled.

Improve docs a bit
2022-05-06 15:22:43 -05:00
Jeff Epler 989fb828d4
Revamp background writing
Now a 'once' and a 'loop' buffer can be specified.

'once' is useful for things like writing a neopixel strip in the background,
if you can guarantee the buffer contents are stable until the write is complete.

'loop' is useful for periodic things, like pwm & servos.

both together are useful for some special cases of pwm/servo, where a
transitional waveform needs to be played for one repetition and then
a new waveform needs to be played after that.

The API is renamed to reflect that it's a more generic 'background'
operation.
2022-04-23 13:09:36 -05:00
Jeff Epler b128f180ca
switch to single single dma channel, fix some bugs 2022-04-19 16:33:51 -05:00
Jeff Epler 33d6d55675
the basics work
the sequence has to be a minimum length, 8 entries, but this problem
is not detected. I don't THINK this is an insurmountable problem.
2022-04-19 15:14:50 -05:00
Jeff Epler a58bf235d8
raspberry: StateMachine: Add support for wrap=, wrap_target= 2022-02-13 16:38:53 -06:00
Scott Shawcroft 3e13d4f5b5
Add sideset_enable support to PIO
This allows for UART TX via PIO
2021-12-22 12:00:19 -08:00
Dan Halbert f1d25af7ba Allow PIO to be user-interruptible 2021-08-27 08:38:51 -04:00
Nathan Young 8221a12cf6 Added support for specifying the JMP pin (RP2 PIO) 2021-07-22 18:39:04 +02:00
Jeff Epler 7fb751808f raspberrypi: Implement ParallelImageCapture using PIO
.. based on code from Phil B.
2021-04-22 12:02:51 -05:00
microDev a52eb88031
run code formatting script 2021-03-15 19:27:36 +05:30
DavePutz 6f4510d7aa
Merge branch 'main' into issue_4111 2021-03-08 23:28:21 -06:00
DavePutz a4dda3a5ba
Merge branch 'main' into issue_4111 2021-03-04 14:38:00 -06:00
Jeff Epler bc14ed31f6 StateMachine.h: Add header for declaration of mcu_pin_obj_t typedef 2021-03-04 12:28:46 -06:00
Jeff Epler ff62b0d2c0 StateMachine: Add pull up/down for inputs 2021-03-04 11:26:29 -06:00
root 8e15f36baa pulseio (pulsein) for RP2040 2021-02-24 16:58:29 -06:00
Scott Shawcroft 360475e266
Implement audiobusio and enhance PIO for it
This adds I2SOut and PDMIn support via PIO.

StateMachines can now:
 * read and read while writing
 * transfer in 1, 2 or 4 byte increments
 * init pins based on expected defaults automatically
 * be stopped and restarted
 * rxfifo can be cleared and rxstalls detected (good for tracking when
   the reading code isn't keeping up)

Fixes #4162
2021-02-23 15:50:00 -08:00
Scott Shawcroft 733094aead
Add initial RP2040 support
The RP2040 is new microcontroller from Raspberry Pi that features
two Cortex M0s and eight PIO state machines that are good for
crunching lots of data. It has 264k RAM and a built in UF2
bootloader too.

Datasheet: https://pico.raspberrypi.org/files/rp2040_datasheet.pdf
2021-01-20 19:16:56 -08:00