fixes for boards where the device name is not the module name
[comedilib.git] / doc / reference.sgml
1 <!DOCTYPE section PUBLIC "-//OASIS//DTD DocBook V3.1//EN">
2
3 <section>
4 <title>
5 Constants and Macros
6 </title>
7
8 <section id="ref-macro-CR-PACK">
9 <title>
10 CR_PACK
11 </title>
12
13 <para>
14 CR_PACK is used to initialize the elements of the chanlist array in the
15 comedi_cmd structure, and the chanspec member
16 of the comedi_insn structure.
17 </para>
18
19 <para>
20 The channel argument is the channel you wish to use, with the channel
21 numbering starting at zero.
22 </para>
23
24 <para>
25 The range is an index, starting at zero, whose meaning
26 is device dependent.  The
27 comedi_get_n_ranges() and
28 comedi_get_range functions
29 are useful in discovering information about the available ranges.
30 </para>
31
32 <para>
33 The aref argument indicates what reference you want the device to use.  It
34 can be any of the following:
35 </para>
36
37 <variablelist>
38   <varlistentry>
39     <term>AREF_GROUND</term>
40     <listitem>
41       <para>
42         is for inputs/outputs referenced to ground
43       </para>
44     </listitem>
45   </varlistentry>
46   <varlistentry>
47     <term>AREF_COMMON</term>
48     <listitem>
49       <para>
50     is for a `common' reference (the low inputs of all the channels are tied
51 together, but are isolated from ground)
52       </para>
53     </listitem>
54   </varlistentry>
55   <varlistentry>
56     <term>AREF_DIFF</term>
57     <listitem>
58       <para>
59     is for differential inputs/outputs
60       </para>
61     </listitem>
62   </varlistentry>
63   <varlistentry>
64     <term>AREF_OTHER</term>
65     <listitem>
66       <para>
67     is for any reference that does not fit into the above categories
68       </para>
69     </listitem>
70   </varlistentry>
71 </variablelist>
72
73 <para>
74 Particular drivers may or may not use the AREF flags.  If they are
75 not supported, they are silently ignored.
76 </para>
77 </section>
78
79 <section id="ref-macro-RANGE-LENGTH">
80 <title>
81 RANGE_LENGTH (deprecated)
82 </title>
83
84 <para>
85 Rangetype values are library-internal tokens that represent an
86 array of range information structures.  These numbers are primarily
87 used for communication between the kernel and library.
88 </para>
89
90 <para>
91 The RANGE_LENGTH() macro returns the length of the array that is
92 specified by the rangetype token.
93 </para>
94
95 <para>
96 The RANGE_LENGTH() macro is deprecated, and should not be used in
97 new applications.  It is scheduled to be removed from the header
98 file at version 1.0.  Binary compatibility may be broken for version
99 1.1.
100 </para>
101 </section>
102
103 </section>
104
105 <section>
106 <title>
107 Data Types and Structures
108 </title>
109
110 <section id="ref-type-comedi-t">
111 <title>
112 comedi_t
113 </title>
114
115 <programlisting>
116 typedef struct comedi_t_struct comedi_t;
117 </programlisting>
118
119 <para>
120 The data type comedi_t is used to represent an open Comedi
121 device.  A valid comedi_t pointer is returned by a successful
122 call to comedi_open(), and should be used for subsequent
123 access to the device.
124 It is a transparent type, and pointers to type comedi_t
125 should not be dereferenced by the application.
126 </para>
127
128 </section>
129
130
131 <section id="ref-type-sampl-t">
132 <title>
133 sampl_t
134 </title>
135
136 <programlisting>
137 typedef unsigned short sampl_t;
138 </programlisting>
139
140 <para>
141 The data type sampl_t is one of the generic types used to represent
142 data values in Comedilib.  It is used in a few places where a data type
143 shorter than lsampl_t is useful.  On most architectures, sampl_t
144 is defined to be uint16.
145 </para>
146
147 <para>
148 Most drivers represent data trasferred by read() and write()
149 using sampl_t.  Applications should check the subdevice flag
150 SDF_LSAMPL to determine if the subdevice uses sampl_t or
151 lsampl_t.
152 </para>
153
154 </section>
155
156 <section id="ref-type-lsampl-t">
157 <title>
158 lsampl_t
159 </title>
160
161 <programlisting>
162 typedef unsigned int lsampl_t;
163 </programlisting>
164
165 <para>
166 The data type lsampl_t is the data type typically used to represent
167 data values in libcomedi.  On most architectures, lsampl_t is
168 defined to be uint32.
169 </para>
170 </section>
171
172
173 <section id="ref-type-comedi-trig">
174 <title>
175 comedi_trig (deprecated)
176 </title>
177
178 <programlisting>
179 typedef struct comedi_trig_struct comedi_trig;
180
181 struct comedi_trig_struct{
182         unsigned int subdev;            /* subdevice */
183         unsigned int mode;              /* mode */
184         unsigned int flags;
185         unsigned int n_chan;            /* number of channels */
186         unsigned int *chanlist;         /* channel/range list */
187         sampl_t *data;                  /* data list, size depends on subd flags */
188         unsigned int n;                 /* number of scans */
189         unsigned int trigsrc;
190         unsigned int trigvar;
191         unsigned int trigvar1;
192         unsigned int data_len;
193         unsigned int unused[3];
194 };
195 </programlisting>
196
197 <para>
198 The comedi_trig structure is a control structure used by the
199 COMEDI_TRIG ioctl, an older method of communicating
200 instructions to the driver and hardware.  Use of comedi_trig is
201 deprecated, and should not be used in new applications.
202 </para>
203 </section>
204
205 <section id="ref-type-comedi-sv-t">
206 <title>
207 comedi_sv_t
208 </title>
209
210 <programlisting>
211 typedef struct comedi_sv_struct comedi_sv_t;
212
213 struct comedi_sv_struct{
214         comedi_t *dev;
215         unsigned int subdevice;
216         unsigned int chan;
217
218         /* range policy */
219         int range;
220         int aref;
221
222         /* number of measurements to average (for ai) */
223         int n;
224
225         lsampl_t maxdata;
226 };
227 </programlisting>
228
229 <para>
230 The comedi_sv_t structure is used by the comedi_sv_*()
231 functions to provide a simple method of accurately measuring
232 slowly varying inputs.  See the relevant section for more
233 details.
234 </para>
235 </section>
236
237 <section id="ref-type-comedi-cmd">
238 <title>
239 comedi_cmd
240 </title>
241
242 <programlisting>
243 typedef struct comedi_cmd_struct comedi_cmd;
244
245 struct comedi_cmd_struct{
246         unsigned int subdev;
247         unsigned int flags;
248
249         unsigned int start_src;
250         unsigned int start_arg;
251
252         unsigned int scan_begin_src;
253         unsigned int scan_begin_arg;
254
255         unsigned int convert_src;
256         unsigned int convert_arg;
257
258         unsigned int scan_end_src;
259         unsigned int scan_end_arg;
260
261         unsigned int stop_src;
262         unsigned int stop_arg;
263
264         unsigned int *chanlist;
265         unsigned int chanlist_len;
266
267         sampl_t *data;
268         unsigned int data_len;
269 };
270 </programlisting>
271
272 <para>
273 More information on using commands can be found in the
274 command section.
275 </para>
276 </section>
277
278 <section id="ref-type-comedi-insn">
279 <title>
280 comedi_insn
281 </title>
282
283 <programlisting>
284 typedef struct comedi_insn_struct comedi_insn;
285
286 struct comedi_insn_struct{
287         unsigned int insn;
288         unsigned int n;
289         lsampl_t *data;
290         unsigned int subdev;
291         unsigned int chanspec;
292         unsigned int unused[3];
293 };
294 </programlisting>
295
296 <para>
297 Comedi instructions are described by the comedi_insn structure.
298 Applications send instructions to the driver in order to preform
299 control and measurement operations that are done immediately or
300 synchronously, i.e., the operations complete before program control
301 returns to the application.  In particular, instructions cannot
302 describe acquisition that involves timers or external events.
303 </para>
304
305 <para>
306 The field insn determines the type of instruction that is sent
307 to the driver.  Valid instruction types are
308 </para>
309
310 <variablelist>
311   <varlistentry>
312     <term>
313 INSN_READ
314     </term>
315     <listitem>
316       <para>
317 read values from an input channel
318       </para>
319     </listitem>
320   </varlistentry>
321   <varlistentry>
322     <term>
323 INSN_WRITE
324     </term>
325     <listitem>
326       <para>
327 write values to an output channel
328       </para>
329     </listitem>
330   </varlistentry>
331   <varlistentry>
332     <term>
333 INSN_BITS
334     </term>
335     <listitem>
336       <para>
337 read/write values on multiple digital I/O channels
338       </para>
339     </listitem>
340   </varlistentry>
341   <varlistentry>
342     <term>
343 INSN_CONFIG
344     </term>
345     <listitem>
346       <para>
347 configure a subdevice
348       </para>
349     </listitem>
350   </varlistentry>
351   <varlistentry>
352     <term>
353 INSN_GTOD
354     </term>
355     <listitem>
356       <para>
357 read a timestamp, identical to gettimeofday()
358       </para>
359     </listitem>
360   </varlistentry>
361   <varlistentry>
362     <term>
363 INSN_WAIT
364     </term>
365     <listitem>
366       <para>
367 wait a specified number of nanoseconds
368       </para>
369     </listitem>
370   </varlistentry>
371 </variablelist>
372
373 <para>
374 The number of samples to read or write, or the size of the configuration
375 structure is specified by the field n, and the buffer for those
376 samples by data.  The field subdev is the subdevice index
377 that the instruction is sent to.  The field chanspec specifies
378 the channel, range, and analog reference (if applicable).
379 </para>
380
381 <para>
382 Instructions can be sent to drivers using comedi_do_insn().
383 Multiple instructions can be sent to drivers in the same system
384 call using comedi_do_insnlist().
385 </para>
386 </section>
387
388 <section id="ref-type-comedi-range">
389 <title>
390 comedi_range
391 </title>
392
393 <programlisting>
394 typedef struct comedi_range_struct comedi_range;
395
396 struct comedi_range_struct{
397         double min;
398         double max;
399         unsigned int unit;
400 }comedi_range;
401 </programlisting>
402
403 <para>
404 The comedi_range structure conveys part of the information
405 necessary to translate sample values to physical units, in particular,
406 the endpoints of the range and the physical unit type.  The
407 physical unit type is specified by the field unit, which may
408 take the values UNIT_volt for volts, UNIT_mA for milliamps,
409 or UNIT_none for unitless.  The endpoints are specified by
410 the fields min and max.
411 </para>
412 </section>
413
414 <section id="ref-type-comedi-krange">
415 <title>
416 comedi_krange
417 </title>
418
419 <programlisting>
420 typedef struct comedi_krange_struct comedi_krange;
421
422 struct comedi_krange_struct{
423         int min;
424         int max;
425         unsigned int flags;
426 };
427 </programlisting>
428
429 <para>
430 The comedi_krange structure is used to transfer range information
431 between the driver and Comedilib, and should not normally be used
432 by applications.  The structure conveys the same information as the
433 comedi_range structure, except the fields min and max
434 are integers, multiplied by a factor of 1000000 compared to the
435 counterparts in comedi_range.
436 </para>
437
438 <para>
439 In addition, kcomedilib uses the comedi_krange structure in place
440 of the comedi_range structure.
441 </para>
442
443 </section>
444
445 <section id="ref-type-comedi-insnlist">
446 <title>
447 comedi_insnlist
448 </title>
449
450 <programlisting>
451 typedef struct comedi_insnlist_struct comedi_insnlist;
452
453 struct comedi_insnlist_struct{
454         unsigned int n_insns;
455         comedi_insn *insns;
456 };
457 </programlisting>
458
459 <para>
460 An instruction list (insnlist) structure is used to communicate
461 a list of instructions.
462 </para>
463
464 </section>
465
466 </section>
467
468 <section>
469 <title>
470 Interface reference
471 </title>
472
473 <para>
474 This chapter is meant to be a reference for some of the advanced
475 features of Comedi.
476 </para>
477
478 <section>
479 <title>
480 Digital input combining machines
481 </title>
482
483 <para>
484 When one or several digital inputs are used to modify an output
485 value, either an accumulator or a single digital line or bit,
486 a bitfield structure is typically used in the Comedi interface.
487 The digital inputs have two properties, "sensitive" inputs and
488 "modifier" inputs.  Edge transitions on sensitive inputs cause
489 changes in the output signal, whereas modifier inputs change the
490 effect of edge transitions on sensitive inputs.  Note that inputs
491 can be both modifier inputs and sensitive inputs.
492 </para>
493
494 <para>
495 For simplification purposes, it is assumed that multiple digital
496 inputs do not change simultaneously.
497 </para>
498
499 <para>
500 The combined state of the modifier inputs determine a modifier
501 state.  For each combination of modifier state and sensitive
502 input, there is a set of bits that determine the effect on the
503 output value due to positive or negative transitions of the
504 sensitive input.  For each transition direction, there are two
505 bits defined as follows:
506 </para>
507
508 <variablelist>
509   <varlistentry>
510     <term>
511 00
512     </term>
513     <listitem>
514       <para>
515 transition is ignored
516       </para>
517     </listitem>
518   </varlistentry>
519   <varlistentry>
520     <term>
521 01
522     </term>
523     <listitem>
524       <para>
525 accumulator is incremented, or output is set
526       </para>
527     </listitem>
528   </varlistentry>
529   <varlistentry>
530     <term>
531 10
532     </term>
533     <listitem>
534       <para>
535 accumulator is decremented, or output is cleared
536       </para>
537     </listitem>
538   </varlistentry>
539   <varlistentry>
540     <term>
541 11
542     </term>
543     <listitem>
544       <para>
545 reserved
546       </para>
547     </listitem>
548   </varlistentry>
549 </variablelist>
550
551 <para>
552 For example, a simple digital follower is specified by the bit
553 pattern 01 10, because it sets the output on positive transitions
554 of the input, and clears the output on negative transitions.  A
555 digital inverter is similarily 10 01.  These systems have only
556 one sensitive input.
557 </para>
558
559 <para>
560 As another example, a simple up counter, which increments on
561 positive transitions of one input, is specified by 01 00.  This
562 system has only one sensitive input.
563 </para>
564
565 <para>
566 When multiple digital inputs are used, the inputs are divided
567 into two types, inputs which cause changes in the accumulator, and
568 those that only modify the meaning of transitions on other inputs.
569 Modifier inputs do not require bitfields, but there needs to be
570 a bitfield of length 4*(2^(N-1)) for each edge sensitive input,
571 where N is the total number of inputs.  Since N is usually 2 or
572 3, with only one edge sensitive input, the scaling issues are
573 not significant.
574 </para>
575 </section>
576
577
578 <section>
579 <title>
580 INSN_CONFIG
581 </title>
582
583 <para>
584 Configuration instructions are used to access device and driver features
585 that do not fit well into other parts of the Comedi interface.  This
586 includes changing the direction of configurable digital I/O lines,
587 configuring complex triggering engines, and counter/timer configuration.
588 </para>
589
590 <para>
591 If a specified ID is not supported, the driver must return -EINVAL.
592 </para>
593
594
595 <section>
596 <title>
597 Digital I/O configuration
598 </title>
599
600 <para></para>
601 <simplelist>
602   <member>
603     Status: Implemented
604   </member>
605   <member>
606     ID: COMEDI_INPUT, COMEDI_OUTPUT, COMEDI_OPENDRAIN
607   </member>
608   <member>
609     Length: 1
610   </member>
611   <member>
612     Chanspec: used to specify channel
613   </member>
614 </simplelist>
615
616 <para>
617 These IDs are used to configure direction of digital I/O lines.
618 Direction is chosen by the ID.  On typical devices, multiple
619 channels are grouped together in blocks for determining direction.
620 Configuring one channel in a block configures the entire block.
621 </para>
622
623 <para>
624 There should also be a method to read the configuration.
625 </para>
626
627 <para>
628 Errors:  Should return -EINVAL if the ID is not supported.
629 </para>
630
631 </section>
632
633 <section>
634 <title>
635 Analog conversion configuration
636 </title>
637
638 <simplelist>
639   <member>
640 Status: design
641   </member>
642   <member>
643 ID: not assigned
644   </member>
645   <member>
646 Length: 
647   </member>
648   <member>
649 Chanspec: used to specify channel
650   </member>
651 </simplelist>
652
653 <para>
654 Some devices have the capability to add white noise (dithering) to
655 analog input measurement.  This additional noise can then be averaged
656 out, to get a more accurate measurement of the input signal.  It
657 should not be assumed that channels can be separately configured.
658 A simple design can use 1 bit to turn this feature on/off.
659 </para>
660
661 <para>
662 Some devices have the capability of changing the glitch characteristics
663 of analog output subsytems.  The default (off) case should be where
664 the average settling time is lowest.  A simple design can use 1 bit
665 to turn this feature on/off.
666 </para>
667
668 <para>
669 Some devices have a configurable analog filters as part of the analog
670 input stage.  A simple designe can use 1 bit to enable/disable the
671 filter.  Default is disabled, i.e., the filter being bypassed, or if
672 the choice is between two filters, the filter with the largest
673 bandwidth.
674 </para>
675 </section>
676
677 <section>
678 <title>
679 Analog Output Waveform Generation
680 </title>
681
682 <simplelist>
683   <member>
684 Status: design
685   </member>
686   <member>
687 ID: not assigned
688   </member>
689   <member>
690 Length:
691   </member>
692   <member>
693 Chanspec: ignored
694   </member>
695 </simplelist>
696
697 <para>
698 Some devices have the ability to cyclicly loop through samples kept in
699 an on-board analog output FIFO.  This config should allow the user to
700 enable/disable this mode.
701 </para>
702
703 <para>
704 This config should allow the user to configure the number of samples
705 to loop through.  It may be necessary to configure the channels used.
706 </para>
707
708 </section>
709
710 <section>
711 <title>
712 Extended Triggering
713 </title>
714
715 <simplelist>
716   <member>
717 Status: alpha
718   </member>
719   <member>
720 ID: not assigned
721   </member>
722   <member>
723 Chanspec: ignored
724   </member>
725 </simplelist>
726
727 <para>
728 This section covers common information for all extended
729 triggering configuration, and doesn't describe a particular
730 type of extended trigger.
731 </para>
732
733 <para>
734 Extended triggering is used to configure triggering engines that
735 do not fit into commands.  In a typical programming sequence, the
736 application will use configuration instructions to configure an
737 extended trigger, and the issue a command, specifying TRIG_OTHER 
738 as one of the trigger sources.
739 </para>
740
741 <para>
742 Extended trigger configuration should be designed in such a way
743 that the user can probe for valid parameters, similar to how
744 command testing works.  An extended trigger config instruction
745 should not configure the hardware directly, rather, the configuration
746 should be saved until the subsequent command is issued.  This
747 allows more flexibility for future interface changes.
748 </para>
749
750 <para>
751 It has not been decided whether the config stage should return a
752 token that is then used as the trigger argument in the command.
753 Using tokens is one method to satisfy the problem that extended
754 trigger configurations may have subtle compatiblity issues with
755 other trigger sources/arguments that can only be determined at
756 command test time.  Passing all stages of a command test should
757 only be allowed with a properly configured extended trigger.
758 </para>
759
760 <para>
761 Extended triggers must use data[1] as flags.  The upper 16 bits
762 are reserved and used only for flags that are common to
763 all extended triggers.  The lower 16 bits may be defined by the
764 particular type of extended trigger.
765 </para>
766
767 <para>
768 Various types of extended triggers must use data[1] to know which
769 event the extended trigger will be assigned to in the command
770 structure.  The possible values are an OR'd mask of the following:
771 </para>
772
773 <itemizedlist>
774   <listitem>
775     <para>
776 COMEDI_EV_START
777     </para>
778   </listitem>
779   <listitem>
780     <para>
781 COMEDI_EV_SCAN_BEGIN
782     </para>
783   </listitem>
784   <listitem>
785     <para>
786 COMEDI_EV_CONVERT
787     </para>
788   </listitem>
789   <listitem>
790     <para>
791 COMEDI_EV_SCAN_END
792     </para>
793   </listitem>
794   <listitem>
795     <para>
796 COMEDI_EV_STOP
797     </para>
798   </listitem>
799 </itemizedlist>
800
801 </section>
802
803 <section>
804 <title>
805 Analog Triggering
806 </title>
807
808 <simplelist>
809   <member>
810 Status: alpha
811   </member>
812   <member>
813 ID: not assigned
814   </member>
815   <member>
816 Implementation: ni_mio_common
817   </member>
818   <member>
819 Chanspec: ignored
820   </member>
821 </simplelist>
822
823 <simplelist>
824   <member>
825 data 1  - trigger and combining machine configuration
826   </member>
827   <member>
828 data 2  - analog triggering signal chanspec
829   </member>
830   <member>
831 data 3  - primary analog level
832   </member>
833   <member>
834 data 4  - secondary analog level
835   </member>
836 </simplelist>
837
838 <para>
839 Analog triggering is described by a digital combining machine that
840 has two sensitive digital inputs.  The sensitive digital inputs are
841 generated by configurable analog comparators.  The analog comparators
842 generate a digital 1 when the analog triggering signal is greater
843 than the comparator level.  The digital inputs are not modifier
844 inputs.  Note, however, there is an effective modifier due to the
845 restriction that the primary analog comparator level must be less
846 than the secondary analog comparator level.
847 </para>
848
849 <para>
850 If only one analog comparator signal is used, the combining machine
851 for the secondary input should be set to ignored, and the secondary
852 analog level should be set to 0.
853 </para>
854
855 <para>
856 The interpretation of the chanspec and voltage levels is device
857 dependent, but should correspond to similar values of the analog
858 input subdevice, if possible.
859 </para>
860
861 <para>
862 Notes:  Reading range information is not addressed.  This makes it
863 difficult to convert comparator voltages to data values.
864 </para>
865
866 <para>
867 Possible extensions: A parameter that specifies the necessary time
868 that the set condition has to be true before the trigger is generated.
869 A parameter that specifies the necessary time that the reset condition
870 has to be true before the state machine is reset.
871 </para>
872
873 </section>
874
875 <section>
876 <title>
877 Bitfield Pattern Matching Extended Trigger
878 </title>
879
880 <simplelist>
881   <member>
882 Status: design
883   </member>
884   <member>
885 ID: not assigned
886   </member>
887   <member>
888 Chanspec: ignored
889   </member>
890 </simplelist>
891
892 <simplelist>
893   <member>
894 data 1  - trigger flags
895   </member>
896   <member>
897 data 2  - mask
898   </member>
899   <member>
900 data 3  - pattern
901   </member>
902 </simplelist>
903
904 <para>
905 The pattern matching trigger issues a trigger when all of a specifed 
906 set of input lines match a specified pattern.  If the device allows,
907 the input lines should correspond to the input lines of a digital input
908 subdevice, however, this will necessarily be device dependent.  Each
909 possible digital line that can be matched is assigned a bit in the
910 mask and pattern.  A bit set in the mask indicates that the
911 input line must match the corresponding bit in the pattern.
912 A bit cleared in the mask indicates that the input line is ignored.
913 </para>
914
915 <para>
916 Notes: This only allows 32 bits in the pattern/mask, which may be
917 too few.  Devices may support selecting different sets of lines from
918 which to match a pattern.
919 </para>
920
921 <para>
922 Discovery: The number of bits can be discovered by setting the mask
923 to all 1's.  The driver must modify this value and return -EAGAIN.
924 </para>
925
926 </section>
927
928 <section>
929 <title>
930 Counter configuration
931 </title>
932
933 <simplelist>
934   <member>
935 Status: design
936   </member>
937   <member>
938 ID: not assigned
939   </member>
940   <member>
941 Chanspec: used to specify counter
942   </member>
943 </simplelist>
944
945 <simplelist>
946   <member>
947 data 1  - trigger configuration
948   </member>
949   <member>
950 data 2  - primary input chanspec
951   </member>
952   <member>
953 data 3  - primary combining machine configuration
954   </member>
955   <member>
956 data 4  - secondary input chanspec
957   </member>
958   <member>
959 data 5  - secondary combining machine configuration
960   </member>
961   <member>
962 data 6  - latch configuration
963   </member>
964 </simplelist>
965
966 <para>
967 Counters can be operated either in synchronous mode (using insn_read)
968 or asynchronous mode (using commands), similar to analog input subdevices.
969 The input signal for both modes is the accumulator.
970 Commands on counter subdevices are almost always specified using
971 scan_begin_src=TRIG_OTHER, with the counter configuration also serving
972 as the extended configuration for the scan begin source.
973 </para>
974
975 <para>
976 Counters are made up of an accumulator and a combining machine that
977 determines when the accumulator should be incremented or decremented
978 based on the values of the input signals.  The combining machine
979 optionally determines when the accumulator should be latched and
980 put into a buffer.  This feature is used in asynchronous mode.
981 </para>
982
983 <para>
984 Notes: How to access multiple pieces of data acquired at each event?
985 </para>
986
987 </section>
988
989 <section>
990 <title>
991 One source plus auxiliary counter configuration
992 </title>
993
994 <simplelist>
995   <member>
996 Status: design
997   </member>
998   <member>
999 ID: not assigned
1000   </member>
1001   <member>
1002 Chanspec: ?
1003   </member>
1004 </simplelist>
1005
1006 <para>
1007 data[1] is flags, including the flags for the command triggering
1008 configuration.  If a command is not subsequently issued on the
1009 subdevice, the command triggering portion of the flags are ignored.
1010 </para>
1011
1012 <para>
1013 data[2] determines the mode of operation.  The mode of operation
1014 is actually a bitfield that encodes what to do for various
1015 transitions of the source signals.
1016 </para>
1017
1018 <para>
1019 data[3] and data[4] determine the primary source for the counter,
1020 similar to _src and _arg used in commands.
1021 </para>
1022
1023
1024 <para>
1025 Notes: How to specify which events cause a latch and push, and what
1026 should get latched.
1027 </para>
1028 </section>
1029
1030 </section>
1031 </section>
1032
1033