By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,364 Members | 1,742 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,364 IT Pros & Developers. It's quick & easy.

Has anyone gotten pyparallel to work?

P: n/a
When using this:

import parallel
p = parallel.Parallel() #open LPT1
p.setData(0x55)

I get this:

Traceback (most recent call last):
File "port2.py", line 2, in ?
p = parallel.Parallel() #open LPT1
File "/usr/lib/python2.3/site-packages/parallel/parallelppdev.py", line
175, in __init__
self._fd = os.open(self.device, os.O_RDWR)

OSError: [Errno 19] No such device: '/dev/parport0'

Exception exceptions.AttributeError: "Parallel instance has no attribute
'_fd'" in <bound method Parallel.__del__ of
<parallel.parallelppdev.Parallel instance at 0x403d96ac>> ignored

Yet a program I wrote in C has no problem accessing or reading bits from
LPT1. /dev/parport0 exists and is chmoded to 666. Is there some secret to
getting pyparallel to work that I'm missing (besides brains)?
Jul 18 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Nevermind. It was easier to swig parapin and use that instead.

Brian <Th*************@ddress.com> wrote in
news:Xn*************************@24.93.43.121:
When using this:

import parallel
p = parallel.Parallel() #open LPT1
p.setData(0x55)

I get this:

Traceback (most recent call last):
File "port2.py", line 2, in ?
p = parallel.Parallel() #open LPT1
File "/usr/lib/python2.3/site-packages/parallel/parallelppdev.py",
line
175, in __init__
self._fd = os.open(self.device, os.O_RDWR)

OSError: [Errno 19] No such device: '/dev/parport0'

Exception exceptions.AttributeError: "Parallel instance has no
attribute '_fd'" in <bound method Parallel.__del__ of
<parallel.parallelppdev.Parallel instance at 0x403d96ac>> ignored

Yet a program I wrote in C has no problem accessing or reading bits
from LPT1. /dev/parport0 exists and is chmoded to 666. Is there some
secret to getting pyparallel to work that I'm missing (besides
brains)?


Jul 18 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.