make single-scan code work for 611x too
authorFrank Mori Hess <fmhess@speakeasy.net>
Thu, 5 Jun 2003 19:52:56 +0000 (19:52 +0000)
committerFrank Mori Hess <fmhess@speakeasy.net>
Thu, 5 Jun 2003 19:52:56 +0000 (19:52 +0000)
comedi/drivers/ni_mio_common.c
comedi/drivers/ni_stc.h

index 579efd2fc907a3073a551c198e1ba84a3e69653e..ecb5c774ea9ad952988fd1863325dd666223d890 100644 (file)
@@ -597,7 +597,7 @@ static void handle_a_interrupt(comedi_device *dev,unsigned short status,
 #endif
                }
                /* handle special case of single scan using AI_End_On_End_Of_Scan */
-               if( s->async->cmd.stop_src == TRIG_COUNT && s->async->cmd.stop_arg == 1 ){
+               if( ( devpriv->ai_cmd2 & AI_End_On_End_Of_Scan ) ){
                        shutdown_ai_command( dev );
                }
 
index 6377b6d20969d0aca9d7e97870e5eb4e16237b92..7ad85e72511dfa3e3c65a797c1baf5a32dcd5be3 100644 (file)
@@ -746,7 +746,7 @@ static ni_board ni_boards[];
        unsigned short ao[2];                                   \
        unsigned short caldacs[MAX_N_CALDACS];                          \
                                                                \
-       unsigned short ai_cmd2; \
+       volatile unsigned short ai_cmd2;        \
                                                                \
        unsigned short ao_conf[2];                              \
        unsigned short ao_mode1;                                \