Check that #define-d PIN combinations make sense at compile-time #204

Closed
opened 2021-03-01 08:25:24 -06:00 by lurch · 1 comment
lurch commented 2021-03-01 08:25:24 -06:00 (Migrated from github.com)

(as initially suggested in #192)

It might be nice to have a compile-time #error if you give an invalid combination of UART_DEFAULT settings? e.g. setting {PICO_DEFAULT_UART=0, PICO_DEFAULT_UART_TX_PIN=13} (invalid because GPIO13 is UART0 RX) or {PICO_DEFAULT_UART=1, PICO_DEFAULT_UART_TX_PIN=0} (invalid because GPIO0 is UART0 TX).
(with similar things being done for I2C and SPI pins too)

(as initially suggested in #192) It might be nice to have a compile-time #error if you give an invalid combination of UART_DEFAULT settings? e.g. setting {PICO_DEFAULT_UART=0, PICO_DEFAULT_UART_TX_PIN=13} (invalid because GPIO13 is UART0 **RX**) or {PICO_DEFAULT_UART=1, PICO_DEFAULT_UART_TX_PIN=0} (invalid because GPIO0 is **UART0** TX). (with similar things being done for I2C and SPI pins too)
kilograham commented 2024-06-21 14:27:37 -05:00 (Migrated from github.com)

#1724 has been merged into develop

#1724 has been merged into develop
Sign in to join this conversation.
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
gh-raspberrypi/pico-sdk#204
No description provided.