error on INSN_INTTRIG

I get the following error:

comedi_perror(): __comedi_errno=11
libc error: Resource temporarily unavailable

(output from program in console offcourse)

The code is this:

  comedi_insn insn;
  lsampl_t data[1];
  memset(&insn,0,sizeof(comedi_insn));
  insn.insn = INSN_INTTRIG;
  insn.subdev = subdevice;
  insn.data = data;
  insn.n = 1;

  data[0] = number; //docs specify this must be 0 but the demo uses a
    //trignumber 
  //data[0] = 0;

  printf("Performing INSN_INTTRIG\n");
  //should return 0 on success (no samples measured)
  return (comedi_do_insn(cDevice,&insn) == 0)? 0 : -1;


(inside a function offcourse)
And is pretty much exactly as is in the ao_waveform example.
The ao_waveform works.

My code doesn't :(

A few questions.
Do I need to run comedi_command before INSN_INTTRIG ??
if so do I need to have a specific setup for comedi_command ??

On opening /dev/comedi0 I get: comedi_perror(): __comedi_errno=22
I still have no idea why this is!
But it doesn't give it unless I give comedi_loglevel(4) before hand.
And if I put loglevel(4) in ao_waveform it comes out there also.


Well when I tried to setup command..
I once got a kernel error message across all my consoles (didn't save
that )
And then I got a complete system freeze :(

using driver ni_pcimio and card PCI-6014C

raait

Received on 2007-10-03Z09:38:18