EasyManuals Logo

Adafruit Feather M4 Express User Manual

Adafruit Feather M4 Express
178 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #59 background imageLoading...
Page #59 background image
CircuitPython Libraries
Each CircuitPython program you run needs to have a lot of information to work. The reason CircuitPython is so simple
to use is that most of that information is stored in other files and works in the background. These files are called
libraries. Some of them are built into CircuitPython. Others are stored on your CIRCUITPY drive in a folder called lib .
Part of what makes CircuitPython so awesome is its ability to store code separately from the firmware itself. Storing
code separately from the firmware makes it easier to update both the code you write and the libraries you depend.
Your board may ship with a lib folder already, its in the base directory of the drive. If not, simply create the folder
yourself.
CircuitPython libraries work in the same was as regular Python modules so the Python docs (https://adafru.it/rar) are a
great reference for how it all should work. In Python terms, we can place our library files in the lib directory because
its part of the Python path by default.
One downside of this approach of separate libraries is that they are not built in. To use them, one needs to copy them
to the CIRCUITPY drive before they can be used. Fortunately, we provide a bundle full of our libraries.
Our bundle and releases also feature optimized versions of the libraries with the .mpy file extension. These files take
less space on the drive and have a smaller memory footprint as they are loaded.
Installing the CircuitPython Library Bundle
We're constantly updating and improving our libraries, so we don't (at this time) ship our CircuitPython boards with the
As we continue to develop CircuitPython and create new releases, we will stop supporting older releases. If
you are running CircuitPython 2.x, you need to update to 3.x. You must download the CircuitPython Library
Bundle that matches your version of CircuitPython. Please update to CircuitPython 3.x and then download the
3.x bundle.
© Adafruit Industries https://learn.adafruit.com/adafruit-feather-m4-express-atsamd51 Page 64 of 183

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Adafruit Feather M4 Express and is the answer not in the manual?

Adafruit Feather M4 Express Specifications

General IconGeneral
BrandAdafruit
ModelFeather M4 Express
CategoryMicrocontrollers
LanguageEnglish

Related product manuals