2222
2323# CIRCUITPY-CHANGE: CircuitPython global marker
2424CFLAGS += -DCIRCUITPY=1
25-
25+ CIRCUITPY_FULL_BUILD = 0
2626# Enable VFS POSIX for Emscripten filesystem
2727MICROPY_VFS = 1
28-
28+ LONGINT_IMPL = MPZ
2929# This variable can take the following values:
3030# 0 - no readline, just simple stdin input
3131# 1 - use MicroPython version of readline
@@ -76,6 +76,13 @@ MICROPY_VFS_LFS2 = 0
7676
7777CIRCUITPY_MESSAGE_COMPRESSION_LEVEL = 1
7878MICROPY_EMIT_NATIVE = 0
79+ CIRCUITPY_USB_DEVICE = 0
80+
81+ # Enable async/await even though FULL_BUILD=0
82+ MICROPY_PY_ASYNC_AWAIT = 1
83+
84+ # WASM has no physical LEDs
85+ CIRCUITPY_STATUS_BAR = 0
7986
8087# Enable modules that we have implemented or that work without hardware
8188CIRCUITPY_BOARD = 1
@@ -89,7 +96,7 @@ CIRCUITPY_MICROCONTROLLER = 1
8996CIRCUITPY_NEOPIXEL_WRITE = 1
9097CIRCUITPY_PWMIO = 1
9198CIRCUITPY_ROTARYIO = 1
92- CIRCUITPY_ROTARYIO_SOFTENCODER = 1
99+ # CIRCUITPY_ROTARYIO_SOFTENCODER = 1
93100CIRCUITPY_TIME = 1
94101
95102# Enable ulab for scientific computing (pure software module)
@@ -106,3 +113,108 @@ CIRCUITPY_JSON = 1
106113CIRCUITPY_OS_GETENV = 1
107114CIRCUITPY_RE = 1
108115CIRCUITPY_ZLIB = 0
116+
117+ # ==============================================================================
118+ # EXPLICITLY DISABLE MODULES
119+ # ==============================================================================
120+ # Since CIRCUITPY_FULL_BUILD=0, many modules are already disabled by default,
121+ # but we explicitly disable modules that might be enabled by dependencies or
122+ # that require external libraries/hardware we don't support.
123+
124+ # Note: MICROPY_PY_ASYNC_AWAIT is set by circuitpy_mpconfig.mk based on CIRCUITPY_FULL_BUILD
125+ # We enable it in mpconfigport.h instead to avoid redefinition
126+
127+ # Audio modules (require external libraries like mp3 decoder, or hardware)
128+ CIRCUITPY_AUDIOBUSIO = 0
129+ CIRCUITPY_AUDIOCORE = 0
130+ CIRCUITPY_AUDIOIO = 0
131+ CIRCUITPY_AUDIOMP3 = 0
132+ CIRCUITPY_AUDIOPWMIO = 0
133+ CIRCUITPY_AUDIOMIXER = 0
134+ CIRCUITPY_AUDIODELAYS = 0
135+ CIRCUITPY_AUDIOFILTERS = 0
136+ CIRCUITPY_AUDIOFREEVERB = 0
137+
138+ # Display modules (need hardware or complex implementations)
139+ CIRCUITPY_DISPLAYIO = 0
140+ CIRCUITPY_BITMAPTOOLS = 0
141+ CIRCUITPY_BITMAPFILTER = 0
142+ CIRCUITPY_FRAMEBUFFERIO = 0
143+ CIRCUITPY_PARALLELDISPLAYBUS = 0
144+ CIRCUITPY_EPAPERDISPLAY = 0
145+ CIRCUITPY_FOURWIRE = 0
146+ CIRCUITPY_I2CDISPLAYBUS = 0
147+
148+ # Bluetooth (needs hardware)
149+ CIRCUITPY_BLEIO = 0
150+ CIRCUITPY_BLEIO_HCI = 0
151+ CIRCUITPY_BLEIO_NATIVE = 0
152+ CIRCUITPY_BLE_FILE_SERVICE = 0
153+
154+ # Hardware-specific modules not implemented
155+ CIRCUITPY_ALARM = 0
156+ CIRCUITPY_ANALOGBUFIO = 0
157+ CIRCUITPY_BITBANGIO = 0
158+ CIRCUITPY_BITOPS = 0
159+ CIRCUITPY_CAMERA = 0
160+ CIRCUITPY_CANIO = 0
161+ CIRCUITPY_COUNTIO = 0
162+ CIRCUITPY_DUALBANK = 0
163+ CIRCUITPY_ESPIDF = 0
164+ CIRCUITPY_ESPULP = 0
165+ CIRCUITPY_FREQUENCYIO = 0
166+ CIRCUITPY_GNSS = 0
167+ CIRCUITPY_I2CTARGET = 0
168+ CIRCUITPY_IMAGECAPTURE = 0
169+ CIRCUITPY_KEYPAD = 0
170+ CIRCUITPY_MDNS = 0
171+ CIRCUITPY_MEMORYMAP = 0
172+ CIRCUITPY_NEOPIXEL = 0
173+ CIRCUITPY_NVM = 0
174+ CIRCUITPY_ONEWIREIO = 0
175+ CIRCUITPY_OS = 0
176+ CIRCUITPY_PS2IO = 0
177+ CIRCUITPY_PULSEIO = 0
178+ CIRCUITPY_RGBMATRIX = 0
179+ CIRCUITPY_RTC = 0
180+ CIRCUITPY_SDCARDIO = 0
181+ CIRCUITPY_SDIOIO = 0
182+ CIRCUITPY_SOCKETPOOL = 0
183+ CIRCUITPY_SSL = 0
184+ CIRCUITPY_STORAGE = 0
185+ CIRCUITPY_SUPERVISOR = 0
186+ CIRCUITPY_SYNTHIO = 0
187+ CIRCUITPY_TOUCHIO = 0
188+ CIRCUITPY_USB_CDC = 0
189+ CIRCUITPY_USB_HID = 0
190+ CIRCUITPY_USB_MIDI = 0
191+ CIRCUITPY_USB_MSC = 0
192+ CIRCUITPY_USB_VIDEO = 0
193+ CIRCUITPY_VIDEOCORE = 0
194+ CIRCUITPY_WATCHDOG = 0
195+ CIRCUITPY_WIFI = 0
196+
197+ # Software modules not yet needed/tested
198+ CIRCUITPY_AESIO = 0
199+ CIRCUITPY_ATEXIT = 0
200+ CIRCUITPY_CODEOP = 0
201+ CIRCUITPY_GETPASS = 0
202+ CIRCUITPY_GIFIO = 0
203+ CIRCUITPY_HASHLIB = 0
204+ CIRCUITPY_LOCALE = 0
205+ CIRCUITPY_MAX3421E = 0
206+ CIRCUITPY_MSGPACK = 0
207+ CIRCUITPY_PIXELBUF = 0
208+ CIRCUITPY_QRIO = 0
209+ CIRCUITPY_TRACEBACK = 0
210+ CIRCUITPY_USERCMODULE = 0
211+
212+ # Additional software modules to consider enabling later
213+ CIRCUITPY_ARRAY = 1
214+ CIRCUITPY_COLLECTIONS = 1
215+ CIRCUITPY_IO = 1
216+ CIRCUITPY_MATH = 1
217+ CIRCUITPY_RANDOM = 1
218+ CIRCUITPY_STRUCT = 0 # Has upstream pointer type bug (mp_uint_t* vs size_t*)
219+ CIRCUITPY_SYS = 1
220+ CIRCUITPY_WARNINGS = 1
0 commit comments