Tags:
view all tags
These instructions assume you have successfully installed and tested your software. See [[AMC13CppGettingStarted]] for instructions if you haven't | *Actions* | | [[#UpdateFirmware][Update Firmware]] | | [[#FakeDataReadout][Fake Data Readout]] | | [[#MultiConnect][Connect Multiple AMC13s]] | | [[#SingleFEDOL][Setup one 10Gb link to cms1 FEROL]] | For some instructions specific for Building 28 (at CERN), please go here: [[Building 28 Instructions]] #UpdateFirmware ---++Update Firmware using !AMC13Tool2 Make sure that you have the latest firmware files for both the Spartan and Kintex chips by downloading the latest '.mcs' files from [[http://ohm.bu.edu/~dzou/firmware.cgi][here]]. To be safe, download all of the MCS files for the latest versions (the tool will pick the correct file where there is more than one choice). Put the firmware files in your current directory. Use the *pk* command to program the T1 (Kintex) and *ps* to program the T2 (Spartan). Then use *reconfigureFPGAs* to force a reload from flash. Here is an example session where we program the Kintex and Spartan and then reload: <pre> [ehazen@cms1 amc13_mcs]$ ../tools/bin/AMC13Tool2.exe -c ../amc13/etc/amc13/connectionSN43.xml Using AMC13 software ver:30757 ><b><u>fv</u></b> # check current firmware versions Connected AMC13s *0: SN: 43 T1v: 0209 T2v: 0021 cf: ../amc13/etc/amc13/connectionSN43.xml ><b>pk</b> # program the Kintex chip_type not specified, using default from serial number... Searching for files with T1 and 7K325T... 1. AMC13T1v0x020d_7k325t.mcs Connect Multiple AMC13s Enter number for MCS file to select (0 to exit): 1 Programming against file: AMC13T1v0x020d_7k325t.mcs... Programming AMC13T1v0x020d_7k325t.mcs to flash address 0x400000... Erasing flash sector at address 0x400000 Erasing flash sector at address 0x440000 ... programming flash at address 0xee9e00 programming flash at address 0xe2e700 % done = 6 programming flash at address 0xd72f00 % done = 13 ... programming flash at address 0x564700 % done = 87 programming flash at address 0x4a8f00 % done = 94 ><b><u>ps</u></b> # program the Spartan chip_type not specified, using default from serial number... Searching for files with T2, and 6SLX25T... 1. AMC13T2v0x0021_6slx25t.mcs Enter number for MCS file to select (0 to exit): 1 Programming against file: AMC13T2v0x0021_6slx25t.mcs... Programming AMC13T2v0x0021_6slx25t.mcs to flash address 0x200000... Erasing flash sector at address 0x200000 Erasing flash sector at address 0x240000 ... programming flash at address 0x2c3b00 programming flash at address 0x208400 % done = 97 </pre> NOTE: The most recent versions of these program commands should automatically verify the relevant flash sector against the chosen firmware file, but if it does not, use 'vk' and 'vs' respectively for verifying the T1 and T2 (upon using the command select the new firmware file to check against what is programmed in flash). Be sure to verify flash sector prior to reconfiguring or power cycling. <pre> ><b><u>reconfigureFPGAs</u></b> # force reload from flash Best exit/restart tool after 10s or so ><b><u>q</u></b> [ehazen@cms1 amc13_mcs]$ ../tools/bin/AMC13Tool2.exe -c ../amc13/etc/amc13/connectionSN43.xml Using AMC13 software ver:30757 ><b><u>fv</u></b> # check versions again Connected AMC13s *0: SN: 43 T1v: 020d T2v: 0021 cf: ../amc13/etc/amc13/connectionSN43.xml > </pre> #FakeDataReadout ---+++ Fake Data Readout This recipe tells you how to generate fake events in the AMC13 and read them out over IPBus. Required equipment: * AMC13XG module installed in upper "MCH2" site in center of crate * SFP transceiver installed in TTC (bottom) site in AMC13XG * Loop-back optical fiber connected between Tx and Rx of TTC SFP Here's the recipe (example below is for SN 86, make sure use the IP address or connection files that correspond to your board): 1. Connect to the AMC13 either by connection file or by spartan (T2) IP address (assuming T1 IP address is 1 higher than the T2 address). <pre> [hazen@cms4 scripts]$ <b><u>AMC13Tool2.exe -c connectionSN86.xml</u></b> OR $ <b><u>AMC13Tool2.exe -c 192.168.1.82</u></b> Address table path "/home/hazen/work/amc13/amc13/etc/amc13" set from AMC13_ADDRESS_TABLE_PATH Using AMC13 software ver:32678 </pre> 2. Reset AMC13 (general and counter). <pre> > rg > rc </pre> 3. Enable link with fake events ('f') and TTC loopback ('t') options and start run (part of enable command by default). NOTE: If we are building fake events, these are generated internally, so in this case, the actual numbers denoted are unimportant. But when building events from actual AMCs, you would denote the slot numbers corresponding to the modules you will be reading event data from. <pre>http://cms1.bu.edu:33001/urn:xdaq-application:lid=12 ><b><u>en 1-4 f t</u></b> parsed list "1-4" as mask 0xf Enabling fake data Enabling TTS as TTC for loop-back AMC13 out of run mode AMC13 is back in run mode and ready </pre> 4. Set up local triggers. There are various options how you would like triggers to be sent (number of triggers per bunch, rate, etc.), for help use 'h localL1A'. In this example we will just send 1 trigger per orbit. <pre> ><b><u>localL1A o 1 1</u></b> Configure LocalL1A enabled mode=0 burst=1 rate=1 rules=0 </pre> 5. Send Triggers <pre> ><b><u>lt 5</u></b> detected number after 'lt' Sending 5 local triggers Trigger: 4 left Trigger: 3 left Trigger: 2 left Trigger: 1 left Trigger: 0 left </pre> 6. Use status command to check to see that L1As were sent+received and that events were built. <pre> ><b><u>st</u></b> Board| SERIALNO| T1_VER| T2_REV| T2_SERNO| --|---------|-------|-------|---------| INFO| 0x56| 0x400A| 0x21| 0x56| Control| DAQ| FAKE| LTRIG| RUN| TTCLOOP| --|----|-----|------|----|--------| REG_1| 0x0| 0x1| 0x1| 0x1| 0x1| AMC_Links| AMC01| AMC02| AMC03| AMC04| --|------|------|------|------| AMC_LINK_READY| 0x0| 0x0| 0x0| 0x0| LOSS_OF_SYNC| 0x1| 0x1| 0x1| 0x1| Event_Builder| COUNT| --|------| L1A| 0x5| Monitor_Buffer| COUNT| --|------| UNREAD_EVT| 0x5| State_Timers| COUNT| --|------------| BUSY| 0x000000001| OVERFLOW_WARNING| 0x000000001| READY| 0x1B8E4CA11| RUN| 0x1B8E4CA0F| TTC_Rx| ENC| RAW| --|----|----| STATE| RDY| RDY| </pre> 7. Read out events. <pre> ><b><u>re</u></b> calling readEvent...AOK Read 16400 words 0: 510000011f400008 1: 104401000060d780 2: 0f00100200010000 3: 0f00100200020000 4: 0f00100200030000 5: 0f00100200040000 6: 010000011f401002 7: 000700060d780000 8: 000b000a00090008 9: 000f000e000d000c ... 16395: 3fff3ffe3ffd3ffc 16396: 4003400240014000 16397: 7122902601001002 16398: 0f2fe8ab000011f4 16399: a0004010fc520000 > </pre> -- Main.EricHazen - 18 Nov 2014 #MultiConnect ---+++ Connect Multiple AMC13s This recipe tells you how to connect multiple AMC13s and how to send fake payloads from AMC13s in slots 1-12 to an AMC13 in the MCH slot. The AMC13s in slots 1-12 act as uHTRs. Required equipment: * AMC13XG module installed in upper "MCH2" site in center of crate * At least one AMC13XG installed in a slot 1-12 * SFP transceiver installed in TTC (bottom) site in all AMC13XGs* * Loop-back optical fiber connected between Tx and Rx of TTC SFP in all AMC13XGs* *The Loop-back for the AMC13XGs in slots 1-12 is for the TTS state to be sent to the backplane There are two ways to connect to multiple AMC13s. One is on the command line with AMC13Tool2, the other is inside AMC13Tool2: ----++First way When starting the tool: <pre> [cjjacob@cms4 amc] ./tools/bin/AMC13Tool2.exe -c 161 -c 303 use_ch false Created URI from IP address: T2: ipbusudp-2.0://192.168.2.188:50001 T1: ipbusudp-2.0://192.168.2.189:50001 Using AMC13 software ver:41103 use_ch false Created URI from IP address: T2: ipbusudp-2.0://192.168.3.160:50001 T1: ipbusudp-2.0://192.168.3.161:50001 Using AMC13 software ver:41103 > </pre> ----++Second Way Inside the tool, use the command <b>connect</b>: <pre> [cjjacob@cms4 amc] ./tools/bin/AMC13Tool2.exe -c 161 Address table path "/home/cjjacob/amc13/amc13/etc/amc13" set from AMC13_ADDRESS_TABLE_PATH use_ch true Created URI from IP address: T2: chtcp-2.0://localhost:10203?target=192.168.2.188:50001 T1: chtcp-2.0://localhost:10203?target=192.168.2.189:50001 Using AMC13 software ver:41103 >connect 303 use_ch false Created URI from IP address: T2: ipbusudp-2.0://192.168.3.160:50001 T1: ipbusudp-2.0://192.168.3.161:50001 Using AMC13 software ver:41103 > </pre> You can see which AMC13s are connected by using the <b>list (fv)</b> command. This also lists their firmware versions and serial numbers. You can select the active AMC13 (the one that will execute your commands) with the <b>selectAMC13 (sel)</b> command. <pre> >fv Connected AMC13s *0: SN: 161 T1v: 0244 T2v: 002e cf: 161 1: SN: 303 T1v: 100b T2v: 002a cf: 303 >sel 1 Setting default AMC13 to 1 </pre> The AMC13s you want to send fake payloads should have 0x1000 series T1 firmware and should be in slots 1-12 (not the MCH slot), which you can find in this [[http://ohm.bu.edu/~dzou/firmware.cgi][list of firmware]]. Check the Update Firmware recipe if you're not sure how to change the AMC13 firmware. If the AMC13 has the 0x1000 series firmware, you can control the fake payloads by setting a lower bound at register 0x18 and an upper bound at register 0x19, then performing a general reset. Example: <pre> >wv 0x18 0x400 Write to address 0X18 >wv 0x19 0x1200 Write to address 0X19 >wv 0 1 Write to address 0 </pre> if you are using HCAL firmware also write <pre> wv 0x17 0x80000000 </pre> will send fake payloads between 0x400 and 0x1200 64-bit words in size. After you've set all the fake payload sizes, return to the AMC13 in the MCH slot with the <b>sel</b> command. You must now enable the AMC13s that will send fake triggers with the <b>en</b> command using their slot number. In this example AMC13 SN 303 is in slot 2 of the crate. <pre> >en 2 t parsed list "2" as mask 0x2 Enabling TTS as TTC for loop-back AMC13 out of run mode AMC13 is back in run mode and ready </pre> Now, you can use the <b>lt</b> command to send local triggers. <pre> >lt 2 detected number after 'lt' Sending 2 local triggers Trigger: 0 left </pre> There are now unread events in the monitor buffer. ---+++ Connect AMC13 and a single 10Gb FEROL #SingleFEDOL Make two connections to cms1 as the daq user, and then in both terminals, cd to the local FEROL directory. First, setup the AMC13 by using the following commands in AMC13Tool2.exe <pre> rg rc en 1-12 f t daq 1 fed 0 100 localL1A o 1 1 </pre> Or you can just run "AMC13Tool2.exe -c 285/c -X amc13_script.txt" in the FEROL directory and it will run all of them for you. Then switch to the other terminal and type "./fedKit.py" into the terminal. It will ask you several questions, but the default values should be fine. Here is an example: <pre> [daq@cms1 FEROL]$ ./fedKit.py Welcome to the optical FEDkit ============================= Please select the data source to be used: 1 - AMC13 data source over 6Gb (L6G_SOURCE) 2 - Generator core of AMC13 over 6Gb (L6G_CORE_GENERATOR_SOURCE) 3 - Loopback at the FEROL (L6G_LOOPBACK_GENERATOR_SOURCE) 4 - AMC13 data source over 10Gb (L10G_SOURCE) 5 - Generator core of AMC13 over 10Gb (L10G_CORE_GENERATOR_SOURCE) 6 - SLINK data source (SLINK_SOURCE) => [4] Please enter the FED id you want to read out [100]: Do you want to write the data to disk? [No]: Starting run... </pre> The program will hang here for up to a minute, but then show the following command prompt: <pre> Running. Point your browser to http://cms1.bu.edu:33001 m display this Menu f# dump the next # FED fragments incl DAQ headers (default 1) e# dump the next # Events with FED data only (default 1) q stop the run and Quit => </pre> At this point you can go back to the AMC13 screen and type "lt 1" to send a trigger or two. You can monitor the status of the link in the AMC13Tool2.exe by typing "status" and looking at the SlinkExpress table. You can also monitor the FEROL by going to: http://cms1.bu.edu:33000/urn:xdaq-application:lid=11 and you can see if events are being built by going to: http://cms1.bu.edu:33001/urn:xdaq-application:lid=12 -- Main.ColinJacob - 10 Dec 2015
Edit
|
Attach
|
Watch
|
P
rint version
|
H
istory
:
r13
<
r12
<
r11
<
r10
<
r9
|
B
acklinks
|
V
iew topic
|
Raw edit
|
More topic actions...
Topic revision: r11 - 20 Apr 2016
-
DanielGastler
Home
Site map
BUCMSPublic web
Main web
Sandbox web
TWiki web
BUCMSPublic Web
Create New Topic
Index
Search
Changes
Notifications
RSS Feed
Statistics
Preferences
P
View
Raw View
Print version
Find backlinks
History
More topic actions
Edit
Raw edit
Attach file or image
Edit topic preference settings
Set new parent
More topic actions
Account
Log In
Register User
Edit
Attach
Copyright © 2008-2023 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki?
Send feedback