byte-triggers


Namebyte-triggers JSON
Version 0.3.0 PyPI version JSON
download
home_pageNone
SummaryProvides byte (0 to 255) triggers on serial/parallel ports and on LSL streams.
upload_time2024-04-03 14:29:33
maintainerNone
docs_urlNone
authorNone
requires_python>=3.9
licenseMIT License Copyright (c) 2022 Mathieu Scheltienne Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords parallel python serial triggers
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
[![Imports: isort](https://img.shields.io/badge/%20imports-isort-%231674b1?style=flat&labelColor=ef8336)](https://pycqa.github.io/isort/)
[![codecov](https://codecov.io/gh/fcbg-hnp-meeg/byte-triggers/graph/badge.svg?token=rSGaJehUMl)](https://codecov.io/gh/fcbg-hnp-meeg/byte-triggers)
[![tests](https://github.com/fcbg-hnp-meeg/byte-triggers/actions/workflows/pytest.yml/badge.svg?branch=main)](https://github.com/fcbg-hnp-meeg/byte-triggers/actions/workflows/pytest.yml)
[![doc](https://github.com/fcbg-hnp-meeg/byte-triggers/actions/workflows/doc.yml/badge.svg?branch=main)](https://github.com/fcbg-hnp-meeg/byte-triggers/actions/workflows/doc.yml)

# Byte-triggers

Delivers integer triggers between 0 and 255 on a parallel port or on an LSL marker
stream.

## Install

`byte_triggers` is available on [PyPI](https://pypi.org/project/byte_triggers/).

```
pip install byte_triggers
```

## Usage

For the API reference, see the online
[documentation](https://fcbg-hnp-meeg.github.io/byte-triggers).

```
from byte_triggers import LSLTrigger, MockTrigger, ParallelPortTrigger

trigger = MockTrigger()
trigger.signal(1)

trigger = LSLTrigger("MyTrigger")
trigger.signal(1)

# on-board parallel port on linux
trigger = ParallelPortTrigger("/dev/parport0")
trigger.signal(1)

# on-board parallel port on windows
trigger = ParallelPortTrigger(0x4FB8)
trigger.signal(1)

# arduino to parallel port converter
trigger = ParallelPortTrigger("arduino")
trigger.signal(1)
```

# Copyright and license

The code is released under the [MIT License](https://opensource.org/licenses/MIT).

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "byte-triggers",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": "Mathieu Scheltienne <mathieu.scheltienne@fcbg.ch>",
    "keywords": "parallel, python, serial, triggers",
    "author": null,
    "author_email": "Mathieu Scheltienne <mathieu.scheltienne@fcbg.ch>",
    "download_url": "https://files.pythonhosted.org/packages/c2/91/461f5b281b23403f0ff38a00b8dfdf1a60194927c00bf9928c098b7981f6/byte_triggers-0.3.0.tar.gz",
    "platform": null,
    "description": "[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n[![Imports: isort](https://img.shields.io/badge/%20imports-isort-%231674b1?style=flat&labelColor=ef8336)](https://pycqa.github.io/isort/)\n[![codecov](https://codecov.io/gh/fcbg-hnp-meeg/byte-triggers/graph/badge.svg?token=rSGaJehUMl)](https://codecov.io/gh/fcbg-hnp-meeg/byte-triggers)\n[![tests](https://github.com/fcbg-hnp-meeg/byte-triggers/actions/workflows/pytest.yml/badge.svg?branch=main)](https://github.com/fcbg-hnp-meeg/byte-triggers/actions/workflows/pytest.yml)\n[![doc](https://github.com/fcbg-hnp-meeg/byte-triggers/actions/workflows/doc.yml/badge.svg?branch=main)](https://github.com/fcbg-hnp-meeg/byte-triggers/actions/workflows/doc.yml)\n\n# Byte-triggers\n\nDelivers integer triggers between 0 and 255 on a parallel port or on an LSL marker\nstream.\n\n## Install\n\n`byte_triggers` is available on [PyPI](https://pypi.org/project/byte_triggers/).\n\n```\npip install byte_triggers\n```\n\n## Usage\n\nFor the API reference, see the online\n[documentation](https://fcbg-hnp-meeg.github.io/byte-triggers).\n\n```\nfrom byte_triggers import LSLTrigger, MockTrigger, ParallelPortTrigger\n\ntrigger = MockTrigger()\ntrigger.signal(1)\n\ntrigger = LSLTrigger(\"MyTrigger\")\ntrigger.signal(1)\n\n# on-board parallel port on linux\ntrigger = ParallelPortTrigger(\"/dev/parport0\")\ntrigger.signal(1)\n\n# on-board parallel port on windows\ntrigger = ParallelPortTrigger(0x4FB8)\ntrigger.signal(1)\n\n# arduino to parallel port converter\ntrigger = ParallelPortTrigger(\"arduino\")\ntrigger.signal(1)\n```\n\n# Copyright and license\n\nThe code is released under the [MIT License](https://opensource.org/licenses/MIT).\n",
    "bugtrack_url": null,
    "license": "MIT License  Copyright (c) 2022 Mathieu Scheltienne  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
    "summary": "Provides byte (0 to 255) triggers on serial/parallel ports and on LSL streams.",
    "version": "0.3.0",
    "project_urls": {
        "documentation": "https://fcbg-hnp-meeg.github.io/byte-triggers",
        "homepage": "https://fcbg-hnp-meeg.github.io/byte-triggers",
        "source": "https://github.com/fcbg-hnp-meeg/byte-triggers",
        "tracker": "https://github.com/fcbg-hnp-meeg/byte-triggers/issues"
    },
    "split_keywords": [
        "parallel",
        " python",
        " serial",
        " triggers"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f7b5e4a38cea0632f2624b29379bed5359ec71e4eacfd8b4ae4d266a279f553a",
                "md5": "87e23b376498a4ac6e3013b1da87c4ce",
                "sha256": "239e9cfeebea983602a3c98ebaee4707badba39ba5aa2cc6dc7a3c2d0f46bd17"
            },
            "downloads": -1,
            "filename": "byte_triggers-0.3.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "87e23b376498a4ac6e3013b1da87c4ce",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 26645,
            "upload_time": "2024-04-03T14:29:31",
            "upload_time_iso_8601": "2024-04-03T14:29:31.590092Z",
            "url": "https://files.pythonhosted.org/packages/f7/b5/e4a38cea0632f2624b29379bed5359ec71e4eacfd8b4ae4d266a279f553a/byte_triggers-0.3.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c291461f5b281b23403f0ff38a00b8dfdf1a60194927c00bf9928c098b7981f6",
                "md5": "5cc86fc06770a93b3fd5f25d95982a84",
                "sha256": "0d0b5788d6a2978ddb11d85523aeb68d8bf04e65c024afeb5873961df57f78c4"
            },
            "downloads": -1,
            "filename": "byte_triggers-0.3.0.tar.gz",
            "has_sig": false,
            "md5_digest": "5cc86fc06770a93b3fd5f25d95982a84",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 21085,
            "upload_time": "2024-04-03T14:29:33",
            "upload_time_iso_8601": "2024-04-03T14:29:33.202119Z",
            "url": "https://files.pythonhosted.org/packages/c2/91/461f5b281b23403f0ff38a00b8dfdf1a60194927c00bf9928c098b7981f6/byte_triggers-0.3.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-03 14:29:33",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "fcbg-hnp-meeg",
    "github_project": "byte-triggers",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "byte-triggers"
}
        
Elapsed time: 0.21973s