Skip to content

Commit 238484e

Browse files
committed
Merge remote-tracking branch 'origin/main' into update-protomatter-rp2
2 parents 407a8c2 + 532e7db commit 238484e

File tree

23 files changed

+361
-392
lines changed

23 files changed

+361
-392
lines changed

locale/circuitpython.pot

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -333,6 +333,7 @@ msgid "All SPI peripherals are in use"
333333
msgstr ""
334334

335335
#: ports/esp32s2/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c
336+
#: ports/raspberrypi/common-hal/busio/UART.c
336337
msgid "All UART peripherals are in use"
337338
msgstr ""
338339

@@ -952,6 +953,7 @@ msgid "Failed to acquire mutex, err 0x%04x"
952953
msgstr ""
953954

954955
#: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c
956+
#: ports/raspberrypi/common-hal/busio/UART.c
955957
msgid "Failed to allocate RX buffer"
956958
msgstr ""
957959

@@ -1102,7 +1104,7 @@ msgid "Init program size invalid"
11021104
msgstr ""
11031105

11041106
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
1105-
msgid "Initial set pin direcion conflicts with initial out pin direction"
1107+
msgid "Initial set pin direction conflicts with initial out pin direction"
11061108
msgstr ""
11071109

11081110
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
@@ -1219,7 +1221,8 @@ msgstr ""
12191221
msgid "Invalid bits per value"
12201222
msgstr ""
12211223

1222-
#: ports/nrf/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c
1224+
#: ports/nrf/common-hal/busio/UART.c ports/raspberrypi/common-hal/busio/UART.c
1225+
#: ports/stm/common-hal/busio/UART.c
12231226
msgid "Invalid buffer size"
12241227
msgstr ""
12251228

@@ -1294,10 +1297,10 @@ msgstr ""
12941297
#: ports/esp32s2/common-hal/busio/I2C.c ports/esp32s2/common-hal/busio/SPI.c
12951298
#: ports/esp32s2/common-hal/busio/UART.c ports/esp32s2/common-hal/canio/CAN.c
12961299
#: ports/mimxrt10xx/common-hal/busio/I2C.c
1297-
#: ports/mimxrt10xx/common-hal/busio/SPI.c
1298-
#: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/I2C.c
1300+
#: ports/mimxrt10xx/common-hal/busio/SPI.c ports/nrf/common-hal/busio/I2C.c
12991301
#: ports/raspberrypi/common-hal/busio/I2C.c
13001302
#: ports/raspberrypi/common-hal/busio/SPI.c
1303+
#: ports/raspberrypi/common-hal/busio/UART.c
13011304
msgid "Invalid pins"
13021305
msgstr ""
13031306

@@ -1346,7 +1349,8 @@ msgstr ""
13461349
msgid "Invalid wave file"
13471350
msgstr ""
13481351

1349-
#: ports/stm/common-hal/busio/UART.c
1352+
#: ports/mimxrt10xx/common-hal/busio/UART.c ports/nrf/common-hal/busio/UART.c
1353+
#: ports/raspberrypi/common-hal/busio/UART.c ports/stm/common-hal/busio/UART.c
13501354
msgid "Invalid word/bit length"
13511355
msgstr ""
13521356

@@ -1846,7 +1850,7 @@ msgstr ""
18461850
msgid "RNG Init Error"
18471851
msgstr ""
18481852

1849-
#: ports/nrf/common-hal/busio/UART.c
1853+
#: ports/nrf/common-hal/busio/UART.c ports/raspberrypi/common-hal/busio/UART.c
18501854
msgid "RS485 Not yet supported on this device"
18511855
msgstr ""
18521856

@@ -2156,10 +2160,6 @@ msgstr ""
21562160
msgid "UART Re-init error"
21572161
msgstr ""
21582162

2159-
#: ports/raspberrypi/common-hal/busio/UART.c
2160-
msgid "UART not yet supported"
2161-
msgstr ""
2162-
21632163
#: ports/stm/common-hal/busio/UART.c
21642164
msgid "UART write error"
21652165
msgstr ""
@@ -2488,7 +2488,7 @@ msgid "binary op %q not implemented"
24882488
msgstr ""
24892489

