Hi,
devMbboDirectCamac.c in dev/camacDev directory uses val field of its
record structure
when writing data to CAMAC module as show below:
cfsa(pcio->f, pcio->ext, &(pmbbodirect->val), &q);
The VAL field of mbboDIrect record is defined as:
field(VAL,DBF_USHORT)
while the function cfsa() has a prototype:
void cfsa (int f, int ext, int *dat, int *q);
The convert() function in mbboDirectRecord.c apply bit shift to the VAL
field and is called
just before writeValue() function is called in a process routine.
static void convert(pmbboDirect)
struct mbboDirectRecord *pmbboDirect;
{
/* convert val to rval */
pmbboDirect->rval = (unsigned long)(pmbboDirect->val);
if(pmbboDirect->shft>0)
pmbboDirect->rval <<= pmbboDirect->shft;
return;
}
So, I think a call of cfsa in devMbboDirectCamac.c could be:
cfsa(pcio->f, pcio->ext, &(pmbbodirect->rval), &q);.
Or is there any good reason to use current code?
Thank you for your comments/opinions in advance,
Noboru Yamamoto
KEKB control group
KEK, JAPAN
- Navigate by Date:
- Prev:
Re: bad UDP messages Noboru Yamamoto
- Next:
Help about compile CDEV shen guobao
- Index:
1994
1995
1996
1997
1998
1999
2000
<2001>
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
RE: VxWorks on Linux Mark Rivers
- Next:
Help about compile CDEV shen guobao
- Index:
1994
1995
1996
1997
1998
1999
2000
<2001>
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|