/* Registration method */ static void drvAsynColbyRegister(void) { static int firstTime = 1; if( firstTime ) { firstTime = 0; iocshRegister( &drvAsynColbyFuncDef,drvAsynColbyCallFunc ); } }
int main(int argc,char *argv[]) { iocshRegister(&asinittestFuncDef,asinittestCallFunc); if(argc>=2) { if (iocsh(argv[1]) < 0) return(1); epicsThreadSleep(.2); } iocsh(NULL); epicsExit(0); return(0); }
static void NTPTime_InitOnce(void *pprio) { struct timespec timespecNow; NTPTimePvt.synchronize = 1; NTPTimePvt.synchronized = 0; NTPTimePvt.loopEvent = epicsEventMustCreate(epicsEventEmpty); NTPTimePvt.syncsFailed = 0; NTPTimePvt.lock = epicsMutexCreate(); /* Initialize OS-dependent code */ osdNTPInit(); /* Try to sync with NTP server */ if (!osdNTPGet(×pecNow)) { NTPTimePvt.syncTick = osdTickGet(); if (timespecNow.tv_sec > POSIX_TIME_AT_EPICS_EPOCH && epicsTimeOK == epicsTimeFromTimespec(&NTPTimePvt.syncTime, ×pecNow)) { NTPTimePvt.clockTick = NTPTimePvt.syncTick; NTPTimePvt.clockTime = NTPTimePvt.syncTime; NTPTimePvt.synchronized = 1; } } /* Start the sync thread */ epicsThreadCreate("NTPTimeSync", epicsThreadPriorityHigh, epicsThreadGetStackSize(epicsThreadStackSmall), NTPTimeSync, NULL); epicsAtExit(NTPTime_Shutdown, NULL); /* Register the iocsh commands */ iocshRegister(&ReportFuncDef, ReportCallFunc); iocshRegister(&ShutdownFuncDef, ShutdownCallFunc); /* Finally register as a time provider */ generalTimeRegisterCurrentProvider("NTP", *(int *)pprio, NTPTimeGetCurrent); }
void epicsShareAPI iocshRegisterVariable (const iocshVarDef *piocshVarDef) { struct iocshVariable *l, *p, *n; int i; int found; iocshTableLock (); while ((piocshVarDef != NULL) && (piocshVarDef->name != NULL) && (*piocshVarDef->name != '\0')) { if (iocshVariableHead == NULL) iocshRegister(&varFuncDef,varCallFunc); found = 0; for (l = NULL, p = iocshVariableHead ; p != NULL ; l = p, p = p->next) { i = strcmp (piocshVarDef->name, p->pVarDef->name); if (i == 0) { errlogPrintf("Warning: iocshRegisterVariable redefining %s.\n", piocshVarDef->name); p->pVarDef = piocshVarDef; found = 1; break; } if (i < 0) break; } if (!found) { n = (struct iocshVariable *) callocMustSucceed(1, sizeof *n, "iocshRegisterVariable"); if (!registryAdd(iocshVarID, piocshVarDef->name, (void *)n)) { free(n); iocshTableUnlock(); errlogPrintf("iocshRegisterVariable failed to add %s.\n", piocshVarDef->name); return; } if (l == NULL) { n->next = iocshVariableHead; iocshVariableHead = n; } else { n->next = l->next; l->next = n; } n->pVarDef = piocshVarDef; } piocshVarDef++; } iocshTableUnlock (); }
extern "C" void NDProcessRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
extern "C" void NDStdArraysRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
extern "C" void NDROIStatRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
void mcaAIMRegister(void) { iocshRegister(&AIMConfigFuncDef,AIMConfigCallFunc); }
extern "C" void NDFileFITSRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
static void sampleChangerRegister(void) { iocshRegister(&initFuncDef, initCallFunc); }
static void pcish(void) { iocshRegister(&pcireadFuncDef,pcireadCall); iocshRegister(&pciconfreadFuncDef,pciconfreadCall); iocshRegister(&pcidiagsetFuncDef,pcidiagsetCall); }
void DSA2000Register(void) { iocshRegister(&DSA2000ConfigFuncDef,DSA2000ConfigCallFunc); }
static void mrmDataBufferRegistrar() { iocshRegister(&mrmDataBufferDef_send, mrmDataBufferFunc_send); iocshRegister(&mrmDataBufferDef_put, mrmDataBufferFunc_put); iocshRegister(&mrmDataBufferDef_read, mrmDataBufferFunc_read); iocshRegister(&mrmDataBufferDef_IRQ, mrmDataBufferFunc_IRQ); iocshRegister(&mrmDataBufferDef_Rx, mrmDataBufferFunc_Rx); iocshRegister(&mrmDataBufferDef_user, mrmDataBufferFunc_user); iocshRegister(&mrmDataBufferDef_stop, mrmDataBufferFunc_stop); iocshRegister(&mrmDataBufferDef_print, mrmDataBufferFunc_print); iocshRegister(&mrmDataBufferDef_initInterest, mrmDataBufferFunc_initInterest); iocshRegister(&mrmDataBufferDef_addInterest, mrmDataBufferFunc_addInterest); iocshRegister(&mrmDataBufferDef_removeInterest, mrmDataBufferFunc_removeInterest); }
void testErrorsRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
void pcoEdgePluginRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
void mcaRontecRegister(void) { iocshRegister(&RontecConfigFuncDef,RontecConfigCallFunc); }
static void daedataRegister(void) { iocshRegister(&initFuncDef, initCallFunc); }
extern "C" void NDEdgeRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
static void isisbeamRegister(void) { iocshRegister(&initFuncDef, initCallFunc); }
extern "C" void NDCircularBuffRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
static void ImsMDrivePlusMotorRegister(void) { iocshRegister(&ImsMDrivePlusCreateControllerDef, ImsMDrivePlusCreateControllerCallFunc); }
static void PMCVMotorRegister(void) { iocshRegister(&PMCVCreateControllerDef, PMCVCreateControllerCallFunc); iocshRegister(&PMCVsetEncModeDef, PMCVsetEncModeCallFunc); iocshRegister(&PMCVsetWPCDef, PMCVsetWPCCallFunc); iocshRegister(&PMCVsetSpeedRampDef, PMCVsetSpeedRampCallFunc); iocshRegister(&PMCVsetDZDef, PMCVsetDZCallFunc); iocshRegister(&PMCVflashCommandDef, PMCVflashCommandCallFunc); iocshRegister(&PMCVsetIndexModeDef, PMCVsetIndexModeCallFunc); iocshRegister(&PMCVsetSyncDef, PMCVsetSyncCallFunc); iocshRegister(&PMCVsetParkDef, PMCVsetParkCallFunc); iocshRegister(&PMCVsetSpeedLimitsDef, PMCVsetSpeedLimitsCallFunc); iocshRegister(&PMCVsetMicrodelayDef, PMCVsetMicrodelayCallFunc); iocshRegister(&PMCVsetWaveformResolutionDef, PMCVsetWaveformResolutionCallFunc); iocshRegister(&PMCVclearBoxErrorsDef, PMCVclearBoxErrorsCallFunc); }
/* Registration routine, runs at startup */ static void helloRegister(void) { iocshRegister(&helloFuncDef, helloCallFunc); }
void epicsShareAPI asIocRegister(void) { iocshRegister(&asSetFilenameFuncDef,asSetFilenameCallFunc); iocshRegister(&asSetSubstitutionsFuncDef,asSetSubstitutionsCallFunc); iocshRegister(&asInitFuncDef,asInitCallFunc); iocshRegister(&asdbdumpFuncDef,asdbdumpCallFunc); iocshRegister(&aspuagFuncDef,aspuagCallFunc); iocshRegister(&asphagFuncDef,asphagCallFunc); iocshRegister(&asprulesFuncDef,asprulesCallFunc); iocshRegister(&aspmemFuncDef,aspmemCallFunc); iocshRegister(&astacFuncDef,astacCallFunc); iocshRegister(&ascarFuncDef,ascarCallFunc); iocshRegister(&asDumpHashFuncDef,asDumpHashCallFunc); }
extern "C" void NDMagnificationCorrectionRegister ( void ) { iocshRegister(&initFuncDef,initCallFunc); }
void drvSIS3801Register(void) { iocshRegister(&drvSIS3801ConfigFuncDef,drvSIS3801ConfigCallFunc); }
/* * Register commands on application startup */ static int Registration() { iocshRegisterCommon(); iocshRegister(®isterRecordDeviceDriverFuncDef, registerRecordDeviceDriverCallFunc); return 0; }
extern "C" void NDTransformRegister(void) { iocshRegister(&initFuncDef,initCallFunc); }
static void shamrockRegister(void) { iocshRegister(&configShamrock, configCallFunc); }
static void SMC100Register(void) { iocshRegister(&SMC100CreateControllerDef, SMC100CreateContollerCallFunc); }