24902490
#: shared-bindings/busio/UART.c
2491-
msgid "bits must be 7, 8 or 9"
2491+
msgid "bits must be in range 5 to 9"
24922492
msgstr ""
24932493

24942494
#: shared-bindings/audiomixer/Mixer.c

locale/es.po

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ msgstr ""
88
"Project-Id-Version: \n"
99
"Report-Msgid-Bugs-To: \n"
1010
"POT-Creation-Date: 2021-01-04 12:55-0600\n"
11-
"PO-Revision-Date: 2021-02-21 22:27+0000\n"
11+
"PO-Revision-Date: 2021-02-26 13:50+0000\n"
1212
"Last-Translator: Jose David M <[email protected]>\n"
1313
"Language-Team: \n"
1414
"Language: es\n"
@@ -473,7 +473,7 @@ msgstr "Por debajo de la tasa mínima de refrescamiento"
473473

474474
#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c
475475
msgid "Bit clock and word select must be sequential pins"
476-
msgstr ""
476+
msgstr "Le reloj de bit y de selector de palabra deben ser pines secuenciales"
477477

478478
#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c
479479
msgid "Bit clock and word select must share a clock unit"
@@ -518,7 +518,7 @@ msgstr "Búfer + compensado muy pequeños %d %d %d"
518518

519519
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
520520
msgid "Buffer elements must be 4 bytes long or less"
521-
msgstr ""
521+
msgstr "Los elementos del búfer deben de ser de una longitud de 4 bytes o menos"
522522

523523
#: shared-module/usb_hid/Device.c
524524
#, c-format
@@ -1112,6 +1112,8 @@ msgstr "IV debe tener %d bytes de longitud"
11121112
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
11131113
msgid "In buffer elements must be 4 bytes long or less"
11141114
msgstr ""
1115+
"Los elementos del búfer de entrada deben ser de una longitud de 4 bytes o "
1116+
"menos"
11151117

11161118
#: py/persistentcode.c
11171119
msgid ""
@@ -1132,10 +1134,14 @@ msgstr "Tamaño del programa Init invalido"
11321134
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
11331135
msgid "Initial set pin direcion conflicts with initial out pin direction"
11341136
msgstr ""
1137+
"La dirección inicial del pin de configuración esta en conflicto con la "
1138+
"dirección de salida inicial del pin"
11351139

11361140
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
11371141
msgid "Initial set pin state conflicts with initial out pin state"
11381142
msgstr ""
1143+
"El estado inicial del pin de configuración esta en conflicto con el estado "
1144+
"inicial de salida del pin"
11391145

11401146
#: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c
11411147
msgid "Initialization failed due to lack of memory"
@@ -1576,11 +1582,11 @@ msgstr "Sin soporte de hardware en pin"
15761582

15771583
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
15781584
msgid "No in in program"
1579-
msgstr ""
1585+
msgstr "No hay \"in\" en el programa"
15801586

15811587
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
15821588
msgid "No in or out in program"
1583-
msgstr ""
1589+
msgstr "No hay \"in\" o \"out\" en el programa"
15841590

15851591
#: shared-bindings/aesio/aes.c
15861592
msgid "No key was specified"
@@ -1726,6 +1732,8 @@ msgstr "Tiempo de espera agotado"
17261732
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
17271733
msgid "Out buffer elements must be 4 bytes long or less"
17281734
msgstr ""
1735+
"Los elementos del búfer de salida deben ser de una longitud de 4 bytes o "
1736+
"menos"
17291737

17301738
#: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c
17311739
msgid "Out of memory"

locale/pt_BR.po

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ msgstr ""
66
"Project-Id-Version: PACKAGE VERSION\n"
77
"Report-Msgid-Bugs-To: \n"
88
"POT-Creation-Date: 2021-01-04 12:55-0600\n"
9-
"PO-Revision-Date: 2021-02-21 22:27+0000\n"
9+
"PO-Revision-Date: 2021-02-26 13:50+0000\n"
1010
"Last-Translator: Wellington Terumi Uemura <[email protected]>\n"
1111
"Language-Team: \n"
1212
"Language: pt_BR\n"
@@ -473,7 +473,7 @@ msgstr "Abaixo da taxa mínima de quadros"
473473

