[argyllcms] Re: tcgetattr failed with 'Input/output error'

  • From: Ludovico Fischer <ranucel@xxxxxxxxxx>
  • To: argyllcms@xxxxxxxxxxxxx
  • Date: Fri, 07 Dec 2007 17:16:24 +0100

It is a eye-one pro, dispread -r gives (when it detecys the instrument,
see below)
1 = 'usb:/bus0/dev2 (GretagMacbeth i1 Pro)'
    2 = '/dev/ttyS0'
    3 = '/dev/ttyS1'
    4 = '/dev/ttyS2'
    5 = '/dev/ttyS3'
I also used the 'simplified' udev rules you propose in the
documentation, as they are identical in format to the other udev rules
on Ubuntu.
Ok, I had misdiagnosed the problem. Whether the tcgeattr error appears
is not dependent on whether I use a space or not. It seemed so only
because I was giving the two syntaxes always on the same order. Here's
what happens: after a successful execution of "dispread -k target.cal
Screen", no matter if the measuring is completed or aborted, somehow the
Eye-one pro  becomes invisible for dispread. dispread (either with -r or
"-k target.cal Screen") must then be run a third time to recognise the
eye one pro again. Note however, that the first time I ran dispread -
after logging in with the Eye one pro attached, it was not detected.
Second time, the procedure starts, I abort with Q. Third time, again
tcgeattr error, and so on. Then I tried to actually complete the whole
measuring process, to make sure it was not linked to the abort keys.
After the measuring process completed, I gave 'dispread -k target.cal
Screen', and I got the error. Also, if after running "dispread -k
target.cal Screen" succesfully, I run dispread -r, the Eye one pro is
vanished, giving this output, instead of the one on top:
Set communication port from the following list (default 1)
    1 = '/dev/ttyS0'
    2 = '/dev/ttyS1'
    3 = '/dev/ttyS2'
    4 = '/dev/ttyS3'
Running dispread -r a second time makes it appear, and the instrument is
always recognised by dispread -r, until one runs the  "dispread -k
target.cal Screen", at which point on is invited to calibrate the
instrument..., then after completion or aborting, the instrument is not
recognised once again etc.

Ludovico Fischer
On Fri, 2007-12-07 at 15:10 +1100, Graeme Gill wrote:
> Ludovico Fischer wrote:
> > 1.If I do dispcal -r with a connected instrument it asks to measure
> > patches; problem solved. dispread - prints usage information.
> Right, but the usage information lists the instruments that it
> thinks are available, and I was interested in whether and what
> serial ports are on your system, and whether your instrument
> is USB connected or not.
> > 2.I have been unclear, sorry. I do supply a basename for the .ti1 file
> > (it's called "Schermo.ti1"). Here, I just managed to reproduce this
> > behaviour again:
> > 
> > ludovico@gogo:~/Desktop/Targets/display$ dispread -k schermetto.cal Schermo
> > dispread: Error - tcgetattr failed with 'Input/output error'
> > ludovico@gogo:~/Desktop/Targets/display$ dispread -kschermetto.cal Schermo
> > Place the instrument on its reflective white reference Serial no.
> > 310345,
> >  and then hit any key to continue,
> >  or hit Esc, ^C or Q to abort:
> Well, I'm guessing you're using an Eye-One Pro, since otherwise you'd
> need to supply a -y flag.
> Unfortunately I can't reproduce your problem. The command line
> parser doesn't care whether there is a space or not between a flag
> and it's argument, so the connection with the tty error is unclear.
> It would help to know whether you have serial ports or not
> (hence my request that you show what dispread -? returns).
> I instrumented all the calls to tcgetattr, and could see no
> difference in the calls with or without a space.
> Note that if for some reason the communications to a USB instrument
> breaks down (ie. killing the program with the device open does this
> for some instruments), then it may not be seen until the instrument
> is physically disconnected and reconnected. This will cause the
> program to look for instruments on serial ports, which (depending
> on your system), could explain tcgetattr failures.
> Graeme Gill.

Other related posts: