This is a list of all the core modules built into CircuitPython, including
.
board
Remember,
contains all of the pins on the board that you can use in your
board
code. From the REPL, you are able to see that list!
Type
into the REPL and press enter. It'll go to a new prompt. It might
import board
look like nothing happened, but that's not the case! If you recall, the
import
statement simply tells the code to expect to do something with that module. In this
case, it's telling the REPL that you plan to do something with that module.
Next, type
into the REPL and press enter.
dir(board)
This is a list of all of the pins on your board that are available for you to use in your
code. Each board's list will differ slightly depending on the number of pins available.
Do you see
? That's the pin you used to blink the red LED!
LED
The REPL can also be used to run code. Be aware that any code you enter into the
REPL isn't saved anywhere. If you're testing something new that you'd like to keep,
make sure you have it saved somewhere on your computer as well!
Every programmer in every programming language starts with a piece of code that
says, "Hello, World." You're going to say hello to something else. Type into the REPL:
print("Hello, CircuitPython!")
©Adafruit Industries
Page 60 of 263
Need help?
Do you have a question about the ESP32-S3 and is the answer not in the manual?