CircuitPython helper library for using the Adafruit MLX90395 tri-Axis magnetometer breakout
Project description
Introduction
CircuitPython helper library for using the Adafruit MLX90395 tri-Axis magnetometer breakout
Dependencies
This driver depends on:
Please ensure all dependencies are available on the CircuitPython filesystem. This is easily achieved by downloading the Adafruit library and driver bundle.
Installing from PyPI
On supported GNU/Linux systems like the Raspberry Pi, you can install the driver locally from PyPI. To install for current user:
pip3 install adafruit-circuitpython-mlx90395
To install system-wide (this may be required in some cases):
sudo pip3 install adafruit-circuitpython-mlx90395
To install in a virtual environment in your current project:
mkdir project-name && cd project-name
python3 -m venv .venv
source .venv/bin/activate
pip3 install adafruit-circuitpython-mlx90395
Usage Example
from time import sleep
import board
import busio
from adafruit_mlx90395 import MLX90395, OSR
i2c = busio.I2C(board.SCL, board.SDA)
sensor = MLX90395(i2c)
while True:
mag_x, mag_y, mag_z = sensor.magnetic
print("X1:{0:10.2f}, Y:{1:10.2f}, Z:{2:10.2f} uT".format(mag_x, mag_y, mag_z))
print("")
sleep(0.5)
Documentation
API documentation for this library can be found on Read the Docs.
For information on building library documentation, please check out this guide.
Contributing
Contributions are welcome! Please read our Code of Conduct before contributing to help this project stay welcoming.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file adafruit-circuitpython-mlx90395-1.0.6.tar.gz
.
File metadata
- Download URL: adafruit-circuitpython-mlx90395-1.0.6.tar.gz
- Upload date:
- Size: 29.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bbc4216213874f8908e1d66591ac051cede92e00678063be5b70e1525c1a4602 |
|
MD5 | 5c9252f006b2f9b514a98072557bda05 |
|
BLAKE2b-256 | a5d76c6fed2eed7f04a9374362a5f1576cbf8d9921d1b25f41a8e11fb2b086d2 |
File details
Details for the file adafruit_circuitpython_mlx90395-1.0.6-py3-none-any.whl
.
File metadata
- Download URL: adafruit_circuitpython_mlx90395-1.0.6-py3-none-any.whl
- Upload date:
- Size: 6.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 690e2dd8b1fcad669a23982c793d9b4e297a764fbcdabd136a1bca67202209d9 |
|
MD5 | 2999131958b42987f9885d968f9c2d00 |
|
BLAKE2b-256 | d59e25242d9ed98e8fb2d52d7e6d17ca1dc2bd99019e2d4019e66b58a4d2fc9c |