Skip to content

Commit c8eb077

Browse files
committed
cdc_uart: avoid compilation warning if UART LEDs not used
1 parent fbc4116 commit c8eb077

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/cdc_uart.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,14 @@ static uint8_t rx_buf[CFG_TUD_CDC_RX_BUFSIZE];
3939
// Actually s^-1 so 25ms
4040
#define DEBOUNCE_MS 40
4141
static uint debounce_ticks = 5;
42+
43+
#ifdef PICOPROBE_UART_TX_LED
4244
static uint tx_led_debounce;
45+
#endif
46+
47+
#ifdef PICOPROBE_UART_RX_LED
4348
static uint rx_led_debounce;
49+
#endif
4450

4551
void cdc_uart_init(void) {
4652
gpio_set_function(PICOPROBE_UART_TX, GPIO_FUNC_UART);

0 commit comments

Comments
 (0)