|
@@ -95,14 +95,14 @@ struct s626_board {
|
|
|
|
|
|
static const struct s626_board s626_boards[] = {
|
|
|
{
|
|
|
- name: "s626",
|
|
|
- ai_chans : S626_ADC_CHANNELS,
|
|
|
- ai_bits: 14,
|
|
|
- ao_chans : S626_DAC_CHANNELS,
|
|
|
- ao_bits: 13,
|
|
|
- dio_chans : S626_DIO_CHANNELS,
|
|
|
- dio_banks : S626_DIO_BANKS,
|
|
|
- enc_chans : S626_ENCODER_CHANNELS,
|
|
|
+ .name = "s626",
|
|
|
+ .ai_chans = S626_ADC_CHANNELS,
|
|
|
+ .ai_bits = 14,
|
|
|
+ .ao_chans = S626_DAC_CHANNELS,
|
|
|
+ .ao_bits = 13,
|
|
|
+ .dio_chans = S626_DIO_CHANNELS,
|
|
|
+ .dio_banks = S626_DIO_BANKS,
|
|
|
+ .enc_chans = S626_ENCODER_CHANNELS,
|
|
|
}
|
|
|
};
|
|
|
|
|
@@ -122,10 +122,10 @@ static int s626_attach(struct comedi_device *dev, struct comedi_devconfig *it);
|
|
|
static int s626_detach(struct comedi_device *dev);
|
|
|
|
|
|
static struct comedi_driver driver_s626 = {
|
|
|
- driver_name:"s626",
|
|
|
- module : THIS_MODULE,
|
|
|
- attach : s626_attach,
|
|
|
- detach : s626_detach,
|
|
|
+ .driver_name = "s626",
|
|
|
+ .module = THIS_MODULE,
|
|
|
+ .attach = s626_attach,
|
|
|
+ .detach = s626_detach,
|
|
|
};
|
|
|
|
|
|
struct s626_private {
|
|
@@ -173,39 +173,39 @@ struct dio_private {
|
|
|
};
|
|
|
|
|
|
static struct dio_private dio_private_A = {
|
|
|
- RDDIn:LP_RDDINA,
|
|
|
- WRDOut : LP_WRDOUTA,
|
|
|
- RDEdgSel : LP_RDEDGSELA,
|
|
|
- WREdgSel : LP_WREDGSELA,
|
|
|
- RDCapSel : LP_RDCAPSELA,
|
|
|
- WRCapSel : LP_WRCAPSELA,
|
|
|
- RDCapFlg : LP_RDCAPFLGA,
|
|
|
- RDIntSel : LP_RDINTSELA,
|
|
|
- WRIntSel : LP_WRINTSELA,
|
|
|
+ .RDDIn = LP_RDDINA,
|
|
|
+ .WRDOut = LP_WRDOUTA,
|
|
|
+ .RDEdgSel = LP_RDEDGSELA,
|
|
|
+ .WREdgSel = LP_WREDGSELA,
|
|
|
+ .RDCapSel = LP_RDCAPSELA,
|
|
|
+ .WRCapSel = LP_WRCAPSELA,
|
|
|
+ .RDCapFlg = LP_RDCAPFLGA,
|
|
|
+ .RDIntSel = LP_RDINTSELA,
|
|
|
+ .WRIntSel = LP_WRINTSELA,
|
|
|
};
|
|
|
|
|
|
static struct dio_private dio_private_B = {
|
|
|
- RDDIn:LP_RDDINB,
|
|
|
- WRDOut : LP_WRDOUTB,
|
|
|
- RDEdgSel : LP_RDEDGSELB,
|
|
|
- WREdgSel : LP_WREDGSELB,
|
|
|
- RDCapSel : LP_RDCAPSELB,
|
|
|
- WRCapSel : LP_WRCAPSELB,
|
|
|
- RDCapFlg : LP_RDCAPFLGB,
|
|
|
- RDIntSel : LP_RDINTSELB,
|
|
|
- WRIntSel : LP_WRINTSELB,
|
|
|
+ .RDDIn = LP_RDDINB,
|
|
|
+ .WRDOut = LP_WRDOUTB,
|
|
|
+ .RDEdgSel = LP_RDEDGSELB,
|
|
|
+ .WREdgSel = LP_WREDGSELB,
|
|
|
+ .RDCapSel = LP_RDCAPSELB,
|
|
|
+ .WRCapSel = LP_WRCAPSELB,
|
|
|
+ .RDCapFlg = LP_RDCAPFLGB,
|
|
|
+ .RDIntSel = LP_RDINTSELB,
|
|
|
+ .WRIntSel = LP_WRINTSELB,
|
|
|
};
|
|
|
|
|
|
static struct dio_private dio_private_C = {
|
|
|
- RDDIn:LP_RDDINC,
|
|
|
- WRDOut : LP_WRDOUTC,
|
|
|
- RDEdgSel : LP_RDEDGSELC,
|
|
|
- WREdgSel : LP_WREDGSELC,
|
|
|
- RDCapSel : LP_RDCAPSELC,
|
|
|
- WRCapSel : LP_WRCAPSELC,
|
|
|
- RDCapFlg : LP_RDCAPFLGC,
|
|
|
- RDIntSel : LP_RDINTSELC,
|
|
|
- WRIntSel : LP_WRINTSELC,
|
|
|
+ .RDDIn = LP_RDDINC,
|
|
|
+ .WRDOut = LP_WRDOUTC,
|
|
|
+ .RDEdgSel = LP_RDEDGSELC,
|
|
|
+ .WREdgSel = LP_WREDGSELC,
|
|
|
+ .RDCapSel = LP_RDCAPSELC,
|
|
|
+ .WRCapSel = LP_WRCAPSELC,
|
|
|
+ .RDCapFlg = LP_RDCAPFLGC,
|
|
|
+ .RDIntSel = LP_RDINTSELC,
|
|
|
+ .WRIntSel = LP_WRINTSELC,
|
|
|
};
|
|
|
|
|
|
/* to group dio devices (48 bits mask and data are not allowed ???)
|
|
@@ -355,100 +355,100 @@ static void CountersInit(struct comedi_device *dev);
|
|
|
/* struct enc_private; */
|
|
|
static struct enc_private enc_private_data[] = {
|
|
|
{
|
|
|
- GetEnable:GetEnable_A,
|
|
|
- GetIntSrc : GetIntSrc_A,
|
|
|
- GetLoadTrig : GetLoadTrig_A,
|
|
|
- GetMode : GetMode_A,
|
|
|
- PulseIndex : PulseIndex_A,
|
|
|
- SetEnable : SetEnable_A,
|
|
|
- SetIntSrc : SetIntSrc_A,
|
|
|
- SetLoadTrig : SetLoadTrig_A,
|
|
|
- SetMode : SetMode_A,
|
|
|
- ResetCapFlags : ResetCapFlags_A,
|
|
|
- MyCRA : LP_CR0A,
|
|
|
- MyCRB : LP_CR0B,
|
|
|
- MyLatchLsw : LP_CNTR0ALSW,
|
|
|
- MyEventBits : EVBITS(0),
|
|
|
+ .GetEnable = GetEnable_A,
|
|
|
+ .GetIntSrc = GetIntSrc_A,
|
|
|
+ .GetLoadTrig = GetLoadTrig_A,
|
|
|
+ .GetMode = GetMode_A,
|
|
|
+ .PulseIndex = PulseIndex_A,
|
|
|
+ .SetEnable = SetEnable_A,
|
|
|
+ .SetIntSrc = SetIntSrc_A,
|
|
|
+ .SetLoadTrig = SetLoadTrig_A,
|
|
|
+ .SetMode = SetMode_A,
|
|
|
+ .ResetCapFlags = ResetCapFlags_A,
|
|
|
+ .MyCRA = LP_CR0A,
|
|
|
+ .MyCRB = LP_CR0B,
|
|
|
+ .MyLatchLsw = LP_CNTR0ALSW,
|
|
|
+ .MyEventBits = EVBITS(0),
|
|
|
},
|
|
|
{
|
|
|
- GetEnable:GetEnable_A,
|
|
|
- GetIntSrc : GetIntSrc_A,
|
|
|
- GetLoadTrig : GetLoadTrig_A,
|
|
|
- GetMode : GetMode_A,
|
|
|
- PulseIndex : PulseIndex_A,
|
|
|
- SetEnable : SetEnable_A,
|
|
|
- SetIntSrc : SetIntSrc_A,
|
|
|
- SetLoadTrig : SetLoadTrig_A,
|
|
|
- SetMode : SetMode_A,
|
|
|
- ResetCapFlags : ResetCapFlags_A,
|
|
|
- MyCRA : LP_CR1A,
|
|
|
- MyCRB : LP_CR1B,
|
|
|
- MyLatchLsw : LP_CNTR1ALSW,
|
|
|
- MyEventBits : EVBITS(1),
|
|
|
+ .GetEnable = GetEnable_A,
|
|
|
+ .GetIntSrc = GetIntSrc_A,
|
|
|
+ .GetLoadTrig = GetLoadTrig_A,
|
|
|
+ .GetMode = GetMode_A,
|
|
|
+ .PulseIndex = PulseIndex_A,
|
|
|
+ .SetEnable = SetEnable_A,
|
|
|
+ .SetIntSrc = SetIntSrc_A,
|
|
|
+ .SetLoadTrig = SetLoadTrig_A,
|
|
|
+ .SetMode = SetMode_A,
|
|
|
+ .ResetCapFlags = ResetCapFlags_A,
|
|
|
+ .MyCRA = LP_CR1A,
|
|
|
+ .MyCRB = LP_CR1B,
|
|
|
+ .MyLatchLsw = LP_CNTR1ALSW,
|
|
|
+ .MyEventBits = EVBITS(1),
|
|
|
},
|
|
|
{
|
|
|
- GetEnable:GetEnable_A,
|
|
|
- GetIntSrc : GetIntSrc_A,
|
|
|
- GetLoadTrig : GetLoadTrig_A,
|
|
|
- GetMode : GetMode_A,
|
|
|
- PulseIndex : PulseIndex_A,
|
|
|
- SetEnable : SetEnable_A,
|
|
|
- SetIntSrc : SetIntSrc_A,
|
|
|
- SetLoadTrig : SetLoadTrig_A,
|
|
|
- SetMode : SetMode_A,
|
|
|
- ResetCapFlags : ResetCapFlags_A,
|
|
|
- MyCRA : LP_CR2A,
|
|
|
- MyCRB : LP_CR2B,
|
|
|
- MyLatchLsw : LP_CNTR2ALSW,
|
|
|
- MyEventBits : EVBITS(2),
|
|
|
+ .GetEnable = GetEnable_A,
|
|
|
+ .GetIntSrc = GetIntSrc_A,
|
|
|
+ .GetLoadTrig = GetLoadTrig_A,
|
|
|
+ .GetMode = GetMode_A,
|
|
|
+ .PulseIndex = PulseIndex_A,
|
|
|
+ .SetEnable = SetEnable_A,
|
|
|
+ .SetIntSrc = SetIntSrc_A,
|
|
|
+ .SetLoadTrig = SetLoadTrig_A,
|
|
|
+ .SetMode = SetMode_A,
|
|
|
+ .ResetCapFlags = ResetCapFlags_A,
|
|
|
+ .MyCRA = LP_CR2A,
|
|
|
+ .MyCRB = LP_CR2B,
|
|
|
+ .MyLatchLsw = LP_CNTR2ALSW,
|
|
|
+ .MyEventBits = EVBITS(2),
|
|
|
},
|
|
|
{
|
|
|
- GetEnable:GetEnable_B,
|
|
|
- GetIntSrc : GetIntSrc_B,
|
|
|
- GetLoadTrig : GetLoadTrig_B,
|
|
|
- GetMode : GetMode_B,
|
|
|
- PulseIndex : PulseIndex_B,
|
|
|
- SetEnable : SetEnable_B,
|
|
|
- SetIntSrc : SetIntSrc_B,
|
|
|
- SetLoadTrig : SetLoadTrig_B,
|
|
|
- SetMode : SetMode_B,
|
|
|
- ResetCapFlags : ResetCapFlags_B,
|
|
|
- MyCRA : LP_CR0A,
|
|
|
- MyCRB : LP_CR0B,
|
|
|
- MyLatchLsw : LP_CNTR0BLSW,
|
|
|
- MyEventBits : EVBITS(3),
|
|
|
+ .GetEnable = GetEnable_B,
|
|
|
+ .GetIntSrc = GetIntSrc_B,
|
|
|
+ .GetLoadTrig = GetLoadTrig_B,
|
|
|
+ .GetMode = GetMode_B,
|
|
|
+ .PulseIndex = PulseIndex_B,
|
|
|
+ .SetEnable = SetEnable_B,
|
|
|
+ .SetIntSrc = SetIntSrc_B,
|
|
|
+ .SetLoadTrig = SetLoadTrig_B,
|
|
|
+ .SetMode = SetMode_B,
|
|
|
+ .ResetCapFlags = ResetCapFlags_B,
|
|
|
+ .MyCRA = LP_CR0A,
|
|
|
+ .MyCRB = LP_CR0B,
|
|
|
+ .MyLatchLsw = LP_CNTR0BLSW,
|
|
|
+ .MyEventBits = EVBITS(3),
|
|
|
},
|
|
|
{
|
|
|
- GetEnable:GetEnable_B,
|
|
|
- GetIntSrc : GetIntSrc_B,
|
|
|
- GetLoadTrig : GetLoadTrig_B,
|
|
|
- GetMode : GetMode_B,
|
|
|
- PulseIndex : PulseIndex_B,
|
|
|
- SetEnable : SetEnable_B,
|
|
|
- SetIntSrc : SetIntSrc_B,
|
|
|
- SetLoadTrig : SetLoadTrig_B,
|
|
|
- SetMode : SetMode_B,
|
|
|
- ResetCapFlags : ResetCapFlags_B,
|
|
|
- MyCRA : LP_CR1A,
|
|
|
- MyCRB : LP_CR1B,
|
|
|
- MyLatchLsw : LP_CNTR1BLSW,
|
|
|
- MyEventBits : EVBITS(4),
|
|
|
+ .GetEnable = GetEnable_B,
|
|
|
+ .GetIntSrc = GetIntSrc_B,
|
|
|
+ .GetLoadTrig = GetLoadTrig_B,
|
|
|
+ .GetMode = GetMode_B,
|
|
|
+ .PulseIndex = PulseIndex_B,
|
|
|
+ .SetEnable = SetEnable_B,
|
|
|
+ .SetIntSrc = SetIntSrc_B,
|
|
|
+ .SetLoadTrig = SetLoadTrig_B,
|
|
|
+ .SetMode = SetMode_B,
|
|
|
+ .ResetCapFlags = ResetCapFlags_B,
|
|
|
+ .MyCRA = LP_CR1A,
|
|
|
+ .MyCRB = LP_CR1B,
|
|
|
+ .MyLatchLsw = LP_CNTR1BLSW,
|
|
|
+ .MyEventBits = EVBITS(4),
|
|
|
},
|
|
|
{
|
|
|
- GetEnable:GetEnable_B,
|
|
|
- GetIntSrc : GetIntSrc_B,
|
|
|
- GetLoadTrig : GetLoadTrig_B,
|
|
|
- GetMode : GetMode_B,
|
|
|
- PulseIndex : PulseIndex_B,
|
|
|
- SetEnable : SetEnable_B,
|
|
|
- SetIntSrc : SetIntSrc_B,
|
|
|
- SetLoadTrig : SetLoadTrig_B,
|
|
|
- SetMode : SetMode_B,
|
|
|
- ResetCapFlags : ResetCapFlags_B,
|
|
|
- MyCRA : LP_CR2A,
|
|
|
- MyCRB : LP_CR2B,
|
|
|
- MyLatchLsw : LP_CNTR2BLSW,
|
|
|
- MyEventBits : EVBITS(5),
|
|
|
+ .GetEnable = GetEnable_B,
|
|
|
+ .GetIntSrc = GetIntSrc_B,
|
|
|
+ .GetLoadTrig = GetLoadTrig_B,
|
|
|
+ .GetMode = GetMode_B,
|
|
|
+ .PulseIndex = PulseIndex_B,
|
|
|
+ .SetEnable = SetEnable_B,
|
|
|
+ .SetIntSrc = SetIntSrc_B,
|
|
|
+ .SetLoadTrig = SetLoadTrig_B,
|
|
|
+ .SetMode = SetMode_B,
|
|
|
+ .ResetCapFlags = ResetCapFlags_B,
|
|
|
+ .MyCRA = LP_CR2A,
|
|
|
+ .MyCRB = LP_CR2B,
|
|
|
+ .MyLatchLsw = LP_CNTR2BLSW,
|
|
|
+ .MyEventBits = EVBITS(5),
|
|
|
},
|
|
|
};
|
|
|
|