Python interface to Carrera(R) DIGITAL 124/132 slotcar systems
Project description
This module provides a Python interface to Carrera(R) DIGITAL 124/132 slotcar systems connected via a serial (cable) connection.
>>> from carreralib import ControlUnit
>>> cu = ControlUnit('/dev/ttyUSB0')
>>> cu.version()
'5337'
>>> cu.poll()
Status(fuel=(14, 14, 14, 14, 14, 14, 0, 0), start=0, mode=6,
pit=(False, False, False, False, False, False, False, False),
display=8)
>>> cu.start()
>>> cu.poll()
Status(fuel=(14, 14, 14, 14, 14, 14, 0, 0), start=1, mode=6,
pit=(False, False, False, False, False, False, False, False),
display=8)
>>> cu.start()
>>> cu.poll()
Timer(address=1, timestamp=105295, sector=1)
>>> cu.poll()
Timer(address=0, timestamp=105410, sector=1)
For demonstration purposes, the carreralib module can also be used from the command line as a simple race management system (RMS).
Please refer to the online documentation for more information.
Installation
carreralib is available from PyPI and can be installed by running:
pip install carreralib
Project Resources
License
Copyright (c) 2015-2022 Thomas Kemmer.
Licensed under the MIT License.
Carrera is a registered trademark of Carrera Toys GmbH.
Thanks to Stephan Heß (a.k.a. slotbaer) for doing all the hard work.
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
Built Distribution
Hashes for carreralib-0.10.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 616d29311b09123cb54680f40cdf9d545122499010c87f189bd158d8c8ac9cdd |
|
MD5 | 4eec0a06fc7b85f327bb5b6ba1a501cd |
|
BLAKE2b-256 | 315302ce38eedab45abcf8019338a206fd9fac6b0b1f81f68fcef4e1f13ff3aa |