May 17, 2004
This tutorial provides basic instructions on converting 'devGpib' device support from R3.13 to R3.14/ASYN. If possible, R3.14/ASYN device support modules should be placed in the EPICS CVS repository in a directory within the modules/instrument directory. Files placed in the modules/instrument directory should be as flexible as possible to ease their use by others. For example, device support database file GPIB link numbers and addresses should be macros and all PV names should be prefixed with a macro.Convert | |
From | To |
-1 | NULL |
'\r' | "\r" |
The fields in devGpibParmBlock have been reordered and some have gone away.
static long init_ai(int parm) { if (parm) { devSupParms.name = "your device's name"; devSupParms.gpibCmds = gpibCmds; devSupParms.numparams = NUMPARAMS; devSupParms.timeWindow = TIME_WINDOW; devSupParms.timeout = TIMEOUT; devSupParms.respond2Writes = -1; } return 0; }
The name
and respond2Writes
values are
unique to your implementation. All the rest should appear exactly as
shown above.
Older device support initialized devGpibParmBlock with a C initializer statement. This is no longer allowed.
include "asyn.dbd"