Version 0.1.0
New MicroPython Goodies
This release includes three new demos ported over from C++: Text, Music and Audio.
These demos are a little rough around the edges, but you can find them in the launcher by holding "A" during boot.
🥳 You can now use "\spr001" to inline sprites in your text, eg: f"\\spr{LEAF:007} woo a leaf!"
🤔 No more Alpha? Bumped version to 0.1.0 to indicate that we (hopefully) shouldn't make any more breaking API changes
- The argument limit of
blit()
has been fixed so you can specify destination width/height for stretch blit. - Error text generated by our bindings will always include the offending function name. Eg:
pen(): a out of range. Expected 0 to 15
- Miscellaneous bugfixes.
- Documentation: https://github.com/pimoroni/picosystem/tree/main/micropython
- A Python file of strongly-typed stub functions you can use to code against: https://github.com/pimoroni/picosystem/blob/main/micropython/picosystem.py
flip()
now also updates input. Here's a working, if terrible, rock-paper-scissors that fits in a tweet (inspired by Kari):
import random
p=pressed
b='RPS'
t=text
s=l=0
pen(0,0,0);clear();pen();t("RPS=YBA",0,0)
while p(X)^1 and l<13:
flip()
for f in 0,1,2:
if p((Y,B,A)[f]):e=random.randint(0,2);s+=(0,1,-1)[f-e];t(f"{b[f]}v{b[e]}=\\pen{('00FFD','0F0FW','F00FL')[f-e]}\\penFFFF s={s}");l+=1
t("Bye")
What's Changed
- New text demo and bug fixes by @lowfatcode in #36
- text() now supports inline icons by @lowfatcode in #41
- MicroPython: Include function name in errors. IO in flip() by @Gadgetoid in #40
- MicroPython: Stubs & docstrings for VSCode by @Gadgetoid in #35
- MicroPython: Readme. by @Gadgetoid in #21
- Port Text example to MicroPython and fix blit() by @Gadgetoid in #42
Full Changelog: v0.0.7...v0.1.0