Epics@GSI Webhome
direct copy from HADES wiki

Running Etrax Thresholds Control

Steps to compile code

  1. login to any hades machine as scs :
    • ssh lxg0434 -l scs
  2. change to etrax directory
    • cd /u/scs/epics_apps/EtraxTest
  3. run setup
    • . ./setup.sh
  4. make
    • make clean && make
  5. If successful, remove binary and copy code on target system's file server (you have to enter twice (correctly) the password of hadaq, copy the whole code block below)

    • ssh hadaq@lxhadesdaq '   
         if [ -d /var/diskless/etrax_fs/epics/epics_apps/EtraxTest/bin ];
         then
            rm -r /var/diskless/etrax_fs/epics/epics_apps/EtraxTest/bin;
         fi' &&
      echo removed binary &&
      scp -r /u/scs/epics_apps/EtraxTest/{bin,db,dbd,iocBoot} hadaq@lxhadesdaq.gsi.de:/var/diskless/etrax_fs/epics/epics_apps/EtraxTest/
       
  6. logout
    • exit

... or all together:

      ssh lxg0434 -l scs
      cd /u/scs/epics_apps/EtraxTest
      . ./setup.sh
      make clean && make
      ssh hadaq@lxhadesdaq '   
         if [ -d /var/diskless/etrax_fs/epics/epics_apps/EtraxTest/bin ];
         then
            rm -r /var/diskless/etrax_fs/epics/epics_apps/EtraxTest/bin;
         fi' &&
      echo removed binary &&
      scp -r /u/scs/epics_apps/EtraxTest/{bin,db,dbd,iocBoot} hadaq@lxhadesdaq.gsi.de:/var/diskless/etrax_fs/epics/epics_apps/EtraxTest/
       

That's all!

Steps to start up

Version for RPC test setup May/June 2008:

Use the script rpc_may08_epics_quickfix (local copy) provided by Michael Traxler on lxhadesdaq,
provided your correct st-RpcThreshold-S3TRBxxx--SubEventIdyyy.cmd startup files are prepared
(xxx: TRB number, yyy: SubEventId number):
  1. login to lxhadesdaq
    • ssh -l hadaq lxhadesdaq.gsi.de
  2. execute at any place rpc_may08_epics_quickfix
    start
    rpc_may08_epics_quickfix start
    stop
    rpc_may08_epics_quickfix stop

Basic/test/preparatory phase version

  1. login to your target machine (e.g. etrax023),(user: root)
      • telnet etrax023
    1. Change to iocboot directory of epics
      • cd /home/hadaq/epics/epics_apps/EtraxTest/iocBoot/iocetrax
    2. Provided your correct st-RpcThreshold-S3TRBxxx--SubEventIdyyy.cmd startup file is prepared, so first check in the current directory for st-RpcThreshold-S3TRBxxx--SubEventIdyyy.cmd
      (xxx: TRB number, yyy: SubEventId number),
      • ls
    3. Start the IOC
      • ../../bin/linux-cris_v32/EtraxTest st-RpcThreshold-S3TRB0--SubEventId809_master.cmd
    4. Keep it running.
      • DO NOT CLOSE THE WINDOW! (Other solution will come) (see solution above using internally screen)

Steps to restart

  1. Use one of those commands to stop the epics IOC application
    • exit , CTRL+Z
  2. Killall instances of EtraxTest (assuming you are the only user running EtraxTest)
    • killall -9 EtraxTest
  3. Restart:
    • ../../bin/linux-cris_v32/EtraxTest st-RpcThreshold-S3TRB0--SubEventId809.cmd

Caveats / Tips & Tricks

When copying with scp you have to look at the protocol ...

Sometimes the binaries stay write-only.
Therefore you should have been using ssh hadaq@lxhadesdaq 'rm -r /var/diskless/etrax_fs/epics/epics_apps/EtraxTest/bin retry it.

How do I know, that a new database file has been created when having performed the steps to compile ?

    • on linux:
      • have a look at the directory /u/scs/epics_apps/EtraxTest/db to the newest files of pattern ...SxTRBy...SubEvtIdz (x:sector, y:trb, z:id)
    • on etrax:
      • have a look at the directory /home/hadaq/epics/epics_apps/EtraxTest/db

In case you are using a new Combination of SECTORxTRBy and SubEventId abc ...

... then you have to create a new cmd file on the ETRAX using the script createCmdFile.sh on the TRB/ETRAX (if you cannot find it there, copy those local files to the corresponding directories)

steps to do:

      1. login to your target machine(s) (e.g. etrax023),(user: root)
        • telnet etrax023
      2. Change to iocboot directory of epics
        • cd /home/hadaq/epics/epics_apps/EtraxTest/iocBoot/iocetrax
      3. execute createCmdFile.sh
        • usage: $ createCmdFile.sh : will give you the help how to use it

-- PeterZumbruch - 27 May 2008

-- PeterZumbruch - 27 May 2008
Topic attachments
I Attachment Action Size Date Who Comment
createCmdFile.shsh createCmdFile.sh manage 3 K 2008-05-27 - 20:49 PeterZumbruch Script to create from template cmd files (v2)
st-RpcThreshold-SsTRBt--SubEventIdXXX.cmd.templatetemplate st-RpcThreshold-SsTRBt--SubEventIdXXX.cmd.template manage 865 bytes 2008-05-27 - 20:49 PeterZumbruch template file (v2)
Topic revision: r6 - 2011-07-14, PeterZumbruch - This page was cached on 2022-10-06 - 06:41.

This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding GSI Wiki? Send feedback | Legal notice | Privacy Policy (german)