Skip to content

Commit acc3770

Browse files
committed
fix build on rp2040
1 parent 72cceaf commit acc3770

File tree

1 file changed

+2
-2
lines changed
  • ports/raspberrypi/common-hal/usb_host

1 file changed

+2
-2
lines changed

ports/raspberrypi/common-hal/usb_host/Port.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,12 +127,12 @@ usb_host_port_obj_t *common_hal_usb_host_port_construct(const mcu_pin_obj_t *dp,
127127
assert_pin_free(dp);
128128
assert_pin_free(dm);
129129

130-
#if PICO_PIO_VERSION > 0
130+
#if PICO_PIO_VERSION == 0
131131
uint32_t used_gpio_ranges = 0;
132132
#else
133133
uint gpio_base = dm->number;
134134
uint gpio_count = 2;
135-
uint32_t required_gpio_ranges = (1u << (gpio_base >> 4)) |
135+
uint32_t used_gpio_ranges = (1u << (gpio_base >> 4)) |
136136
(1u << ((gpio_base + gpio_count - 1) >> 4));
137137
#endif
138138

0 commit comments

Comments
 (0)