pxt-microbit icon indicating copy to clipboard operation
pxt-microbit copied to clipboard

experiment with screen in micro:bit

Open tballmsft opened this issue 2 years ago • 4 comments

tballmsft avatar Aug 17 '22 00:08 tballmsft

Michal.

To torture myself, I am trying to put together the elements I think I need to get the screen into pxt-microbit (in advance of then pulling it out into an extension). I've made some progress but am getting some odd errors, mainly to do with the Image interface. Oh, I also forgot that pxt-microbit builds two version (mbcodal, mbit), so there's some magic to do so that the new packages only get built for mbcodal.

If you want to try it out, you should pxt link to pxt-common-packages, as I have a change there (already in main).

-- Tom

tballmsft avatar Aug 17 '22 00:08 tballmsft

I added disablesVariant but now there is a name clash on Image class, which has different definition in micro:bit.

AFAIK there is no way to rename the one in micro:bit core from an extension, and if you rename the one in game---light, your code won't work with a regular Arcade. Maybe you can define some type aliases.

The pin stuff can be probably fixed by editing the screen code directly (it goes into extension, so no need to introduce anything in common packages).

mmoskal avatar Aug 17 '22 12:08 mmoskal

now it fails on mixer - I think you want to drop it and use micro:bit native sound

mmoskal avatar Aug 19 '22 14:08 mmoskal

Thanks for the help! Yes, I thought I had removed the dependence on mixer.

tballmsft avatar Aug 19 '22 15:08 tballmsft