# Servodoor: a simple library for controlling RC servo based doors
Servo door is a simple library for controlling (RC servo) doors via via
Pimoroni's [Servo 2040](https://shop.pimoroni.com/products/servo-2040)
18-channel servo controller. Initially designed for use in T-maze type
experiments. The Serovo 2040 must be running the
[servodoor-firmware](https://github.com/willdickson/servodoor-firmware)
## Installing
Install using pip
```bash
$ pip install servodoor
```
## Installing from source
This package uses the [poetry](https://python-poetry.org/) dependency manager.
The installation instructions for poetry can be found
[here](https://python-poetry.org/docs/#installation)
Once poetry is installed the serovodoor package can be installed using
```bash
$ poetry install
```
Additional documentation on using poetry can be found
[here](https://python-poetry.org/docs/)
## Usage
```python
import time
from servodoor import ServoDoor
port = '/dev/ttyACM0'
ctrl = ServoDoor(port)
rsp = ctrl.get_config()
print(rsp['config'])
rsp = ctrl.get_positions()
print(rsp['positions'])
ctrl.set_doors({'front': 'open'})
time.sleep(5.0)
ctrl.set_doors({'front': 'close'})
time.sleep(5.0)
```
Raw data
{
"_id": null,
"home_page": "https://github.com/willdickson/servodoor",
"name": "servodoor",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.10,<3.12",
"maintainer_email": "",
"keywords": "",
"author": "Will Dickson",
"author_email": "wbd@caltech.edu",
"download_url": "https://files.pythonhosted.org/packages/9e/32/ac965ef80aba9e2595c67fcc7b4b195c632ed0eaa8e1c76176b1a4b981df/servodoor-0.1.0.tar.gz",
"platform": null,
"description": "# Servodoor: a simple library for controlling RC servo based doors \n\nServo door is a simple library for controlling (RC servo) doors via via\nPimoroni's [Servo 2040](https://shop.pimoroni.com/products/servo-2040)\n18-channel servo controller. Initially designed for use in T-maze type\nexperiments. The Serovo 2040 must be running the\n[servodoor-firmware](https://github.com/willdickson/servodoor-firmware)\n\n## Installing\nInstall using pip \n\n```bash\n$ pip install servodoor \n```\n\n## Installing from source\n\nThis package uses the [poetry](https://python-poetry.org/) dependency manager.\nThe installation instructions for poetry can be found\n[here](https://python-poetry.org/docs/#installation)\n\nOnce poetry is installed the serovodoor package can be installed using\n\n```bash\n$ poetry install\n```\nAdditional documentation on using poetry can be found\n[here](https://python-poetry.org/docs/)\n\n\n## Usage\n```python\nimport time\nfrom servodoor import ServoDoor\n\nport = '/dev/ttyACM0'\nctrl = ServoDoor(port)\n\nrsp = ctrl.get_config()\nprint(rsp['config'])\n\nrsp = ctrl.get_positions()\nprint(rsp['positions'])\n\nctrl.set_doors({'front': 'open'})\ntime.sleep(5.0)\n\nctrl.set_doors({'front': 'close'})\ntime.sleep(5.0)\n```\n\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A simple library for controlling RC servo based doors",
"version": "0.1.0",
"project_urls": {
"Homepage": "https://github.com/willdickson/servodoor",
"Repository": "https://github.com/willdickson/servodoor"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "5311549724f1df82b01743b34c3b6a67eab9618a6c420101dab8194cf1131e1a",
"md5": "a20c162a3d6ebe365a700ecabaed29cf",
"sha256": "acc27815a760b3e38321245ddd6c9646c052d13172eaad8c12f3f73da3a99c31"
},
"downloads": -1,
"filename": "servodoor-0.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "a20c162a3d6ebe365a700ecabaed29cf",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.10,<3.12",
"size": 3457,
"upload_time": "2023-09-15T00:01:30",
"upload_time_iso_8601": "2023-09-15T00:01:30.450846Z",
"url": "https://files.pythonhosted.org/packages/53/11/549724f1df82b01743b34c3b6a67eab9618a6c420101dab8194cf1131e1a/servodoor-0.1.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "9e32ac965ef80aba9e2595c67fcc7b4b195c632ed0eaa8e1c76176b1a4b981df",
"md5": "0e8e86846028f39cf60473f2f15a1113",
"sha256": "93c2f3cbb31530ec1f26a217cecacecec8469760b350ec921473d3f67eee6965"
},
"downloads": -1,
"filename": "servodoor-0.1.0.tar.gz",
"has_sig": false,
"md5_digest": "0e8e86846028f39cf60473f2f15a1113",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.10,<3.12",
"size": 2838,
"upload_time": "2023-09-15T00:01:32",
"upload_time_iso_8601": "2023-09-15T00:01:32.333063Z",
"url": "https://files.pythonhosted.org/packages/9e/32/ac965ef80aba9e2595c67fcc7b4b195c632ed0eaa8e1c76176b1a4b981df/servodoor-0.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-09-15 00:01:32",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "willdickson",
"github_project": "servodoor",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "servodoor"
}