#!../../bin/linux-x86/sioc-b044-fm01

## You may have to change sioc-b044-fm01 to something else
## everywhere it appears in this file

#< /afs/slac.stanford.edu/g/lcls/vol8/epics/iocTop/users/scondam/epics/ioc/FreqCounter/iocBoot/sioc-b044-fm01/envPaths
<  /afs/slac/g/lcls/epics/iocTop/FreqCounter/FreqCounter/iocBoot/sioc-b044-fm01/envPaths

## iocAdmin Setup
epicsEnvSet("ENGINEER","Shantha Condamoor") 
epicsEnvSet("LOCATION","RF Hut s20-5") 

#Soft IOCs only (can be longer than 40 characters): 
epicsEnvSet("STARTUP","/afs/slac/g/lcls/epics/iocCommon/sioc-b044-fm01") 
epicsEnvSet("ST_CMD","startup.cmd") 

cd ${TOP}

## Register all support components
dbLoadDatabase("dbd/freqCount.dbd",0,0)
freqCount_registerRecordDeviceDriver(pdbbase)

## Location of stream protocol files
epicsEnvSet "STREAM_PROTOCOL_PATH", "${TOP}/db"
##############################################################
# Add LAN box configuration before iocInit.
## Set up IOC/hardware links -- GPIB/LAN connection

# The LAN-GPIB gateway interface setup:
# VXI-11 is the standard for "GPIB over network".
# Some devices (e.g. newer oscilloscopes) support it natively, 
# other GPIB devices can be connected via a LAN-GPIB gateway. 

# require "stream"
#vxi11Configure ("port name", "ip address or host name", 1, default timeout, "gpibname")
# The LAN-GPIB gateway uses the "gpibname" hpib or gpib by default. 
##############################################################
vxi11Configure("bus2", "ioc-b044-fm01", 0, 0.0, "gpib0", 0)
asynSetOption("bus2",0,"rpctimeout","10")
##############################################################
# Network interface
# require "stream"
# drvAsynIPPortConfigure ("port name", "hostname or ip address:port")

#drvAsynIPPortConfigure ("bus2","ioc-b044-fm01:23",0,0,0)
##############################################################
# E5810Reboot("<ip_address>",0)


## Load record instances
#dbLoadRecords("db/xxx.db","user=scondamHost")
dbLoadRecords("db/iocAdmin.db", "IOC=sioc-b044-fm01") 
dbLoadRecords("db/Hp53181AB044.db")


cd ${TOP}/iocBoot/${IOC}
iocInit()

## Start any sequence programs
#seq sncxxx,"user=scondamHost"
