c0z3n / pysimpledmx Goto Github PK
View Code? Open in Web Editor NEWpysimpledmx is a simple dmx control module in python, for the Enttec DMX USB Pro
pysimpledmx is a simple dmx control module in python, for the Enttec DMX USB Pro
You specify that addresses are to be given on the range [1,512], yet you use them to directly index into an array of length 512. Unsurprisingly, trying to set channel 512 raises a IndexError.
I would PR but the change it so trivial it would take me more time to fork this repo than for you to just fix it.
Hey i cant seem to get an address above 250 to work , and also in some of my devices i have to set the dmx address 1 above what i need any thoughts ?
Hi,
I have an USB->DMX Cable that works with Erwin Roll's DMX driver (/dev/dmx0).
I'm trying to avoid using the DMX driver to use the vanilla serial port, from /dev/ttyUSB0.
So I'm trying to use your python code and open either
/dev/ttyUSB0 or /dev/serial/by-id/usb-FTDI_USB and none work.
My DMX Light seems to never receive data.
On which platform did you develop it ? Could that work on Linux without the /dev/dmx driver ?
THanks.
Would you consider creating a package for this code by adding a setup.py
and uploading it to PyPi
?
It would be easier to be able to pip install pysimpledmx
instead of having to download the file.
I would be happy to send a pull request with the needed files, if that is the hold up.
pysimpledmx.py, line 47 should be:
print 'Invalid channel specified: %s' % (chan-1)
Note the parens around chan-1
. Without them, the interpreter tries to subtract 1 from the string "Invalid..."
I've tried submitting the changes but am getting a 403 error on push (also: I'm not super familiar with pushing to GitHub repos that I don't own, which may have something to do with that).
when i start the installation it come up with error
Traceback (most recent call last):
File "setup.py", line 2, in
from setuptools import setup, find_packages
ImportError: No module named setuptools
Hi, I've been using your script for a while, but recently started using this other snippet. I've received much better performance, so I thought I'd share. I'm not a complete python expert, but somehow this one has less bottleneck issues.
http://agreeabledisagreements.blogspot.com/2012/10/a-beginners-guide-to-dmx512-in-python.html
Both of these methods work well on the raspberry pi.
It appears this part of the code throws an error while trying to set channel 1:
if not 1 <= chan-1 <= DMX_SIZE:
Channel 2 is mapping to channel 1 though when send to the fixture... confusing
Is there a way to Receive DMX?
Hi,
I have some problem to connect a Contest light connected with Enttec OpenDMX USB.
So it works fine with QLC plus but I can't change colors with pySimpleDMX. It recognizes OpenDMX in /dev/ttyUSB0. Did I miss a value to change ?
In [1]: import pysimpledmx
In [2]: mydmx = pysimpledmx.DMXConnection("/dev/ttyUSB0")
Opened /dev/ttyUSB1.
In [3]: mydmx.setChannel(2, "100", autorender=True)
In [4]: mydmx.setChannel(1, "100", autorender=True)
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-5-a1d167a61129> in <module>()
----> 1 mydmx.setChannel(1, "100", autorender=True)
/usr/local/lib/python2.7/dist-packages/pysimpledmx/pysimpledmx.pyc in setChannel(self, chan, val, autorender)
45 '''
46 if not 1 <= chan-1 <= DMX_SIZE:
---> 47 print 'Invalid channel specified: %s' % chan-1
48 return
49 # clamp value
TypeError: unsupported operand type(s) for -: 'str' and 'int'
Thank you for your help.
After running pip install pysimpledmx i'm getting the error:
ImportError: No module named pysimpledmx
In my site-packages folder there is one folder called: pysimpledmx-0.1.0-py2.7.egg-info
But inside it contains no .py files
Probably a beginner python mistake.
Thanks for help :)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.