474474
#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c
475475
msgid "Bit clock and word select must be sequential pins"
476-
msgstr ""
476+
msgstr "O Bit clock e o word select devem ser pinos sequenciais"
477477

478478
#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c
479479
msgid "Bit clock and word select must share a clock unit"
@@ -520,7 +520,7 @@ msgstr "O buffer + desvio é muito pequeno %d %d %d"
520520

521521
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
522522
msgid "Buffer elements must be 4 bytes long or less"
523-
msgstr ""
523+
msgstr "Os elementos do buffer devem ter 4 bytes de comprimento ou menos"
524524

525525
#: shared-module/usb_hid/Device.c
526526
#, c-format
@@ -1115,7 +1115,7 @@ msgstr "O IV deve ter %d bytes de comprimento"
11151115

11161116
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
11171117
msgid "In buffer elements must be 4 bytes long or less"
1118-
msgstr ""
1118+
msgstr "No buffer, os elementos devem ter 4 bytes ou menos"
11191119

11201120
#: py/persistentcode.c
11211121
msgid ""
@@ -1136,10 +1136,13 @@ msgstr "O tamanho do programa Init é inválido"
11361136
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
11371137
msgid "Initial set pin direcion conflicts with initial out pin direction"
11381138
msgstr ""
1139+
"A direção do pino inicial está em conflito com a direção inicial do pino"
11391140

11401141
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
11411142
msgid "Initial set pin state conflicts with initial out pin state"
11421143
msgstr ""
1144+
"A definição do estado inicial do pino está em conflito com estado do inicial "
1145+
"do pino"
11431146

11441147
#: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c
11451148
msgid "Initialization failed due to lack of memory"
@@ -1576,11 +1579,11 @@ msgstr "Nenhum suporte de hardware no pino"
15761579

15771580
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
15781581
msgid "No in in program"
1579-
msgstr ""
1582+
msgstr "Sem entrada no programa"
15801583

15811584
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
15821585
msgid "No in or out in program"
1583-
msgstr ""
1586+
msgstr "Sem entrada ou saída no programa"
15841587

15851588
#: shared-bindings/aesio/aes.c
15861589
msgid "No key was specified"
@@ -1726,7 +1729,7 @@ msgstr "A operação expirou"
17261729

17271730
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
17281731
msgid "Out buffer elements must be 4 bytes long or less"
1729-
msgstr ""
1732+
msgstr "Os elementos da saída do buffer devem ter 4 bytes ou menos"
17301733

17311734
#: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c
17321735
msgid "Out of memory"

locale/sv.po

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ msgstr ""
66
"Project-Id-Version: PACKAGE VERSION\n"
77
"Report-Msgid-Bugs-To: \n"
88
"POT-Creation-Date: 2021-01-04 12:55-0600\n"
9-
"PO-Revision-Date: 2021-02-21 22:27+0000\n"
9+
"PO-Revision-Date: 2021-02-26 13:50+0000\n"
1010
"Last-Translator: Jonny Bergdahl <[email protected]>\n"
1111
"Language-Team: LANGUAGE <[email protected]>\n"
1212
"Language: sv\n"
@@ -466,7 +466,7 @@ msgstr "Under minsta bildfrekvens"
466466

467467
#: ports/raspberrypi/common-hal/audiobusio/I2SOut.c
468468
msgid "Bit clock and word select must be sequential pins"
469-
msgstr ""
469+
msgstr "Bitklocka och word select måste vara sekventiella pinnar"
470470

471471
#: ports/atmel-samd/common-hal/audiobusio/I2SOut.c
472472
msgid "Bit clock and word select must share a clock unit"
@@ -511,7 +511,7 @@ msgstr "Buffert + offset för liten %d %d %d"
511511

