]> jspc29.x-matter.uni-frankfurt.de Git - daqtools.git/commitdiff
added padiwa option
authorECal Group <hadaq@cbmpc026.gsi.de>
Thu, 24 Sep 2015 12:00:54 +0000 (14:00 +0200)
committerECal Group <hadaq@cbmpc026.gsi.de>
Thu, 24 Sep 2015 12:00:54 +0000 (14:00 +0200)
thresholds/write_thresholds.pl
users/gsi_dlab_cbmpc26/first.C
users/gsi_dlab_cbmpc26/start_readout.pl
users/gsi_dlab_cbmpc26/startup_trb046.sh

index c0ef4f22ca16b990bb98b6dbfa8e0440cf33055a..93a02c75c4d8ffbb4b362c9a6fe0fc3f6b32e739 100755 (executable)
@@ -10,10 +10,12 @@ use POSIX qw(strftime);
 
 my $offset = 0;
 my $help;
+my $mode="padiwa";
 
 my $result = GetOptions (
     "h|help" => \$help,
     "o|offset=s" => \$offset,
+    "m|mode=s" => \$mode,
     );
 
 if($help) {
index 884384746c7e89728fa8353ec4eca0a986d243f8..ce4b0ab1adef678dea466ac2b09369b21fa998d3 100644 (file)
@@ -60,7 +60,7 @@ void first()
          //tdc->SetRefChannel(36, 35, 0xffff, 10000,  -500., 500., true);
 
         tdc->SetRefChannel(35, 33, 0xffff, 10000,  -10., 400., true);
-        tdc->SetRefChannel(36, 35, 0xffff, 10000,  -10., 400., true);
+        tdc->SetRefChannel(36, 33, 0xffff, 10000,  -10., 400., true);
          // IMPORTANT: for both channels references should be already specified
          tdc->SetDoubleRefChannel(36, 35, 1000, -10., 500., 1000, -10., 200.);
       }
@@ -70,7 +70,8 @@ void first()
        tdc->CreateHistograms( channels );
        tdc->SetRefChannel(1, 3, 0xffff, 10000,  -50., 50., true);
        tdc->SetRefChannel(2, 4, 0xffff, 10000,  -50., 50., true);
-
+       
+       tdc->SetDoubleRefChannel(1, 2, 1000, -100., 100., 1000, -100., 100.);
       }
 
 
index 09b0c39cfa2ad6d80093ae9d0c23f4039260bb54..2f8d15a5bf9397ee49d20fe6328a57e72d85156d 100755 (executable)
@@ -12,8 +12,8 @@ $c=q|pkill -f "daq_netmem -m 1"|;
 qx($c);
 
 
-$c=q|xterm -geometry 122x14-0+0 -e bash -c 'daq_evtbuild -m 1 -d file -o /tmp'|;
+$c=q|xterm -geometry 122x14-0+0 -e bash -c 'daq_evtbuild -m 1 -xte -d file -o /data/daq/'|;
 system("$c &");
 sleep 1;
-$c="xterm -geometry 82x10-0+210 -e bash -c 'daq_netmem -m 1 -i UDP:127.0.0.1:50000'";
+$c="xterm -geometry 82x10-0+210 -e bash -c 'daq_netmem -m 1 -i UDP:127.0.0.1:50001'";
 system("$c &");
index c1e08f311d9da71cbe47641c285cff16ba3b0020..0f2a69625bad618f1d3293770854397cadf6213a 100755 (executable)
@@ -7,11 +7,13 @@ xset -b
 ##### TRBNET #####
 # set the TRBNet addresses of the Endpoints
 
-trbcmd s 0xb000000390381d28 0 0x0200
-trbcmd s 0xa300000390381328 1 0x0201
-trbcmd s 0x4800000390381628 2 0x0202
-trbcmd s 0x1700000390382028 3 0x0203
-trbcmd s 0xdc00000390380c28 5 0x8000
+#trbcmd s 0xb000000390381d28 0 0x0200
+#trbcmd s 0xa300000390381328 1 0x0201
+#trbcmd s 0x4800000390381628 2 0x0202
+#trbcmd s 0x1700000390382028 3 0x0203
+#trbcmd s 0xdc00000390380c28 5 0x8000
+
+~/trbsoft/daqtools/merge_serial_address.pl ~/trbsoft/daqtools/base/serials_trb3.db ~/trbsoft/daqtools/base/addresses_trb3.db  > /dev/null
 
 ##### Ethernet and UDP #######
 trbcmd w 0x8000 0x8300 0x8000          # SubeventId         
@@ -34,8 +36,8 @@ trbcmd w 0x8000 0x8101 0x90f6 #upper byte
 
 
 # destination port and source IP and so on
-trbcmd w 0x8000 0x8102 0xc0a80001     # destination IP-address: 192.168.0.1 
-trbcmd w 0x8000 0x8103 0xc350         # destination port                 
+trbcmd w 0x8000 0x8102 0xc0a80002     # destination IP-address: 192.168.0.2
+trbcmd w 0x8000 0x8103 0xc351         # destination port                 
 trbcmd w 0x8000 0x8104 0xdead8001     # source MAC-address               
 trbcmd w 0x8000 0x8105 0x0230         # source MAC: upper bytes                  
 trbcmd w 0x8000 0x8106 0xc0a80072     # source IP                        
@@ -46,19 +48,21 @@ trbcmd w 0x8000 0x8108 0x0578         # MTU
 #####  TDC  #######
 # 0xfe48 is the broadcast address of TDC-endpoints in the system
 trbcmd w 0xfe48 0xc800 0x00000001 ## logic analyser control register
-trbcmd w 0xfe48 0xc801 0x020f0205 ## trigger window enable & trigger window width
+trbcmd w 0xfe48 0xc801 0x81000100 ## trigger window enable & trigger window width
 trbcmd w 0xfe48 0xc802 0x00000000 ## channel 01-31 enable
 trbcmd w 0xfe48 0xc803 0x00000000 ## channel 32-63 enable
-trbcmd w 0xfe48 0xc804 0x00000008 ## enable number of words
+trbcmd w 0xfe48 0xc804 0x00000080 ## enable number of words
 
 
-trbcmd w 0x0200 0xc802 0x0000000f ## channel 01-4  enable
+trbcmd w 0x8a00 0xc802 0x00000000 ## channel 01-4  enable
+trbcmd w 0x8a00 0xc803 0xffffffff ## channel 32-63 enable
 
-#trbcmd w 0x0200 0xc803 0xffffffff ## channel 32-63 enable
+trbcmd w 0x8a03 0xc802 0x0000003f ## channel 01-4  enable
+trbcmd w 0x8a03 0xc803 0x00000000 ## channel 32-63 enable
 
 trbcmd w 0x8000 0xa140 0xffff  #set CTS pulser to 100Hz
 
-trbcmd setbit 0x8000 0xa101 0x2 #enable pulser channel 0
+trbcmd setbit 0x8000 0xa101 0x80 #enable trigger3
 
 ##### to disable/enable specific peripheral FPGAs ####
 # trbcmd w 0x8000 0xc0 0xf1
@@ -67,6 +71,7 @@ trbcmd setbit 0x8000 0xa101 0x2 #enable pulser channel 0
 
 
 # invert inputs, as input pulse is negative
-~/trbsoft/daqtools/tools/padiwa.pl 0x200 1 invert 0xaaaa  
+~/trbsoft/daqtools/tools/padiwa.pl 0x8a00 0 invert 0xaaaa 
+~/trbsoft/daqtools/tools/padiwa.pl 0x8a00 1 invert 0xaaaa