Skip to contentSkip to conversation

Analogy simultaneous read write commands

Xenomai-help Jules Warsh 2 participants 2 messages May 25, 2011 – Jun 2, 2011

lore
Share & tools
lore
#0 lore raw

Hello,

Is it possible to:
- Set a command (a4l_snd_command) to read data from an Analogy subdevice,
- Set a command (a4l_snd_command) to write data to a different Analogy subdevice,
- Trigger both commands, and

- Collect/write data from/to buffers ?

Or whatever other actions to implement the same functionality above?

Thank you.

#1 lore raw

Hi,

Once more, sorry for the late reply.

Quoted 6 lines · Jules Warsh

Hello,

Is it possible to:
- Set a command (a4l_snd_command) to read data from an Analogy subdevice,
- Set a command (a4l_snd_command) to write data to a different Analogy subdevice,
- Trigger both commands, and

Yes. It is possible

With one file descriptor (an a4l_desc_t to be more precise):
- you can launch many synchronous acquisitions (instruction) on many subdevices.
- you can launch only one asynchronous acquisition (command) on any subdevice (the asynchronous buffer is instanciated with the creation of the file descriptor)

So, all you have to do is open as many file descriptor on the same analogy device (let's say analogy0) as the number of simultaneous acquisitions you want to trigger.

Quoted 2 lines

- Collect/write data from/to buffers ?

Yes. If you have opened two file descriptors, you will read on one fd (with a4l_async_read()) and write on the other one (with a4l_async_write()).

Quoted 10 lines

Or whatever other actions to implement the same functionality above?

Thank you.

_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Signature · 1 line
Alexis.