Skip to main content

Denkovi Relay Board Controller

Project description

Denkovi Relay Board Controller v1.5.2

Copyright (c) Peter Bingham (petersbingham@hotmail.co.uk)

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Known Limitations and Assumptions


  1. Written and Tested in Python 2.7 and 3.5.
  2. 4 and 8 relay boards do not handle connection to multiple devices. Connects to first found Denkovi.
  3. Not thread safe.
  4. Possible race conditions with device plugging.
  5. Uses a VCP delay of 50ms. Documentation specifies 5ms but was still seeing corruption at 20ms. Could be improved for the gets by doing an initial sync and then keeping track of the states in the class.

Help


  • Install using "python setup.py install" in this directory at thecommand line.
  • Both installions require serial module. The Linux version requires pylibftdi. For Windows FTD2XX.dll will need to be in your path; you can get this by allowing windows to download and install the drivers for the board.
  • Usage is pretty simple. Have a look at the examples and test code in the "Example & Test" folder. Look at the dae_RelayBoard file to see the interface functions.
  • To run "Example & Test\example16.py", for example, set the com port in the file and then open a cmd and cd into "Example & Test" folder and type "python example16.py".
  • For the case of multiple FTDI devices (4 & 8 relay boards) add a #num to the end of the, otherwise optional, deviceID (eg type4#3). num is zero indexed. See following example:
import dae_RelayBoard
dr = dae_RelayBoard.DAE_RelayBoard("type4")
dr.initialise("DAE#1") # initialise second board

Change Log


  • 1.5.2 - Fix FT_handle type to match FTD2XX DLL library.
  • 1.5.1 - Correctly shuts down FTDI on Linux.
  • 1.5.0 - Adds ability to select from multiple FTDI devices.
  • 1.4.0 - Adds Python 3 support.
  • 1.3.2 - Uses case insensitive for the serial number comparison.
  • 1.3.1 - Fixes premature return when trying to discover first device.
  • 1.3 - setup.py package installer added.
  • 1.2 - Linux support added.
  • 1.1 - Fixed serial not being flagged as close on disconnect and failure to ensure disconnection on a reconnect.

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

dae_relayboard-1.5.2.tar.gz (9.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dae_RelayBoard-1.5.2-py3-none-any.whl (14.0 kB view details)

Uploaded Python 3

File details

Details for the file dae_relayboard-1.5.2.tar.gz.

File metadata

  • Download URL: dae_relayboard-1.5.2.tar.gz
  • Upload date:
  • Size: 9.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.19

File hashes

Hashes for dae_relayboard-1.5.2.tar.gz
Algorithm Hash digest
SHA256 d0722c26253e78c64b367881ba6329042cccf2faaa5ce22ad092d23008c7e635
MD5 0927701f87916bdc126c5f1e3354c037
BLAKE2b-256 4249d0451e3fb5f8509705b63f82363c7c44fd7c179a3099ca67b4178f66e846

See more details on using hashes here.

File details

Details for the file dae_RelayBoard-1.5.2-py3-none-any.whl.

File metadata

  • Download URL: dae_RelayBoard-1.5.2-py3-none-any.whl
  • Upload date:
  • Size: 14.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.19

File hashes

Hashes for dae_RelayBoard-1.5.2-py3-none-any.whl
Algorithm Hash digest
SHA256 c80a640d138a4c1792a7bd8a1cc6978c90f792caf8fdd182219daa0c9f56e0a3
MD5 47d6bb282846a9cac5d5666c4ca5427f
BLAKE2b-256 2bd62f48df66385a042053a2d620dbe9f73d4a6e75d8e8f56a2291b8a66878e9

See more details on using hashes here.

Supported by

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