Introduction¶
This library provides FeatherWing specific classes for those that require a significant amount of initialization.
Dependencies¶
These drivers depends on:
Please ensure all dependencies are available on the CircuitPython filesystem. This is easily achieved by downloading the Adafruit library and driver bundle and highly recommended over installing each one.
API Reference¶
adafruit_featherwing.motor_featherwing
¶
Helper for using motors with the Motor FeatherWing.
- Author(s): Scott Shawcroft
adafruit_featherwing.ina219_featherwing
¶
Helper for using the INA219 FeatherWing.
- Author(s): Kattni Rembor
-
class
adafruit_featherwing.ina219_featherwing.
INA219FeatherWing
[source]¶ Class representing an Adafruit INA219 FeatherWing.
Automatically uses the feather’s I2C bus.
-
bus_voltage
¶ Bus voltage returns volts.
This example prints the bus voltage with the appropriate units.
from adafruit_featherwing import ina219_featherwing import time ina219 = ina219_featherwing.INA219FeatherWing() while True: print("Bus Voltage: {} V".format(ina219.bus_voltage)) time.sleep(0.5)
-
current
¶ Current returns mA.
This example prints the current with the appropriate units.
from adafruit_featherwing import ina219_featherwing import time ina219 = ina219_featherwing.INA219FeatherWing() while True: print("Current: {} mA".format(ina219.current)) time.sleep(0.5)
-
shunt_voltage
¶ Shunt voltage returns volts.
This example prints the shunt voltage with the appropriate units.
from adafruit_featherwing import ina219_featherwing import time ina219 = ina219_featherwing.INA219FeatherWing() while True: print("Shunt Voltage: {} V".format(ina219.shunt_voltage)) time.sleep(0.5)
-
voltage
¶ Voltage, known as load voltage, is bus voltage plus shunt voltage. Returns volts.
This example prints the voltage with the appropriate units.
from adafruit_featherwing import ina219_featherwing import time ina219 = ina219_featherwing.INA219FeatherWing() while True: print("Voltage: {} V".format(ina219.voltage)) time.sleep(0.5)
-
Contributing¶
Contributions are welcome! Please read our Code of Conduct before contributing to help this project stay welcoming.
Building locally¶
To build this library locally you’ll need to install the circuitpython-build-tools package.
python3 -m venv .env
source .env/bin/activate
pip install circuitpython-build-tools
Once installed, make sure you are in the virtual environment:
source .env/bin/activate
Then run the build:
circuitpython-build-bundles --filename_prefix adafruit-circuitpython-featherwing --library_location .