If uart is disabled, no pins will work; show NotImplementedError instead

This commit is contained in:
Jeff Epler 2022-11-08 14:58:59 -06:00
parent 8658e7a954
commit 7c9cd567a0
No known key found for this signature in database
GPG Key ID: D5BF15AB975AB4DE

View File

@ -155,7 +155,7 @@ STATIC mp_obj_t busio_uart_make_new(const mp_obj_type_t *type, size_t n_args, si
args[ARG_receiver_buffer_size].u_int, NULL, false);
return (mp_obj_t)self;
#else
mp_raise_ValueError(translate("Invalid pins"));
mp_raise_NotImplementedError(NULL);
#endif // CIRCUITPY_BUSIO_UART
}