Closed robobyt closed 5 years ago
We received this from a BrainPad Classic user.
Hello,
When using the Digital Write Pin block in MakeCode for the classic BrainPad I get the following error:
Program Error: Unable to get property 'digitalWritePin' of undefined or null reference
See screen capture below. This was using Microsoft Edge on a computer running Windows 10. I have also tried Firefox and Google Chrome and got similar errors, even on a different computer running Windows 7. I called the main GHI phone line and the person who answered tried it and said he got a similar error message and suggested I email in the details.
Since then I discovered this only affects simulation. The pin behaves normally if the error is ignored and the board is programmed. I have not seen this error with any other commands I am familiar with. Do you know if there is a solution or workaround? Although a solution would be nice, it is not that urgent now that I know the board works if programmed.
Thanks, Ed Smith
You need to populate the list of pins at https://github.com/microsoft/pxt-brainpad/blob/70ebbdbb8d3973d8818b37b786bc1f14d52001c8/sim/dalboard.ts#L95
When I try to use block 'PINS' I got 'Cannot read property 'digitalWritePin' of null'. What could be wrong?