512512
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
513513
msgid "Buffer elements must be 4 bytes long or less"
514-
msgstr ""
514+
msgstr "Buffertelement måste vara fyra byte långa eller mindre"
515515

516516
#: shared-module/usb_hid/Device.c
517517
#, c-format
@@ -1102,7 +1102,7 @@ msgstr "IV måste vara %d byte lång"
11021102

11031103
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
11041104
msgid "In buffer elements must be 4 bytes long or less"
1105-
msgstr ""
1105+
msgstr "Inbuffertelement måste vara 4 byte långa eller mindre"
11061106

11071107
#: py/persistentcode.c
11081108
msgid ""
@@ -1122,11 +1122,13 @@ msgstr "Storlek på init-program ogiltigt"
11221122

11231123
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
11241124
msgid "Initial set pin direcion conflicts with initial out pin direction"
1125-
msgstr ""
1125+
msgstr "Initial pinn-riktning står i konflikt med initial utpinn-riktning"
11261126

11271127
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
11281128
msgid "Initial set pin state conflicts with initial out pin state"
11291129
msgstr ""
1130+
"Initial inställning av pinntillstånd är i konflikt med initialt "
1131+
"utpinntillstånd"
11301132

11311133
#: ports/esp32s2/common-hal/watchdog/WatchDogTimer.c
11321134
msgid "Initialization failed due to lack of memory"
@@ -1562,11 +1564,11 @@ msgstr "Inget hårdvarustöd på pinne"
15621564

15631565
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
15641566
msgid "No in in program"
1565-
msgstr ""
1567+
msgstr "Inget in i programmet"
15661568

15671569
#: ports/raspberrypi/common-hal/rp2pio/StateMachine.c
15681570
msgid "No in or out in program"
1569-
msgstr ""
1571+
msgstr "Inget in eller ut i programmet"
15701572

15711573
#: shared-bindings/aesio/aes.c
15721574
msgid "No key was specified"
@@ -1710,7 +1712,7 @@ msgstr "Åtgärden orsakade timeout"
17101712

17111713
#: ports/raspberrypi/bindings/rp2pio/StateMachine.c
17121714
msgid "Out buffer elements must be 4 bytes long or less"
1713-
msgstr ""
1715+
msgstr "Utbuffertelement ska vara max fyra byte långa"
17141716

17151717
#: ports/esp32s2/bindings/espidf/__init__.c ports/esp32s2/esp_error.c
17161718
msgid "Out of memory"

ports/atmel-samd/boards/catwan_usbstick/mpconfigboard.mk

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,5 @@ LONGINT_IMPL = NONE
1111
CIRCUITPY_FULL_BUILD = 0
1212
CIRCUITPY_COUNTIO = 0
1313
CIRCUITPY_ROTARYIO = 0
14+
15+
SUPEROPT_GC = 0

ports/mimxrt10xx/common-hal/busio/UART.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,10 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self,
9393
self->character_bits = bits;
9494
self->timeout_ms = timeout * 1000;
9595

96+
if (self->character_bits != 7 && self->character_bits != 8) {
97+
mp_raise_ValueError(translate("Invalid word/bit length"));
98+
}
99+
96100
// We are transmitting one direction if one pin is NULL and the other isn't.
97101
bool is_onedirection = (rx == NULL) != (tx == NULL);
98102
bool uart_taken = false;
@@ -154,10 +158,6 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self,
154158
mp_raise_ValueError(translate("Hardware in use, try alternative pins"));
155159
}
156160

157-
if(self->rx == NULL && self->tx == NULL) {
158-
mp_raise_ValueError(translate("Invalid pins"));
159-
}
160-
161161
if (is_onedirection && ((rts != NULL) || (cts != NULL))) {
162162
mp_raise_ValueError(translate("Both RX and TX required for flow control"));
163163
}

