comedi_do_insn: errno=110 Connection timed out

57 views
Skip to first unread message

Koloman Kara

unread,
Nov 28, 2019, 8:28:08 AM11/28/19
to Comedi: Linux Control and Measurement Device Interface
Hello good people

I'm trying to run mf624 daq card with Comedi under Ubuntu 18.04.3 LTS
Installation seems to by OK. I can write to analog output (subdevice 1).
But I'm not able to read from analog input (subdevice 0) 
If I try to run 
$ comedi_test -s 0 -v
I get timeout errror.

Here is full output from comedi_test:

I: Comedi version: 0.7.76
I: Comedilib version: unknown =)
I: driver name: mf6x4
I: device name: mf624
I:
I: subdevice 0
I: testing info...
rev 1
I: subdevice type: 1 (analog input)
  number of channels: 8
  max data value: 16383
  ranges:
    all chans: [-10,10]
I: testing insn_read...
rev 1
E: comedi_do_insn: Connection timed out
I: testing insn_read_0...
comedi_do_insn returned 0, good
I: testing insn_read_time...
rev 1
comedi_do_insn: -1
W: comedi_do_insn: errno=110 Connection timed out
W: comedi_do_insn: returned -1 (expected 3)
read time: -1574947557723228 us
I: testing cmd_no_cmd...
got EIO, good
I: testing cmd_probe_src_mask...
not applicable
I: testing cmd_probe_fast_1chan...
not applicable
I: testing cmd_read_fast_1chan...
not applicable
I: testing cmd_write_fast_1chan...
not applicable
I: testing cmd_logic_bug...
not applicable
I: testing cmd_fifo_depth_check...
not applicable
I: testing cmd_start_inttrig...
not applicable
I: testing mmap...
not applicable
I: testing read_select...
not applicable
I: testing bufconfig...
buffer length is 0, good

Can anybody help me please?

Koloman Kara

unread,
Nov 28, 2019, 8:31:13 AM11/28/19
to Comedi: Linux Control and Measurement Device Interface
Here si full output of 

$ comedi_board_info -v

comedi_board_info -v
overall info:
  version code: 0x00074c
  driver name: mf6x4
  board name: mf624
  number of subdevices: 4
subdevice 0:
  type: 1 (analog input)
  flags: 0x00110000
          SDF_READABLE:subdevice can be read
          SDF_GROUND:can do aref=ground
  number of channels: 8
  max data value: 16383
  ranges:
    all chans: [-10 V,10 V]
  command:
    not supported
subdevice 1:
  type: 2 (analog output)
  flags: 0x00020000
          SDF_WRITABLE:subdevice can be written
  number of channels: 8
  max data value: 16383
  ranges:
    all chans: [-10 V,10 V]
  command:
    not supported
subdevice 2:
  type: 3 (digital input)
  flags: 0x00010000
          SDF_READABLE:subdevice can be read
  number of channels: 8
  max data value: 1
  ranges:
    all chans: [0 V,5 V]
  command:
    not supported
subdevice 3:
  type: 4 (digital output)
  flags: 0x00020000
          SDF_WRITABLE:subdevice can be written
  number of channels: 8
  max data value: 1
  ranges:
    all chans: [0 V,5 V]
  command:
    not supported

Robert

unread,
Dec 7, 2020, 6:02:26 AM12/7/20
to Comedi: Linux Control and Measurement Device Interface
Dear all,

I have the same issue running Ubuntu 18.04 LTS with the MF634 daq card. The card seems to be recognized without problems. However, I cannot read analogue inputs using the demos script "inp.c" of comedilib. It gives the same error as reported above (by kolom...@gmail.com): "Connection timed out".

Did you @ kolom...@gmail.com already figure out what the problem is?

Thank you in advance and best wishes,
Robert

Ian Abbott

unread,
Dec 7, 2020, 8:08:15 AM12/7/20
to comed...@googlegroups.com, Rostislav Lisovy
On 07/12/2020 11:02, 'Robert' via Comedi: Linux Control and Measurement
Device Interface wrote:
> Dear all,
>
> I have the same issue running Ubuntu 18.04 LTS with the MF634 daq card.
> The card seems to be recognized without problems. However, I cannot read
> analogue inputs using the demos script "inp.c" of comedilib. It gives
> the same error as reported above (by kolom...@gmail.com): "Connection
> timed out".
>
> Did you @ kolom...@gmail.com already figure out what the problem is?
>
> Thank you in advance and best wishes,
> Robert

I think I see what the problem is, but will try and confirm with the
original author of the driver, Rostislav Lisovy.

I think the problem is that check for end of conversion is inverted.
After initiating a software trigger for the A/D conversion, the code
currently waits for the EOLC bit to go high to signal the end of the
conversion, but according to the user manuals for MF624 and MF634, this
is an active low signal that is high while the conversion is in progress
and goes low at the end of the conversion.

--
-=( Ian Abbott <abb...@mev.co.uk> || MEV Ltd. is a company )=-
-=( registered in England & Wales. Regd. number: 02862268. )=-
-=( Regd. addr.: S11 & 12 Building 67, Europa Business Park, )=-
-=( Bird Hall Lane, STOCKPORT, SK3 0XA, UK. || www.mev.co.uk )=-

Ian Abbott

unread,
Mar 1, 2021, 1:53:05 PM3/1/21
to comed...@googlegroups.com
On 07/12/2020 13:08, Ian Abbott wrote:
> On 07/12/2020 11:02, 'Robert' via Comedi: Linux Control and Measurement
> Device Interface wrote:
>> Dear all,
>>
>> I have the same issue running Ubuntu 18.04 LTS with the MF634 daq
>> card. The card seems to be recognized without problems. However, I
>> cannot read analogue inputs using the demos script "inp.c" of
>> comedilib. It gives the same error as reported above (by
>> kolom...@gmail.com): "Connection timed out".
>>
>> Did you @ kolom...@gmail.com already figure out what the problem is?
>>
>> Thank you in advance and best wishes,
>> Robert
>
> I think I see what the problem is, but will try and confirm with the
> original author of the driver, Rostislav Lisovy.
>
> I think the problem is that check for end of conversion is inverted.
> After initiating a software trigger for the A/D conversion, the code
> currently waits for the EOLC bit to go high to signal the end of the
> conversion, but according to the user manuals for MF624 and MF634, this
> is an active low signal that is high while the conversion is in progress
> and goes low at the end of the conversion.

I sent a patch in December to change this (basically, by inverting the
previous test for end-of-conversion). I tagged the patch to be
backported to the "stable" kernel series. The change has now been
included in recent kernel updates for Ubuntu 18.04 LTS. The Ubuntu
kernel versions 4.15.0-136 and 5.4.0-66 include this change. With a bit
of luck, it might work now (after booting with the updated kernel), but
I am unable to test it.
Reply all
Reply to author
Forward
0 new messages