Cleanup, fix an issue reported by Kazuro Furukawa.
This commit is contained in:
@@ -23,7 +23,6 @@ TEMPLATES += top/iocApp/Makefile
|
||||
TEMPLATES += top/iocApp/Db/Makefile
|
||||
TEMPLATES += top/iocApp/src/Makefile
|
||||
TEMPLATES += top/iocApp/src/_APPNAME_Main.cpp
|
||||
TEMPLATES += top/iocApp/src/sncExample.stt
|
||||
|
||||
TEMPLATES += top/exampleApp/Makefile
|
||||
TEMPLATES += top/exampleApp/Db/Makefile
|
||||
|
||||
@@ -48,7 +48,7 @@ _APPNAME__SRCS_DEFAULT += _APPNAME_Main.cpp
|
||||
_APPNAME__SRCS_vxWorks += -nil-
|
||||
|
||||
# Add support from base/src/vxWorks if needed
|
||||
_APPNAME__OBJS_vxWorks += $(EPICS_BASE_BIN)/vxComLibrary
|
||||
#_APPNAME__OBJS_vxWorks += $(EPICS_BASE_BIN)/vxComLibrary
|
||||
|
||||
# Link in the code from the support library
|
||||
_APPNAME__LIBS += _APPNAME_Support
|
||||
|
||||
@@ -6,45 +6,34 @@ include $(TOP)/configure/CONFIG
|
||||
#=============================
|
||||
|
||||
#=============================
|
||||
# build an ioc application
|
||||
# Build the IOC application
|
||||
|
||||
PROD_IOC = _APPNAME_
|
||||
|
||||
# _APPNAME_.dbd will be created and installed
|
||||
DBD += _APPNAME_.dbd
|
||||
|
||||
# _APPNAME_.dbd will be made up from these files:
|
||||
_APPNAME__DBD += base.dbd
|
||||
#include definitions for any other support applications needed
|
||||
|
||||
# Include dbd files from all support applications:
|
||||
#_APPNAME__DBD += xxx.dbd
|
||||
|
||||
# <name>_registerRecordDeviceDriver.cpp will be created from <name>.dbd
|
||||
# Add all the support libraries needed by this IOC
|
||||
#_APPNAME__LIBS += xxx
|
||||
|
||||
# _APPNAME__registerRecordDeviceDriver.cpp derives from _APPNAME_.dbd
|
||||
_APPNAME__SRCS += _APPNAME__registerRecordDeviceDriver.cpp
|
||||
|
||||
# Build the main IOC entry point on workstation OSs.
|
||||
_APPNAME__SRCS_DEFAULT += _APPNAME_Main.cpp
|
||||
_APPNAME__SRCS_vxWorks += -nil-
|
||||
|
||||
#The following adds support from base/src/vxWorks
|
||||
_APPNAME__OBJS_vxWorks += $(EPICS_BASE_BIN)/vxComLibrary
|
||||
|
||||
#add a definition for each support application used by this application
|
||||
#_APPNAME__LIBS += xxx
|
||||
|
||||
#NOTES:
|
||||
# 1)It is not possible to build sncExample both as a component of _APPNAME_
|
||||
# and standalone. You must choose only one.
|
||||
# 2)To build sncExample SNCSEQ must be defined in <top>/configure/RELEASE
|
||||
|
||||
#The following builds sncExample as a component of _APPNAME_
|
||||
#_APPNAME__SRCS += sncExample.stt
|
||||
#_APPNAME__LIBS += seq pv
|
||||
# Add support from base/src/vxWorks if needed
|
||||
#_APPNAME__OBJS_vxWorks += $(EPICS_BASE_BIN)/vxComLibrary
|
||||
|
||||
# Finally link to the EPICS Base libraries
|
||||
_APPNAME__LIBS += $(EPICS_BASE_IOC_LIBS)
|
||||
|
||||
#The following builds sncExample as a standalone application
|
||||
#PROD_HOST += sncExample
|
||||
#sncExample_SNCFLAGS += +m
|
||||
#sncExample_SRCS += sncExample.stt
|
||||
#sncExample_LIBS += seq pv
|
||||
#sncExample_LIBS += $(EPICS_BASE_HOST_LIBS)
|
||||
|
||||
#===========================
|
||||
|
||||
include $(TOP)/configure/RULES
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#include "epicsExit.h"
|
||||
#include "epicsThread.h"
|
||||
#include "iocsh.h"
|
||||
|
||||
@@ -17,5 +18,6 @@ int main(int argc,char *argv[])
|
||||
epicsThreadSleep(.2);
|
||||
}
|
||||
iocsh(NULL);
|
||||
epicsExit(0);
|
||||
return(0);
|
||||
}
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
program sncExample
|
||||
float v;
|
||||
assign v to "{user}:xxxExample";
|
||||
monitor v;
|
||||
|
||||
ss ss1
|
||||
{
|
||||
state low
|
||||
{
|
||||
when(v>5.0)
|
||||
{
|
||||
printf("changing to high\n");
|
||||
} state high
|
||||
when(delay(.1))
|
||||
{
|
||||
} state low
|
||||
}
|
||||
state high
|
||||
{
|
||||
when(v<=5.0)
|
||||
{
|
||||
printf("changing to low\n");
|
||||
} state low
|
||||
when(delay(.1))
|
||||
{
|
||||
} state high
|
||||
}
|
||||
}
|
||||
@@ -8,14 +8,14 @@
|
||||
cd ${TOP}
|
||||
|
||||
## Register all support components
|
||||
dbLoadDatabase("dbd/_APPNAME_.dbd",0,0)
|
||||
_CSAFEAPPNAME__registerRecordDeviceDriver(pdbbase)
|
||||
dbLoadDatabase "dbd/_APPNAME_.dbd"
|
||||
_CSAFEAPPNAME__registerRecordDeviceDriver pdbbase
|
||||
|
||||
## Load record instances
|
||||
#dbLoadRecords("db/xxx.db","user=_USER_Host")
|
||||
|
||||
cd ${TOP}/iocBoot/${IOC}
|
||||
iocInit()
|
||||
iocInit
|
||||
|
||||
## Start any sequence programs
|
||||
#seq sncxxx,"user=_USER_Host"
|
||||
|
||||
@@ -6,13 +6,14 @@
|
||||
#< envPaths
|
||||
|
||||
## Register all support components
|
||||
dbLoadDatabase("../../dbd/_APPNAME_.dbd",0,0)
|
||||
_CSAFEAPPNAME__registerRecordDeviceDriver(pdbbase)
|
||||
dbLoadDatabase "dbd/_APPNAME_.dbd"
|
||||
_CSAFEAPPNAME__registerRecordDeviceDriver pdbbase
|
||||
|
||||
## Load record instances
|
||||
dbLoadRecords("../../db/_APPNAME_.db","user=_USER_")
|
||||
#dbLoadTemplate "db/_APPNAME_.substitutions"
|
||||
#dbLoadRecords "db/_APPNAME_.db", "user=_USER_"
|
||||
|
||||
iocInit()
|
||||
iocInit
|
||||
|
||||
## Start any sequence programs
|
||||
#seq snc_APPNAME_,"user=_USER_"
|
||||
#seq sncxxx, "user=_USER_"
|
||||
|
||||
@@ -8,22 +8,22 @@
|
||||
#< ../nfsCommands
|
||||
|
||||
cd topbin
|
||||
|
||||
## You may have to change _APPNAME_ to something else
|
||||
## everywhere it appears in this file
|
||||
|
||||
ld < _APPNAME_.munch
|
||||
|
||||
## Register all support components
|
||||
cd top
|
||||
dbLoadDatabase("dbd/_APPNAME_.dbd",0,0)
|
||||
_CSAFEAPPNAME__registerRecordDeviceDriver(pdbbase)
|
||||
dbLoadDatabase "dbd/_APPNAME_.dbd"
|
||||
_CSAFEAPPNAME__registerRecordDeviceDriver pdbbase
|
||||
|
||||
## Load record instances
|
||||
#dbLoadRecords("db/_APPNAME_.db","macro=value")
|
||||
#dbLoadTemplate("db/_APPNAME_.substitutions")
|
||||
#dbLoadTemplate "db/_APPNAME_.substitutions"
|
||||
#dbLoadRecords "db/_APPNAME_.db", "user=_USER_"
|
||||
|
||||
cd startup
|
||||
iocInit()
|
||||
iocInit
|
||||
|
||||
## Start any sequence programs
|
||||
#seq &sncExample,"user=_USER_"
|
||||
#seq &sncxxx, "user=_USER_"
|
||||
|
||||
Reference in New Issue
Block a user