Skip to content

Commit

Permalink
Merge pull request #54 from nikitinvv/master
Browse files Browse the repository at this point in the history
replaced hardcoded PVs with new tomoStream PVs
  • Loading branch information
decarlof committed Dec 21, 2022
2 parents 1a37785 + 36e168c commit e947699
Show file tree
Hide file tree
Showing 14 changed files with 760 additions and 217 deletions.
2 changes: 1 addition & 1 deletion iocBoot/iocTomoStream_2BM/start_medm
Original file line number Diff line number Diff line change
@@ -1 +1 @@
medm -x -macro "P=2bmb:,R=TomoStream:" ../../tomoStreamApp/op/adl/tomoStream.adl &
medm -x -macro "P=2bmb:,R=TomoStream:,BEAMLINE=tomoStream_2BM" ../../tomoStreamApp/op/adl/tomoStream.adl &
4 changes: 3 additions & 1 deletion iocBoot/iocTomoStream_2BM/start_tomostream.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,6 @@
# python -i start_tomostream.py
# The -i is needed to keep Python running, otherwise it will create the object and exit
from tomostream.tomostream_2bm import TomoStream_2BM
ts = TomoStream_2BM(["../../db/tomoStream_settings.req","../../db/tomoStream_settings.req"], {"$(P)":"2bmb:", "$(R)":"TomoStream:"})
ts = TomoStream_2BM(["../../db/tomoStream_settings.req",
"../../db/tomoStream_2BM_settings.req"],
{"$(P)":"2bmb:", "$(R)":"TomoStream:"})
11 changes: 9 additions & 2 deletions iocBoot/iocTomoStream_2BM/tomoStream.substitutions
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
file "$(TOP)/db/tomoStream.template"
{
pattern
{ P, R, TOMO_SCAN, IMAGE_P, DARK_PVA, FLAT_PVA, RECON_PVA, THETA_PVA, MCT_OPTICS}
{2bmb:, TomoStream:, 2bmb:TomoScanStream:, 2bmb:TomoScanStream:PvaPluginPVPrefix, 2bmb:TomoScanStream:StreamDarkFields, 2bmb:TomoScanStream:StreamFlatFields, 2bmb:TomoStream:StreamRecon, 2bmb:TomoScanStream:StreamTheta, 2bm:MCTOptics:}
{ P, R, TOMO_SCAN, IMAGE_P, DARK_PVA, FLAT_PVA, RECON_PVA, THETA_PVA}
{2bmb:, TomoStream:, 2bmb:TomoScanStream:, 2bmb:TomoScanStream:PvaPluginPVPrefix, 2bmb:TomoScanStream:StreamDarkFields, 2bmb:TomoScanStream:StreamFlatFields, 2bmb:TomoStream:StreamRecon, 2bmb:TomoScanStream:StreamTheta}
}

file "$(TOP)/db/tomoStream_2BM.template"
{
pattern
{ P, R, MCT_OPTICS, TOMO_0_DEG, TOMO_90_DEG, SAMPLE_Y, ROI_PLUGIN}
{2bmb:, TomoStream:, 2bm:MCTOptics:, 2bmS1:m2, 2bmS1:m1, 2bmb:m25, 2bmbSP1:ROI1:}
}
2 changes: 1 addition & 1 deletion iocBoot/iocTomoStream_7BM/start_medm
Original file line number Diff line number Diff line change
@@ -1 +1 @@
medm -x -macro "P=7bmtomo:,R=TomoStream:" ../../tomoStreamApp/op/adl/tomoStream.adl &
medm -x -macro "P=7bmtomo:,R=TomoStream:,BEAMLINE=tomoStream_7BM" ../../tomoStreamApp/op/adl/tomoStream.adl &
19 changes: 0 additions & 19 deletions tomoStreamApp/Db/tomoStream.template
Original file line number Diff line number Diff line change
Expand Up @@ -224,22 +224,3 @@ record(bo,"$(P)$(R)AbortRecon")
field(ZNAM,"No")
field(ONAM,"Yes")
}

##############################################
# Lens change synchronization with orthoslices
##############################################

record(bo,"$(P)$(R)LensChangeSync")
{
field(ZNAM,"No")
field(ONAM,"Yes")
}

################
# mctOptics
################

record(stringout, "$(P)$(R)MctOpticsPVPrefix")
{
field(VAL, "$(MCT_OPTICS)")
}
49 changes: 49 additions & 0 deletions tomoStreamApp/Db/tomoStream_2BM.template
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Database for EPICS PVS for tomography data streaming software
# This database contains all of the PVs used by the tomostream base class.

##############################################
# Lens change synchronization with orthoslices
##############################################

record(bo,"$(P)$(R)LensChangeSync")
{
field(ZNAM,"No")
field(ONAM,"Yes")
}

################
# mctOptics
################

record(stringout, "$(P)$(R)MctOpticsPVPrefix")
{
field(VAL, "$(MCT_OPTICS)")
}

##########################################################
# sample tomo0, tomo90 deg and translation motors PV names
##########################################################

record(stringout, "$(P)$(R)SampleTomo0degPVName")
{
field(VAL, "$(TOMO_0_DEG)")
}

record(stringout, "$(P)$(R)SampleTomo90degPVName")
{
field(VAL, "$(TOMO_90_DEG)")
}

record(stringout, "$(P)$(R)SampleYPVName")
{
field(VAL, "$(SAMPLE_Y)")
}

######################
# Roi Plugin PV Prefix
######################

record(stringout, "$(P)$(R)RoiPluginPVPrefix")
{
field(VAL, "$(ROI_PLUGIN)")
}
30 changes: 30 additions & 0 deletions tomoStreamApp/Db/tomoStream_2BM_settings.req
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# This file is used by autosave to determine what PVs to save
# It is also used by tomoStream to determine what PVs to create

# This file contains all of the PVs used by the tomostream base class.

# Lines that begin with #controlPV are not saved by autosave,
# but they are used by tomostream.
# These PVs are not saved in the tomostream configuration file.

##############################################
# Lens change synchronization with orthoslices
##############################################
$(P)$(R)LensChangeSync

################
# mctOptics
################
$(P)$(R)MctOpticsPVPrefix

##########################################################
# sample tomo0, tomo90 deg and translation motors PV names
##########################################################
$(P)$(R)SampleTomo0degPVName
$(P)$(R)SampleTomo90degPVName
$(P)$(R)SampleYPVName

######################
# Roi Plugin PV Prefix
######################
$(P)$(R)RoiPluginPVPrefix
10 changes: 0 additions & 10 deletions tomoStreamApp/Db/tomoStream_settings.req
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,3 @@ $(P)$(R)PixelSize
###################################
#controlPV $(P)$(R)StartRecon
#controlPV $(P)$(R)AbortRecon

##############################################
# Lens change synchronization with orthoslices
##############################################
$(P)$(R)LensChangeSync

################
# mctOptics
################
$(P)$(R)MctOpticsPVPrefix

0 comments on commit e947699

Please sign in to comment.