Skip to main content

A set of Python bindings to control cash registers

Project description

https://travis-ci.org/palazzem/python-cash-register.svg?branch=master https://codecov.io/gh/palazzem/python-cash-register/branch/master/graph/badge.svg

Python bindings for generic cash registers, using the XON/XOFF protocol for serial communication.

Support

If you need support, please use the GitHub issue tracker.

Contributing

We love contributions, so please feel free to fix bugs, improve things, provide documentation. Just follow the guidelines and submit a PR.

Requirements

  • Python 2.7, 3.3, 3.4 and 3.5

Overview

Coming soon.

Getting started

This example could be outdated and you should not use it until a stable version of the library is out:

from serial import Serial
from cash_register.models.xditron import SaremaX1


# defines the serial communication
conn = Serial()
conn.port = '/dev/ttyUSB0'
conn.baudrate = 9600
conn.xonxoff = True
conn.timeout = 1

# create a cash register with a serial connection handler
register = SaremaX1('Shop center', connection=conn)

# write a list of products
products = [
    {
        'description': 'Potatoes',
        'amount': '2.0',
        'quantity': '3.0',
    },
    {
        'description': 'Water',
        'amount': '0.50',
    },
]

# prepare and send cash register commands
register.sell_products(products)
register.send()

Documentation

Coming soon.

License

python-cash-register is released under the terms of the BSD license. Full details in LICENSE file.

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

python-cash-register-0.1.0.tar.gz (7.9 kB view details)

Uploaded Source

File details

Details for the file python-cash-register-0.1.0.tar.gz.

File metadata

File hashes

Hashes for python-cash-register-0.1.0.tar.gz
Algorithm Hash digest
SHA256 712c0c65e2bdb6237f4ab910845351737f01c4658bd7d5d82ef7e9b6f2ca5980
MD5 16783e218eb9db1ee6a334b7f50a4d8e
BLAKE2b-256 dc38d4f5b3957c862ea1e889d379b6e8b20a67b8817f8c85aa86a1db4a935075

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