Skip to main content

pyMYS

It is a module to make easier communication with MySensor’s network.

Documentation

Currently, all documentation can be accessed in project’s GitHub page.

Dependencies

You can find all dependencies in requirements.txt and install them using pip.

Installation

python setup.py install

or

pip pymys

Support

This project should support all Python 3 versions. However, it was onlye tested with Python 3.4.

Examples

If you just want to print all messages that your Gateway send to you.

from pymys import mysensors as mys


def show_msg(msg):
    print(msg)

gw = mys.SerialGateway("/dev/ttyACM0", message_callback=show_msg)
print("Trying to connect...")
gw.connect()
print("Connected!")

while True:
    gw.process()

Creating an application with threads which allow you write raw messages and send to your network over your Gateway

import threading

from pymys import mysensors as mys


def run_gateway():
    while True:
        gw.process()


def show_msg(msg):
    print("Read: {}".format(msg))

gw = mys.SerialGateway("/dev/ttyACM0", message_callback=show_msg)
print("Trying to connect...")
gw.connect()
print("Connected!")

t = threading.Thread(target=run_gateway)
t.start()

while True:
    data = input("")
    msg = mys.Message(data)
    gw.send(msg)

What’s new

  • Base structure for Gateway

  • Support to Serial Gateway

  • Support to protocol 1.4

  • Support to protocol 1.5

  • Support to protocol 1.6

  • Support to change callback functions

  • Support to get dinamically the protocol version from the Gateway

Metadata

Release files for pymys 0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pymys 0.2
File Size Uploaded Provenance
pymys-0.2.tar.gz 8.3 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for pymys 0.2
File Interpreter ABI Platform
pymys-0.2-py3-none-any.whl Python 3 none any Details

Total release size: 20.3 kB

Release files / pymys-0.2.tar.gz

Download URL pymys-0.2.tar.gz
Size 8.3 kB
Tags Source
SHA-256 checksum
How to use checksums
b76c48291569ff956197ade99435516c73681fd603e16778372858278dc6f22f
BLAKE2b-256 checksum
How to use checksums
d56c9f602f8bb1ce6804bf7a5baeb8889bc7d91ab1521b78000fba65b06990aa
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / pymys-0.2-py3-none-any.whl

Download URL pymys-0.2-py3-none-any.whl
Size 12.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fd7a305882eed73c9a42380dfe8c5b24f758b5faf25c43520f5a45980a090bb8
BLAKE2b-256 checksum
How to use checksums
f1cdc6a7858b6aeef97977435f7745b5cede7edfedb3bdbcbc923cb428c65080
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for pymys 0.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page