mirror of
https://github.com/sascha-hemi/pycom-documentation.git
synced 2026-03-21 06:06:03 +01:00
* changed shield examples * changed shield links * added example text * added getting-started * added getting started * upate shield getting started * add new examples * add sleep and scan examples * update links * changed links to release
1.5 KiB
1.5 KiB
title
| title |
|---|
| Shields |
The API pages in this section explain the additional functionality offered by the following shields:
- Pysense
- Pysense 2.0 X
- Pytrack
- Pytrack 2.0 X
- Pyscan
Note that this functionality is not built into the firmware, and you will need to download additional libraries from our Github libraries repository.
The API pages are separated per sensor:
- Accelerometer (LIS2HH12)
- Light Sensor (LTR329ALS01)
- Temperature / Humidity Sensor (SI7006A20)
- Pressure Sensor (MPL3115A2)
- RFID / NFC (MFRC630)
- GPS (L76GNSS)
Next to that, you will need either one of the supporting files needed to operate the shield:
- Pycoproc - used on the first version of the Shields
- Pycoproc2 - used on the second version of the Shields
Uploading the Libraries to a Device
Place the applicable Python files for your shield into the /lib folder of your project. Do not forget to press upload project to device in Pymakr to make sure you are able to use them.
Importing and using the libraries
Once the libraries are uploaded to the device, they can be used/imported as a typical MicroPython library would be. For example, importing and using the light sensor on the Pysense:
from pycoproc import Pycoproc
from LTR329ALS01 import LTR329ALS01
py = Pycoproc()
lt = LTR329ALS01(py)
print(lt.light())