From 7b702917629f17e84c261da963807fa895ba46a4 Mon Sep 17 00:00:00 2001 From: Frank Mori Hess Date: Sat, 31 Dec 2005 23:53:06 +0000 Subject: [PATCH] Added support for a couple missing ao registers to m_series_stc_writew() --- comedi/drivers/ni_mio_common.c | 4 ++-- comedi/drivers/ni_pcimio.c | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/comedi/drivers/ni_mio_common.c b/comedi/drivers/ni_mio_common.c index b5349ea0..d4825692 100644 --- a/comedi/drivers/ni_mio_common.c +++ b/comedi/drivers/ni_mio_common.c @@ -878,7 +878,7 @@ static int ni_ao_prep_fifo(comedi_device *dev,comedi_subdevice *s) int n; /* reset fifo */ - devpriv->stc_writew(dev, 0,DAC_FIFO_Clear); + devpriv->stc_writew(dev, 1,DAC_FIFO_Clear); if(boardtype.reg_type & ni_reg_6xxx_mask) ni_ao_win_outl(dev, 0x6, AO_FIFO_Offset_Load_611x); @@ -2167,7 +2167,7 @@ static int ni_ao_inttrig(comedi_device *dev,comedi_subdevice *s, ni_set_bits(dev, Interrupt_B_Enable_Register, AO_FIFO_Interrupt_Enable | AO_Error_Interrupt_Enable, 0); interrupt_b_bits = AO_Error_Interrupt_Enable; #ifdef PCIDMA - devpriv->stc_writew(dev, 0, DAC_FIFO_Clear); + devpriv->stc_writew(dev, 1, DAC_FIFO_Clear); if(boardtype.reg_type & ni_reg_6xxx_mask) ni_ao_win_outl(dev, 0x6, AO_FIFO_Offset_Load_611x); ni_ao_setup_MITE_dma(dev, &s->async->cmd); diff --git a/comedi/drivers/ni_pcimio.c b/comedi/drivers/ni_pcimio.c index 1482ec17..e8561709 100644 --- a/comedi/drivers/ni_pcimio.c +++ b/comedi/drivers/ni_pcimio.c @@ -1070,6 +1070,9 @@ static void m_series_stc_writew(comedi_device *dev, uint16_t data, int reg) case AO_Command_1_Register: offset = M_Offset_AO_Command_1; break; + case AO_Command_2_Register: + offset = M_Offset_AO_Command_2; + break; case AO_Mode_1_Register: offset = M_Offset_AO_Mode_1; break; @@ -1088,6 +1091,9 @@ static void m_series_stc_writew(comedi_device *dev, uint16_t data, int reg) case AO_Start_Select_Register: offset = M_Offset_AO_Start_Select; break; + case AO_Trigger_Select_Register: + offset = M_Offset_AO_Trigger_Select; + break; case Clock_and_FOUT_Register: offset = M_Offset_Clock_and_FOUT; break; -- 2.26.2