diff --git a/athena/Makefile b/athena/Makefile deleted file mode 100644 index 11c884a12ab0fae207ae0db13528dca8470c6d6c..0000000000000000000000000000000000000000 --- a/athena/Makefile +++ /dev/null @@ -1,2 +0,0 @@ -a.out: a.c - gcc a.c -I/usr/local/dscud5 -L/usr/local/dscud5 -ldscud-6.00 -lpthread diff --git a/athena/Makefile_base_src_softIoc b/athena/Makefile_base_src_softIoc deleted file mode 100644 index 5313f88ff60fda2d95f8249df88b60ef448a824a..0000000000000000000000000000000000000000 --- a/athena/Makefile_base_src_softIoc +++ /dev/null @@ -1,52 +0,0 @@ -########################################################################## -# Copyright (c) 2003 The University of Chicago, as Operator of Argonne -# National Laboratory. -# Copyright (c) 2003 The Regents of the University of California, as -# Operator of Los Alamos National Laboratory. -# EPICS BASE Versions 3.13.7 and higher are distributed subject to the -# Software License Agreement found in the file LICENSE that is included -# with this distribution. -########################################################################## - -TOP=../.. - -include $(TOP)/configure/CONFIG - -PROD_IOC = softIoc - -USR_DBDFLAGS += -I/opt/synApps_5_4_1/support/std/2-7/dbd -USR_DBDFLAGS += -I/opt/synApps_5_4_1/support/calc/2-7/dbd - -DBD += softIoc.dbd -softIoc_DBD += base.dbd -softIoc_DBD += system.dbd -softIoc_DBD += epidRecord.dbd -softIoc_DBD += shareBase.dbd -softIoc_DBD += std.dbd -softIoc_DBD += scalerRecord.dbd -softIoc_DBD += stdSupport.dbd - -softIoc_DBD += aCalcoutRecord.dbd -softIoc_DBD += calcSupport.dbd -softIoc_DBD += sCalcoutRecord.dbd -softIoc_DBD += swaitRecord.dbd -softIoc_DBD += transformRecord.dbd - - -ABS_INSTALL_DIR = $(shell $(PERL) $(TOOLS)/fullPathName.pl $(INSTALL_LOCATION)) -USR_CXXFLAGS += -DEPICS_BASE=$(ABS_INSTALL_DIR) -EPICS_DBDFLAGS += -I/home/controls/epid/synApps_5_4_1/support/std/2-7/dbd/ - -softIoc_SRCS += softIoc_registerRecordDeviceDriver.cpp -softIoc_SRCS += softMain.cpp - -softIoc_LIBS = $(EPICS_BASE_IOC_LIBS) -LDFLAGS += -L/opt/synApps_5_4_1/support/std/2-7/lib/linux-x86 -lstd -LDFLAGS += -L/opt/synApps_5_4_1/support/seq/2-0-12/lib/linux-x86 -lseq -lpv -LDFLAGS += -L/opt/synApps_5_4_1/support/asyn/4-10/lib/linux-x86 -lasyn -LDFLAGS += -L/opt/synApps_5_4_1/support/calc/2-7/lib/linux-x86 -lcalc -LDFLAGS += -L/opt/synApps_5_4_1/support/sscan/2-6-4/lib/linux-x86 -lsscan - -DB += softIocExit.db - -include $(TOP)/configure/RULES diff --git a/athena/README b/athena/README deleted file mode 100644 index ec77f60ecf4946e7c36e0941961299a458192f21..0000000000000000000000000000000000000000 --- a/athena/README +++ /dev/null @@ -1,9 +0,0 @@ -Athena II board development for Ben -Uses - -/opt/synApps_5_4_1/ /opt/epics-3.14.10-linux/ - - -To enable PID processing -ezcawrite stdTest:PID1.FBON 1 - diff --git a/athena/a.c b/athena/a.c deleted file mode 100644 index 60ffafdc74490f99b30d4d249040de30d9789831..0000000000000000000000000000000000000000 --- a/athena/a.c +++ /dev/null @@ -1,145 +0,0 @@ -#include <stddef.h> -#include <stdlib.h> -#include <stdio.h> -#include <string.h> - -#include <stdio.h> -#include <stdlib.h> -#include <math.h> -#include <fcntl.h> -#include <unistd.h> -#include <string.h> -#include <sys/types.h> -#include <sys/ioctl.h> -#include <sys/file.h> -#include "dscud.h" - - -static BYTE result; // returned error code -static ERRPARAMS errorParams; // structure for returning error code and error string -static DSCB dscb; // handle used to refer to the board -static DSCCB dsccb; // structure containing board settings -static DSCADSETTINGS dscadsettings; // structure containing A/D conversion settings -static DSCSAMPLE sample; // sample reading - - - -main() { - if( dscInit( DSC_VERSION ) != DE_NONE ) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscInit error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - return 1; - } - dsccb.base_address = 0x280; - dsccb.int_level = 5; - if(dscInitBoard(DSC_PROM, &dsccb, &dscb)!= DE_NONE) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscInit error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - return 1; - } - memset(&dscadsettings, 0, sizeof(DSCADSETTINGS)); - - dscadsettings.range = RANGE_10; - dscadsettings.polarity = BIPOLAR; - dscadsettings.gain = GAIN_1; - dscadsettings.load_cal = 0; - - dscadsettings.current_channel = 0; - if ((result = dscADSetSettings( dscb, &dscadsettings ) ) != DE_NONE ) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscADSetSettings error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - exit(2); - } - - //printf ("0x%x\n", &dscb); - if ((result = dscADSample (dscb, &sample)) != DE_NONE) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscADSample error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - exit(2); - } - printf("%d\n", sample); - dscFreeBoard(dscb); - dscFree(); - return 0; -} - -static long write_bo(pai) - struct boRecord *pai; -{ -#if 0 - char *DevName = "/dev/pci-das08_adc00"; - int fdADC; /* A/D file descriptors */ - struct vmeio *pvmeio; - - pvmeio = (struct vmeio *)&(pai->out.value); - if (pvmeio->signal >= 0 && pvmeio->signal < 4) { - ; - } else { - fprintf(stderr, "DAS08: Invalid bit number %d in BO record\n", pvmeio->signal); - exit(2); - } - -#ifdef DAS_LOCKING - lockf (lock_fd, F_LOCK, 0); -#endif - if (( fdADC = open(DevName, ADC_SOFT_TRIGGER)) < 0 ) { - printf("error opening device %s\n", DevName); - exit(2); - } - - if (pai->rval & 1) val |= 1 << (pvmeio->signal); - else val &= ~(1 << (pvmeio->signal)); - - ioctl(fdADC, ADC_SET_DIO, val); - - printf("%d\n", val); - - close(fdADC); -#ifdef DAS_LOCKING - lockf (lock_fd, F_ULOCK, 0); -#endif - -#endif - return(0); -} - -static long read_bi(pai) - struct biRecord *pai; -{ -#if 0 - char *DevName = "/dev/pci-das08_adc00"; - int fdADC; /* A/D file descriptors */ - struct vmeio *pvmeio; - unsigned short val; - - pvmeio = (struct vmeio *)&(pai->inp.value); - if (pvmeio->signal >= 0 && pvmeio->signal < 3) { - ; - } else { - fprintf(stderr, "DAS08: Invalid bit number %d in BI record\n", pvmeio->signal); - exit(2); - } - -#ifdef DAS_LOCKING - lockf (lock_fd, F_LOCK, 0); -#endif - if (( fdADC = open(DevName, ADC_SOFT_TRIGGER)) < 0 ) { - printf("error opening device %s\n", DevName); - exit(2); - } - - ioctl(fdADC, ADC_GET_DIO, &val); - - close(fdADC); -#ifdef DAS_LOCKING - lockf (lock_fd, F_ULOCK, 0); -#endif - - pai->rval = (val >> pvmeio->signal) & 1; -#endif - return(0); -} diff --git a/athena/a.db b/athena/a.db deleted file mode 100644 index 5b15ed722e087db6b4c4dfcd5994d3d9bd4685b5..0000000000000000000000000000000000000000 --- a/athena/a.db +++ /dev/null @@ -1,28 +0,0 @@ -grecord(ai,"adc0") -{ - field(DTYP,"ATHENA") - field(INP,"#C0 S0") - field(SCAN,"1 second") -} -grecord(ai,"adc1") -{ - field(DTYP,"ATHENA") - field(INP,"#C0 S1") - field(SCAN,"1 second") -} -grecord(ao,"dac0") -{ - field(DTYP,"ATHENA") - field(OUT,"#C0 S0") -} - -grecord(ao,"dac1") -{ - field(DTYP,"ATHENA") - field(OUT,"#C0 S1") -} -grecord(bo,"bo0") -{ - field(DTYP,"ATHENA") - field(OUT,"#C0 S0") -} diff --git a/athena/devAthena.c b/athena/devAthena.c deleted file mode 100644 index 539ecce893282cfa78de3eb2ba5bdfcdc1e428bf..0000000000000000000000000000000000000000 --- a/athena/devAthena.c +++ /dev/null @@ -1,320 +0,0 @@ -#include <stddef.h> -#include <stdlib.h> -#include <stdio.h> -#include <string.h> - -#include "alarm.h" -#include "callback.h" -#include "cvtTable.h" -#include "dbDefs.h" -#include "dbAccess.h" -#include "recGbl.h" -#include "recSup.h" -#include "devSup.h" -#include "link.h" -#include "dbCommon.h" -#include "aiRecord.h" -#include "aoRecord.h" -#include "biRecord.h" -#include "boRecord.h" -#include "epicsExport.h" - - -#include <stdio.h> -#include <stdlib.h> -#include <math.h> -#include <fcntl.h> -#include <unistd.h> -#include <string.h> -#include <sys/types.h> -#include <sys/ioctl.h> -#include <sys/file.h> -#include "dscud.h" - - -/* Create the dset for devAiTestAsyn */ -static long init_record(); -static long read_ai(); -static long write_ao(); -static long read_bi(); -static long write_bo(); -struct { - long number; - DEVSUPFUN report; - DEVSUPFUN init; - DEVSUPFUN init_record; - DEVSUPFUN get_ioint_info; - DEVSUPFUN read_ai; - DEVSUPFUN special_linconv; -}devAiAthena={ - 6, - NULL, - NULL, - init_record, - NULL, - read_ai, - NULL}; - - -struct { - long number; - DEVSUPFUN report; - DEVSUPFUN init; - DEVSUPFUN init_record; - DEVSUPFUN get_ioint_info; - DEVSUPFUN write_ao; - DEVSUPFUN special_linconv; -}devAoAthena={ - 6, - NULL, - NULL, - init_record, - NULL, - write_ao, - NULL}; - -epicsExportAddress(dset,devAiAthena); -epicsExportAddress(dset,devAoAthena); - - -#if 0 -struct { - long number; - DEVSUPFUN report; - DEVSUPFUN init; - DEVSUPFUN init_record; - DEVSUPFUN get_ioint_info; - DEVSUPFUN read_ai; - DEVSUPFUN special_linconv; -}devBiAthena={ - 6, - NULL, - NULL, - init_record, - NULL, - read_bi, - NULL}; -#endif - -struct { - long number; - DEVSUPFUN report; - DEVSUPFUN init; - DEVSUPFUN init_record; - DEVSUPFUN get_ioint_info; - DEVSUPFUN read_ai; - DEVSUPFUN special_linconv; -}devBoAthena={ - 6, - NULL, - NULL, - init_record, - NULL, - write_bo, - NULL}; -epicsExportAddress(dset,devBoAthena); - - -static BYTE result; /* returned error code */ -static ERRPARAMS errorParams; /* structure for returning error code and error string */ -static DSCB dscb; /* handle used to refer to the board */ -static DSCCB dsccb; /* structure containing board settings */ -static DSCADSETTINGS dscadsettings; /* structure containing A/D conversion settings */ -static DSCDASETTINGS dscdasettings; -static DSCSAMPLE sample; /* sample reading */ - -static athena_init = 0; - - -static long init_record(pai) - struct aiRecord *pai; -{ - if (athena_init) return 0; - - if( dscInit( DSC_VERSION ) != DE_NONE ) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscInit error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - return 1; - } - dsccb.base_address = 0x280; - dsccb.int_level = 5; - if(dscInitBoard(DSC_PROM, &dsccb, &dscb)!= DE_NONE) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscInit error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - return 1; - } - - /* configure DIO ports all for output */ - BYTE config_bytes[4]; - - /* Set all ports to output */ - config_bytes[0] = 0x0; - config_bytes[1] = 0x0; - config_bytes[2] = 0x0; - config_bytes[3] = 0x0; - - if ((result = dscDIOSetConfig(dscb, config_bytes)) != DE_NONE) - { - dscGetLastError(&errorParams); - fprintf(stderr, "dscDIOSetConfig failed: %s (%s)\n", - dscGetErrorString(result), errorParams.errstring); - return 1; - } - -#if 0 - -/* Athena does not support software selection on D/A */ - memset(&dscdasettings, 0, sizeof(DSCDASETTINGS)); - - dscdasettings.range = RANGE_10; - dscdasettings.polarity = BIPOLAR; - dscdasettings.gain = GAIN_1; - dscdasettings.load_cal = 0; - - if ((result = dscDASetSettings( dscb, &dscdasettings ) ) != DE_NONE ) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscDASetSettings error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - exit(2); - } -#endif - - printf("Athena is initialized\n"); - athena_init = 1; -/* - dscFreeBoard(dscb); - dscFree(); -*/ - return(0); -} - - -static long write_ao(pai) - struct aoRecord *pai; -{ - struct vmeio *pvmeio; - - pvmeio = (struct vmeio *)&(pai->out.value); - if (pvmeio->signal >= 0 && pvmeio->signal < 4) { - ; - } else { - fprintf(stderr, "debAthena: Invalid D/A output number %d in AO record\n", pvmeio->signal); - exit(2); - } -/*BYTE DSCUDAPICALL dscDASetPolarity(DSCB board, BYTE polarity); -BYTE DSCUDAPICALL dscDASetSettings( DSCB board, DSCDASETTINGS * dasettings); -BYTE DSCUDAPICALL dscDAConvert(DSCB board, BYTE channel, DSCDACODE output_code); -*/ - - /*status = dbPutLink(&pao->out,DBR_DOUBLE, &pao->oval,1);*/ - /* 12-bit DAC */ - /*printf("dac %d; value%f\n", pvmeio->signal, pai->oval);*/ - /* DAC output value is from 0 -> 2047 -> 4095 */ - /* -5 to +5 volts; 2047 is zero */ - DSCDACODE oval = 0; - if (pai->oval < -2047) oval = 0; - else if (pai->oval > 2048) oval = 4095; - else oval = (DSCDACODE)pai->oval + 2047; -/* printf("dac %d; value%f %d\n", pvmeio->signal, pai->oval, oval);*/ - result = dscDAConvert(dscb, (BYTE)pvmeio->signal, (DSCDACODE)oval); - - return(0); -} - -static long read_ai(pai) - struct aiRecord *pai; -{ - struct vmeio *pvmeio; - pvmeio = (struct vmeio *)&(pai->inp.value); - if (pvmeio->signal >= 0 && pvmeio->signal < 16) { - /*sprintf(buf,DevName, pvmeio->signal);*/ - } else { - fprintf(stderr, "Athena: Invalid channel number %d in AI record\n", pvmeio->signal); - exit(2); - } - - /*printf ("0x%x\n", &dscb);*/ - memset(&dscadsettings, 0, sizeof(DSCADSETTINGS)); - - dscadsettings.range = RANGE_10; - dscadsettings.polarity = BIPOLAR; - dscadsettings.gain = GAIN_1; - dscadsettings.load_cal = 0; - - dscadsettings.current_channel = pvmeio->signal; - if ((result = dscADSetSettings( dscb, &dscadsettings ) ) != DE_NONE ) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscADSetSettings error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - exit(2); - } - if ((result = dscADSample (dscb, &sample)) != DE_NONE) - { - dscGetLastError(&errorParams); - fprintf( stderr, "dscADSample error: %s %s\n", dscGetErrorString(errorParams.ErrCode), errorParams.errstring ); - exit(2); - } - /*printf("%d\n", sample);*/ - pai->rval = sample; - /*printf("%d\n", sample);*/ - return 0; -} - -static long write_bo(pai) - struct boRecord *pai; -{ - struct vmeio *pvmeio; - - pvmeio = (struct vmeio *)&(pai->out.value); - if (pvmeio->signal >= 0 && pvmeio->signal < 24) { - ; - } else { - fprintf(stderr, "debAthena: Invalid DIO output number %d in BO record\n", pvmeio->signal); - exit(2); - } - - /* printf("D/O %d; value %d\n", pvmeio->signal, pai->rval); */ - - result = dscDIOSetBit(dscb, (BYTE)pvmeio->signal, (BYTE)pai->rval); - - return(0); -} - -static long read_bi(pai) - struct biRecord *pai; -{ -#if 0 - char *DevName = "/dev/pci-das08_adc00"; - int fdADC; /* A/D file descriptors */ - struct vmeio *pvmeio; - unsigned short val; - - pvmeio = (struct vmeio *)&(pai->inp.value); - if (pvmeio->signal >= 0 && pvmeio->signal < 3) { - ; - } else { - fprintf(stderr, "DAS08: Invalid bit number %d in BI record\n", pvmeio->signal); - exit(2); - } - -#ifdef DAS_LOCKING - lockf (lock_fd, F_LOCK, 0); -#endif - if (( fdADC = open(DevName, ADC_SOFT_TRIGGER)) < 0 ) { - printf("error opening device %s\n", DevName); - exit(2); - } - - ioctl(fdADC, ADC_GET_DIO, &val); - - close(fdADC); -#ifdef DAS_LOCKING - lockf (lock_fd, F_ULOCK, 0); -#endif - - pai->rval = (val >> pvmeio->signal) & 1; -#endif - return(0); -} diff --git a/athena/devSoft.dbd b/athena/devSoft.dbd deleted file mode 100644 index 0761b0f9e92194dc29c0109a4288394e5b76c70d..0000000000000000000000000000000000000000 --- a/athena/devSoft.dbd +++ /dev/null @@ -1,48 +0,0 @@ -device(ai,CONSTANT,devAiSoft,"Soft Channel") -device(ao,CONSTANT,devAoSoft,"Soft Channel") -device(bi,CONSTANT,devBiSoft,"Soft Channel") -device(bo,CONSTANT,devBoSoft,"Soft Channel") -device(calcout,CONSTANT,devCalcoutSoft,"Soft Channel") -device(event,CONSTANT,devEventSoft,"Soft Channel") -device(longin,CONSTANT,devLiSoft,"Soft Channel") -device(longout,CONSTANT,devLoSoft,"Soft Channel") -device(mbbi,CONSTANT,devMbbiSoft,"Soft Channel") -device(mbbiDirect,CONSTANT,devMbbiDirectSoft,"Soft Channel") -device(mbbo,CONSTANT,devMbboSoft,"Soft Channel") -device(mbboDirect,CONSTANT,devMbboDirectSoft,"Soft Channel") -device(stringin,CONSTANT,devSiSoft,"Soft Channel") -device(stringout,CONSTANT,devSoSoft,"Soft Channel") -device(subArray,CONSTANT,devSASoft,"Soft Channel") -device(waveform,CONSTANT,devWfSoft,"Soft Channel") - -device(ai,CONSTANT,devAiSoftRaw,"Raw Soft Channel") -device(ao,CONSTANT,devAoSoftRaw,"Raw Soft Channel") -device(bi,CONSTANT,devBiSoftRaw,"Raw Soft Channel") -device(bo,CONSTANT,devBoSoftRaw,"Raw Soft Channel") -device(mbbi,CONSTANT,devMbbiSoftRaw,"Raw Soft Channel") -device(mbbiDirect,CONSTANT,devMbbiDirectSoftRaw,"Raw Soft Channel") -device(mbbo,CONSTANT,devMbboSoftRaw,"Raw Soft Channel") -device(mbboDirect,CONSTANT,devMbboDirectSoftRaw,"Raw Soft Channel") - -device(ao,CONSTANT,devAoSoftCallback,"Async Soft Channel") -device(bo,CONSTANT,devBoSoftCallback,"Async Soft Channel") -device(calcout,CONSTANT,devCalcoutSoftCallback,"Async Soft Channel") -device(longout,CONSTANT,devLoSoftCallback,"Async Soft Channel") -device(mbbo,CONSTANT,devMbboSoftCallback,"Async Soft Channel") -device(mbboDirect,CONSTANT,devMbboDirectSoftCallback,"Async Soft Channel") -device(stringout,CONSTANT,devSoSoftCallback,"Async Soft Channel") - -device(ai, INST_IO,devTimestampAI,"Soft Timestamp") -device(stringin,INST_IO,devTimestampSI,"Soft Timestamp") - -device(ai, INST_IO,devAiGeneralTime,"General Time") -device(bo, INST_IO,devBoGeneralTime,"General Time") -device(longin, INST_IO,devLiGeneralTime,"General Time") -device(stringin,INST_IO,devSiGeneralTime,"General Time") - -device(stringout,INST_IO,devSoStdio,"stdio") - -device(ai,VME_IO,devAiAthena,"ATHENA") -device(ao,VME_IO,devAoAthena,"ATHENA") -device(bo,VME_IO,devBoAthena,"ATHENA") - diff --git a/athena/pid_control.db b/athena/pid_control.db deleted file mode 100755 index 56b385db44574e04e3340829e46ee1cd9a59e8c5..0000000000000000000000000000000000000000 --- a/athena/pid_control.db +++ /dev/null @@ -1,85 +0,0 @@ -grecord(epid,"$(P)$(PID)") { - field(INP,"$(INP)") - field(OUTL,"$(OUT) PP NMS") - field(SCAN,"$(SCAN)") - field(KP,"$(KP)") - field(KI,"$(KI)") - field(KD,"$(KD)") - field(LOPR,"$(LOPR)") - field(HOPR,"$(HOPR)") - field(DRVL,"$(DRVL)") - field(DRVH,"$(DRVH)") - field(PREC,"$(PREC)") - field(STPL,"0") - field(FLNK,"$(P)$(PID)_limits.VAL PP NMS") -} -grecord(transform,"$(P)$(PID)_limits") { - field(DESC,"PID limits") - field(CMTA,"Low input") - field(INPA,"$(DRVL)") - field(CMTB,"High limit") - field(INPB,"$(DRVH)") - field(CMTO,"Low output") - field(CLCO,"a") - field(OUTO,"$(P)$(PID).DRVL NPP NMS") - field(CMTP,"High output") - field(CLCP,"b") - field(OUTP,"$(P)$(PID).DRVH NPP NMS") - field(PREC,"$(PREC)") -} -grecord(transform,"$(P)$(PID)_incalc") { - field(DESC,"PID input calc") - field(PREC,"$(PREC)") -} - -# These records are for tweaking the output (if the feedback is off) -grecord(ao,"$(P)$(PID)OUT_tweak") { - field(PREC,"3") -} - -grecord(calcout,"$(P)$(PID)OUT_tweak_down") { - field(INPA,"$(P)$(PID)OUT_tweak.VAL NPP NMS") - field(INPB,"$(OUT) NPP NMS") - field(CALC,"B-A") - field(OUT, "$(OUT) PP NMS") -} - -grecord(calcout,"$(P)$(PID)OUT_tweak_up") { - field(INPA,"$(P)$(PID)OUT_tweak.VAL NPP NMS") - field(INPB,"$(OUT) NPP NMS") - field(CALC,"B+A") - field(OUT, "$(OUT) PP NMS") -} - -# These records are for tweaking the setpoint -grecord(ao,"$(P)$(PID)SP_tweak") { - field(PREC,"3") -} - -grecord(calcout,"$(P)$(PID)SP_tweak_down") { - field(INPA,"$(P)$(PID)SP_tweak.VAL NPP NMS") - field(INPB,"$(P)$(PID).VAL NPP NMS") - field(CALC,"B-A") - field(OUT, "$(P)$(PID).VAL PP NMS") -} - -grecord(calcout,"$(P)$(PID)SP_tweak_up") { - field(INPA,"$(P)$(PID)SP_tweak.VAL NPP NMS") - field(INPB,"$(P)$(PID).VAL NPP NMS") - field(CALC,"B+A") - field(OUT, "$(P)$(PID).VAL PP NMS") -} - -# STOP logic -# This record turns off feedback -grecord(ao,"$(P)$(PID)Stop") { - field(VAL,"0") - field(OUT, "$(P)$(PID).FBON PP NMS") - field(FLNK,"$(P)$(PID)Stop2") -} - -# This record turns off the output -grecord(ao,"$(P)$(PID)Stop2") { - field(VAL,"0.0") - field(OUT, "$(OUT) PP NMS") -} diff --git a/athena/pid_control.template b/athena/pid_control.template deleted file mode 100644 index b4c06fc7a41642ab97cdc73817bf7455c54800a6..0000000000000000000000000000000000000000 --- a/athena/pid_control.template +++ /dev/null @@ -1,7 +0,0 @@ -file /target/pid_control.db -{ -pattern -{P, PID, INP, OUT, LOPR, HOPR, DRVL, DRVH, PREC, KP, KI, KD, SCAN} -{stdTest:, PID1, adc0, dac0, -10000, 10000, -50000, 50000, 3, 0.2, 3., 0., ".1 second"} -} - diff --git a/athena/startup.cmd b/athena/startup.cmd deleted file mode 100644 index b6425db9f2389105726232d352b9bbd0cde8e20f..0000000000000000000000000000000000000000 --- a/athena/startup.cmd +++ /dev/null @@ -1,6 +0,0 @@ -#dbLoadDatabase "../../dbd/athena.dbd" -#registerRecordDeviceDriver(pdbbase) -dbLoadRecords "a.db" -dbLoadTemplate "/target/pid_control.template" -#dbLoadRecords "/target/pid_control.db" -iocInit