1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 <2023> 2024 2025 | Index | 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 <2023> 2024 2025 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: Compiling IOC with sequencer from scratch. seq command not found. |
From: | "Marco A. Barra Montevechi Filho via Tech-talk" <tech-talk at aps.anl.gov> |
To: | Mark Rivers <rivers at cars.uchicago.edu> |
Cc: | "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov> |
Date: | Fri, 20 Jan 2023 20:31:31 +0000 |
Solved.
After looking a little more in_depth into the compiled example i found: SoftCedApp/src/O.linux-x86_64/sncProgram.c: seqRegisterSequencerProgram (&sncExample); Compiling my incomplete IOC application without the dbd file i found the c code that comes from the stt file: ./SoftKinApp/src/O.linux-x86_64/Kinematics.c and it has:#include "epicsExport.h" static void imbuia_kinematicsRegistrar (void) {
seqRegisterSequencerCommands();
seqRegisterSequencerProgram (&imbuia_kinematics);
}
epicsExportRegistrar(imbuia_kinematicsRegistrar);So it became clear to me that the argument is the name of the program declared in the stt file, not the name of the file itself. Sorry for the confusion, thanks for your patience and time Marco From: Marco A. Barra Montevechi Filho <marco.filho at lnls.br>
Sent: 20 January 2023 17:18 To: Mark Rivers <rivers at cars.uchicago.edu> Cc: tech-talk at aps.anl.gov <tech-talk at aps.anl.gov> Subject: Re: Compiling IOC with sequencer from scratch. seq command not found. No, i didnt. Im unfortunately
not very familiar with this command.
Im looking at this documentation right now to try to understand exactly what it expects as argument: https://epics.anl.gov/base/R3-15/5-docs/AppDevGuide/IOCShell.html. It seems to me it creates the proper ioc shell function, which is exactly what i want. But its not clear to me where does the compilation gets the source from and what should my argument be. I added a file called Kinematics.dbd to my src folder, added SoftKin_DBD += Kinematics.dbd To my makefile, but whatever i try to put inside the .dbd file generates compilation error. I tried: registrar(sncExampleRegistrar) registrar(sncKinematics) registrar(sncKinematicsRegistrar) registrar(sncSoftKin) registrar(sncSoftKinRegistrar) etc... Compilation error: marco@docker:~/work/cnpem_git/IMB/SoftKin$ make make -C ./configure install
make[1]: Entering directory '/home/marco/work/cnpem_git/IMB/SoftKin/configure'
make -C O.linux-x86_64 -f ../Makefile TOP=../.. \
T_A=linux-x86_64 install
make[2]: Entering directory '/home/marco/work/cnpem_git/IMB/SoftKin/configure/O.linux-x86_64'
perl -CSD /usr/local/epics-nfs/base/R7.0.7/bin/linux-x86_64/convertRelease.pl checkRelease
make[2]: Leaving directory '/home/marco/work/cnpem_git/IMB/SoftKin/configure/O.linux-x86_64'
make[1]: Leaving directory '/home/marco/work/cnpem_git/IMB/SoftKin/configure'
make -C ./SoftKinApp install
make[1]: Entering directory '/home/marco/work/cnpem_git/IMB/SoftKin/SoftKinApp'
make -C ./src install
make[2]: Entering directory '/home/marco/work/cnpem_git/IMB/SoftKin/SoftKinApp/src'
make -C O.linux-x86_64 -f ../Makefile TOP=../../.. \
T_A=linux-x86_64 install
make[3]: Entering directory '/home/marco/work/cnpem_git/IMB/SoftKin/SoftKinApp/src/O.linux-x86_64'
Creating dbd file SoftKin.dbd
perl -CSD /usr/local/epics-nfs/base/R7.0.7/bin/linux-x86_64/dbdExpand.pl -I. -I.. -I../O.Common -I../../../dbd -I/usr/local/epics-nfs/base/R7.0.7/dbd -I/usr/local/epics-nfs/modules/R7.0.7/synApps_6_2/synApps/support/seq-2-2-9//dbd
-o SoftKin.dbd base.dbd Kinematics.dbd
perl -CSD /usr/local/epics-nfs/base/R7.0.7/bin/linux-x86_64/registerRecordDeviceDriver.pl -I. -I.. -I../O.Common -I../../../dbd -I/usr/local/epics-nfs/base/R7.0.7/dbd -I/usr/local/epics-nfs/modules/R7.0.7/synApps_6_2/synApps/support/seq-2-2-9//dbd
-o SoftKin_registerRecordDeviceDriver.cpp ../O.Common/SoftKin.dbd SoftKin_registerRecordDeviceDriver /home/marco/work/cnpem_git/IMB/SoftKin
/usr/bin/g++ -D_GNU_SOURCE -D_DEFAULT_SOURCE -D_X86_64_ -DUNIX -Dlinux -O3 -g -Wall -mtune=generic -m64 -I. -I../O.Common -I. -I. -I.. -I../../../include/compiler/gcc -I../../../include/os/Linux -I../../../include
-I/usr/local/epics-nfs/base/R7.0.7/include/compiler/gcc -I/usr/local/epics-nfs/base/R7.0.7/include/os/Linux -I/usr/local/epics-nfs/base/R7.0.7/include -I/usr/local/epics-nfs/modules/R7.0.7/synApps_6_2/synApps/support/seq-2-2-9//include -MM -MF SoftKin_registerRecordDeviceDriver.d
SoftKin_registerRecordDeviceDriver.cpp
Installing created dbd file ../../../dbd/SoftKin.dbd
/usr/bin/g++ -D_GNU_SOURCE -D_DEFAULT_SOURCE -D_X86_64_ -DUNIX -Dlinux -O3 -g -Wall -mtune=generic -m64 -I. -I../O.Common -I. -I. -I.. -I../../../include/compiler/gcc -I../../../include/os/Linux -I../../../include
-I/usr/local/epics-nfs/base/R7.0.7/include/compiler/gcc -I/usr/local/epics-nfs/base/R7.0.7/include/os/Linux -I/usr/local/epics-nfs/base/R7.0.7/include -I/usr/local/epics-nfs/modules/R7.0.7/synApps_6_2/synApps/support/seq-2-2-9//include -c SoftKin_registerRecordDeviceDriver.cpp
/usr/bin/g++ -o SoftKin -L/home/marco/work/cnpem_git/IMB/SoftKin/lib/linux-x86_64 -L/usr/local/epics-nfs/base/R7.0.7/lib/linux-x86_64 -L/usr/local/epics-nfs/modules/R7.0.7/synApps_6_2/synApps/support/seq-2-2-9/lib/linux-x86_64
-Wl,-rpath,/home/marco/work/cnpem_git/IMB/SoftKin/lib/linux-x86_64 -Wl,-rpath,/usr/local/epics-nfs/base/R7.0.7/lib/linux-x86_64 -Wl,-rpath,/usr/local/epics-nfs/modules/R7.0.7/synApps_6_2/synApps/support/seq-2-2-9/lib/linux-x86_64 -rdynamic -m64
SoftKin_registerRecordDeviceDriver.o Kinematics.o SoftKinMain.o -lseq -lpv -ldbRecStd -ldbCore -lca -lCom
/usr/bin/ld: SoftKin_registerRecordDeviceDriver.o: in function `SoftKin_registerRecordDeviceDriver':
/home/marco/work/cnpem_git/IMB/SoftKin/SoftKinApp/src/O.linux-x86_64/SoftKin_registerRecordDeviceDriver.cpp:280: undefined reference to `pvar_func_sncExampleRegistrar'
collect2: error: ld returned 1 exit status
make[3]: *** [/usr/local/epics-nfs/base/R7.0.7/configure/RULES_BUILD:231: SoftKin] Error 1
make[3]: Leaving directory '/home/marco/work/cnpem_git/IMB/SoftKin/SoftKinApp/src/O.linux-x86_64'
make[2]: *** [/usr/local/epics-nfs/base/R7.0.7/configure/RULES_ARCHS:58: install.linux-x86_64] Error 2
make[2]: Leaving directory '/home/marco/work/cnpem_git/IMB/SoftKin/SoftKinApp/src'
make[1]: *** [/usr/local/epics-nfs/base/R7.0.7/configure/RULES_DIRS:85: src.install] Error 2
make[1]: Leaving directory '/home/marco/work/cnpem_git/IMB/SoftKin/SoftKinApp'
make: *** [/usr/local/epics-nfs/base/R7.0.7/configure/RULES_DIRS:85: SoftKinApp.install] Error 2From: Mark Rivers <rivers at cars.uchicago.edu>
Sent: 20 January 2023 16:52 To: Marco A. Barra Montevechi Filho <marco.filho at lnls.br> Cc: tech-talk at aps.anl.gov <tech-talk at aps.anl.gov> Subject: RE: Compiling IOC with sequencer from scratch. seq command not found. Did you remember to add the registrar command for your sequencer program to your application dbd file?
From: Tech-talk <tech-talk-bounces at aps.anl.gov>
On Behalf Of Marco A. Barra Montevechi Filho via Tech-talk
Hello all, good evening. SNCSEQ = /usr/local/epics-nfs/modules/R7.0.7/synApps_6_2/synApps/support/seq-2-2-9/
# Set RULES here if you want to use build rules from somewhere # other than EPICS_BASE: #RULES = $(MODULES)/build-rules
# These lines allow developers to override these RELEASE settings # without having to modify this file directly. -include $(TOP)/../RELEASE.local -include $(TOP)/../RELEASE.$(EPICS_HOST_ARCH).local -include $(TOP)/configure/RELEASE.local
include $(TOP)/configure/CONFIG #---------------------------------------- # ADD MACRO DEFINITIONS AFTER THIS LINE #=============================
#============================= # Build the IOC application
PROD_IOC = SoftKin # SoftKin.dbd will be created and installed DBD += SoftKin.dbd
# SoftKin.dbd will be made up from these files: SoftKin_DBD += base.dbd
# Include dbd files from all support applications: #SoftKin_DBD += xxx.dbd
# Add all the support libraries needed by this IOC #SoftKin_LIBS += xxx
# SoftKin_registerRecordDeviceDriver.cpp derives from SoftKin.dbd SoftKin_SRCS += SoftKin_registerRecordDeviceDriver.cpp ####SoftKin_SRCS += Kinematics.stt
# Build the main IOC entry point on workstation OSs. SoftKin_SRCS_DEFAULT += SoftKinMain.cpp SoftKin_SRCS_vxWorks += -nil-
# Add support from base/src/vxWorks if needed #SoftKin_OBJS_vxWorks += $(EPICS_BASE_BIN)/vxComLibrary
#####ADD Sequencer #SoftKin_DBD += #SoftKinSupport_LIBS += seq pv SoftKin_SRCS += Kinematics.stt SoftKin_LIBS += seq pv
# Finally link to the EPICS Base libraries SoftKin_LIBS += $(EPICS_BASE_IOC_LIBS) #SoftKin_LIBS += seq pv
#===========================
include $(TOP)/configure/RULES #---------------------------------------- # ADD RULES AFTER THIS LINE
#- You may have to change SoftKin to something else #- everywhere it appears in this file
< envPaths
cd "${TOP}"
## Register all support components dbLoadDatabase "dbd/SoftKin.dbd" SoftKin_registerRecordDeviceDriver pdbbase
## Load record instances #dbLoadRecords("db/SoftKin.db","user=marco") dbLoadTemplate("${TOP}/SoftKinApp/Db/Kinematics.substitutions")
cd "${TOP}/iocBoot/${IOC}" iocInit
## Start any sequence programs seq Kinematics,"BLP=SOL:,HP=S:,MP=m1"
Aviso Legal: Esta mensagem e seus anexos podem conter informações confidenciais e/ou de uso restrito. Observe atentamente seu conteúdo e considere eventual consulta ao remetente antes de copiá-la, divulgá-la ou distribuí-la. Se você recebeu esta mensagem por engano, por favor avise o remetente e apague-a imediatamente. Disclaimer: This email and its attachments may contain confidential and/or privileged information. Observe its content carefully and consider possible querying to the sender before copying, disclosing or distributing it. If you have received this email by mistake, please notify the sender and delete it immediately. |