From 554f114f181ee942ee3c74e44cef653604abbaef Mon Sep 17 00:00:00 2001 From: Anson Mansfield Date: Mon, 14 Jul 2025 12:45:42 -0400 Subject: [PATCH] examples/rp2/pio_uart_rx.py: Fix use of PIO constants. Running the unmodified `pio_uart_rx.py` example by uploading the file and importing it doesn't succeed, and instead emits a NameError at line 26. Signed-off-by: Anson Mansfield --- examples/rp2/pio_uart_rx.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/rp2/pio_uart_rx.py b/examples/rp2/pio_uart_rx.py index f46aaa6a5..a5b221087 100644 --- a/examples/rp2/pio_uart_rx.py +++ b/examples/rp2/pio_uart_rx.py @@ -23,7 +23,7 @@ PIO_RX_PIN = Pin(3, Pin.IN, Pin.PULL_UP) @asm_pio( autopush=True, push_thresh=8, - in_shiftdir=rp2.PIO.SHIFT_RIGHT, + in_shiftdir=PIO.SHIFT_RIGHT, fifo_join=PIO.JOIN_RX, ) def uart_rx_mini(): @@ -42,7 +42,7 @@ def uart_rx_mini(): @asm_pio( - in_shiftdir=rp2.PIO.SHIFT_RIGHT, + in_shiftdir=PIO.SHIFT_RIGHT, ) def uart_rx(): # fmt: off