Skip to content

Commit

Permalink
Update installation procedure and documentation.
Browse files Browse the repository at this point in the history
  • Loading branch information
kaklik committed Nov 1, 2024
1 parent 5cd9587 commit 9b93a79
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 2 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,13 @@ Dependencies are also available on pip (useful on systems without native package
The latest version of pymlab library use true I²C transfers instead of SMBus transfers. It is needed by some sensors. Namely by SHT31, SHT25 etc. Therefore an updated version of i2c-tools and python-smbus module is needed for correct working of pymlab library and some examples.
The latest version of python-smbus could be installed from [this fork of i2c-tools](https://github.com/MLAB-project/i2c-tools).

### Install in to Ubuntu python system
### Install in to Ubuntu venv system

Create venv by `python3 -m ven .venv` then activate it using `source .venv/bin/activate` in the python enviroment you can install the pymlab library:

$ git clone https://github.com/MLAB-project/pymlab
$ cd pymlab/
$ sudo python3 setup.py develop
$ pip install -e .

#### HIDAPI interface for the USBI2C01A MLAB module (Optional support)

Expand Down
44 changes: 44 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
[build-system]
requires = ["setuptools>=61.0", "wheel", "setuptools_scm"]
build-backend = "setuptools.build_meta"

[project]
name = "pymlab"
dynamic = ["version"]
description = "Toolbox for interfacing I2C sensors."
readme = "README.md"
license = {text = "Lesser General Public License v3"}
authors = [
{name = "Jan Milík", email = "milikjan@fit.cvut.cz"},
{name = "Roman Dvořák", email = "romandvorak@mlab.cz"},
{name = "Jakub Kákona", email = "kaklik@mlab.cz"}
]
keywords = ["TWI", "IIC", "I2C", "USB", "sensors", "drivers"]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)",
"Natural Language :: Czech",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7"
]

dependencies = [
"smbus",
"six",
"numpy",
"hidapi"
]

[project.optional-dependencies]
test = ["pytest"]

[tool.setuptools]
package-dir = {"" = "src"}
packages = ["pymlab", "pymlab.sensors", "pymlab.tests"]

[tool.setuptools_scm]
version_scheme = "guess-next-dev"
local_scheme = "node-and-date"


0 comments on commit 9b93a79

Please # to comment.