DS Operations

From DaqWiki
Jump to navigation Jump to search

CDM and GDM

CDM ODB Keys

/Equipment/CDMxx/Settings/

Key Description Notes
Example Example Example
Example Example Example
Example Example Example

bad CDM or VX link status

GDM-CDM-VX status page shows some channels with bad link status

On the GDM-CDM-VX status page, ports in the CDM VX LVDS port table can have various link statuses.

Link status descriptions
cdm link status rx connection (transmitting to vx module)
vx link status tx connection (receiving from vx module)
vx link rx data 0x1c and 0xbc are idle characters. We expect these to flip flop.

The status codes are as follows:

Status codes
Code Binary Interpretation
0 0000 ??
1 0001 Sending idle characters ok but receiving bad characters?
3 0011 Sending and receiving idle characters. Data flip flops between 0x1c and 0xbc
8 1000 No transmission - link fully broken

The link timings need to be adjusted. These are done in the ODB: /Equipment/CDMxx/Settings/vx_tx_delay_common and /Equipment/CDMxx/Settings/vx_rx_delay_common. This shifts the phase of all the links from the CDM. To find the correct settings ssh into the CDM as root. Then run the following, depending on which links is bad:

RX Phase Scan

root@cdm203:~# ./test_cdm.exe --vx-rx-phase-scan
dsdm_open: mapping /dev/mem at 0x80010000
dsdm_open: FPGA build: 0xc4b4a086
DS-DM firmware build 0xc4b4a086, board id 0x204d4443 (CDM), top level version 0x20260922
VX_RX delays phase scan...
VX-RX delays scan: tap   0, ddr 0, d:  0, vx link status 0x8833 0x33333111, all good: 1, good links: 10, delay 0x00000000 (0.000 ns)
VX-RX delays scan: tap 200, ddr 0, d:  0, vx link status 0x8833 0x33333111, all good: 1, good links: 10, delay 0x000000c8 (0.391 ns)
VX-RX delays scan: tap 400, ddr 0, d:  0, vx link status 0x8833 0x33333111, all good: 1, good links: 10, delay 0x00000190 (0.781 ns)
VX-RX delays scan: tap   0, ddr 1, d:  0, vx link status 0x8833 0x33333111, all good: 1, good links: 10, delay 0x00000200 (1.000 ns)

The rx phase scan should go up to 40 ns. While this runs look at the GDM-CDM-VX status page and wait until the CDM link statuses are all green. They may be green for a range of values, we want to pick the center of the range. Note that the delays will wrap at 8 ns, such that the actual delay is given by x%8. The value entered into the ODB (/Equipment/CDMxx/Settings/vx_rx_delay_common) is the delay hexidecimal value. In the above example, for 1.000 ns this is 0x00000200.

TX Phase Scan

The tx phase scan can only take options in the range [0, 3]. Similar to the rx phase scan, watch the GDM-CDM-VX status page and wait until the vx link statuses are all green, and pick the value corresponding to that to enter into /Equipment/CDMxx/Settings/vx_tx_delay_common. This sets the tx phase for all channels of that CDM.