Use new dbLink APIs instead of checking link.type

This commit is contained in:
Andrew Johnson
2016-08-27 16:30:48 -05:00
parent cca6a5d05a
commit 37b6cbb50c
43 changed files with 328 additions and 354 deletions

View File

@@ -48,19 +48,16 @@ epicsExportAddress(dset, devBiSoft);
static long init_record(biRecord *prec)
{
if (prec->inp.type == CONSTANT) {
if (recGblInitConstantLink(&prec->inp, DBF_ENUM, &prec->val))
prec->udf = FALSE;
}
if (recGblInitConstantLink(&prec->inp, DBF_ENUM, &prec->val))
prec->udf = FALSE;
return 0;
}
static long read_bi(biRecord *prec)
{
if (!dbGetLink(&prec->inp, DBR_USHORT, &prec->val, 0, 0)) {
if (prec->inp.type != CONSTANT)
prec->udf = FALSE;
if (prec->tsel.type == CONSTANT &&
prec->udf = FALSE;
if (dbLinkIsConstant(&prec->tsel) &&
prec->tse == epicsTimeEventDeviceTime)
dbGetTimeStamp(&prec->inp, &prec->time);
}