ports/nrf/common-hal/busio/UART.c

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,9 @@ static uint32_t get_nrf_baud (uint32_t baudrate) {
7070
{ 14400, NRF_UARTE_BAUDRATE_14400 },
7171
{ 19200, NRF_UARTE_BAUDRATE_19200 },
7272
{ 28800, NRF_UARTE_BAUDRATE_28800 },
73-
{ 31250, NRF_UARTE_BAUDRATE_31250 },
73+
{ 31250, NRF_UARTE_BAUDRATE_31250 },
7474
{ 38400, NRF_UARTE_BAUDRATE_38400 },
75-
{ 56000, NRF_UARTE_BAUDRATE_56000 },
75+
{ 56000, NRF_UARTE_BAUDRATE_56000 },
7676
{ 57600, NRF_UARTE_BAUDRATE_57600 },
7777
{ 76800, NRF_UARTE_BAUDRATE_76800 },
7878
{ 115200, NRF_UARTE_BAUDRATE_115200 },
@@ -144,6 +144,10 @@ void common_hal_busio_uart_construct(busio_uart_obj_t *self,
144144
mp_float_t timeout, uint16_t receiver_buffer_size, byte* receiver_buffer,
145145
bool sigint_enabled) {
146146

147+
if (bits != 8) {
148+
mp_raise_ValueError(translate("Invalid word/bit length"));
149+
}
150+
147151
if ((rs485_dir != NULL) || (rs485_invert)) {
148152
mp_raise_ValueError(translate("RS485 Not yet supported on this device"));
149153
}

ports/raspberrypi/boards/adafruit_feather_rp2040/board.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,6 @@
3030
#include "src/rp2_common/hardware_gpio/include/hardware/gpio.h"
3131

3232
void board_init(void) {
33-
common_hal_never_reset_pin(&pin_GPIO17);
34-
gpio_init(17);
35-
gpio_set_dir(17, GPIO_OUT);
36-
gpio_put(17, true);
3733
}
3834

3935
bool board_requests_safe_mode(void) {

ports/raspberrypi/boards/adafruit_feather_rp2040/pins.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,19 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
1414
{ MP_ROM_QSTR(MP_QSTR_RX), MP_ROM_PTR(&pin_GPIO1) },
1515
{ MP_ROM_QSTR(MP_QSTR_D1), MP_ROM_PTR(&pin_GPIO0) },
1616
{ MP_ROM_QSTR(MP_QSTR_TX), MP_ROM_PTR(&pin_GPIO0) },
17-
{ MP_ROM_QSTR(MP_QSTR_D4), MP_ROM_PTR(&pin_GPIO4) },
17+
{ MP_ROM_QSTR(MP_QSTR_D4), MP_ROM_PTR(&pin_GPIO6) },
1818

1919
{ MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_GPIO2) },
2020
{ MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_GPIO3) },
21-
{ MP_ROM_QSTR(MP_QSTR_D5), MP_ROM_PTR(&pin_GPIO5) },
22-
{ MP_ROM_QSTR(MP_QSTR_D6), MP_ROM_PTR(&pin_GPIO6) },
21+
{ MP_ROM_QSTR(MP_QSTR_D5), MP_ROM_PTR(&pin_GPIO7) },
22+
{ MP_ROM_QSTR(MP_QSTR_D6), MP_ROM_PTR(&pin_GPIO8) },
2323
{ MP_ROM_QSTR(MP_QSTR_D9), MP_ROM_PTR(&pin_GPIO9) },
2424
{ MP_ROM_QSTR(MP_QSTR_D10), MP_ROM_PTR(&pin_GPIO10) },
2525
{ MP_ROM_QSTR(MP_QSTR_D11), MP_ROM_PTR(&pin_GPIO11) },
2626
{ MP_ROM_QSTR(MP_QSTR_D12), MP_ROM_PTR(&pin_GPIO12) },
2727
{ MP_ROM_QSTR(MP_QSTR_D13), MP_ROM_PTR(&pin_GPIO13) },
2828

2929
{ MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_GPIO16) },
30-
{ MP_ROM_QSTR(MP_QSTR_NEOPIXEL_POWER), MP_ROM_PTR(&pin_GPIO17) },
3130

3231
{ MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) },
3332
{ MP_ROM_QSTR(MP_QSTR_SPI), MP_ROM_PTR(&board_spi_obj) },

0 commit comments

Comments
 (0)