Skip to content
This repository has been archived by the owner on Dec 23, 2021. It is now read-only.

microbit: [ERROR] name 'pin0' is not defined #398

Open
gabrielle-ohlson opened this issue May 3, 2021 · 0 comments
Open

microbit: [ERROR] name 'pin0' is not defined #398

gabrielle-ohlson opened this issue May 3, 2021 · 0 comments

Comments

@gabrielle-ohlson
Copy link

gabrielle-ohlson commented May 3, 2021

When trying to run a micropython file using this extension and referencing any of the pins (e.g., pin0), I receive the following error in the console:

[ERROR] name 'pin0' is not defined

Here's an example of code that produces this error:

from microbit import *
import microbit

while True:
	if pin0.read_digital():
		display.scroll("Hello World!")

and the resulting error:

[ERROR] name 'pin0' is not defined 
	Traceback of code execution : 
	  File "/home/gohlson/code/micro-bit/main.py", line 5, in <module>
    if pin0.read_digital():
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant