-
Notifications
You must be signed in to change notification settings - Fork 193
RP2040 on tune #254
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RP2040 on tune #254
Changes from all commits
a5c2639
b6926da
7cd06ac
33f76f4
b89e39f
708e064
fc3e0f9
2b0d752
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -85,14 +85,17 @@ MOZZI_CHECK_SUPPORTED(MOZZI_AUDIO_MODE, MOZZI_OUTPUT_EXTERNAL_TIMED, MOZZI_OUTPU | |
|
|
||
| #if MOZZI_IS(MOZZI_AUDIO_MODE, MOZZI_OUTPUT_PWM) | ||
| # if !defined(MOZZI_AUDIO_BITS) | ||
| # define MOZZI_AUDIO_BITS 11 | ||
| # define MOZZI_AUDIO_BITS 16 // PWMAudio expects 16bits | ||
| # endif | ||
| # if !defined(MOZZI_AUDIO_PIN_1) | ||
| # define MOZZI_AUDIO_PIN_1 0 | ||
| # endif | ||
| # if !defined(MOZZI_AUDIO_PIN_2) | ||
| # define MOZZI_AUDIO_PIN_2 1 | ||
| # endif | ||
| # define BYPASS_MOZZI_OUTPUT_BUFFER true | ||
| # define MOZZI_RP2040_BUFFERS 8 // number of DMA buffers used | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It may be worth documenting: Is that 8 the result to experimentation, or would other values be expected to work, too?
Collaborator
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I used the same values that the library example (which are the same than for I2S). Other values might be expected to work, but I did not test thoughtfully. |
||
| # define MOZZI_RP2040_BUFFER_SIZE 256 // total size of the buffer, in samples | ||
| #endif | ||
|
|
||
| #if MOZZI_IS(MOZZI_AUDIO_MODE, MOZZI_OUTPUT_I2S_DAC) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this a requirement with PWMAudio, too?
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup!
(Can't find the reference ATM, but I read that somewhere in PWMAudio)https://arduino-pico.readthedocs.io/en/latest/pwm.html#pwmaudio-pin-true