Skip to main content

A Python wrapper for the Thinkify Reader Protocol.

Project description

The Thinkify Python Library
========

This library is a Python wrapper for `Thinkify's <http://www.thinkifyit.com>`_ Thinkify Reader Protocol. It allows developers to issue commands to their RFID readers as well as retreive data from them.

Installation
---------------

To install the Thinkify python library using `pip <https://pypi.python.org/pypi/pip>`_:

.. code-block:: bash

$ sudo pip install thinkify


or alternatively via easy_install:

.. code-block:: bash

$ sudo easy_install thinkify


or from source:

.. code-block:: bash

$ sudo python setup.py install


Usage
---------------

.. code-block:: pycon

>>> from thinkify.reader import ThinkifyReader
>>> reader = ThinkifyReader('/dev/tty.usbmodem1411')

>>> # Get the firmware version on your reader
>>> reader.get_version()
VERSION=2.2.3

>>> # Get a list of nearby tags
>>> tag_list = reader.get_tags()
STARTINVENTORY
TAG=3000E2001021490
TAG=3000E2001021491
STOPINVENTORY=0x0002 0x0031

# Iterate over the tag_list and inspect properties of each `Tag` object
>>> [tag.epc_id for tag in tag_list]
3000E2001021490
3000E2001021491

Notes
---------------

This library covers about ~20% of the total functionality provided by the `Thinkify Reader Protocol <http://bit.ly/1dKFJ5x>`_ (TRP) - it basically covers what I currently need. If one feels inclined to add extended functionality, please fork!

Another small side note: Instead of using TRP's "T(x)" command which loops indefinitely looking for tag presence, my current workflow is to handle the looping logic in Python. This is because:

* It's cumbersome to constantly read data from the I/O buffer using pyserial.
* It's difficult to manage the timing of the scan loop on the device itself.

Anyway, it works for my use case -- if someone can think of a cleaner way to handle this, please fork.

Author
---------------

This library is maintained by Sean Coonce and can be found here: https://github.com/cooncesean/thinkify/

Project details


Download files

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

Source Distribution

thinkify-0.1.4.tar.gz (3.7 kB view details)

Uploaded Source

File details

Details for the file thinkify-0.1.4.tar.gz.

File metadata

  • Download URL: thinkify-0.1.4.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for thinkify-0.1.4.tar.gz
Algorithm Hash digest
SHA256 c9b8d835c2f8268deeb6d3bfbcb291f9e02cc28153cd7ea3bda9fa828fe30d9f
MD5 8fc1c64f76b7894eda7b199d9514e124
BLAKE2b-256 9f51662c4786dbcbad452513b3d3065273a17ed6fe5b21bf8f95988a8f2c1b2b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page