OLA Python: no module named...

488 views
Skip to first unread message

Tuckie

unread,
Sep 19, 2010, 5:04:13 PM9/19/10
to open-lighting
When I try to run ./client_wrapper.py, I get the error:

Traceback (most recent call last):
File "./client_wrapper.py", line 25, in <module>
from ola.OlaClient import OlaClient, Universe
ImportError: No module named ola.OlaClient


I'm kind of new dealing with libraries in python, and I cannot seem to
get python to see ola.

I've configured & compiled ola with the "--enable-python-libs" flag,

/usr/local/lib/python2.6/site-packages/ola contains:

ArtnetConfigMessages_pb2.py
ArtnetConfigMessages_pb2.pyc
ArtnetConfigMessages_pb2.pyo
__init__.py
__init__.pyc
__init__.pyo
OlaClient.py
OlaClient.pyc
OlaClient.pyo
Ola_pb2.py
Ola_pb2.pyc
Ola_pb2.pyo
rpc
UsbProConfigMessages_pb2.py
UsbProConfigMessages_pb2.pyc
UsbProConfigMessages_pb2.pyo


What am I missing and does anyone have any suggestions?

Simon Newton

unread,
Sep 19, 2010, 5:07:45 PM9/19/10
to open-l...@googlegroups.com
Does your sys.path include /usr/local/lib/python2.6/site-packages?

> --
> open-l...@googlegroups.com  /  http://groups.google.com/group/open-lighting
> To unsubscribe email open-lightin...@googlegroups.com
>

Tuckie

unread,
Sep 20, 2010, 2:15:50 PM9/20/10
to open-lighting
Thanks for pointing me in the right direction, that was indeed it. Now
to start all over with the process on 0.8.2 :)

Is there any documentation for the python libs? I can't seem to find
something that is the equivalent of SetChannel for sending data to the
ola server. I'm looking for an application that would have multiple
threads running that would only be writing to a portion of the dmx
universe, so sending the entire dmx buffer makes little sense.

As an alternative route, do you (or anyone) happen to know of a good
python E1.31 or ArtNet library?

Thanks again for all your help.

On Sep 19, 5:07 pm, Simon Newton <nomi...@gmail.com> wrote:
> Does your sys.path include /usr/local/lib/python2.6/site-packages?
>

Simon Newton

unread,
Sep 20, 2010, 5:38:49 PM9/20/10
to open-l...@googlegroups.com
On Mon, Sep 20, 2010 at 11:15 AM, Tuckie <wit...@gmail.com> wrote:
> Thanks for pointing me in the right direction, that was indeed it. Now
> to start all over with the process on 0.8.2 :)
>
> Is there any documentation for the python libs? I can't seem to find
> something that is the equivalent of SetChannel for sending data to the
> ola server.  I'm looking for an application that would have multiple
> threads running that would only be writing to a portion of the dmx
> universe, so sending the entire dmx buffer makes little sense.

Take a look at the python/examples/ola_send_dmx.py . You can't send
individual set channel commands to the server since it only deals with
DMX blocks. Instead you should update the data array and then call
client.SendDmx() when it's ready to go.

The python library may be a bit broken in 0.8.2 because I changed some
client code around but if you find issues let me know and I'll fix
them.

Simon

Reply all
Reply to author
Forward
0 new messages