[Date Prev][Date Next][Date Index]

Re: spec, EPICS, and 'the energy'




Pete,

With Jonathan Lang at SRI-CAT, I've modified the standard spec energy  
macros to work with their Kohzu monochromator.  The macros calculate the  
proper positions and move the motors directly rather than use the  
energy-related EPICS process variables.  (Only a dozen or two lines of  
macro code had to be added or modified to make it work.)  I assume the  
ENERGY process variable would still reflect the current energy, as the new  
motor positions ought to trigger the record processing for that.

From the comments in the latest version of 'energy.mac':

# The macros in this file support various energy-selecting monochromators.
# Motor mnemonics present in the config file determine which monochromator
# calculations are used as follows:
#
#       monu or mono                            (type 1)
#               - selects a single-motor monochromator
#
#       mono, mon_y, mon_z                      (type 2)
#               - selects a three-motor monochromator such as from Kohzu,
#                 as used at several APS beamlines.  The g_mo_s parameter
#                 specifies the offset.  The mono_flag parameter selects
#                 between two configurations.
#
#       monu, mond and montrav                  (type 3)
#               - selects a three-motor monochromator that uses the
#                 g_mo_s parameter to specify the offset between crystals
#
#       monu, mond, montrav and monoff          (type 4)
#               - selects a four-motor monochromator

If that's what you need, let me know.  (I've fixed a few more  
spec-to-epics related glitches since your version, so you ought to get  
updated anyway.  Plus I've just got spec's epics_get() and epics_put()  
channel access functions working with arrays.)

-----------------------------------------------------------------
Gerry Swislow                       phone:  (617) 576-1610
Certified Scientific Software         fax:  (617) 497-4242
PO Box 390640                       email:  gerry@certif.com
Cambridge, MA  02139-0007             Web:  http://www.certif.com