8000 Merge branch 'shrink_host_enum_buffer' into gc_selective_collect · rschanafelt/circuitpython@494f208 · GitHub
[go: up one dir, main page]

Skip to content

Commit 494f208

Browse files
committed
Merge branch 'shrink_host_enum_buffer' into gc_selective_collect
2 parents 7a360c3 + f5aef15 commit 494f208

File tree

4 files changed

+17
-7
lines changed

4 files changed

+17
-7
lines changed

locale/sv.po

Lines changed: 4 additions & 4 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: 2025-04-21 18:19+0000\n"
9+
"PO-Revision-Date: 2025-04-23 08:01+0000\n"
1010
"Last-Translator: Jonny Bergdahl <jonny@bergdahl.it>\n"
1111
"Language-Team: LANGUAGE <LL@li.org>\n"
1212
"Language: sv\n"
@@ -2642,7 +2642,7 @@ msgstr "bits måste vara 32 eller färre"
26422642
#: shared-bindings/audiofilters/Distortion.c
26432643
#: shared-bindings/audiodelays/Reverb.c
26442644
msgid "bits_per_sample must be 16"
2645-
msgstr ""
2645+
msgstr "bits_per_sample måste vara 16"
26462646

26472647
#: shared-bindings/audiodelays/Echo.c shared-bindings/audiofilters/Distortion.c
26482648
#: shared-bindings/audiofilters/Filter.c shared-bindings/audiomixer/Mixer.c
@@ -4071,7 +4071,7 @@ msgstr "rsplit(None,n)"
40714071

40724072
#: shared-bindings/audiodelays/Reverb.c
40734073
msgid "samples_signed must be true"
4074-
msgstr ""
4074+
msgstr "samples_signed måste vara sann"
40754075

40764076
#: ports/atmel-samd/common-hal/audiobusio/PDMIn.c
40774077
#: ports/raspberrypi/common-hal/audiobusio/PDMIn.c
@@ -4080,7 +4080,7 @@ msgstr "samplingsfrekvens utanför räckvidden"
40804080

40814081
#: py/modmicropython.c
40824082
msgid "schedule queue full"
4083-
msgstr "schemakön full"
4083+
msgstr "schemakö full"
40844084

40854085
#: py/builtinimport.c
40864086
msgid "script compilation not supported"

ports/espressif/Makefile

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,10 +360,19 @@ CFLAGS += \
360360
-DCFG_TUD_TASK_QUEUE_SZ=32
361361
endif
362362
ifeq ($(CIRCUITPY_USB_DEVICE),1)
363+
ifeq ($(IDF_TARGET),esp32s2)
364+
# Make more room in internal RAM on the S2.
365+
CFLAGS += \
366+
-DCFG_TUD_CDC_RX_BUFSIZE=128 \
367+
-DCFG_TUD_CDC_TX_BUFSIZE=128 \
368+
-DCFG_TUD_MSC_BUFSIZE=1024
369+
else
363370
CFLAGS += \
364371
-DCFG_TUD_CDC_RX_BUFSIZE=1024 \
365372
-DCFG_TUD_CDC_TX_BUFSIZE=1024 \
366-
-DCFG_TUD_MSC_BUFSIZE=4096 \
373+
-DCFG_TUD_MSC_BUFSIZE=4096
374+
endif
375+
CFLAGS += \
367376
-DCFG_TUD_MIDI_RX_BUFSIZE=128 \
368377
-DCFG_TUD_MIDI_TX_BUFSIZE=128 \
369378
-DCFG_TUD_VENDOR_RX_BUFSIZE=128 \

ports/raspberrypi/audio_dma.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,6 @@ audio_dma_result audio_dma_setup_playback(
256256
#endif
257257
max_buffer_length);
258258
#endif
259-
dma->buffer[1] = (uint8_t *)port_realloc(dma->buffer[1], max_buffer_length, true);
260259
dma->buffer_length[1] = max_buffer_length;
261260

262261
if (dma->buffer[1] == NULL) {

supervisor/shared/usb/tusb_config.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,10 @@ extern "C" {
172172
#endif
173173

174174
// Size of buffer to hold descriptors and other data used for enumeration
175+
// CircuitPython itself is 284 bytes of configuration descriptor when both CDC endpoints are
176+
// enabled, plus 4 bytes for alignment.
175177
#ifndef CFG_TUH_ENUMERATION_BUFSIZE
176-
#define CFG_TUH_ENUMERATION_BUFSIZE 256
178+
#define CFG_TUH_ENUMERATION_BUFSIZE (284 + 4)
177179
#endif
178180

179181
#if CIRCUITPY_USB_KEYBOARD_WORKFLOW

0 commit comments

Comments
 (0)
0