microsoft / pxt-calliope

A Microsoft MakeCode editor for the Calliope Mini board
https://makecode.calliope.cc
Other
39 stars 22 forks source link

digital read doesnt work in simulation #260

Closed ToniTaste closed 10 months ago

ToniTaste commented 10 months ago

Digital Read doesn't work in the simulation.

To Reproduce Please use this program: basic.forever(function () { if (pins.digitalReadPin(DigitalPin.P0) == 0) { basic.setLedColor(0xff0000) } else { basic.setLedColor(0x00ff00) } })

Expected behavior When you set pin P0 to 1 in the simulation there won't be a change on the light color.

Screenshots Screenshot 2023-11-21 124139

Desktop (please complete the following information):

Amerlander commented 10 months ago

Thank you for finding that issue.

Will be fixed in https://github.com/microsoft/pxt-calliope/pull/261