#!../../../bin/linuxRT-x86_64/Klystron
#==============================================================
#
#  Abs:  EPICS Startup Script for Klystron Station 10-2 (Dev in B15)
#
#  Name: st.cmd
#
#  Facility:  FACET-II Klystron Controls
#
#  Auth: 26-Nov-2018, Kristi Luchini  (LUCHINI)
#  Rev:  dd-mmm-yyyy, Reviewer's Name (USERNAME)
#--------------------------------------------------------------
#  Mod:
#       10-Jul-2023, M. Puckett       (jmpdude):
#         Moved from replicating FACET-II 10-3 to replicating 10-2,
#         moved this sioc to slot 2 from slot 4, and updated to the most
#         recent firmware (gen2/242 hash).
#       03-Jul-2023, M. Puckett       (jmpdude):
#         Per Sonya's suggestion, put the non-sioc-specific variables
#         back to their equivalents for 10-3 so that their screens in
#         FACETHOME could be seen, as is, in the dev environment.
#       30-Jun-2023, M. Puckett       (jmpdude):
#         Adding sioc-b15-ky02, cloned from sioc-li10-ky03, for
#         teststand in B15.
#       27-Oct-2020, K. Luchini       (luchini):
#         add init_seq.cmd
#       24-Sep-2020, K. Luchini       (luchini):
#         add macro DEV
#       27-Aug-2020, K. Luchini       (luchini):
#         restore macros STN and LOCA for sequences
#       21-Aug-2020, K. Luchini       (luchini):
#         add init_llrfAmc.cmd,init_llrf.cmd
#         add YAML_DIR, YAML_FILE env var
#         remove macro STN and LOCA
#         move common section to iocBoot/common/st.cmd.llrf
#         comment out the sequence for now.
#       09-Dec-2019, K. Luchini       (luchini):
#         add caPutLogInit
#       25-Apr-2019, K. Luchini       (LUCHINI):
#         move from iocBoot/<ioc> to iocBoot/facet/<ioc>
#
#==============================================================
#
# Set environment variables
epicsEnvSet("LOCA"              ,"LI10")
epicsEnvSet("STN"               ,"2")
epicsEnvSet("DEV"               ,"KLYS:${LOCA}:$(STN)1")
epicsEnvSet("IOC_NAME"          ,"SIOC:B15:KY02")
epicsEnvSet("LOCATION"          ,"cpu-b15-ky01")
epicsEnvSet("BOARD_IP"          ,"10.0.1.102")
epicsEnvSet("YAML_DIR"          ,"${IOC_DATA}/${IOC}/yaml")
epicsEnvSet("YAML_FILE"         ,"${YAML_DIR}/000TopLevel.yaml")
epicsEnvSet("YAML_DEFAULTS_FILE","${YAML_DIR}/config/defaults.yaml")
epicsEnvSet("YAML_LOCAL_DIR"    ,"firmware/llrf-hls/hash-24213c2/yaml_local/LlrfGen2")

# Load generic environment variables and databases
< ../../common/st.cmd.linuxRT
< iocBoot/common/st.cmd.llrf
< iocBoot/common/init_seq.cmd

# End of script
