Fix PDMIn.c formatting
This commit is contained in:
parent
7fc0aa5791
commit
6d3698848c
@ -110,18 +110,18 @@ void common_hal_audiobusio_pdmin_construct(audiobusio_pdmin_obj_t *self,
|
|||||||
} else if (clock_pin == &pin_PB11) {
|
} else if (clock_pin == &pin_PB11) {
|
||||||
self->clock_unit = 1;
|
self->clock_unit = 1;
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#else
|
||||||
#ifdef SAM_D5X_E5X
|
#ifdef SAM_D5X_E5X
|
||||||
if (clock_pin == &pin_PA10 || clock_pin == &pin_PB16) {
|
if (clock_pin == &pin_PA10 || clock_pin == &pin_PB16) {
|
||||||
self->clock_unit = 0;
|
self->clock_unit = 0;
|
||||||
} else if (clock_pin == &pin_PB12
|
} else if (clock_pin == &pin_PB12
|
||||||
#if defined(PIN_PB28) && !defined(IGNORE_PIN_PB28)
|
#if defined(PIN_PB28) && !defined(IGNORE_PIN_PB28)
|
||||||
|| data_pin == &pin_PB28) {
|
|| data_pin == &pin_PB28
|
||||||
#else
|
|
||||||
) {
|
|
||||||
#endif
|
#endif
|
||||||
|
) {
|
||||||
self->clock_unit = 1;
|
self->clock_unit = 1;
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
} else {
|
} else {
|
||||||
raise_ValueError_invalid_pin_name(MP_QSTR_clock);
|
raise_ValueError_invalid_pin_name(MP_QSTR_clock);
|
||||||
}
|
}
|
||||||
@ -147,11 +147,12 @@ if (false
|
|||||||
#endif
|
#endif
|
||||||
) {
|
) {
|
||||||
self->serializer = 1;
|
self->serializer = 1;
|
||||||
#endif
|
#else
|
||||||
#ifdef SAM_D5X_E5X
|
#ifdef SAM_D5X_E5X
|
||||||
if (data_pin == &pin_PB10 || data_pin == &pin_PA22) {
|
if (data_pin == &pin_PB10 || data_pin == &pin_PA22) {
|
||||||
self->serializer = 1;
|
self->serializer = 1;
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
} else {
|
} else {
|
||||||
raise_ValueError_invalid_pin_name(MP_QSTR_data);
|
raise_ValueError_invalid_pin_name(MP_QSTR_data);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user