Skip to content

Commit af0cdc4

Browse files
committed
Remove debug prints
1 parent 2901d0f commit af0cdc4

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

ports/raspberrypi/common-hal/rp2pio/StateMachine.c

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -195,9 +195,7 @@ static pio_pinmask_t _check_pins_free(const mcu_pin_obj_t *first_pin, uint8_t pi
195195
if (exclusive_pin_use || _pin_reference_count[pin_number] == 0) {
196196
assert_pin_free(pin);
197197
}
198-
mp_printf(&mp_plat_print, "pins_we_use + pin %d\n", pin_number);
199198
PIO_PINMASK_SET(pins_we_use, pin_number);
200-
PIO_PINMASK_PRINT(pins_we_use);
201199
}
202200
}
203201
return pins_we_use;
@@ -265,8 +263,6 @@ static bool use_existing_program(PIO *pio_out, uint *sm_out, int *offset_inout,
265263
*pio_out = pio;
266264
*sm_out = j;
267265
*offset_inout = _current_program_offset[i][j];
268-
mp_printf(&mp_plat_print, "use existing program pio=%i offset=%u\n",
269-
i, _current_program_offset[i][j]);
270266
return true;
271267
}
272268
}
@@ -300,14 +296,11 @@ bool rp2pio_statemachine_construct(rp2pio_statemachine_obj_t *self,
300296
// Create a program id that isn't the pointer so we can store it without storing the original object.
301297
uint32_t program_id = ~((uint32_t)program);
302298

303-
mp_printf(&mp_plat_print, "construct\n");
304-
305299
uint gpio_base = 0, gpio_count = 0;
306300
#if NUM_BANK0_GPIOS > 32
307-
PIO_PINMASK_PRINT(pins_we_use);
308301
if (PIO_PINMASK_VALUE(pins_we_use) >> 32) {
309302
if (PIO_PINMASK_VALUE(pins_we_use) & 0xffff) {
310-
mp_printf(&mp_plat_print, "Uses pins from 0-15 and 32-47. not possible\n");
303+
// Uses pins from 0-15 and 32-47. not possible
311304
return false;
312305
}
313306
}
@@ -337,7 +330,6 @@ bool rp2pio_statemachine_construct(rp2pio_statemachine_obj_t *self,
337330

338331
if (!use_existing_program(&pio, &state_machine, &offset, program_id, program_len, gpio_base, gpio_count)) {
339332
uint program_offset;
340-
mp_printf(&mp_plat_print, "gpio_base = %d gpio_count = %d\n", gpio_base, gpio_count);
341333
bool r = pio_claim_free_sm_and_add_program_for_gpio_range(&program_struct, &pio, &state_machine, &program_offset, gpio_base, gpio_count, true);
342334
if (!r) {
343335
return false;
@@ -659,9 +651,7 @@ void common_hal_rp2pio_statemachine_construct(rp2pio_statemachine_obj_t *self,
659651

660652
int pio_gpio_offset = 0;
661653
#if NUM_BANK0_GPIOS > 32
662-
PIO_PINMASK_PRINT(pins_we_use);
663654
if (PIO_PINMASK_VALUE(pins_we_use) >> 32) {
664-
mp_printf(&mp_plat_print, "Using upper bank\n");
665655
pio_gpio_offset = 16;
666656
if (PIO_PINMASK_VALUE(pins_we_use) & 0xffff) {
667657
mp_raise_ValueError_varg(MP_ERROR_TEXT("Cannot use GPIO0..15 together with GPIO32..47"));

0 commit comments

Comments
 (0)