This section is under revision to better reflect the latest installation and basic operation of the Midas package.
... This section will... describes step-by-step the installation procedure of the Midas package on several platform as well as the procedure to run a demo sample experiment. In a second stage, the frontend or the analyzer can be moved to another computer to test the remote connection capability.
The Midas Package source and binaries can be found at : PSI or at TRIUMF . An online SVN web site is also available for the latest developments.
Even though Midas is available for multiple platforms, the following description are for Linux installation and Windows installation.
cd /home/mydir tar -zxvf midas-1.9.x.tar.gz
>ls COPYING doc/ examples/ include/ linux/ makefile.nt mscb/ utils/ CVS/ drivers/ gui/ java/ Makefile* mcleanup* src/ vxworks/
svn co svn+ssh://svn@savannah.psi.ch/afs/psi.ch/project/meg/svn/midas/trunk midas svn co svn+ssh://svn@savannah.psi.ch/afs/psi.ch/project/meg/svn/mxml/trunk mxml
svn co svn+ssh://svn@savannah.psi.ch/afs/psi.ch/project/meg/svn/rome/trunk rome
cvs -d anoncvs@midas.triumf.ca:/usr/local/cvsroot checkout roody
cd /home/mydir/midas su - make install
# midas service midas 1175/tcp # Midas server
service midas { flags = REUSE NOLIBWRAP socket_type = stream wait = no user = root server = /usr/local/bin/mserver log_on_success += USERID HOST PID log_on_failure += USERID HOST disable = no }
/usr/local/lib
# # Midas experiment list midas /home/midas/online midas decay /home/slave/decay_daq slave
> cd /home/mydir/midas > make cc -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/midas.o src/midas.c cc -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/system.o src/system.c cc -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/mrpc.o src/mrpc.c cc -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/odb.o src/odb.c cc -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/ybos.o src/ybos.c cc -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/ftplib.o src/ftplib.c rm -f linux/lib/libmidas.a ar -crv linux/lib/libmidas.a linux/lib/midas.o linux/lib/system.o linux/lib/mrpc.o linux/lib/odb.o linux/lib/ybos.o linux/lib/ftplib.o a - linux/lib/midas.o a - linux/lib/system.o a - linux/lib/mrpc.o a - linux/lib/odb.o a - linux/lib/ybos.o a - linux/lib/ftplib.o rm -f linux/lib/libmidas.so ld -shared -o linux/lib/libmidas.so linux/lib/midas.o linux/lib/system.o linux/lib/mrpc.o linux/lib/odb.o linux/lib/ybos.o linux/lib/ftplib.o -lutil -lpthread -lc cc -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/mana.o src/mana.c cc -Dextname -DHAVE_HBOOK -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/hmana.o src/mana.c ... g++ -DHAVE_ROOT -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -D_REENTRANT -I/home1/midas/ root/include -o linux/lib/rmana.o src/mana.c g++ -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINU -fPIC -o linux/lib/mfe.o src/mfe.c cc -Dextname -c -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/lib/fal.o src/fal.c ... cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mserver src/mserver.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mhttpd src/mhttpd.c src/mgd.c -lmidas -lutil -lpthread -lm g++ -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -DHAVE_ROOT -D_REENTRANT -I/home1/midas/root/include -o linux/bin/mlogger src/mlogger.c -lmidas -L/home1/midas/root/lib -lCore -lCint -lHist -lGraf -lGraf3d -lGpad -lTree -lRint -lPostscript -lMatrix -lPhysics -lpthread -lm -ldl -rdynamic -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/odbedit src/odbedit.c src/cmdedit.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mtape utils/mtape.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mhist utils/mhist.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mstat utils/mstat.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mcnaf utils/mcnaf.c drivers/bus/camacrpc.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mdump utils/mdump.c -lmidas -lz -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/lazylogger src/lazylogger.c -lmidas -lz -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mchart utils/mchart.c -lmidas -lutil -lpthread cp -f utils/stripchart.tcl linux/bin/. cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/webpaw utils/webpaw.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/odbhist utils/odbhist.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/melog utils/melog.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/mlxspeaker utils/mlxspeaker.c -lmidas -lutil -lpthread cc -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -o linux/bin/dio utils/dio.c -lmidas -lutil-lpthread g++ -g -O2 -Wall -Iinclude -Idrivers -Llinux/lib -DINCLUDE_FTPLIB -DOS_LINUX -fPIC -DHAVE_ROOT -D_REENTRANT -I/home1/midas/root/include -o linux/bin/rmidas src/rmidas.c -lmidas -L/home1/midas/root/lib -lCore -lCint -lHist -lGraf -lGraf3d -lGpad -lTree -lRint -lPostscript -lMatrix -lPhysics -lGui -lpthread -lm -ldl -rdynamic -lutil -lpthread
#------------------------------------------------------------------- # The following lines define direcories. Adjust if necessary # DRV_DIR = ../../drivers/bus INC_DIR = ../../include LIB_DIR = ../../linux/lib
#------------------------------------------------------------------- # The following lines define direcories. Adjust if necessary # DRV_DIR = /home/mydir/midas/drivers/bus INC_DIR = /usr/local/include LIB_DIR = /usr/local//lib
> cd /home/mydir/midas/examples/experiment > make gcc -g -O2 -Wall -g -I../../include -I../../drivers/bus -DOS_LINUX -Dextname -c -o camacnul.o ../../drivers/bus/camacnul.c g++ -g -O2 -Wall -g -I../../include -I../../drivers/bus -DOS_LINUX -Dextname -o frontend frontend.c camacnul.o ../../linux/lib/mfe.o ../../linux/lib/libmidas.a -lm -lz -lutil -lnsl -lpthread g++ -D_REENTRANT -I/home1/midas/root/include -DHAVE_ROOT -g -O2 -Wall -g -I../../include -I../../drivers/bus -DOS_LINUX -Dextname -o analyzer.o -c analyzer.c g++ -D_REENTRANT -I/home1/midas/root/include -DHAVE_ROOT -g -O2 -Wall -g -I../../include -I../../drivers/bus -DOS_LINUX -Dextname -o adccalib.o -c adccalib.c g++ -D_REENTRANT -I/home1/midas/root/include -DHAVE_ROOT -g -O2 -Wall -g -I../../include -I../../drivers/bus -DOS_LINUX -Dextname -o adcsum.o -c adcsum.c g++ -D_REENTRANT -I/home1/midas/root/include -DHAVE_ROOT -g -O2 -Wall -g -I../../include -I../../drivers/bus -DOS_LINUX -Dextname -o scaler.o -c scaler.c g++ -o analyzer ../../linux/lib/rmana.o analyzer.o adccalib.o adcsum.o scaler.o ../../linux/lib/libmidas.a -L/home1/midas/root/lib -lCore -lCint -lHist -lGraf -lGraf3d -lGpad -lTree -lRint -lPostscript -lMatrix -lPhysics -lpthread -lm -ldl -rdynamic -lThread -lm -lz -lutil -lnsl -lpthread >
> frontend Event buffer size : 100000 Buffer allocation : 2 x 100000 System max event size : 524288 User max event size : 10000 User max frag. size : 5242880 # of events per buffer : 10 Connect to experiment ...Available experiments on local computer: 0 : midas 1 : root Select number:0 <---- predefined experiment from exptab file Sample Frontend connected to <local>. Press "!" to exit 17:27:47 ================================================================================ Run status: Stopped Run number 0 ================================================================================ Equipment Status Events Events/sec Rate[kB/s] ODB->FE FE->ODB -------------------------------------------------------------------------------- Trigger OK 0 0.0 0.0 0 0 Scaler OK 0 0.0 0.0 0 0
>odbedit Available experiments on local computer: 0 : midas 1 : root Select number: 0 [local:midas:S]/>start now Starting run #1 17:28:58 [ODBEdit] Run #1 started [local:midas:R]/>
Sample Frontend connected to <local>. Press "!" to exit 17:29:07
================================================================================
Run status: Running Run number 1
================================================================================
Equipment Status Events Events/sec Rate[kB/s] ODB->FE FE->ODB
--------------------------------------------------------------------------------
Trigger OK 865 99.3 5.4 0 9
Scaler OK 1 0.0 0.0 0 1
Components - Top - Internal features