Lightweight ROS-like pub-sub tool utilizing ZeroMQ
Project description
Zero Message
Zero Message is a lightweight ROS-like pub-sub tool for Python 3.4+.
- Provides a wrapper around ZeroMQ socket.
- Communicate between any Python program using publisher-subscriber protocol
Installation
pip install zeromessage
Quick start
Refer to the /examples:
# listener.py
import asyncio
from zeromessage import EnvelopSocket
socket = EnvelopSocket.as_subscriber()
def doSomething(msg):
print(msg)
subscribe_coroutine = socket.subscribe('test', doSomething)
asyncio.get_event_loop().run_until_complete(subscribe_coroutine())
# talker.py
import time
from zeromessage import EnvelopSocket
socket = EnvelopSocket.as_publisher()
while True:
socket.publish('test', {
'data': [1, 2, 3]
})
time.sleep(1)
Command Line tools
A rostopic like tool is provided.
zerotopic echo -- --help
API Document
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
zeromessage-0.2.tar.gz
(2.9 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file zeromessage-0.2.tar.gz.
File metadata
- Download URL: zeromessage-0.2.tar.gz
- Upload date:
- Size: 2.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.4.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
352d1785a62c2fdbc6a054a77ef04363c745191866e6bee0e715d2c8482ef3c5
|
|
| MD5 |
f4a8a281efcacdd5f918ba9b102a274e
|
|
| BLAKE2b-256 |
2fc639efcfc619a85ff5df9263542c5cf34ca16ca8bf46b48ef3989c30d6a61a
|
File details
Details for the file zeromessage-0.2-py3-none-any.whl.
File metadata
- Download URL: zeromessage-0.2-py3-none-any.whl
- Upload date:
- Size: 3.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.4.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6f0d390da7309904277aaa8a513f016a2b13c9d89c6095f5938560426a046a70
|
|
| MD5 |
935a643f8a8dad2192a17d990b7dd7f4
|
|
| BLAKE2b-256 |
671342dd7567c7f6f9089059f4cab2bd73337c552d73f5a270b7d62c47d60798
|