Python interface to Carrera(R) DIGITAL 124/132 slotcar systems
Project description
This module provides a Python interface to Carrera® DIGITAL 124/132 slotcar systems connected via a serial (cable) connection, or via Bluetooth LE using Carrera AppConnect®.
>>> 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-2023 Thomas Kemmer.
Licensed under the MIT License.
Carrera® and Carrera AppConnect® are registered trademarks of Carrera Toys GmbH.
carreralib is not an official Carrera® product, and is not affiliated with or endorsed by 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
File details
Details for the file carreralib-1.0.2.tar.gz
.
File metadata
- Download URL: carreralib-1.0.2.tar.gz
- Upload date:
- Size: 45.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 74021143d5aa9f40279b26234d8f1157ef5a071793a8f446c73b3a035cb43139 |
|
MD5 | 81769111e8c679764c54c6c23f676f87 |
|
BLAKE2b-256 | c4df4121701d942227d460911512668f165310e6b3e910425711a3ca6e7e7244 |
File details
Details for the file carreralib-1.0.2-py3-none-any.whl
.
File metadata
- Download URL: carreralib-1.0.2-py3-none-any.whl
- Upload date:
- Size: 14.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4978e39b2536bf286060c1815e338712c20086a784c993772459f2eba2b1b4c9 |
|
MD5 | 0b93dc8da1e6ad6dad6331563bb8e6c2 |
|
BLAKE2b-256 | 177819d46d47053578f265871c6250cde9bfcd4b51b1484bb34fdee6dc66a53b |