#circuitpython-dev
1 messages · Page 421 of 1
ya, but usually simple to fix. got a link to the error?
its being picky about white space
lol
mpconfigboard.h has an extra line at the end and the pins.c has some white space on the start of the line
you probably setup pre-commit in vscode and it'll autofix it
generally it's easiest to auto-run pre-commit before committing
will try
@rycwo I don't believe TinyUSB has support in its main branch yet. It's waiting on https://github.com/sekigon-gonnoc/Pico-PIO-USB/pull/22
So, progress is being made but isn't there yet. Once it is, we'll also need to connect the actual reading and writing of packets to the new TinyUSB API for it. You could start this on iMX for now if you are eager. We're happy to help ramp folks up to contributing to CircuitPython. Chatting with us on Discord is a good place to start: https:/adafru.it/dis...
no need to close the PR, just push a new commit to the same branch
ok. I am not used to github
np
Removed white spaces.
/me is back from paternity leave
I don't think we use much from ASF4 and rely on samd-peripherals instead.
The functionality you are suggesting makes sense. We don't have it currently because no one has needed it.
@slender iron paternity leave? congrats 🙂
yup! thank you!
I missed that in taking my own paternity leave haha
you'll need the empty board.c file in the folder too
(there may be other files as well)
I'll check that later then
and by empty, I mean it has functions that don't have contents
you should be able to copy it from another board
good luck!
Code looks good! Thank you!
Am I reading it right that a UART at 115200 will be the correct speed before and after changing CPU frequency?
Also, why enable this on a per-board basis? Shouldn't it apply to all iMX RT?
To really put the processor in a low power mode you have to turn off the peripherials
I think we should be a bit more specific and differentiate between the processor core and the system on a chip (soc) which includes peripherals.
Light sleep and time.sleep() should stop the clock to the core to save power. It shouldn't have power disabled because that would reset the core. It should also maintain any active peripherals. In other words, the core is in a low power state but the s...
The pin should be reset between VM runs by this code: https://github.com/adafruit/circuitpython/blob/main/ports/mimxrt10xx/common-hal/microcontroller/Pin.c#L38=
It looks like I changed that code in #6125 and hopefully fixed @LedbetterAlex's original issue.
This sounds like a Teensy bootloader quirk more than an issue with our linker script. (Maybe the size detection code just assumes continuous ranges.) However, I wouldn't mind changing the linker script to take up continuous ranges if it means it preserves the filesystem.
I think you just need to modify the LENGTH parameters here for the first few ranges: https://github.com/adafruit/circuitpython/blob/main/ports/mimxrt10xx/linking/common.ld#L20=
I want to drive two 1.28 inch displays on a RPi Pico. The controllers are GCA901 so I need to run two SPI devices with, presumably, device selection using Chip Select. How do I configure disaplyio to work with two displays on a common bus? I see a reference to the configuration definition CIRCUITPY_DISPLAY_LIMIT - what is the current default value?
Looks like @dhalbert removed pulseio for the itsybitsy m0 express in commit 843598ec. I tested this with an itsybitsy m0 express and rcwl-1601 and it does work but the accuracy is terrible without pulseio.
We traded off pulseio against other things when we needed space. Perhaps the library should not attempt to work without pulseio.
CircuitPython version
Adafruit CircuitPython 7.2.5 on 2022-04-06; Raspberry Pi Pico with rp2040
Code/REPL
import os
import time
import board
import storage
import busio as io
from adafruit_sdcard import SDCard
from digitalio import DigitalInOut
SD_PATH = "/sd"
spi = io.SPI(board.GP2, board.GP3, board.GP0)
cs = DigitalInOut(board.GP1)
sdcard = SDCard(spi, cs)
vfs = storage.VfsFat(sdcard)
storage.mount(vfs, SD_PATH)
# list out all the dir...
I want to drive two 1.28 inch displays on a RPi Pico. The controllers are GCA901 so I need to run two SPI devices with, presumably, device selection using Chip Select. How do I configure disaplyio to work with two displays on a common bus? I see a reference to the configuration definition CIRCUITPY_DISPLAY_LIMIT - what is the current default value?
I believe the default setting on almost all devices is 1. I think the only device with limit of 2 is the Monster M4sk https://github.com/...
I believe the default setting on almost all devices is
1. I think the only device with limit of2is the Monster M4sk https://github.com/adafruit/circuitpython/blob/main/ports/atmel-samd/boards/monster_m4sk/mpconfigboard.h
That was my finding as well.
The current limit is 1 display. I have been told you can re-compile it and
change the value to 2, but because circuitpython is basically running a
virtual machine it doesn't work so great ( atleast that's how I understand
it, I might not be explaining it correctly). You can use multiple displays
using rgb565. I dunno if the particular display driver you mentioned
supports it.
On Mon, May 9, 2022, 8:53 PM David Goadby @.***> wrote:
I want to drive two 1.28 inch displays on a RPi Pico...
Can you give more detail on the number of directories and files? How many directories at the root, and what's the average and range in number of files in those directories? You might try not to listdir on files that aren't directories (os.stat[6] will be non-zero for non-zero-length files, I believe).
There are 160 files and 5 directories on the card. One of the directories is empty and the largest one includes 120 files. On average, 20 files.
The file system of the card is FAT32
Actually, it's mostly not slow while listdir on directories. But on files, listdir takes longer to raise an exception.
Checking os.stat[6] is a little bit quicker, but I'd like to know how can I tell the difference between empty files and directories for both of them returns a 0 on os.stat[6] ...
It seems to me that this isn't a bug but a limitation as noted in the documentation PulseIn.maxlen: When len() is equal to maxlen, it is unclear which pulses are active and which are idle. Making maxlen greater than the number of pulses to be received should make the code work as hoped.
I use this to test if a path is a directory:
import os
IS_DIR = 0x4000
IS_FILE = 0x8000
def is_dir(file):
return os.stat(file)[0] & IS_DIR != 0
I don't know if there is some unavoidable overhead, but you can try speeding up the bus speed.
The default speed in the library is 1.32MHz, this sets it to 10MHz:
sdcard = SDCard(spi, cs, baudrate=10_000_000)
Seems all good to me. The hiibot iots2 has been added to the tinyuf2 CI, but it won't be available until the next release.
Thank circuitpython for adding a new board to circuitpython org. I hope it can pass
is there a good tutorial to setup the workflow to add a board with VSCode ? I can't pass the pre-commit test
@gilded cradle I think there's an issue with this entry in the 'features' of the qtpy esp32-s2 https://github.com/adafruit/circuitpython-org/blame/e402c8fd88a174e785186ea1703fbf5c34c8b325/_board/adafruit_qtpy_esp32s2.md#L15
@warm flame For the core, the documentation we have is https://github.com/adafruit/circuitpython/blob/main/BUILDING.md#code-quality-checks -- You didn't mention what OS you're using but Linux, Windows using WSL, or Mac should work as long as you follow the instructions in BUILDING.md. I am not aware of any vscode-specific instructions and I strongly suspect that Windows-without-WSL is going to have additional challenges. I always use the terminal on Debian Linux to do things like run pre-commit.
even on windows ?
For the features: portion of the board information, please only use the values listed in the template:
# Features are tags; they should be limited to the items in this list and spelled exactly the same.
# Include only the features your board supports, and remove these comment lines before committing.
# Breadboard-Friendly is a parallel pin layout with minimal non-critical perpendicular pins
features:
- Speaker
- Solder-Free Alligator Clip
- Feather-Compatible
- Battery ...
Before this, people were requested to follow a set list of features, but we had no automated check for it. Do this as a step of the CI, or a step that can be run locally.
I found several boards that had non-standard features listed; I corrected or deleted them as I saw appropriate.
There are also a number of boards without any features: blocks. I did not attempt to fix this. However, if this were fixed we could add an additional check in this script for future boards. However, this assu...
@warm flame I use debian, the CI uses ubuntu.
as it will be a Virtual machine, is there a debian fork that is more oriented toward DEV
Here's an example of the check failing when a nonstandard feature is specified:
jepler@rat:~/src/circuitpython-org$ git diff
diff --git a/_board/feather_m4_express.md b/_board/feather_m4_express.md
index cdde3923..b8948476 100644
--- a/_board/feather_m4_express.md
+++ b/_board/feather_m4_express.md
@@ -10,6 +10,7 @@ date_added: 2019-3-8
family: atmel-samd
bootloader_id: feather_m4
features:
+ - OSHWA Certified
- Feather-Compatible
- Battery Charging
- Breadboard...
What do you think of Kali Linux ?
I have not personally used it.
I think this probably isn't super-important, and whether to use typecodes or 1/2/4 integers feels like an open question. I used typecodes partially because they felt natural (I was replacing a function call with a parameter of 'L' anyway!) but also because of ease of implementation. I shouldn't have favored ease of implementation so strongly. Anyhow, let's not do this right now.
We are also seeing issues with MCP960x, which does clock stretching and repeated start. Before #6366, I see Input/output error, as above. After #6366, I am more likely to see the sensor not even appear in a scan.
@slender iron if you are eventually looking for smaller things to do, there are a couple of things for 7.3.0 that are in code familiar to you:
what desktop environement do you use with debian ?
I use xfce, but that doesn't mean I necessarily recommend it. Gnome is probably a better suggestion for those new to Linux, it's more polished.
I use cinnamon (with Ubuntu 22.04, but could be installed with Debian, I think).
Gnome takes up more space. I have a short taskbar at the bottom with lotsa icons
@tulip sleet kk, I think I’ll try to get through all my email first. I made good progress on it yesterday
I agree on that!
(On my phone now while holding the baby)
your arm muscles will get stronger (speaking from experience)
i am not big into themes, etc. My desktop background is solid black 🙂
@slender iron enjoy those moments, they are too short.
and nostalgia kicks in hard when they are 13 and are being Hades Bum Hole
Sometimes it starts earlier, like 5 and 6 lol…
Terrible 2, F**ing 4 and more
pay no attention to these guys 😉
vim but again this is not a recommendation. vscode is available for linux, so if you're comfortable with it choose it.
vim is "dos" like right
Seems all good to me. The hiibot iots2 has been added to the tinyuf2 CI, but it won't be available until the next release.
Thanks. This is a great start. There's a different set of features for Blinka boards and this will help a lot with that.
keyboard commands: it's a modal editor (command vs insert mode). I use emacs. If you are used to IDE's, atom, vscode, or PyCharm may be more up your alley
pycharm is not only for python ?
Thanks for submitting a PR as well as coming up with a script that checks this.
@gilded cradle you're welcome! after I found the 'frontmatter' pypi library it was not hard to write it
first I failed to find a way to do it in jekyll but that's not important since we can run other things in CI
Yeah, I was thinking we had to do some pure actions thing. Writing a python script is much better.
Yeah, it's still not showing stats, but those errors in the developer console are gone so I don't think it's related to that.
it's part of the family of editors from JetBrains; I don't know how constricted it is
I use PyCharm for all kinds of things. It works with many more things than Python.
It doesn't do syntax highlighting on the ones it can't handle, if I remember correctly. But it does open them.
thanks
@lone axle Do you have a moment to review this? I'm blocked on it for a task I'm doing. I tested it thoroughly, so I don't feel like it needs testing. Plus, I'm not sure how many folks have more than one of these anyway. (Though I'm pretty sure no one tested the original and it didn't work.) https://github.com/adafruit/Adafruit_CircuitPython_VL53L1X/pull/6
yep I'll take a look.
Thanks so much! I just pushed another change, but it should pass as well.
Looks good to me, left review. Want me to merge while I'm there?
Yes please!
Thank you so much!
@gilded cradle Is there some issue with platform detect? Getting the following error trying to build sphinx docs locally: Traceback (most recent call last): File "/Users/kattni/.virtualenvs/pylint/lib/python3.10/site-packages/sphinx/ext/autodoc/importer.py", line 70, in import_module return importlib.import_module(modname) File "/Users/kattni/.pyenv/versions/3.10.0/lib/python3.10/importlib/__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 1050, in _gcd_import File "<frozen importlib._bootstrap>", line 1027, in _find_and_load File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 688, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 883, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "/Users/kattni/repos/Adafruit_CircuitPython_Simple_Text_Display/adafruit_simple_text_display.py", line 26, in <module> import board File "/Users/kattni/.virtualenvs/pylint/lib/python3.10/site-packages/board.py", line 166, in <module> elif board_id == ap_board.KHADAS_VIM3: AttributeError: module 'adafruit_platformdetect.constants.boards' has no attribute 'KHADAS_VIM3'
Or is that maybe a red herring.
Force reinstalled it and it fixed that error. Nevermind, apologies for the ping.
Ugh, ok, Sphinx issue. Docs are building properly locally, including the API page. Remotely, they're passing when they build, but the API page is blank. I have no idea where to start with this.
Where are you at with this? Different error or same?
No more errors involved, which is what's frustrating. I can build it locally, but it's building wrong remotely (even though it passes)
Oh ok. Did something change in the docs content-wise?
Nothing changed.
Hmm. Same version of sphinx as you have locally?
Hmm, I didn't verify that. Checking.
ok
Looks like I was behind. Building again now locally.
Still building properly locally with the latest Sphinx. 😦
Ok, I don't have any other ideas at the moment, but will let you know if I do.
Thanks. Appreciate the help.
The errno messages for EPERM and ENODEV were wrong. In particular the ENODEV message was confusingly wrong.
This grows builds slightly due to a new string, and alter the errors we see in some circumstances, but I think it's better to have the correct messages. If the mesages are mentioned in any guides, they'll need to be changed, but I think the mentions may only be in issues. I'll do a learn.adafruit.com site search after this is merged.
seems like an improvement, thanks
The motivation is that I am doing I2C debugging. I thought the "Unsupported operation" meant there was some kind of transmission error, but in fact it was "No such device": literally there was no response from the addressed device.
@tulip sleet all of my reload changes broke the ble reload. think I should PR a fix into 7.2?
I did get initial functionality working with external oscillator (bypass crystal mode) by modifying one line in this file
hpl_osc32kctrl_config.h
One issue is this description I do not feel is correct. This is for enabling the external clock source, instead assuming crystal. MPLABs also has ad descriptions but when comparing changes between external clock and external crystal this is all that changes.
// <q> Crystal connected to XIN32/XOUT32 Enable
// <i> Indicates whether the ...
what do others think? should we fix ble reload in 7.2?
@slender iron I know you are still catching up, but you did say yesterday to ping you if there is something we wait on. I'd love to be able to get the PewPew LCD merged before 7.3 is out, so if you have time, could you take a look at https://github.com/pidcodes/pidcodes.github.com/pull/733 ?
ya, I can do a pid.codes pass now
The trigger was happening when reload was suspended and therefore
ignored. Now, manage reload in one place in the file. This may
trigger reloads on BLE command error but that should be rare.
Fixes #6258
LGTM! @kattni, do you want to retest? Notice this is on 7.2.x, not main.
Absolutely! I'll do that now.
@tulip sleet Can you get me a build for Circuit Playground Bluefruit from that 7.2.x PR so I don't have to wait on CI to build it?
I can
Thanks!
the transfer works but then the download button stops working
Just got back from a walk. 7.2.x is fine, though there are not that many users, so could be main, since I think we could release 7.3.0 quite soon. If we can't fix the I2C issues quickly, for instance, I would just as soon release 7.3.0 to get all the recent changes into stable.
There is no Transfer or Download anymore
I'll test it with the latest version
well, its download after it is run it
I'll merge 7.2.x into main after the PR is in
and we can decide what to actually release later
@slender iron It works great with PyLeap! Fixed the issue with needing to click reset to get the code to run.
hurrah - thanks!
Oh there's the new issue you reported.
there had been a lot of churn with the reload code
Where it "stops" during downloading. Even though it downloaded and ran the first program I tried
yup
Ok. I'll file the bug there, and close the bug related to the reload
OK, so restarting the app made the button work again, but now it isn't loading anything new.
There's a bug on PyLeap for the reload thing too. Not sure if that will be closed.
ah, I don't think it will be
So basically, it only works on the first try, then never again.
@onyx hinge Your PR failed on the same issue again?
Heh fair enough.
@onyx hinge Merged!
@slender iron @tulip sleet So this will be a 7.2.6 release?
we might not do a 7.2.6, because I think we will do 7.3.0 final pretty soon. And there are not a lot of people using PyLeap
I could easily do a 7.2.6, though. I want to test a change I made in the release process anyway. I mean, is it true the audience for this is very small?
I believe so, yes. But Trevor doesn't venture into beta builds, and at the moment, the other testers aren't either. So he's concerned about putting a warning into the app about hitting reset to get the code to run.
then I can do a 7.2.6, if you think it would help that process.
But this CP update causes a bunch of issues in PyLeap anyway, and Trev will need to experience them to fix them.
I think it might, yeah.
trev should use the absolute latest
I'll talk to him about it then. But if this is in 7.2.x, it won't be in latest, will it?
Also, if he doesn't use stable, then when PyLeap gets released, we'd have to ask users to use absolute latest as well.
how imminent is PyLeap release?
I think 7.3.0 will get released within a week or two
Ok.
let's try to get Trev to use 7.3.0-beta.2 and absolute newest
Ok I'll chat with him.
it has to get tested anyway against PyLeap to make sure they work together
@stuck elbow one nitpick is the hardware repo should link to the software branch
you mean the pew library or the circuitpython repo?
the pewpew-lcd repo should link to CP
the library gets compiled in
or your fork
I link to circuitpython.org, but I guess I should link to the code directly, or even to the pull request?
PR is fine
One thing I realized when I got a PR to my community bundle library is that it had not received the update to .pre-commit-config.yaml updating the black rev. I was able to fix it since I knew what the problem and fix was, but is there a way to do something like make updates available to libraries? Like something you could connect to via git and pull infrastructure changes like that from?
I could see it being particularly aggravating for someone that didn't realize what had happened with a repo that had been cloned from cookiecutter before the fix.
Great! You should be able to define CONF_XOSC32K_XTALEN earlier then to override this version.
Jeff just ran into that with an Adafruit library. I'm not sure how we can automate that.
Reset issue in PyLeap fixed by this PR.
@slender iron Can you let me know when that fix goes into main, so I can let Trev know? He's got the beta running on one CPB, I'm having him run latest on a second one, and test both.
added, thanks
@idle owl will do. probably tomorrow in another PR
Ok, sounds good.
I have an idea to try out, I can report back on how it goes 😁
Fair enough! Sounds good
@tulip sleet Do you have a few minutes to maybe help me parse some guide feedback? I think it's an Arduino problem, but I'm uncertain. Has to do with PWM on QT Py SAMD21. Jeff helped me a bit, but we thought you might know better.
sure
Vid might be fastest.
What is the exhaustive list of things that mpy-cross removes when a library is converted to a .mpy? I know essentially what it does, but I don't think I've ever asked for a canonical list in one question. That I can find anyway.
comments, docstrings and type hints, I think
Whitespace?
no whitespace in bytecode
Ok
also any globals that begin with _ and have value set using an integer expression wrapped in const()
Hmm
they get replaced with the value of that expression
Oof. Ok. Trying to explain what happens to a .py file when you run mpy-cross on it for a guide page.
it gets compiled to bytecode, which is similar to machine code that normal program binaries use
https://opensource.com/article/18/4/introduction-python-bytecode <-- this might help?
And that compilation removes comments, docstrings, type hints, whitespace, and replaces any _ globals that have a value set using an int inside const() with the value. Yes?
it's not like it removes those things, more like they don't get translated to the bytecode
Ahhh. Ok
there is no bytecode for a comment or for whitespace
the docstrings are removed, though
there is an option to not remove them, iirc
Fair enough.
the consts are simply replaced with their value, but only if they are "private" -- when they start with _
Yeah ok
if they are not private, they are left in there, because something might want to import them
Ah ok, that makes sense.
https://towardsdatascience.com/understanding-python-bytecode-e7edaae8734d <-- this is a better and more detailed explanation than the previous link
it's a bit like assembly
The first one didn't seem all that helpful, so another more detailed one might help.
I only know Python. Heh.
I mean I can find my way around Arduino, and I've submitted to the CP core...
But I usually need help.
This link is much better.
right, arduino compiles to machine code, which is a binary that can run directly on the microcontroller
mpy-cross compiles to bytecode, which is a binary that can run directly on the python virtual machine
And CP has the same concept of a virtual machine? I've heard Scott reference it a number of times, so I guess yes.
python virtual machine is like an abstract computer that is the same no matter if you run python on an intel or arm or, say, risc-v
Neat ok
cp has a different virtual machine and slightly different bytecode than regular python
when you have to match the .mpy to the python version, that is because the virtual machine has changed and expects different bytecode
like, for example, new commands have been added
Ohhh right.
I never really knew why we needed to change mpy version, I only knew that we needed to.
So would you say the result is a file that is smaller and more optimised? And it takes up less.... RAM and flash? or only flash.
it's smaller, but that's not the reason why it uses less memory
Oh
the thing is, to execute the python code, the python interpreter has to compile it to bytecode anyways, always
I saw that in the link you sent
what runs on the vm is always bytecode
so if you give it a python file, it has to compile it, and keep the compiled bytecode in memory while it is being executed
but if you give it an mpy file, it can just read it directly from the flash and execute it, without using additional memory, and without having to compile it
Ohhhh
so there are two things that use that extra memory: the compilation process itself, which needs to keep some extra variables while it's compiling, and the resulting bytecode, which needs to be stored in memory during and after the compilation
This is clearing up a lot of things I've always kind of glossed over.
this is why mpy files can have much more code in them
they are also slightly faster to start, since there is no compilation step, but usually you can't really tell the difference, with all the other delays that CP has on startup
enjoy
Here is the notes document for next Monday’s CircuitPython Weekly meeting. It is at the normal time of 11am Pacific / 2pm Eastern here on Discord. Everyone is encouraged to attend! Please add your hug reports and status updates even if you’ll be attending the meeting - it’s super helpful! If you are unable to attend but would still like to include updates, feel free to include them in the notes and we’ll read them off during the meeting. Hope to see you there! <@&356864093652516868> https://docs.google.com/document/d/1fc8UvMSBTq0x2Sh94_R6pSRm1v81sZCWA4L7TwsFzfg/edit?usp=sharing
CircuitPython Weekly for May 16, 2022 Here is the notes document for next Monday’s CircuitPython Weekly meeting. It is at the normal time of 11am Pacific / 2pm Eastern here on Discord. Everyone is encouraged to attend! Please add your hug reports and status updates even if you’ll be attending ...
I recently purchased this display for a project Im working on, they provide Arduino code to initialize the display and write bitmaps, which works, however I am unable to manage to port the sketch to ...
mpy byte code is loaded into RAM to run. It isn't run from flash. So, it saves memory usually used in the compile step but not after. (Almost, the mpy process may do a little optimization (const) which could save a little RAM.)
@idle owl don't give too many specifics about mpy because it does change from time to time
One request. Wemos creations repo should be ready for a PR too.
Thanks for adding this board!
Please remove these defines because they aren't used for C3.
It is a bug that the usb module appears on the download page. It is only enabled on iMX RT ports currently. RP2 will be next once TinyUSB has PIO host support.
Noticed that some of the builtins are missing from the documentation page for the API, particularly what exceptions are available to be raised.
Your pin naming isn't right. Circuitpython uses whatever the silkscreen says, in this case matching the IO# numbering. So IO0-IO10 should be D0-D10, etc.
Thank you, I am waiting for TinyUSB host or USBHost library for sam in arduino to be ported too for my use case.
Test on some other boards, the issue is only present on the USB CDC. All is good on TX/RX UART pins.
Added Circuit Python support for Cytron Maker Feather AIoT S3.
Thanks.
Thanks for the info. I'll reach out on Discord for more information!
@slender iron hey 👋 wasn't sure which channel to use (let me know if we should switch) but I'm coming from issue #5986 -- not sure what you meant by "iMX", but if you point me to the right direction I'm happy to start tinkering when I find free time!
it's one of the supported ports, mostly the Teensy boards as far as I know
https://circuitpython.org/downloads?q=imx <--- boards
https://github.com/adafruit/circuitpython/tree/main/ports/mimxrt10xx
https://github.com/adafruit/circuitpython/tree/main/ports/mimxrt10xx/common-hal/usb_host
ah right thanks, I'll dig around a bit to try to get a better understanding of all the pieces involved
(Adafruit's M7 boards and development have been postponed because of chip shortage)
If there's a reason not to roll this step into ci_fetch_deps can you let us know what it is? Superficially, it looks like frozen should just be added to the list in that file:
elif target == "docs":
- submodules = ["extmod/ulab/"]
+ submodules = ["extmod/ulab/", "frozen"]
elif target == "mpy-cross-mac":
and if the data is needed during create_website_pr.yml it would need an added call to ci_fetch_deps.py. If it re-uses the same docs key that's fine, or yo...
Has this board been added to circuitpython? A board definition needs to be added to circuitpython first, then the board can be listed on circuitpython.org
This lists the frozen modules below the built-in ones on boards pages.
Also includes a fix of files.json to replace frozen dir names with actual module names, as mentioned here.
The (?) link points to the glossary's short paragraph on frozen modules.
Another possibility was [the frozen modules page...
Thank circuitpython for adding a new board to circuitpython , I hope it can pass
Thanks so much for your guidance. I'm going to work on this over the next few days and will post back here once I make some progress.
Looking forward to your progress! I will be out for a few weeks so if you run into more questions I hope someone else will be able to help you out.
github doesn't seem to have a way to note yourself as 'on vacation', either to reduce notifications or to let others know you won't be available to respond on issues/pull requests/review requests .. am I missing something?
I guess I can "set status", where is that shown...?
oh yes I can set myself 'busy'. yay.
Busy having fun I hope! Have a great vacation
#ifndef MP_WARN_CAT
#define MP_WARN_CAT(x) #x
#endif
```oh good, micropython can warn the cat
I think this lets you write MP_WARN_CAT(stay off the table) though it may have no effect at runtime
Pushed an update:
- separating the frozen modules as suggested
- changed the top paragraph a little bit, with a link to the glossary
- adding the
frozendirectory to ci_fetch_deps.py in the "docs" and "website" categories
It is required for the website too, in order to list the modules accurately in build_board_info.py and not the frozen directories (for files.json). See https://github.com/ad...
It would be nice to have a more end-user-oriented reference on frozen modules, explaining that they take precedence over the lib directory, and how to replace them with a newer version (by placing a new version in the root directory). Maybe as a page in docs.circuitpython.org.
I agree. I didn't even know the specific details of that.
This looks great. Thanks for making these changes.
oh interesting quirk of documentation:
_MCP23017_ADDRESS = const(0x20)
...
class MCP23017(MCP230XX):
...
def __init__(
self, i2c: I2C, address: int = _MCP23017_ADDRESS, reset: bool = True
) -> None:
leads to the docs:
class adafruit_mcp230xx.mcp23017.MCP23017(i2c: busio.I2C, address: int = micropython.const, reset: bool = True)
So the default address is "micropython.const"...
Worth not using a const for just that one for clearer documentation ?
maybe we could add an explicit docstring which would give the value?
or just put the value in there directly, it's not like it's used anywhere else
it is missing :param:(s) in the docstring
it would be good to add :param:s anyway, and @stuck elbow 's point is good too
I think there are a number of libraries like this
I think it does that for micropython.const only, not just a normal UPPERCASE variable
if you remove the underscore, does it change the signature?
You'll need your own USB VID/PID combination. Espressif usually gives them out here: https://github.com/espressif/usb-pids
I wonder if the const could inherit from int in the stubs...
Why are you including the library as a frozen?
problem is, this is running in normal python, so it takes const from stubs, not the magic behavior of micropython's const
the docs compilation, I mean
I wonder if we could just set __repr__ on the const in the stub, to make it display the value passed
because it's declared as int? That's an easy fix
a behaviour I fail to reproduce in the MCP23017
I'll deal with that when it happens. This guide page is entirely meant to explain library file types, including mpys, and we get these questions a lot, and someone has to reiterate all of the info deshipu gave me every time it comes up. Ideally, we have it in a guide, and we can point folks to it instead.
also no underscore. It doesn't have to be const(), except to make the variable not be in the compiled dictionary
I do know mpy will change with MP 1.19
or maybe the tools versions you're using are not the same as the CI??
I'll keep that in mind. Thanks for the heads up.
Ok. What would change then? I'm not entirely sure what changed specific to the versions when we had to switch to a new version previous to this.
the mpy version number has to do with the file structure largely. in the past it changed so that mpy could hold native code and more efficiently load strings
the next change is largely so that mpy code can be run directly from flash (with the huge caveat of having a specific filesystem to store it)
you'll never guess
I REMOVED micropython from autodoc_mock_imports
and poof it worked
(the AHT library didn't have it mocked)
no other modification was required
Ahhh ok. Out of curiosity, is that specific filesystem something we will have? Or is that not something we can/will do.
I don't think we will soon at least
oh that's a bummer
as soon as Apple supports MTP
the new format needs a filesystem that stores the file linearly
because it uses XIP to run the code
right, but mtp would free us to use any filesystem we like
Eventually it will be possible to store such .mpy files in a linear, read-only, memory-mappable filesystem so they can be executed from flash/ROM.
oh they don't have one yet then ?
Ok fair enough.
@idle owl then I suppose I lied to you when I said mpy are executed from flash -- sorry
the frozen modules are, though
right?
yep
No worries! That's why having that conversation in this channel was helpful, because others can provide their knowledge as well.
Thank you! This addresses my concerns about the CI. I didn't review the PR in other respects, though.
@tulip sleet let me know when you are around for a chat. I've got another issue to fix with ble reload
For what it's worth it was also just fascinating to follow along
I should have considered that angle too! I feel the same a lot of the time, so I know what you mean.
@tulip sleet Guide feedback saying that my explanation of the flash usage for CircuitPython is incorrect on ESP32-S3... 8MB of flash, how much is used for firmware, and how much for CIRCUITPY? I checked the S2, and it's 1MBish for CIRCUITPY, which is what I said in the guide. Am I missing something?
that was me, the S3 has 8MB, while the S2 has 4
yup
@idle owl which board specifically? It looks like maybe any part with 8MB flash gets 2048KiB for firmware and 3776KiB for CIRCUITPY.
yup that's the 8MB partition scheme in tinyuf2
Plugged in an S3. CIRCUITPY is 3.8MB.
Good catch. Thanks!
So this is now accurate? The 8 MB of flash is inside the module and is used for both program firmware and filesystem storage. For example, in CircuitPython, we have 4 MB set aside for program firmware (this includes two OTA option spots as well) and an approximately 3.8MB section for CircuitPython scripts and files.
I had finished all my guide feedback, refreshed and there was a new one. Had to squash it! Must reach 0! 😄
the original poster on the forum who mentioned the other issue with the Feather S3 page also noticed that the schematics uses a bloc for the S3 that has two "DAC" pins, it's a really minor thing, but if Limor feels like updating it 🤷
it's deep in the schematic, I don't think anyone is gonna be confused by it
great sleuthing
i was out for a walk and am back now
Still fighting (as I do other things) with this Sphinx issue. Docs passing and building locally and remotely. However, the API page is blank remotely, and shows up locally. No changes were made, the docs build under the GitHub Actions for the latest change to the remote repo shows exactly the same Sphinx build output as my local setup does. Tried rebuilding through RTD, no change remotely. So I have no explanation or idea where to start on this one. No errors to work with, no obvious direction. https://github.com/adafruit/Adafruit_CircuitPython_Simple_Text_Display
@idle owl by viewing the raw log something interesting becomes visible but I'm not sure what it means yet. ```
WARNING: autodoc: failed to import module 'adafruit_simple_text_display'; the following exception was raised:
Traceback (most recent call last):
File "/home/docs/checkouts/readthedocs.org/user_builds/adafruit-circuitpython-simple-text-display/envs/latest/lib/python3.10/site-packages/sphinx/ext/autodoc/importer.py", line 62, in import_module
return importlib.import_module(modname)
File "/home/docs/.asdf/installs/python/3.10.0/lib/python3.10/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/home/docs/checkouts/readthedocs.org/user_builds/adafruit-circuitpython-simple-text-display/checkouts/latest/adafruit_simple_text_display.py", line 28, in <module>
import terminalio
File "/home/docs/checkouts/readthedocs.org/user_builds/adafruit-circuitpython-simple-text-display/envs/latest/lib/python3.10/site-packages/terminalio.py", line 26, in <module>
FONT = fontio.BuiltinFont()
File "/home/docs/checkouts/readthedocs.org/user_builds/adafruit-circuitpython-simple-text-display/envs/latest/lib/python3.10/site-packages/fontio.py", line 31, in init
self._font = ImageFont.load_default()
File "/home/docs/checkouts/readthedocs.org/user_builds/adafruit-circuitpython-simple-text-display/envs/latest/lib/python3.10/site-packages/PIL/ImageFont.py", line 361, in load_default
f._load_pilfont_data(
File "/home/docs/checkouts/readthedocs.org/user_builds/adafruit-circuitpython-simple-text-display/envs/latest/lib/python3.10/site-packages/PIL/ImageFont.py", line 107, in _load_pilfont_data
image.load()
File "/home/docs/checkouts/readthedocs.org/user_builds/adafruit-circuitpython-simple-text-display/envs/latest/lib/python3.10/site-packages/PIL/ImageFile.py", line 241, in load
n, err_code = decoder.decode(b)
SystemError: PY_SSIZE_T_CLEAN macro must be defined for '#' formats
looking for now-outdated files... none found
maybe see what happens if you switch it back to python3.9 for building on rtd https://docs.python.org/3/c-api/arg.html#strings-and-buffers
I'd also just consider asking readthedocs, they may either know an answer or view it as something they need to fix
I don't see where to switch the version of Python used. I know it's a thing, because we dealt with it recently, but I'm not sure where it is.
I'm wondering if it was something on Sphinx's end.
I guess I can ask RTD.
.readthedocs.yaml
/home/docs/checkouts/readthedocs.org/user_builds/adafruit-circuitpython-simple-text-display/envs/latest/bin/python -m pip install --upgrade --no-cache-dir mock==1.0.1 pillow==5.4.1 alabaster>=0.7,<0.8,!=0.7.5 commonmark==0.8.1 recommonmark==0.5.0 sphinx sphinx-rtd-theme readthedocs-sphinx-ext<2.2
it's installing a specific version of pillow. This problem was fixed in pillow 6.0.0.
so maybe figure out where that particular pillow version request is coming from
Yeah ok
I thought maybe it was the blinka version of displayio but it's not.. https://github.com/adafruit/Adafruit_Blinka_Displayio/blob/main/setup.py#L39=
np
what did you try?
Looking deeper.
Tried setting pillow version in the docs/requirements.txt.
Which it does install from after grabbing pillow-5.x
but apparently that does nothing
Details Read the Docs project URL: https://readthedocs.org/projects/pep-previews/ Build URL (if applicable): https://readthedocs.org/projects/pep-previews/builds/16667606/ Expected Result Unnecessa...
maybe there are two problems, because the specific error I saw earlier isn't in the output now .. but it still made no difference to having the API page appear
you're just looking in the sidebar for it right?
I clicked "simpletest" and then clicked "next" on the bottom of that page
which should go to API
goes to "no title" now.
https://docs.circuitpython.org/projects/simple-text-display/en/latest/api.html is there for me now
oh!
Hard refresh and it's there for me too!
Hurrah. I guess it did install a later version of Pillow.
it probably installed one and then the other
I reverted the change to the version of Python used
so it's only me adding a specific version of pillow.
Attempting uninstall: pillow
Found existing installation: Pillow 5.4.1
Uninstalling Pillow-5.4.1:
Successfully uninstalled Pillow-5.4.1
Successfully installed pillow-9.1.0
yeah it installs the one then replaces it with the other.
@gilded cradle WDYT of adding a >= 6.0.0 requirement to pillow here, would it negatively affect platforms we want to support or would they have the necessary version available?
We may be able to write 'any pillow version, but at least 6 if python 3.10 is installed', I'd have to check how requirements.txt deals with a situation like this pillow pillow >= 6.0.0; python_version>=3.10 (any version of pillow, unless python 3.10 or above is installed, in which case at least version 6.. is the intent)
raspbian oldstable has 5.4 (and python 3.7)
What does adding pillow as a requirement do? It's an image manipulation library.
It's already a requirement of https://github.com/adafruit/Adafruit_Blinka_Displayio/blob/main/requirements.txt I just want to get a version that's compatible with python 3.10
sorry I was unclear on that point (where I wanted to add it)
Sure, we can change that to >= 6.0.0.
my syntax for applying it based on Python version is wrong
pillow>=6.0.0; python_version>'3.9'
I'm uneasy because that LOOKS like a string comparison but maybe it's not
I'm not sure what the pip syntax is
so I just tested this in docker python:3.9 and docker python:3.10: ```pip install 'pillow==5.4.1'; pip install 'pillow' "pillow>=6.0.0; python_version>'3.9'"
the install of pillow==5.4.1 first is to copy what RTD is doing, that causes us problems.
so I feel like this is relatively safe
oh yes, I guess so!
Oh, good I just came here to talk/ask about this 😅
There are others that aren't rendering properly. No idea if it's the same issue.
now you can look in the raw log for that error though!
I'd hold off fixing any more if melissa is going to change blinka displayio though
I mean, fixing them by changing the python version
Right. I agree.
Ok, so.... a .py file vs a .mpy file. A .py file on a smaller micro will result in memory allocation failures? As well as taking up more flash, but that's typically not the issue. I understand why .py requires more memory, but I want to make sure I'm explaining this properly.
Or "can" result in anyway.
a .py file requires more memory when imported, so if there's not much memory remaining the import is more likely to fail
because the process of turning the py text into the internal representation (bytecode) uses memory
an mpy just needs to be loaded into memory, a py needs to also share that memory with the running compiler
this is why sometimes the order of importing files matters
you want to import the big ones that require more memory during compilation first, while there is still memory free
Yeah I had a few sentences on why .py requires more memory from yesterday. But I was struggling to connect "what is a .py file" with "uses extra memory". These things are the connection.
oh @idle owl, I believe there was a conversation about a font repository a while ago. I mentioned this to @lone axle during a stream recently, I think it would be really interesting to mention U8g2 as a repository of fonts, (under some type of open license), in the fonts guide.
there's a bunch: https://github.com/olikraus/u8g2/wiki/fntgrp
https://github.com/olikraus/u8g2/tree/master/tools/font/bdf
Maybe even somebody would have the courage to go through them and pick a few at different sizes that look good and can be showcased for people to select.
Hmm. How often is it updated? The issue with linking to other folks' repos is if it gets deleted etc in the future. If it's not updated that often, we could fork it, and link our fork... But it might be fine? If @lone axle is up for it, I think that might be a good idea. Is that the repo you always link when asked that question?
Need to jet for dinner. Be back in a bit.
I would like to know where the sys.path() for libs is defined when I get back through. 🙂
I only discovered it recently, it seems active, it's a "monochrome graphics library for embedded devices", the fonts are only part of it, some under MIT, others under creative commons, etc. We could totally mirror them as long as that's ok with the license
Fair enough. We've linked to other folks' repos before, so it's not unprecedented, but opting to fork it means we have our own copy if they disappear for any reason.
@tulip sleet Where is sys.path() in terms of the library file order? As in where is the code telling CP where to look? I thought I knew, but apparently I don't.
>>> import sys
>>> sys.path
['', '/', '.frozen', '/lib']
Ohhhhhh. Right.
if nothing is frozen, .frozen is not in the path
>>> sys.path
['', '/', '/lib']
Nifty.
e.g. on Qt Py M0
Ah ok
i only know that because I happened to try it on the board I currently had plugged in
Hahaha. Nice
nobody knows how this works anymore, we are doomed
It has become sentient.
by the way there's like 25 occurences of "micropython" being in "autodoc_mock_imports" in the bundle (excluding comments)
@tulip sleet What is the first '' in the sys.path? I thought it started in root /, then checked .frozen if it's there, and then /lib... So what is the ''?
current directory, I think
https://docs.python.org/3/library/sys.html#sys.path
As initialized upon program startup, the first item of this list, path[0], is the directory containing the script that was used to invoke the Python interpreter. If the script directory is not available (e.g. if the interpreter is invoked interactively or if the script is read from standard input), ***path[0] is the empty string, which directs Python to search modules in the current directory first. ***Notice that the script directory is inserted before the entries inserted as a result of PYTHONPATH.
Hmm. So '' for us is CIRCUITPY as well?
Ok got it. Thanks!
Thanks for the support provided by circuitpython, because some libraries are not in Rozen, many new libraries have been added, and some customized modifications have been made to adafruit library
Thank you. I've submitted the application board at circuit python. Let's pass it later
CircuitPython version
Adafruit CircuitPython 7.3.0-beta.2-31-g72807bb6c on 2022-05-11; Adafruit Feather ESP32S2 with ESP32S2
Code/REPL
# Issue occurs in REPL before any code is run
Behavior
As soon as the board boots to the REPL prompt >>>, the board LED is turn faintly on and all the GPIO pins go to 3.3V.
I'm not sure if it's related but I've also noticed that when I2C data is sent over the STEMMA QT connection the charging LED blinks and t...
For LC709203F, I am seeing bad handling of a clock stretch. The top trace is ESP-S3, the bottom trace is ESP-S2. The first four I2C transactions are the same. Then there is a clock stretch, which works on the S2, but not the S3. Note that SDA goes high after a relatively short time in the top (S3, bad) trace.

This adds the new suggested method for downloading submodules into the make help command.
Rationale
After returning to (the internals of) CircuitPython, I forgot the newer command for initing the submodules. It looks like the documentation is only in the circuitpython build guide.
Changes and Concerns
See the changes [here](https://github.com/TG-Techie/circuitpython/blob/cb2bf41be6bec85f655fcff9c73b8a...
Is this the best 'spelling' for the feature? Is it worth adding at all?
Closes adafruit/circuitpython#6371
Also updates awesome-circuitpython to latest
Thanks for the suggestion. I've fixed the second problem you noted, and offered a pull request to add the new 'feature', though I don't know whether Adafruit will choose to accept it.
If you have further issues or enhancements specifically about the circuitpython.org website, you can file them over on that repo: https://github.com/adafruit/circuitpython-org/ -- though it's no trouble that you filed this issue here.
Thanks again!
I noticed an odd message from the pre-commit run in our github ci:
[@octokit/rest]
const Octokit = require("@octokit/rest")is deprecated. Useconst { Octokit } = require("@octokit/rest")instead
While pursuing this, I found that the action we use (pre-commit/action) is deprecated. Pre-commit instead proposes you use their CI service, https://pre-commit.ci/
On the other hand, transitioning from the current action to a two-step shell command `pip install pre-commit; pre-commit run...
I read about this. For open-source repos, it is free, including for an organization. It will automatically fix things that can be fixed, which is good, but requires users to know to pull the automatic changes back when submitting a PR. It will be faster than doing pip install pre-commit, but that is not a big timesink in the scheme of things. The automatic fixing would save a lot of tiny commits for people who forget to install pre-commit locally.
building my debian workframe... virtualbox is being a Hades Pit with me
Sounds good. I'll add to the guide.
Thanks again for the suggestion.
Something that points to https://learn.adafruit.com/how-to-add-a-new-board-to-the-circuitpython-org-website would probably be useful as well.
I tried out pre-commit.ci on two of my personal projects .. https://results.pre-commit.ci/run/github/77753953/1652368838.qvt34fwsRSiYze0oigbXMQ https://results.pre-commit.ci/repo/github/293359557
It's too bad their URLs are opaque. It does run fast, but in one of the two cases I ran into trouble where pre-commit behaved different than locally OR on github actions.
Here's an example of it pushing to a pull request: https://github.com/jepler/wwvbpy/pull/31 https://results.pre-commit.ci/run/github/77753953/1652369245._qJ40VmDTM2jffJpA_bWNQ
Note: This is waiting on https://github.com/adafruit/circuitpython/pull/6383 to be merged first.
We deliberately changed ESP boards to pull pins up when not in use. Floating them caused sporadic neopixel issues otherwise. We do have a way for a board to set a specific pin to a different state. We could do that for the board LED on the S2 feather so that the pin is pulled down instead.
I tried out pre-commit.ci on two of my personal projects .. https://results.pre-commit.ci/run/github/77753953/1652368838.qvt34fwsRSiYze0oigbXMQ https://results.pre-commit.ci/repo/github/293359557
It's too bad their URLs are opaque. It does run fast, but in one of the two cases I ran into trouble where pre-commit behaved different than locally OR on github actions.
Here's an example of it pushing to a pull request: https://github.com/jepler/wwvbpy/pull/31 https://results.pre-commit.ci/ru...
Also I didn't go through the features they could have, but at least made "breadboard-friendly" consistent.
I hope it will be accepted this time
you know you can push to the same branch to update a PR
well now you know !
for a moment ;-)
lol
pre-commit failed again
but in vscode it told me all was ok in my pre-commit
go figure
I can do suggestions in the PR that you can then accept in the github UI
that would then fix it
a leftover tab
If you accept the changes, that should make pre-commit happy.
void board_init(void) {
}
Remove blank spaces/empty line.
CIRCUITPY_ESP_FLASH_SIZE = 4MB
Add newline at the end of file.
{ MP_ROM_QSTR(MP_QSTR_IO18), MP_ROM_PTR(&pin_GPIO18) },
{ MP_ROM_QSTR(MP_QSTR_IO4), MP_ROM_PTR(&pin_GPIO4) },
Remove blank spaces.
there should be a button to "accept changes" or something like that in the github UI
ok
you can also batch the changes and accept them in one commit
what software did you use to create the PR ?
github directly
ah, if you use the github app for example you can modify your code and push more changes to the PR to fix pre-commit issues and stuff
cool cool
@tulip sleet For sys.path, is it weird to do print(sys.path) in the REPL? vs simply sys.path which does the same thing. I'm asking because in the guide I suggested that you could run the two lines of code in code.py or the REPL, but in code.py it would need to be print(sys.path). So I figured include the REPL example, but use print() so it would work in code as well.
My prog workflow is dating from before 2005 and the other one I know is for PLC (automation) which is also outdated
it's fine, if you want a consolidated example. If you don't say print() then anything that's None will not print anything, but that's not going to happen here.
I don't quite understand what you mean.
there's a small difference between print(x) and x in the REPL, relative to the automatic use of repr() for strings, but that's fine I think
>>> "1234"
'1234'
>>> print("1234")
1234
>>> None
>>> print(None)
None
So basically for this example, it's fine, but don't assume it is always that way?
for a list, there would be no difference
Ok thanks
I support this proposal; it would be really useful to be able to use e.g. the M4 CPU power to do FFT, digital filters etc. in a background process from CircuitPython without needing to go back to lower-level programming environments.
For example, people are doing Software-defined Radio (SDR) stuff on ATmega328Ps (see here). So being able to at least do filtering of audio frequencies (low-pass, band-pass, high-pass), amplitude modification, amplitude...
I'm actually nervous about that pull request
Why?
first time I am that far in it
We all started somewhere, and we all had our first PRs, and our first complicated PRs.
We're all here to help out with it to make sure you're able to contribute.
I understand being nervous, I was too. But there's no need. We understand.
I also have general anxiety disorder ...
That I also understand.
so yeah pretimuch anything makes me nervous
it passed pre-commit, it's building
Well, once this is sorted, we can be excited for you. 🙂
---> Cannot find file ../ports/espressif/build-Lilygo-T-oi-Plus-ESP32C3/firmware.uf2
this is making me pannic
lol
I can empathize with nervousness about waiting for the computer to say "no". It does it without a hint of empathy. But it's not capable of any. We are, though, or aspire to be.
It would make CircuitPython a real killer environment for commercial solutions if there was some kind of support for modern software security features in the uCs.
I could imagine several routes for achieving this:
-
Be able to compile a custom CircuitPython binary (uf2 image?) that bundles your application code and the CPy environment and then be able to set the security bits.
-
Implement a code-encryption mechanism so that the upload uses a public device key for encrypting the so...
This is the Update ports/espressif etc PR, yes? You're Simon?
The build hasn't failed yet. Sometimes things that look like failure warnings are standard parts of the process.
@warm flame so you're right that the line about not finding .uf2 is important
esp32-c3 can't use uf2 (as far as I know), so it is necessary to add the board to a list of exceptions
it would be nice to have defaults per variant or whatever it's called
look in tools/build_board_info.py and find the lines like ```python
# esp32c3
"adafruit_qtpy_esp32c3": BIN,
And yeah it would be better if this were more automatic like neradoc suggests! but as of now it's not
that's around line 72 in my copy
ok
Hey. @tulip sleet ... I just realised I was running sys.path on the Circuit Playground Bluefruit, and still got this: ```Adafruit CircuitPython 7.2.5-1-g8d7390992 on 2022-05-10; Adafruit Circuit Playground Bluefruit with nRF52840
import sys
print(sys.path)
['', '/', '.frozen', '/lib']```
I don't see any frozen libraries in that build.
Also, where is .frozen anyway? It's not a visible directory, so I should probably explain the concept...
it's a fake directory; the frozen stuff is not really in the filesystem. I'm trying to remember which board didn't show frozen stuff at all.
you can't os.listdir(".frozen") for example
right
the pico has no .frozen, is it a RP2040 thing ?
I read up on sys.path and for the first time, wondered how it actually worked with .frozen. It simply made sense before, .frozen means the frozen modules.
But now knowing what sys.path does, I questioned it for the first time.
I was looking on a QT Py SAMD21, hmm
That's what I thought.
the "original" QT Py
Yeah.
Do you have a Trinket or GEMMA handy?
Maybe it's a lack-of-flash thing?
Stretching here.
yes, I'm going to check that
I think that in 7.2.5 it is listed on all boards, but in 7.3.0 it's only listed if used
@tulip sleet @idle owl
Ohhhhhh.
Hmph.
I guess I'll pretend folks are using 7.3.0 and ignore any feedback between now and then about the page being wrong.
i have no memory of such a PR, hmm
It came with a micropython merge is my guess
Good call. Thank you!
@idle owl I cannot reproduce LC709203F problems on ESP32-S2, but it's completely reliable to reproduce on S3: https://github.com/adafruit/circuitpython/issues/6311
Oof. Yeah you mentioned that.
I guess at least I'm not completely off?
there is definitely a problem on S3, it's obscure, I can't make it happen when using the Arduino library. It is clock-stretching-related, it appears
It's always clock stuff.
hmm, you actually reproduced on S2 with bitbangio
Yeah.
so anyway I am going to concentrate on S3 with regular busio
i am amazed this sensor works at all. The datasheet implies it's hard to wake up, and that it may prevent other I2C devices from working when it's asleep. But that does not happen
Hah! No I haven't run into any of that nonsense.
I may push this past 7.3.0, this may be another job for Espressif to fix, but I have to come up with a non-CIrcuitPython failure. And the fellow who fixed the previous I2C bug is stuck at home Shanghai so his supply of I2C devices is very limited
anyway, just FYI
Oi. Ok thanks for letting me know.
spritetm?
o-marshmallow: Omar
Oh that's where the username came from. That's pretty funny.
how do I add file to a pullrequest
I am going to ignore the S2 bitbangio issue for now. The LC709203F does clock stretching for several ms at a time, which seems to be an issue for the S3. I cannot reproduce the problem using https://github.com/adafruit/Adafruit_LC709203F/tree/master/examples/LC709203F_demo and removing the delay in loop(). I see clock stretches in that case, but they are handled properly. So there's something different about CircuitPython, perhaps again the multiple tasks we are running.
git add or the equivalent in the GUI or the web interface.
I'm not sure how to do that through GitHub. I have run into this previously and usually end up switching to working on it locally on my machine. I would google whether there's a way to do it through the GitHub UI though.
@warm flame in your branch in GitHub, use this:
Oh nice!
did it.
I forgot a space between ":" and "BIN" failed pre-commit
lol
should be ok now
This guide page is a massive wall of text. I have no idea what to use as images. Have to come up with something.
Probably screenshots of CIRCUITPY with various libraries or some such. Kind of boring, but better than nothing.
build worked
Great job sticking through this!
what are the 2 yellow check ?
Yellow dots? They're queued up, or haven't finished running yet.
Some CI things require other things to complete before they show up and run.
So sometimes, you'll think it finished because one of them completed successfully, but then another one shows up.
so it takes a lot of time ?
Oh yes. Much less than it used to, but still can be quite a bit.
I can't mark off those modules on the original issue, could someone please update it?
it's gonna build every board because of the change to build_board_info.py, so it takes a long time
ohhhhhhhhh
nothing we can do about it for now
it should pass then
because I didn't touch to anything more than the ESP32-C3 board
and it already passed
wth
my build failed
again : Cannot find file ../ports/espressif/build-Lilygo-T-oi-Plus-ESP32C3/firmware.uf2
"lilygo_ttgo_t-oi_plus": BIN,
yeah you need to use the exact directory name "Lilygo-T-oi-Plus-ESP32C3" it's the board identifier
also I would prefer personally that it uses all lower case
ok will change that then
that's just me I guess, but I think we should have a rule about that
I'm just bothered by Seeed_XIAO_nRF52840_Sense and the inconsistency with other xiao boards
in general we use underscores in the directory names
and I agree, they should be all lowercase
Ahh, sorry, I guess this should have been a discord/forum question first :/. My problem is that I have a buzzer connected to a pin which starts buzzing as soon as I power up. I'll throw some logic in the code.py file that quiets my sound pin on boot up. Thanks.
anyways be back later
@idle owl am I still good to run the patch tomorrow for the pre-commit file?
Should be! Do it slowly simply to make sure things are still working properly, obviously. But yep!
Sweeto! Will do!
Whoops, I meant Saturday, but same same!
Also reproduced on Adafruit ESP32-S3 Feather
Right, that's what I thought, but thought maybe something had changed.
The core adafruit_bus_device module is only present when frozen in, right? I'm gonna mention that and link to the external one repo in the core docs but wanted to check
It's built into the core, it's not frozen in... I thought?
And if it doesn't fit in a given build, you have to load it into the lib folder manually.
This lets the BLE stack run through the wait period after a VM run
when it may be waiting for more writes due to an auto-reload.
User BLE functionality will have their events stopped. Scanning and
advertising is also stopped.
and to determine if its in any given boards firmware build:
https://docs.circuitpython.org/en/latest/shared-bindings/support_matrix.html
Turns out NeoPixel is a great library to show the difference in memory usage between mpy, py, and frozen imports (on CPX). Tried CircuitPlayground library first, but I knew what the result would be when I got to .py file, failed. I got screenshots anyway, might have a place somewhere on this page.
Hi all!
Cookiecutter is still the preferred way to make new libraries?
(A quick glance at the learn guide says yes but thought it'd be worth a doublecheck)
Yes! Unfortunately there are a few things still missing from cookiecutter, but we're doing our best to keep it updated. That is the preferred way to start a new lib for sure, though.
Also, good to see you! It's been ages 🙂
Awesome! I see it's changed
Quite a bit!
And you too! It's good to be back 😊
The README should be up to date with what prompts mean what, and I think the guide is also up to date, but I'm not certain.
So far it looks like it is both update date and mirrored
Excellent
Could a run a specific to this question by please?
I've been working on a thing and am not sure which if any bundle it would be best for.
Sure! I might have an answer. If I don't, someone will, I'm sure.
Thanks, I ask b/c I'm guessing you will 🤷♂️😄 (or pass it to the weekly meeting)
(typing...)
This makes sense to me!
bleio_user_reset() needs to be added to devices/ble_hci/, I think, to fix the undefined errors.
A) Would there be interest in a minimal typing library? (with ~one alteration to the Core)
B) Would it be something that should be on the adafruit, circuitpy org, or community track?
C) Has there been previous discussion of this? I did some searching around but didn't find PRs or other documents (I have not checked recording)
My bad, It's three. Maybe this should be a issue or PR
Optional explanation:
I've made a branch of CP that supports __class_getitem__ after making a typed codebase and struggling to hack it into working on stock CP. In short, i think the only things needed to make it "hack-less" is bing able to do SomeType[...] and a typing module with TYPE_CHECKING, Generic, Protocol, TypeVar, and
Sorry for the delay 😅
No worries, thanks for tagging me, I was off elsewhere.
Reading now.
We have a typing library?... hold on
@marble hornet How close is this to what you mean?
didn't work
Oh i mean the opposite. Bringing some cpython typing to CP.
didn't name the directory right
Only the parts that cannot go in type-hints
Ah ok. I think this is best place for this question is In the Weeds on Monday, or in an issue on the core, or both, for that matter. I think we'll come to a more thorough solution with more input.
Thank you and will do!
Good to know it sounds like it's work bringing-up (?)
I'd say so yeah, for sure. No idea what will come of it, but it's definitely worth bringing up.
Dunno if you had this answered fully but adafruit_bus_device is part of the core. The python module can be frozen in if for some reason you didn't build the core module
I would think the frozen python module would take more space than the native implementation ?
If I'm comparing import memory free between frozen, mpy and py, what's the best comparison to use? Difference between frozen and py, and py and mpy? Or difference between frozen and both py and mpy, or difference between baseline and frozen, mpy, and py? Now that I'm thinking about it, probably baseline.
Otherwise it's not really a good comparison.
Baseline may make it easy to see, rather then relative
Yeah that's what I realised after typing it. Basically, once I had it in front of me typed out, it was obvious.
38 boards to check left
Thanks for the information. I have chosen to use an extra XIAO RP2040 board to drive the second display and use I2C to take the data from the main processor. The RP2040 is a lot cheaper than many hours of my time trying to get dual display to work.
Again, thanks for your help.
@jaunty juniper What's the next step ?
somebody reviews it, approves it and then somebody merges it, meanwhile you can add it to circuitpython.org
https://learn.adafruit.com/how-to-add-a-new-board-to-the-circuitpython-org-website/overview
So is that a configuration setting for some builds? Like some just have it built in by default, or they all do?
like all (optional) builtin modules
it's CIRCUITPY_BUSDEVICE, which is on by default in full builds
full builds (CIRCUITPY_FULL_BUILD) is turned off on some small boards, typically M0
boards that require the external adafruit_bus_device if using a library that requires it:
https://docs.circuitpython.org/en/latest/shared-bindings/support_matrix.html?filter=-bus_device
that's more than I expected
but I guess it's all M0s
This process is overwelming
and I never used ruby
too many new stuff
What Neradoc said. Most have it built-in. I could search if you need a list but I think it is only turned off in the smaller SAMD21 builds.
I extercised this problem in a different way (causes a crash) in a simple ESP-IDF program on several S3 boards, and reported it comprehensively in https://github.com/espressif/esp-idf/issues/8894#issuecomment-1125564756.
Thanks!
@kattni want to test BLE reload again?
Circuitpython Core Support
This PR adds 3 toggle-able features to the core:
Pep 560
add __class_getitem__ as discussed above.
Adds .subscr to `mp_type_type
Pep 585
add generic [] operator to builtin containers and collections to return themselves.
ex:dict[str, int] is dict # True
Pep 604 like
This adds the | operator ...
I opened this by accident amd make separate pr with an explanation and rational later
Thanks @tannewt and @prplz I will look at this next week.
Got it thanks!
Besides speeding up the bus, could you also try using sdcardio instead of adadfruit_sdcard? It is a native implementation of the Python code inadafruit_sdcard.
I no longer think this is important to merge, if it only affects boards without os.urandom. However, if someone feels different, please feel free to re-open it.
If this is about enabling the use of these expressions for typing, consider just making sure there's no need to evaluate the typing definitions. I think the best we've found (in terms of effect on mpy size or RAM size) is
from __future__ import annotations
try:
from typing import TYPE_CHECKING
except ImportError:
TYPE_CHECKING = const(false)
if TYPE_CHECKING:
optional_str = str | None
str_int_dict = dict[str, int]
...
def f() -> optional_str: ...
Pushing this to 7.x.x because it seems like an ESP-IDF issue.
@onyx hinge what are you thinking about https://github.com/adafruit/circuitpython/pull/6338 ? I talked to Scott about this a couple of days ago, but he wasn't sure either. I think we don't know of an example where SH1107 is used for non-one-bit displays
@tulip sleet Unless someone thinks there are >1 bit SH1107 displays then we either want to ignore the positional argument, or give an error. Ignoring it had the lower flash size cost.
giving an error would be better, but I didn't want to add messages to the core
Scott was interested in an error. I will see if there's a message we can reuse, or maybe use the range checking arg checker
I will take it over
thank you, feel free.
are you quitting work early today? You will have a marvelous trip, bon voyage!
if we were taking my 'solution' then at a minimum a note in the docs should be added that the flag is ignored unless it's a 1bpp display
thank you! I will be 'around' today but I am not necessarily 'working'.
say, I'm not sure what that implies by the way:
typing.TYPE_CHECKING
A special constant that is assumed to be True by 3rd party static type checkers. It is False at runtime.
and then tomorrow is travel day, sunday is the first day in paris
it is only True when processed by mypy, etc. Is that what you mean?
the actual module defines it as False
but what does it to test it then ? wouldn't it cause a runtime error when annotating with the types guarded by it?
not when used in conjunction with from __future__ import annotations
or using string-annotations
from __future__ import annotations
from typing import TYPE_CHECKING
if TYPE_CHECKING:
from typing import Optional
def f() -> Optional[str]: pass
```so for instance this is acceptable to Python3 even though 'at runtime' `Optional` isn't actually imported
as is this variant, which uses a string annotation: ```python
from typing import TYPE_CHECKING
if TYPE_CHECKING:
from typing import Optional
def f() -> "Optional[str]": pass
and in CircuitPython, python try: from typing import TYPE_CHECKING except ImportError: TYPE_CHECKING = const(0) # can't be const(False) means everything in the if TYPE_CHECKING: block is not even placed in the mpy file, which is pretty keen
could do?
try:
from typing import TYPE_CHECKING
# put conditional stuff here
from typing import Optional
optional_str = str | None
#etc.
so it's telling the static analyzer where to look for types that are otherwise hidden from the runtime
There's a small chance it won't be doing what you expect (say you had from typing import Optionall, the wrong import error will be suppressed) and I'm not sure mpy-cross will successfully eliminate the dead code the way if TYPE_CHECKING + const will
you're right about the dead-code, yes, I forgot that
actually adding typing to jepler_udecimal enough for it to pass mypy --strict is feeling like a challenge!
Another day, another documentation PR! Resolves #6381, and works towards #6326:
- Adds additional exceptions to
builtins
Adds links to guides/libraries for:
qriofontioterminalio(really just a note additional that it doesn't give REPL access with link to REPL guide page)microcontroller(actually just a touchup, no linking)audiomp3rp2pioalarmbitmaptools
Also makes additions from #6353 prettier.
Anything else I need to do?
I also have a patch for the circuitpython.org prepared, but I'm waiting for this to land first.
I added a validation check in shared-bindings, and also left the forced fix in, because the common-halroutine can be called from other places, like aboard.c` file.
While looking through the messages for one I could reuse, I found several messages that are almost identical and could be merged. I'll make some PR for that later.
Found 436 errors in 3 files (checked 3 source files)
Yup, typing jepler_udecimal is a slog.
These cross-references are excellent. Thank you!
I suggested some changes from "library" to "module", when describing a built-in module.
//| .. note:: This module only handles decoding QR codes. If you are looking
//| This module is typically not used by user level code.
//| .. note:: This module is intended only for low-level usage. For working with
Seriously arbitrary style question: If I'm referring to a ".mpy file", should I expect people to read the . as "dot", meaning I put "a" before it, or should I expect people to skip over the . and read only "mpy", in which case it should be "an" before it?
These cross-references are excellent. Thank you!
I suggested some changes from "library" to "module", when describing a built-in module.
I skip the dot in my head, so to me "an" makes more sense
I keep going back and forth, I've been leaning towards "an" but haven't been consistent, and I need to be.
Looking at it too long, I almost feel it works the other way - I'll read it differently depending on whether you use "a" or "an" haha

This is not a priority for Adafruit funded folks because we generally don't support commercial applications. MicroPython may support this though. I know they support more commercial applications.
One small change to switch to a unique creation id. I added it here: https://github.com/creationid/lilygo-creations/blob/main/README.md
CIRCUITPY_CREATION_ID = 0x00C30002
@proven garnet I was thinking. Equally as important as the pre-commit-config patch, is getting cookiecutter in line with the current updates. Otherwise, new libraries are being created that aren't up to date and we end up missing things. Is that something you could also work on this weekend? I left one suggestion here: https://github.com/adafruit/Adafruit_CircuitPython_TSC2007/pull/2 but if that's everything, please add these changes to cookiecutter if you have the cycles.
I am (again) looking at consolidating error messages that are almost identical, and using common validation routines like the mp_arg_validate... routines when possible. The last time I tried this, it didn't save that much, but it does reduce the number of messages that need to be translated. I won't submit a final PR until after 7.3.x is branched, but I did a bunch already, and I have an older branch with similar work I need to look at again.
Yeah, I can definitely do that. Is everything ready to go? If so I can

If you caught everything that needed updating when you made that PR, then yes, it's ready to go. That's the only reference I was aware of as to what needed to be updated in cookiecutter.
Sweeto! Yeah, I can get it done over the weekend, possibly today
Perfect, thank you. I can't help folks who started a library 2 months ago, but I can help folks creating libraries moving forward. 🙂
you helped me 🙂
I'm playing around with automatically building a template library with cookiecutter and seeing if hooking it up as an upstream in git has any success
Hah! Valid. You're exactly who I was thinking of when I said that 😄
So every cookiecutter change would build a library, but I'm not sure how having a repository setup like that will behave since it isn't really an upstream (I think?)
Hmm. No idea.
Not even sure I'm following 😄
It's a python script that could run via CI that would submit a pull request to a library (say, "CircuitPython_AutoBuild") with infrastructure changes, and anyone with that as an upstream could easily pull changes from it. Or that's the hope anyway.
Oh oof. I'd be totally lost as to how to do that. But I now understand what you mean.
cookiecutter has a pretty sleek Python interface it seems, so I'm starting there
Nice
But it can't catch everything, if for some reason we need to modify __version__ in library files or something then womp womp
but maybe at least the other stuff
@proven garnet Bonus points if you do a pass on .pylintrc to up min-similarity-lines= to 12 while you're at it. 😆 This is not as high a priority though. So don't feel obligated. I think Adabot might be able to do that, but then again, I think that regularly and am regularly incorrect. So...
is jerry out of town?
I'm revisiting https://github.com/adafruit/Adafruit_CircuitPython_ESP32SPI/issues/72 and wondering why get_time doesn't just block until the time is valid
Is there any hope for support for XMP (not NEC) IR protocol within the adafruit_irremote library? Is it already there and I just don't know how to read a help manual?
guptaxpn — Today at 2:28 PM
https://github.com/crankyoldgit/IRremoteESP8266/issues/1414 << It would appear that it's been done elsewhere, but I just can't figure out how to port this.
Probably better suited for this channel.
@deft jay I don't think it should go in irremote but could be in a new library
I don't know why we'd add support for it though
Comcast remotes specifically utilize XMP
is making a non-blocking function blocking an api break?
which services a huge portion of the US
Tannewt is asking whether you changing a non-blocking function into a blocking function is considered breaking the API. The wording was a bit odd.
Would adafruit accept pull requests?
Well, there's two options here. If it's a separate library, which it sounds like it sort of needs to be, you could submit it to the Community Bundle. If it were to be included in the existing library, then yes, you would make a PR to the lib. However, IRRemote is one of those libs we can't really extend too much because it's included in CircuitPython builds for memory-constrained microcontroller boards. So we have to be careful in considering what to add.
Basically, you would create a library under your own GitHub, submit it to the Community Bundle, and then it's available within the Community bundle for download on circuitpython.org/libraries.
Aah
so that's why it's NEC only
an odd omission considering the arduino ones are so big
but I guess they also get cut back at compile time
I think we implemented NEC, and that was enough for most things, so we went with it for CircuitPython, and then when we ended up needing it in memory-constrained situations, we decided to keep it as such.
Is this for the .pre-commit-config.yaml patch to the libraries, or the cooiecutter patch?
@idle owl was there inspiration from this project in the dev for the adafruit library? : https://github.com/cyborg5/IRLibC ?
It looks several years since last commit, I wonder if there's a way to pull some stuff around
That would be to the libraries. Cookiecutter is still 12 I think.
Got it, I'll add that in for the infrastructure patch then
Is that also ready to roll out?
You know, I'm not sure. There might have been. Chris is a close friend of Adafruit.
The min-similarity-lines bit?
I added that in for the cookie cutter patch
He's the reason I felt like I could take this project on. Or at least his personal remote project.
I'm thinking his library might actually work, I think GICABLE might be comcast?
No idea, but worth trying for sure.
Wait I think I unconfused myself haha. I'm rolling out the .pre-commit-config.yaml patch this weekend but didn't have a general patch put together for the changes proposed for libraries I listed here: https://github.com/adafruit/Adafruit_CircuitPython_BME680/pull/48
Ahhh yeah ok that's separate.
Probably better to do in pieces anyway.
I am going to defer this past 7.3.0, since there it didn't build, and I want to see how it affects builds on Windows, which some people do.
The .pylintrc change from 4 to 12 came out of the Sprints. The reason it's no rush, is it hasn't come up in other libs yet, but it almost certainly will.
So I'm getting ahead of things.
For once 😄
No worries! I'll add it to that "PR" I just mentioned and after this round of patches start working on something for those. Unless Adabot is able to do them, but otherwise I'm happy to
Well, we can try Adabot in teaching you how to do it, to find out if you can.
Oh yeah, I 'member
The more complicated the patch, the more likely it is to fail across more libraries.
So it might be worth doing multiple patches for that one.
I say might be, I mean is.
Sounds good! If next week is good, I can make myself available from 12-1 any day!
Or another week, no rush for me
Wednesdays are a little dicey since I have a 1pm, but doable!
Mondays are always busy with meetings. Tuesday is typically free. We can start then and move it into further days if necessary.
Sounds good!
I added it to my calendar. Hopefully you're better at remembering things than I am.
Feel free to ping me before that so it's on my radar, heh.

Hah 😄 Well, maybe between the two of us, lol.
Looks good to me! Thank!
Cancelled full build run, since the doc build is fine, and we don't need to test every build.
Hmph. CircuitPlayground library was missing from /frozen for some reason. I was on main branch. Obviously pull and make fetch-submodules fixed it. But I'm still curious how it wasn't there to begin with. 🤷🏻♀️
Hey @dhalbert, this is ready functionality-wise at this point; it does look like I pushed some builds over the edge though (~50 bytes too much for most failures). There are some that seem a bit odd though, for example trinket_m0_haxpress at 732 bytes over?
As you mentioned above, this probably means that this feature should go behind a feature flag?
I have some ideas for post-7.3.0 for shrinking some builds a bit by consolidating similar error messages, but yes, we probably need to conditionalize it.
I saw the LilyGo TTO T-01-C3 we already defined, and thought maybe it is a typo, but it is a board with many fewer pins. So there 1is a Lilygo board with OI(oh eye) in its anme, and another board with01` (zero one) in its name. Oy.
Thanks for the updates!
One small change to switch to a unique creation id. I added it here: https://github.com/creationid/lilygo-creations/blob/main/README.md
Just curious, does anyone know of any reason why compiling with#define CIRCUITPY_DISPLAY_LIMIT 4 and creating four displayio.I2CDisplay objects would cause a HardFault?
I don't see anything obvious in "shared-module/displayio/init.c" (I'm trying to use four SSD1306 I2C OLEDs on a ESP32s3. Any three work)
I can only think of checking whether you're running out of some resource (RAM, etc.)
100kB free (this is on ESP32S3)
@tulip sleet yeah T-01 and T-oi are confusing!!!
quote: _T-OI As the name suggests, T is still our T series. TOI is from the right to the left, meaning IOT products. _
lol
! tcefreP
Pin names in board.{SCK,MOSI,MISO} and board.SPI() were a bit off, perhaps because of previously-mentioned board rev. My boards are Rev C, and these changes have been verified to work with an SPI TFT.
Thanks for catching these errors!!
Thanks! I will merge for 7.3.0 inclusino.
Yup, it's waiting on the CPX PR, which needs a merge and release.
https://github.com/adafruit/Adafruit_CircuitPython_CircuitPlayground/pull/117
All set now; thanks @jepler!
Both the atmel-samd and the nrf ports wait until the UART peripheral is no longer busy to return. I think, but am not sure, that mean that the last byte has been transmitted out of the FIFO. If the i.MX port is not doing that, then it should, and we would welcome that fix.
There is an issue I found about this for atmel-samd: https://github.com/adafruit/circuitpython/issues/1770
CircuitPython version
Adafruit CircuitPython 7.0.0-alpha.5-716-gd2d08fc94-dirty on 2022-05-13; Adafruit QT Py RP2040 with rp2040
Code/REPL
import time, gc
import board, busio, displayio
displayio.release_displays()
for i in range(5):
print("waiting for USB", 5-i)
time.sleep(1) # wait for USB to connect
i2cA = busio.I2C(scl=board.SCL, sda=board.SDA)
i2cB = busio.I2C(scl=board.SCL1, sda=board.SDA1)
#i2cB = busio.I2C(scl=board.TX, sda=boa...
Partly addressed by #6069. See #6284 for further followup.
@tannewt This bug is fixed by the new mDNS code?
Fixed by #5785. Now goes into safe mode if CIRCUITPY can't be mounted or created. Tested by trying on some boards that have bad flash chips or bad connections.
Fixed as reported above.
make fetch-submodules does this now, though I think the times for these are now swamped by other submodules
Fixed by #5468, I believe.
Hi, I came here looking for a solution to a problem, where RP2040 communicates with LTE/WiFi to send data. At this time pretty much any library is using time.sleep. Meaning while I am sending data over UART the code is blocking. The device does not react to buttons, etc. My understanding is if a thread would be used for offloading data another thread could be used to keep the device "operational". I am happy to be educated on different approach to resolve this scenario.
Thank you
Needs retest after recent rework of autoreload logic.
@jaunty juniper so RTD broke even though there were no errors in the CI build?
yup, it runs its own thing from .readthedocs.yml which does not use the same rules as the CI
but apart from this file, I don't know what makes it do what where why
I wonder if RTD offers a way to test build the docs with their system in the CI so it's run with the actual configuration file it uses (and fails if the configuration causes an error)
that would be nice! not sure either
I kind of want to add a comment in ci_fetch_deps.py:
elif target == "docs":
# NOTE: must match .readthedocs.yml as this script is not run by readthedocs
submodules = ["extmod/ulab/", "frozen/"]
feel free, push a new commit in the fixup PR
it will restart (it hasn't started yet anyway)
https://docs.readthedocs.io/en/stable/pull-requests.html yes, readthedocs has something for this -- we have to enable it on rtd, I think
I've experimentally enabled this setting on circuitpython
(just now)
You could also set up your own readthedocs site just for testing (maybe you can hide it from search engines), and do it on your own pushes, or trigger the webhook manually only
Thanks @wtuemura and @bergdahl !
This saves 124 bytes on trinket m0, though at some performance cost (I didn't measure). On "full build"s it saves 24 bytes, the rest is only saved on small builds.
Taking just the extra memset() removal part of the patch saves 24 bytes of flash, removing the int-at-a-time optimization from string0 saves 100.
It's lightly tested on a pygamer with the de-optimization manually enabled (it wouldn't be enabled on a pygamer by default).
why yes, it's my travel day and here I am making CP patches
well, if it's a distraction from impatience or worry, sounds fine
impatience, mostly
In prep for 7.3.0 final
you couldn't make all of these in CP, but you could make some (and think about what core changes would enable some of the other ones at a minimum of fuss) .. https://blinry.org/50-tic80-carts/
like maybe the heart particle system https://blinry.org/50-tic80-carts/24/
@onyx hinge willing to approve https://github.com/adafruit/circuitpython/pull/6398 ? (frozen updates)
Thanks! verified all submodule changes were in the forward direction.