From: Frank Mori Hess Date: Wed, 24 Oct 2007 18:14:55 +0000 (+0000) Subject: Prevent glitches when transitioning from static control of dio lines X-Git-Tag: r0_7_75~8 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=ab94ff3970cd8d2305f4450e247d855cb1b98033;p=comedi.git Prevent glitches when transitioning from static control of dio lines to waveform output. --- diff --git a/comedi/drivers/ni_mio_common.c b/comedi/drivers/ni_mio_common.c index 999211ec..b5002f42 100644 --- a/comedi/drivers/ni_mio_common.c +++ b/comedi/drivers/ni_mio_common.c @@ -3171,6 +3171,8 @@ static int ni_ao_reset(comedi_device *dev,comedi_subdevice *s) return 0; } +// digital io + static int ni_dio_insn_config(comedi_device *dev,comedi_subdevice *s, comedi_insn *insn,lsampl_t *data) { @@ -3392,6 +3394,8 @@ static int ni_cdio_cmd(comedi_device *dev, comedi_subdevice *s) ni_writel(cdo_mode_bits, M_Offset_CDO_Mode); if(s->io_bits) { + ni_writel(s->state, M_Offset_CDO_FIFO_Data); + ni_writel(CDO_SW_Update_Bit, M_Offset_CDIO_Command); ni_writel(s->io_bits, M_Offset_CDO_Mask_Enable); }else {