From: Ian Abbott Date: Mon, 8 Nov 2010 11:38:40 +0000 (+0000) Subject: Include chanlist length in call to comedi_get_cmd_generic_timed. X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=309fc0d7f84aa27d4a46938ad2ca37628d83789d;p=comedilib.git Include chanlist length in call to comedi_get_cmd_generic_timed. Truncate the Float period to an integer. --- diff --git a/swig/ruby/demo/cmd b/swig/ruby/demo/cmd index 4a2d56b..10da076 100755 --- a/swig/ruby/demo/cmd +++ b/swig/ruby/demo/cmd @@ -14,8 +14,8 @@ class SWIG::TYPE_p_comedi_t_struct def prepare_cmd_lib(subdevice, freq, cmd) begin - cmd = get_cmd_generic_timed(subdevice, cmd, - 1000000000.0 / freq) + cmd = get_cmd_generic_timed(subdevice, cmd, $n_chan, + (1000000000.0 / freq).truncate) rescue ComediError printf("comedi_get_cmd_generic_timed failed\n") return cmd