Skip to main content

command-line interface for superior communication with any embedded device.

Project description

|PyPI version| |Join the chat at| |Stories in Ready|

pytelemetry command line interface

This tool enables superior communication with any embedded device. It is
for you if:

- you are using ``printf`` to debug your application
- you are all the time re-writing custom protocols for the serial port
- you need a **reliable** and **error-tolerant** communication protocol
- you want to finely tune your application without loosing time
compiling & flashing just to tune a parameter
- you want to **plot** parameters on the device in **real-time**
- your embedded device has very limited resources and will tolerate
only a lightweight communication library


pytelemetry-cli is a **command line interface**. It provides a set of
commands to connect to a device, read, plot and write data on it.

.. figure::
:alt: Overview


pytelemetry-cli relies on
```pytelemetry`` <>`__ |PyPI
version| to implement the specific communication protocol.

To communicate with the device, you only need to make your device use
the ```telemetry`` <>`__


The underlying communication protocol mostly follows the
`PubSub <>`__\ (publish/subscribe)
messaging pattern.

[..] messages are published to "topics" or named logical channels.
Subscribers in a topic-based system will receive all messages
published to the topics to which they subscribe [..]. *Source:

interface and plot widget

Aan example of listing serial ports ``ls -s``, connecting to a device
through COM20 ``serial com20 --bauds 115200``, listing all received
topics ``ls`` and opening a plot on topic touch ``plot touch``

.. figure::
:alt: Console example

Console example

.. figure::
:alt: Plot example

Plot example


``pytelemetrycli`` requires python 3.5+, PyQt4 and numpy.


It is recommended to download
```numpy`` <>`__ and
```PyQt4`` <>`__ wheels
python packages (courtesy of Christoph Gohlke).

In case you were wondering, **no** you **don't** have to install Qt. The
binary wheel is enough.

Then install with pip the downloaded files

.. code:: bash

pip install numpy-x.xx.x+vanilla-cp3x-none-winxxx.whl
pip install PyQt4-x.xx.x-cp3x-none-winxxx.whl

Then, simply install ``pytelemetrycli`` with pip as usual

.. code:: bash

pip install pytelemetrycli

Mac OS

The easiest way to install numpy and PyQt4 seem to be using
``homebrew``. lease note that you should also have installed python 3.5
with homebrew for this to work correctly. Also, avoid to have another
python 3.5 distribution on your system otherwise you will face import
issues as well.

.. code:: bash

brew install python3
brew install pyqt --with-python3
pip3 install pytelemetrycli



setup for embedded devices

To setup telemetry on any embedded device, please refer to the
```Telemetry`` <>`__ repository.

If you only wish to test the command-line interface, you can also
directly flash a test firmware from our own `collection <#>`__ *Note: in
process. In the future we will support a variety of devices so you can
quickly start on with the command line.*

List of commands

The command line interface can be started like this


python3 -m pytelemetrycli.cli

or more simply



If everything is installed properly, ``:>`` should welcome you.


pytelemetry terminal started. (type help for a list of commands.)
:> _

help [command]

Without arguments, you get a list of all available commands. Otherwise
the full ``command`` documentation.


.. code:: bash

Without options, prints a list of all received topics.
With the --serial flag, prints a list of all available COM ports

Usage: ls [options]

-s, --serial Use this flag to print a list of all available serial ports


.. code:: bash

Connects pytelemetry to the serial port.

Usage: serial <port> [options]

-b X, --bauds X Connection speed in bauds [default: 9600]


.. code:: bash

Prints X last received samples from <topic>.

Usage: print <topic> [options]

-a X, --amount X Amount of samples to display [default: 1]


.. code:: bash

Publishes a (value | string) on <topic>.

Usage: pub <topic> <value> (--u8 | --u16 | --u32 | --i8 | --i16 | --i32 | --f32 | --s)


.. code:: bash

Plots <topic> in a graph window.

Usage: plot <topic>


.. code:: bash

Disconnects from any open connection.

Usage: disconnect


.. code:: bash

Exits the terminal application.

Usage: quit

.. |PyPI version| image::
.. |Join the chat at| image::
.. |Stories in Ready| image::
.. |PyPI version| image::

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pytelemetrycli, version 1.0.4
Filename, size File type Python version Upload date Hashes
Filename, size pytelemetrycli-1.0.4-py3-none-any.whl (17.0 kB) File type Wheel Python version py3 Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page