diff options
Diffstat (limited to 'cyw43-pio/src/lib.rs')
| -rw-r--r-- | cyw43-pio/src/lib.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/cyw43-pio/src/lib.rs b/cyw43-pio/src/lib.rs index 40cf63a17..1280e2059 100644 --- a/cyw43-pio/src/lib.rs +++ b/cyw43-pio/src/lib.rs | |||
| @@ -120,7 +120,7 @@ where | |||
| 120 | cfg.clock_divider = FixedU32::from_bits(0x0100); | 120 | cfg.clock_divider = FixedU32::from_bits(0x0100); |
| 121 | } | 121 | } |
| 122 | 122 | ||
| 123 | #[cfg(not(feature = "overclock"))] | 123 | #[cfg(not(any(feature = "overclock", feature = "rm2")))] |
| 124 | { | 124 | { |
| 125 | // same speed as pico-sdk, 62.5Mhz | 125 | // same speed as pico-sdk, 62.5Mhz |
| 126 | // This is actually the fastest we can go without overclocking. | 126 | // This is actually the fastest we can go without overclocking. |
| @@ -132,6 +132,12 @@ where | |||
| 132 | cfg.clock_divider = FixedU32::from_bits(0x0200); | 132 | cfg.clock_divider = FixedU32::from_bits(0x0200); |
| 133 | } | 133 | } |
| 134 | 134 | ||
| 135 | #[cfg(feature = "rm2")] | ||
| 136 | { | ||
| 137 | // This is found to work better with the RM2 module which is found on the Pimoroni Pico Plus 2 W | ||
| 138 | cfg.clock_divider = FixedU32::from_bits(0x0300); | ||
| 139 | } | ||
| 140 | |||
| 135 | sm.set_config(&cfg); | 141 | sm.set_config(&cfg); |
| 136 | 142 | ||
| 137 | sm.set_pin_dirs(Direction::Out, &[&pin_clk, &pin_io]); | 143 | sm.set_pin_dirs(Direction::Out, &[&pin_clk, &pin_io]); |
