Table of Contents

Overview

I preface this entry by noting there a lot of things I do not know about the implementation of timing at SLAC. I know in principle what is happening, but the implementation is much more complicated.

The SLAC timing system provides 4 triggers to the S20 laser system. One for the regenerative amplifier (120 Hz) and three at 10 Hz for the pulse slicer, pre-amp pump laser (CFR) and main amp pump lasers (2x SAGA). Thus to change the timing of the laser relative to the electron beam four triggers have to be changed. This is unusual for SLAC and was implemented so that we can change SAGA+IR timing and reduce energy remotely without turning down the pump lasers. At the moment the process of making sure all four triggers are sync'd is done through a python script. If this works well enough an SIOC can be created to streamline the process.


This page shows how to enable synchronization of all four triggers and change the timing of the laser relative to the electron beam.

Adjusting Timing Between Laser and Electron Beam

Adjusting the timing between the laser and the electron beam requires adjusting all four triggers the timing system provides to the laser. The python script used here keeps all four triggers synchronized with a fixed offset. Once the python script is running, relative timing between the laser and the electron beam is changed by changing the value of the PV OSC:LA20:10:FS_TGT_TIME. 

It is important that this program is only running on one computer at any given time. It does not have to be on the computer you're using to change the timing.

1) Open a terminal and connect to facet-srv01 (I don't know if it HAS to be 01, but I know that works). User profile doesn't matter. Then type

source use_python3.sh
pydm /home/fphysics/jemay/code/panels/LaserCoordination.py

This will pop a screen that looks like this:


2) "Load Current Offsets", which will calculate the timing difference between the regenerative amplifier and the other three triggers:

(We know the offset box needs to be bigger).


3) Select "Tracking Enabled"


4) Adjust the "target time". (PV OSC:LA20:10:FS_TGT_TIME) I have no idea what the absolute value of this PV means, but relative changes are true to expectations. If you change the value by 1 ns the laser will arrive earlier/later by 1 ns. You can change this target time by 1 fs, but I can't recall if that will work. We can test this when EOS is going. The units on the display are nanoseconds.

Once tracking is enabled you can also change the target time in the vitara panel or just writing to the PV.

Troubleshooting

The timing between laser and electron beam is monitored and kept constant by a High Level Application (HLA). This is not the application described above (the one above synchronizes the four triggers from the timing system with each other, but not with the electron beam). The HLA is an application that is common to all laser + electron/x-ray synchronization across SLAC.

How do I know the target time is working?

The "Target Time" and the "Counter Time" should match.

When working correctly "Target Time" is repeatable and reliable, so you can go back to previous settings for "Target Time" and expect repeatable results. Caveat: certain underlying inputs into the RF locking system can change on the scale of once a year, so do not rely on target times and things you dig out of the archiver from months ago.

If you change the "Target Time" and the "Counter Time" does not follow to within 0.1ns, then you should re-calibrate the femtosecond script. To re-calibrate, please see When I change the target time the counter time changes, but by the wrong amount, which is below.

If the "Counter Time" does not change at all, then the HLA has likely died. Please see When I change the "Target Time" the "Counter Time" doesn't change at all.

When I change the target time the counter time changes, but by the wrong amount

Or the two have a constant offset that is greater than 0.1 ns. (The script does way better than 0.1 ns synchronization, but doesn't display this on the counter time.) Either of these mean the HLA has lost calibration. To recalibrate:

1) Open the S20 Vitara control panel


2) Open the HLA script controls


3) Recalibrate the HLA

A little window will pop up. Select "Calibrating" and click "Apply". The process will take a few minutes. While in progress the button will read "Calibrating", when it is done the button will change name to "Ready".


4) Change "Target Time" and make sure it is consistent with "Counter Time". i.e they agree and move together.

When I change the "Target Time" the "Counter Time" doesn't change at all

The HLA is probably dead. At the moment the HLA lives in a screen on facet-srv01.

1) To check to see if it is running you need to find the screen instance. You can be on any profile when connected to facet-srv01.

The one called "s20_lasertiming" is the screen that contains the s20 laser timing.


2) Check to see what happened to the HLA.

It spits out a bunch of stuff:

So the software segmentation faulted.


3) From the screen, restart the HLA:

python femto.py configs/facet-s20.json

This will start to scroll a whole bunch of stuff, watch it for a bit to make sure it isn't throwing any errors. Detach the screen by pressing ctrl+a then ctrl+d.

You'll now need to recalibrate the script following When I change the target time the counter time changes, but by the wrong amount.


What if there is no "s20_lasertiming" instance of screen?

1) Open a new screen and start the HLA.

screen -S s20_lasertiming
cd /home/fphysics/jemay/code/fs-timing
source use_python3.sh
python /home/fphysics/jemay/code/fs-timing/femto.py /home/fphysics/jemay/code/configs/facet_s20.json

Detach the screen by pressing ctrl+a then ctrl+d.

You'll now need to recalibrate the script following When I change the target time the counter time changes, but by the wrong amount.

Counter Time is 1.2e11 and Doesn't Change

This happened after a power outage. There is a frequency counter on top of the DM controller (Keysight 53230A) that measures the delay between two triggers, at least one of which is the regen. If this counter reads 120 Hz then it is in frequency counting mode, not time interval mode, and is measuring the regen frequency. The EDM panel then converts this number to ns by multiplying by 1e9, hence the 1.2e11 number.

To setup the controller:

  1. Unplug the ethernet cable from the back and wait a minute or so. The controller needs to have remote control disabled to change settings locally.
  2. Turn Ch. 2 on if it isn't already. 
  3. Set the device to Time Interval mode by pushing the Time Interval Button.
  4. Set both channels to 50Ohm, DC coupling.
  5. Adjust the trigger settings for each channel to Rising slope at -200mV.
    1. I don't remember exactly how to adjust each setting, but it works similar to an oscilloscope. 
  6. When finished the display should look like this:

Notice the trigger settings in the top tabs.


I'm trying to move the oscillator cavity motor, but the measured frequency isn't changing

Is the motor initialized and homed? The motor homes in place, so it can be safely initialized and homed.

  • No labels