all existing manipulations of UDF in process() are removed and

udf is set FALSE when the raw value is successfully read.
This commit is contained in:
Marty Kraimer
2002-02-04 15:11:22 +00:00
parent 3280244690
commit c707269064
+1 -3
View File
@@ -206,15 +206,14 @@ static long process(pmbbi)
short i;
unsigned long rval = pmbbi->rval;
pmbbi->udf = FALSE;
if(pmbbi->shft>0) rval >>= pmbbi->shft;
if (pmbbi->sdef){
pstate_values = &(pmbbi->zrvl);
pmbbi->val = 65535; /* initalize to unknown state*/
pmbbi->udf = TRUE;
for (i = 0; i < 16; i++){
if (*pstate_values == rval){
pmbbi->val = i;
pmbbi->udf = FALSE;
break;
}
pstate_values++;
@@ -222,7 +221,6 @@ static long process(pmbbi)
}else{
/* the raw value is the desired value */
pmbbi->val = (unsigned short)rval;
pmbbi->udf = FALSE;
}
}
else if(status == 2) status = 0;