Skip to content

Commit b3552b8

Browse files
committed
extra extra... assertion catches bug
1 parent e5f3ea6 commit b3552b8

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/rp2_common/hardware_clocks/clocks.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,9 @@ void clock_gpio_init_int_frac16(uint gpio, uint src, uint32_t div_int, uint16_t
245245
invalid_params_if(HARDWARE_CLOCKS, true);
246246
}
247247

248+
#if !PICO_RP2040 // assert currently broken on RP2040, but we know that hardware has 16 bit integer part
248249
static_assert(CLOCKS_CLK_GPOUT0_DIV_INT_MSB - CLOCKS_CLK_GPOUT0_DIV_INT_LSB == 15, "");
250+
#endif
249251
invalid_params_if(HARDWARE_CLOCKS, div_int >> 16);
250252
// Set up the gpclk generator
251253
clocks_hw->clk[gpclk].ctrl = (src << CLOCKS_CLK_GPOUT0_CTRL_AUXSRC_LSB) |

0 commit comments

Comments
 (0)