#Testing a frozen module in CP
1 messages ยท Page 1 of 1 (latest)
Hey @elder peak. So, here's what I do.
There's a /frozen directory in the CircuitPython repo. Inside it are what appear to be library repositories. One of them is the CircuitPlayground library. Go into that directory, and copy the adafruit_circuitplayground directory to your desktop or somewhere convenient (so you can put it back when you're done, easiest way to get back your build environment). Then, copy the adafruit_circuitplayground directory from your local copy of the Circuit Playground library repo into that same folder, replacing the current one. (So you're copying your working changes into the /frozen/Adafruit_CircuitPython_CircuitPlayground directory.)
Then, build for Circuit Playground Express, using the Russian translation because it's apparently the biggest right now. So cd ports/atmel-samd then make BOARD=circuitplayground_express TRANSLATION=ru and see if it succeeds, or fails.
If it fails because it's too big, we will discuss how to slim down your library contribution at that point. Or discuss whether or not we can include it at all.
To test a frozen library in general, you can do the same thing but with any of the other existing frozen library. Testing a new frozen library is a little more complicated (but apparently covered in the guide).
Oh nice! I have a minute now lemme give it a shot
I get a weird few fatal: no tag exactly matches lines but it did build a UF2
Um
I think I get that sometimes too
Really? It worked?
I'm genuinely surprised.
How much space does it say is left?
Because we also can't leave it with a few bytes only. ๐
1032 bytes in flash firmware
21072 bytes in ram
That's pretty good.
Build without the TRANSLATION.
I want to see how much the basic en_us build has left.
I can also still remove some of the bells and whistles I probably have in that code too
So, I think that's a good idea to do. Since that library is already a super tight fit on CPX, I think it's important to keep that in mind when adding features. So slimming down what you submitted is still worth it.
Will do! Also for no translation it's 3328 bytes for flash firmware, same for ram
Ok, that's excellent.
So yeah, go ahead and slim it down, and we'll test it again for good measure, and then talk about merging it at that point.
I guess there's a few ways to do it, I guess it depends if this should be a breaking change or not - currently there are two ways to access the inputs
The old methods and now this
I'm going to say it absolutely can't be a breaking change. The only time we can break this library is in the event of something catastrophic happening elsewhere that requires it. Even when we added the Bluefruit, we made all of it backwards compatible with the preexisting code.
It's far too highly used for it to be worth it to break anything.
Oh! And I guess it depends on what features aren't worth introducing, I can make a list on the PR and you can let me know what's not worth the space
We're releasing 7.2 soon. I'd like to see the update in there because otherwise it's ages before we end up making another release to update frozen modules (unless something broke, which this isn't about).
So... let's prioritise this. ๐
That would be good!
Sounds good, just added a list to the PR