40m QIL Cryo_Lab CTN SUS_Lab TCS_Lab OMC_Lab CRIME_Lab FEA ENG_Labs OptContFac Mariner WBEEShop
  ATF eLog, Page 20 of 56  Not logged in ELOG logo
ID Date Author Typeup Category Subject
  1954   Mon Jun 29 21:28:46 2015 KojiElectronicsGeneral2ch Photo Sensor circuit

Here the performance measurements for a 2CH reflective photo sensor circuit are presented.

Two sensor heads are driven by Nick's constant current driver. They are connected in series. Therefore the two heads need to be connected at the same time to make them work correctly.

The reflected light is detected by two photo diodes (per head) to cancel angular motion of the mirror. The photocurrent is amplified in the head and sent to the box.

It has a modulation input. One can connect a SYNC output of a signal generator to chop the LED current. The modulation freq of 3~5kHz gives the best result.
In order to use the modulation function, two internal jumpers should be removed to activate AC coupling cirucit.

The final outputs have 500Hz roll-off with 3rd order butterworth.

Attachment 1: Calibration of the photo sensor (CH1 only)

An Al mirror is placed in front of the photo sensor head1 on a sliding stage. When the sensor head is touch the mirror, the diplacement is marked zero. The sensor output depends on the distance of the sensor from the mirror. From the measured profile of the sensor, the near- and far-side calibrations were estimated to 2.6e3 V/m and 0.67e3 V/m, respectively. These numbers depends on the reflecting surface and if the modulation is used or not, as well as the modulation frequency. Therefore the calibration should be done everytime one sets the sensors up.

Attachment 2: Receiver performance

By disabling the current source, the dark noise level was tested. The PDs have the dark noise level of ~1pA/rtHz floor. This corresponds to the shot noise of 3uA DC current. This measurement has been done at the test points before the final roll off filters.

Attachment 3/4: DC RIN / AC RIN measurements

A head was positioned in front of the mirror with the distance where the response hit the maximum. This corresponds to the measurement of the RIN when there is no modulation. When the modulation is used, we can define a similar quantity to RIN, here we call this AC RIN. I don't see good suppression of the DC fluctuation. It might suggest that the DC amplitude of the LED current is changing this much and the ambient noise is not affecting the performance. So when an ambient noise is not an issue, DC meausrement gives us a better performance. When an ambient noise disturbs the displacement sensing, the modulation function should be used with the cost of noise floor level.

Attachment 5: Displacement noise without modulation

Finally, the displacement equvalent noise level was checked. This measurement has been done by placing Head1 in front of a fixed mirror with the distance about 1.5mm. This corresponds to the DC output of about 5V. The noise level is 0.2~0.5 nm/rtHz above 2Hz and 3/f^3 nm/rtHz below 2Hz. This noise curve actually includes the vibrational noise of the measurement setup.
 

Attachment 1: PS_Calib.png
PS_Calib.png
Attachment 2: PS_Dark_noise.png
PS_Dark_noise.png
Attachment 3: PS_DC_OUT.png
PS_DC_OUT.png
Attachment 4: PS_AC_OUT.png
PS_AC_OUT.png
Attachment 5: PS_Disp_Noise.png
PS_Disp_Noise.png
  1964   Thu Jul 9 00:37:35 2015 Kate, AlessandraElectronicsSeismometerPCB

I have attached some pictures of the PCB required to make digital measurement for the seismometer.

Attachment 1: IMG_1128.JPG
IMG_1128.JPG
Attachment 2: IMG_1130.JPG
IMG_1130.JPG
Attachment 3: IMG_1131.JPG
IMG_1131.JPG
  2003   Thu Aug 13 13:12:48 2015 Rich AbbottElectronicsFSSTTFSS Fieldbox, Mysteries Revealed

Link to a block diagram to aid in the setup of the PDH loops TTFSS_Fieldbox.pdf

Attachment 1: TTFSS_Fieldbox.pdf
TTFSS_Fieldbox.pdf
  2091   Fri Apr 21 16:06:51 2017 AidanElectronicsCamerasPhosphor coated camera shows ZERO response at 2004nm

Johannes and I took the phospor coated CCD camera (from the cryo lab) down to the ATF to see the response to 2004nm. We tested it was working by shining an incandescent light onto it and confirming that we could see a signal on the monitor. Then we took the output of the 2004nm laser diode and put about 600 microWatts directly onto the CCD camera and ...

We saw no response at all. Nothing - on any of the gain settings.

 

 

  2105   Mon May 22 17:08:33 2017 awadeElectronicsScatterometerHooking up Newport 6000 to emcore laser diode

For the Si scatter laser (Emcore 1772, see ATF:2058 and subsequent posts) we needed a new laser diode controller. The two Thorlabs controllers that were originally used for TEC and LDD control have been commandeered for the 2µm experiment in the TCS lab.  I found a Newport 6000 combined TEC and laser diode controller that can drive 4 A through a Peltier with PI control and drive up to 3A through a diode: more than enough for the task.

I've soldered up some connectors and tested the diode at 34.9 C and a current of 330 mA.  Seems to produce a beam, although I need to check power.

Here are the pin-outs and pin-ins that were connectorized.

Pin in/outs for Newport 6000 and Throlabs LM14S2 TEC control
Description Newport 6000 Pin-outs Thorlabs LM14S2 pin-ins*
TEC+ 1,2 4
TEC- 3,4 5
Sensor + 7 2
Sensor - 8 3
GND 5,6  
NC 9 6,7,8,9

* Pin 1 on the LM14S2 is used for the TEC lockout feedback. This can be disabled with a switch on the bottom of the unit.

Pin in/outs for Newport 6000 and Throlabs LM14S2 LDD control
Description Newport 6000 Pin-outs Thorlabs LM14S2 pin-ins
Interlock 1,2 1,5
Laser Cathode (+) 4,5 7
Laser Anode (-) 8,9 3
PD Cathode (+) 6 2
PD Anode (-) 7 4
Chassis GND  3 -
NC   6,8,9

 

Settings for Newport 6000

Here were the settings I keyed in. The values for the internal thermistor were based an an educated guess that that is was a 10kΩ, ß = 3988 type device.  

TEC settings:

Ts = 34.90 C
Sens = 100 µA Therm
Mode = Const T
Gain = 10 Fast
Lim Ite = 1.00 A
Tol Time = 2.0 S
Lim Th = 42.00 C
C1 = 1.0445 x 10^-3
C2 = 2.5075 x 10^-4
C3 = 0 x 10^-7

LDD settings:

Mode = Io
BW = High
Io Limit = 330 mA (Max operating current)
Vcomp = 2.5 V (Max Laser Bias Forward Voltage)
Im Lim = 2500 µA (shutdown trigger if internal PD exceeds this current)
Po Lim = 42 mW (shutdown trigger if PD cal. power reaches this limit, it is not calibrated so not relevant)
Vf loss = 6 mV/A
Tol Time = 1.0 s
Tol Iop = 10 mA
Int Contact = OFF
Resp = 0 µA/mW (calibration of internal laser PD, not set here)
PD zero = 0 µA

  2106   Mon May 22 23:40:42 2017 awadeElectronicsScatterometerHooking up Newport 6000 to emcore laser diode
I rattle through night
My fan blows no more sweet prince
New one is coming.
  2117   Wed Jun 7 15:19:30 2017 AidanElectronicsCamerasTwo micron camera light-saber test of Pembroke Widy camera

I ran the 1550nm laser through the silicon piece at 11mW incident power. The laser current was set to 100mA and the output power was measured on the Thorlabs 2W power head. The camera was approximately 250mm from the silicon and I did my best to image the front surface of the silicon.

The camera exposure time was set to 200ms. The didn't seem to be any other gain settings available. 

I took 100 images with the laser on and then 100 images with the laser off. I average these and took the difference - which is shown below. You can see a faint horizontal light-saber line around Y-coordinate = 170 pixels.

The data from the averaged images is in the attached MAT file.

Attachment 1: IMG_9850.JPG
IMG_9850.JPG
Attachment 2: Screen_Shot_2017-06-07_at_3.06.37_PM.png
Screen_Shot_2017-06-07_at_3.06.37_PM.png
Attachment 3: Widy_Data.mat
  2118   Wed Jun 7 15:30:46 2017 AidanElectronicsCamerasTwo micron camera light-saber test of Pembroke Widy camera

Some more plots of the data, including a mean of the columns in the image of the silicon. The silicon piece is about 60mm in width.

Quote:

I ran the 1550nm laser through the silicon piece at 11mW incident power. The laser current was set to 100mA and the output power was measured on the Thorlabs 2W power head. The camera was approximately 250mm from the silicon and I did my best to image the front surface of the silicon.

The camera exposure time was set to 200ms. The didn't seem to be any other gain settings available. 

I took 100 images with the laser on and then 100 images with the laser off. I average these and took the difference - which is shown below. You can see a faint horizontal light-saber line around Y-coordinate = 170 pixels.

The data from the averaged images is in the attached MAT file.

 

Attachment 1: Screen_Shot_2017-06-07_at_3.29.10_PM.png
Screen_Shot_2017-06-07_at_3.29.10_PM.png
  2180   Thu Sep 21 12:03:27 2017 awadeElectronicsScatterometerHooking up Newport 6000 to emcore laser diode

So I turned on the Emcore 1772 laser today to take a few test measurements for Amani in the silicon scatter setup, laser power meter now shows that it is putting out 28 mW at full power. Nominal full power is at 40 mW.

The temperature had been tuned down to 30.04 C from the original 34.9 C.  But this didn't seem to change the power output much.  

Hopefully this laser isn't slowly dying.

Quote:

For the Si scatter laser (Emcore 1772, see ATF:2058 and subsequent posts) we needed a new laser diode controller. The two Thorlabs controllers that were originally used for TEC and LDD control have been commandeered for the 2µm experiment in the TCS lab.  I found a Newport 6000 combined TEC and laser diode controller that can drive 4 A through a Peltier with PI control and drive up to 3A through a diode: more than enough for the task.

I've soldered up some connectors and tested the diode at 34.9 C and a current of 330 mA.  Seems to produce a beam, although I need to check power.

Here are the pin-outs and pin-ins that were connectorized.

Pin in/outs for Newport 6000 and Throlabs LM14S2 TEC control
Description Newport 6000 Pin-outs Thorlabs LM14S2 pin-ins*
TEC+ 1,2 4
TEC- 3,4 5
Sensor + 7 2
Sensor - 8 3
GND 5,6  
NC 9 6,7,8,9

* Pin 1 on the LM14S2 is used for the TEC lockout feedback. This can be disabled with a switch on the bottom of the unit.

Pin in/outs for Newport 6000 and Throlabs LM14S2 LDD control
Description Newport 6000 Pin-outs Thorlabs LM14S2 pin-ins
Interlock 1,2 1,5
Laser Cathode (+) 4,5 7
Laser Anode (-) 8,9 3
PD Cathode (+) 6 2
PD Anode (-) 7 4
Chassis GND  3 -
NC   6,8,9

 

Settings for Newport 6000

Here were the settings I keyed in. The values for the internal thermistor were based an an educated guess that that is was a 10kΩ, ß = 3988 type device.  

TEC settings:

Ts = 34.90 C
Sens = 100 µA Therm
Mode = Const T
Gain = 10 Fast
Lim Ite = 1.00 A
Tol Time = 2.0 S
Lim Th = 42.00 C
C1 = 1.0445 x 10^-3
C2 = 2.5075 x 10^-4
C3 = 0 x 10^-7

LDD settings:

Mode = Io
BW = High
Io Limit = 330 mA (Max operating current)
Vcomp = 2.5 V (Max Laser Bias Forward Voltage)
Im Lim = 2500 µA (shutdown trigger if internal PD exceeds this current)
Po Lim = 42 mW (shutdown trigger if PD cal. power reaches this limit, it is not calibrated so not relevant)
Vf loss = 6 mV/A
Tol Time = 1.0 s
Tol Iop = 10 mA
Int Contact = OFF
Resp = 0 µA/mW (calibration of internal laser PD, not set here)
PD zero = 0 µA

 

  2192   Fri Feb 9 15:20:59 2018 AidanElectronicsCamerasHeimann Sensor thermopile array qualitative test

I recently purchased a relatively cheap 80x64 thermopile array for testing. It had a Ge window on the front of the TO-39 module which I removed with some photodiode can cutters. I put a variety of sources onto the array (from 532nm to 10.6 microns) and was able to record intensity distributions. The following images are from:

  • 532nm, 3.5mW laser pointer
  • 633nm, 1.5mW laser pointer
  • 2004nm, 1.4mW laser diode
  • 10,600nm, 42mW CO2 laser pick off

I had tested this device yesterday with the CO2 laser with the Ge window still in place and there were a lot of interference fringes. Removing the window seemed to help with this but I've yet to do any quantitative measurements. However, this looks promising as an alternative to a TV camera for beam monitoring (e.g. from PMCs, etc).

The array had a decent amount of noise on it that could be excited by me waving my hand near the device. So a proper AR window in front might improve the situation.

 

Attachment 1: HS_00532nm_3mW.png
HS_00532nm_3mW.png
Attachment 2: HS_00633nm_1.5mW.png
HS_00633nm_1.5mW.png
Attachment 3: HS_02004nm_1.3mW.png
HS_02004nm_1.3mW.png
Attachment 4: HS_10600nm_43mW.png
HS_10600nm_43mW.png
Attachment 5: IMG_2716.JPG
IMG_2716.JPG
Attachment 6: IMG_2721.JPG
IMG_2721.JPG
Attachment 7: FullSizeRender.jpg
FullSizeRender.jpg
Attachment 8: IMG_2694.JPG
IMG_2694.JPG
Attachment 9: IMG_2711.JPG
IMG_2711.JPG
Attachment 10: IMG_2714.JPG
IMG_2714.JPG
  2203   Tue Jun 19 14:38:23 2018 AidanElectronicsTMTFOrdered clamp plates to mount TECs to fiber for low-bandwidth control

I ordered the following two clamps to clamp TECs to an optical fiber for slow bandwidth control.

Attachment 1: TOP_clamp_fiber_TEC.pdf
TOP_clamp_fiber_TEC.pdf
Attachment 2: BASE_clamp_fiber_TEC.pdf
BASE_clamp_fiber_TEC.pdf
  2206   Thu Jun 28 16:59:17 2018 AidanElectronicsTMTFOrdered clamp plates to mount TECs to fiber for low-bandwidth control

The fiber temperature actuator clamps arrived today. Extensive use will likely reveal some revisions that could be made but the fit test with a fiber and a single TEC was successful - see attached photos.

Quote:

I ordered the following two clamps to clamp TECs to an optical fiber for slow bandwidth control.

 

Attachment 1: IMG_4256.jpg
IMG_4256.jpg
Attachment 2: IMG_4257.jpg
IMG_4257.jpg
Attachment 3: IMG_4254.jpg
IMG_4254.jpg
  2365   Tue Jun 25 19:56:23 2019 ranaElectronicsCleanlinessMoku Out

I've removed the Moku and its iPad from the lab to see what its up to noise-wise.

  2373   Mon Jul 22 20:36:35 2019 KojiElectronics2micronLasersSockets for LaserComponents PDs

We received the TO-66 sockets for LaserComponents PDs (Andon Electronics F425-1009-01-295V-R27-L14 Qty.10). It is made of FRP. It is very nicely made.

Attachment 1: IMG_8793.jpg
IMG_8793.jpg
Attachment 2: IMG_8792.jpg
IMG_8792.jpg
Attachment 3: IMG_8791.jpg
IMG_8791.jpg
  2394   Tue Aug 13 16:53:57 2019 Nathan HollandElectronics2micronLasersPhase Noise of Brimrose AOM Driver (VCO).

After reviewing the Brimrose AOM driver mnual, yesterday, it turns out I was previously using it incorrectly. It is a VCO with the frequency port accepting a DC voltage, between 0 and 10 V to control the frequency of the AOM - note that the mapping is not intuitive so one should refer to the manual. The modulation port is used for amplitude modulation, not frequency modulation. This port, modulation, has 50 ohm input impedance and accepts signals between DC and 10 MHz - modulating the power output. Table 1 below shows the operating parameters we should use:

Table 1: Recommended, constant, operating procedures for Brimrose AOM driver.
Port Value (V) Comments
Frequency +9.08 Gives 80 MHz modulation frequency.
Modulation +0.85 Gives 27 dBm of RF output, which is 90% of the maximum linear range of the Brimrose AOM.

 

Following this I characterised the phase noise of this VCO. Results are shown in attachment 1, for various powers. The setup is shown in figure 2, with the data for M = +0.85 V provided in attachment 3. These results show that this VCO has poor phase performance. A value of M = +0.02 V gives the same RF power as when a 0.5 Vpp signal @ 80 MHz was input into the modulation port - as I was previously doing.

This has a few implications for previous measurements:

  • The reason it was hard for the Mach Zehnder to remain locked for a substantial duration was due to the low input power to the AOM. This probably resulted in little signal in the Mach Zehnder LO arm.
  • Previously the amplitude modulation would have provided a 80 MHz signal in the Mach Zehnder LO arm

 

The script used to create the smoothed ASD can be found here.

Attachment 1: 20190813__Brimrose_AOM_Driver_phase_noise.pdf
20190813__Brimrose_AOM_Driver_phase_noise.pdf
Attachment 2: 20190813__VCO_phase_noise_setup.pdf
20190813__VCO_phase_noise_setup.pdf
Attachment 3: brimrose_AOM_driver_VCO_phase_noise_spectra.hdf5
  2418   Sun Sep 8 16:08:04 2019 ranaElectronicsGeneralSolder: what kind of solder to use and why?

This is a summary of some information on types of solder and their usefulness.

Summary: use the 63/37 Sn/Pb solder from Kester. It is eutectic and has a low melting point so that your opamps won't get damaged.

Eutectic:

We want our solders to be "eutectic" so that it goes from the liquid phase directly to solid with no intermediate slurry. This makes a reliable (and nice looking!) solder joint.

Lead:

The tin-lead solder is a good combo.

 

Links:

  1. Basics of solder choice from Hackaday
  2.  NASA's Tin Whiskers homepage
  3. "Tin Whiskers are Real & Complex" Maxim
  2436   Tue Oct 22 15:55:52 2019 KojiElectronicsGeneralBorrowed ITC510 from Cryo

From Cryo Cav setup

Borrowed ITC510 Laser Driver/TEC controller combo -> QIL

  2437   Thu Oct 24 11:58:27 2019 ChrisElectronicsCDSnew QIL AA boards

The anti-alias boards in the QIL AA chassis have been replaced with newer ones I found in the EE shop (serial numbers S1200217, S1200274, S1200275, S1200277).

The new boards (D070081-v4) have input buffers and a reasonably high input impedance (20k), unlike the old boards (D070081-v1).  However, according to the DCC revision notes, they may suffer from some excess low frequency noise caused by LT1492 opamps.  If it becomes a problem for us, we can replace those opamps.

The low input impedance of the original boards explains the anomalous ADC/DAC loopback measurement Jon made several months ago.  It should now be close to 0.5 ADC ct per DAC ct.  I have checked the DC gain for the first few channels, but have not exhaustively tested the new boards.  (Perhaps Jon has a script to automate this?)

  2541   Wed Mar 17 16:06:24 2021 aaronElectronicsEquipment transferborrowed filter

entered just before (Wed Mar 17 16:06:37 2021) to borrow a mini-circuits filter (SLP-100)

  2572   Thu May 20 16:57:32 2021 KojiElectronicsGeneralKeithley Source Meter returned to Downs

I've returned the Keithley Source Meter unit
- The unit (Keithley 2450?2460?)
- A power cable
- A pair of banana clips
- the transistor test fixture & triax cable/connectors
 

Attachment 1: P_20210520_154439.jpg
P_20210520_154439.jpg
Attachment 2: P_20210520_154505.jpg
P_20210520_154505.jpg
Attachment 3: P_20210520_154523.jpg
P_20210520_154523.jpg
  2763   Thu Apr 28 11:39:24 2022 JCElectronicsGeneralNetwork

I checked the internet in the TCS/MD Lab and it is running great and the switch is runing properly.

Attachment 1: IMG_0671.jpeg
IMG_0671.jpeg
  2779   Mon Jun 6 14:05:08 2022 AidanElectronicsPurchasesReturn me to WB265B: Location of Thorlabs S130C (silicon photodiode 5mW/500mW settings)

[Aidan]

I bought a new photodiode for the West Bridge Labs. It will be housed in the QIL (WB265B) in the central cupboards. There is a QR code on it linking to this page. 

 

Attachment 1: S130C_calibration.pdf
S130C_calibration.pdf S130C_calibration.pdf S130C_calibration.pdf S130C_calibration.pdf
Attachment 2: IMG_9289.jpg
IMG_9289.jpg
Attachment 3: IMG_9287.jpg
IMG_9287.jpg
  2788   Thu Jun 23 11:56:21 2022 JCElectronicsGeneralEquipment

[JC, Paco]

I took the Moku and iPad from QIL over to 40m for PLL Measurement at the 40m. (SURF)

  2137   Tue Jul 11 12:25:29 2017 awadeHowtoGeneralA Note On Plotting

There is no universally perfect plot and some details are a matter of taste.  However, bad plots often miss a few important features.
This is a checklist of features a plot should have. Hopefully this is useful to SURFs and new students.
If you have anything to add please edit this post and leave a note at the bottom.
Plots should have: 
  • large 16-20 point font on ticks and labels (bigger for titles);
  • always include units in axis labels (e.g. axislabel = 'Photo detector signal [V]'), if units are arbitrary then be explicit use 'a.u.';
  • axes need tick marks;
  • Scale data to cover most of the area. It probably should hit the very edge of the plot, but squashed up data is imposible to read. Matlab leaves a small gap at the edges, you need to set axis range manually.
  • thicken data lines (unless doing so obscures details of the data);
  • data points should usually be discreet points and not connected lines. It is ok to have lines for PSDs and time series. However, for most measurements with distinct measurement events those points usually should not be connected to distinguish data from fitted lines;
  • include a legend (almost always);
  • use pleasant harmonious colors, this is no-longer the 1990's and computers can do other colors now;
  • grid lines are good, especially for log plots, set the gamma to 0.2-0.4 or black-grey 0.3 so they sit in the background;
  • error bars (always);
  • if you include a fitted function put the equation on the plot along with fitted parameters and their uncertainties;
  • when making a Bode check use tick marks that are round numbers of 5s or 10s of dB (smaller gradations are ok as long as they sensibly spaced graduations around 0 dB and the grid lines match up); ticks of 2.314 dB, 2.317 dB , 2.320 dB are not ok.  Phase is often expressed in degrees and should be centered around zero on the y-axis with sensible graduations spanning ±180 degrees.  Never plot angle and magnitude on the same axis, it should be a two panel plot;
  • choose a standard aspect ratio (unless it makes sense to do otherwise): 16:9, 4:3 or the golden ratio (google it)
  • NEVER POST PLOTS AS JPEG OR BITMAP TO ELOG, if this were ancient Roman times this would be a crucifixion offense, always produce vector graphics. PDF IS HIGHLY PREFERABLE TO EPS (see 40m:12506);
  • Do not post plots of size greater than 1 MB, there is rarely a reason for a plot to be this big, you are a bad person if you force 1 MB plots on other peoples servers and computers. It could be you have plotted all million points in your dataset or it has rendered wrong. To fix this maybe try use: Imagemagick "convert -layers Optimize input.pdf output.pdf" .
  • title the plot and name file descriptively with date included (i.e. filename = 'plotyyyymmdd_ThisImportantThingIMeasured.pdf', title = 'This Important Thing I Measured (yyyymmdd)'). Remember, people from Mother England and Her colonies can't read dates properly (they do dd/mm/yyyy) so find a date convention that is explicit and minimizes confusion.
  • package the data and plotting code in a .zip or .tar attached to the same elog post (unless it is very large, >4 Mb), parcels of data stored in your personal directories are not useful to other people; and
  • step back and contemplate, does this plot convey information quickly and efficiently

 

Note that on the LIGO Caltech nodus elog it is possible to embed plots but you need double check to see if it is attached at the bottom.  Some embedded graphics can’t be clicked on to expand which is a a problem.  Sometimes it is easiest to just attach it at the bottom.

Edit Tue Jul 11 16:03:52 2017: Plot file size suggestion from Criag
Edit Thu Jul 13 10:29:31 2017: bode plots suggestion Gautam
​Edit Mon Mon Jul 17 15:30:12 2017: more on bode plots
Edit Wed Apr 25 12:41:41 2018: Added note about plotting data points as discrete seperate elements instead of connected lines
  2249   Thu Aug 30 18:13:28 2018 awadeHowtoGeneralRunning Acromag IOC epics servers out of docker

Acromag cards require a computer running an IOC process to poll channels and broadcast across the local network.  I often want to quickly test new configurations and setup small one-off configurations. Adding additional acromag cards to an existing setup often means restarting services and disturbing the state of live experiments. Also, channel access isn't available outside the network (say, in the EE shop).

Why?

There isn't  a one line command for installing all the EPICS tools needed to run the Modbus over IP server.  Installation involves a bit of wrangling with build commands that can be hard to reproduce without detailed instructions on identical systems. It can take a lot of time just to setup a tester rig.

Docker seems like a good tool for spinning up test modbus-to-EPICS servers and might be more flexible in the lab for evolving setups that need tweeking/updating without always breaking the rest of the lab.  It doesn't really add too much overhead to the host system as the processes are running directly on the host with container host system only being a lightweight addition.

Its also system agnostic.  I've managed to run a server on a Debian system and my Mac laptop in the EE shop (with acromag cards plugged directly into its ethernet, i.e. no router)

As an added bonus you can follow the Dockerfile to get an explicit set of instructions for how to install if you wanted to do it by hand on your local system.  The Dockerfile compiles on every push, so you know its methods work.

Running acromag IOC out of docker

I have put together a working docker image that is easy to compile/pull and run for running acromag cmd and db files.  You can find the Dockerfile on github HERE.  One instance has been running for ~3 months in the PSL lab without a single crash, some newer ones are running in the QIL lab with about two lines in bash to get them going. There doesn't seem to be any lag in their performance.

There are two ways of getting a container up and running: pull the image from dockerhub (fast), or, build the Dockerfile directly directly on your host machine (slower but customizable​).  For both you will need to install docker on the host system.  

Starting a default test instance

Method 1 pull precompiled docker image:

> docker pull andrewwade/modbusepicsdocker

> docker run -dt -p 5064:5064 -p 5065:5065 -p 5064:5064/udp -p 5065:5065/udp andrewwade/modbusepicsdocker

This runs a test instance and broadcasts a soft channel called "C3:EXP-modbusDocker".  Here -dt runs the docker container as a background service and holds it open on the last launch command until you call a "docker stop containername".  You can see that it works by running caget on a system with EPICS tools installed

> caget C3:EXP-modbusDocker

Should return: C3:EXP-modbusDocker       1.2345

Obviously the host machine must be connected to the network.

Note: If you opt to use the prebuilt image, you might not even need to pull the image in the first step. If docker doesn't have it, it goes and fetches it.  So it might just be a oneliner, depending on the configuration of your docker host.

Method 2 building locally

This method might be necessary if your computer can't see the internet, if you need to customize or if you want to compile for a different architecture (i.e. an ARM processor).

First pull/download the git

> git pull https://github.com/fincle/modbusEPICSDocker.git

cd into the dir containing the file "Dockerfile"

> cd modbusEPICSDocker

Then build

> docker build -t mydockername .

This should take 10-15 minutes to build.  Then you can run it as before:

> docker run -dt -p 5064:5064 -p 5065:5065 -p 5064:5064/udp -p 5065:5065/udp mydockername​:latest

Once again you can look to see if it is successfully broadcasting a soft channel:

> caget C3:EXP-modbusDocker

Should return: C3:EXP-modbusDocker       1.2345

Configuring for acromag

Setting up an acromag server is just as easy.  You need two sets of files, the IOCStart.cmd script file that runs at start and a some .db files to define your channel names and their math.

Some example files are given in the git modbus folder (also attached below). For an Acomag XT1221 ADC card uncomment the XT1221 block and change the IP address to that of your acromag card's.  You might also want to change the "ADC_Reg_XXXX" name to something descriptive of your application.  

Next add a line like 

dbLoadDatabase("/home/modbus/defaultXT1221.db") 

to the bottom to call a .db file with all the details of your channels.

Using the default defaultXT1221.db provided, just rename channels and labels as needed.

To spin it up you need to bind mount these files into the /home/modbus directory of the docker container at startup.

> docker run -dt --name MyDockerContainerName -v /exact/path/to/IOCStart.cmd:/home/modbus/IOCStart.cmd -v  /exact/path/to/db/files/dir:/home/modbus -p 5064:5064 -p 5065:5065 -p 5064:5064/udp -p 5065:5065/udp andrewwade/modbusepicsdocker

or, if you built locally, the name of your local image. 

If the Acromag card is available on the network and you've configured it right you should be able to see the channels broadcast on the network.

More info

That's it.  You should be able to get acromag cards up an running in as little as one line in command prompt on a range of different host systems.

Although I haven't tested it you might also be able to run multiple instances on the one host.  This could be handy for having a truly modular deployment where you can pull down particular units for updates to channels without disturbing the whole system state.

Docker can also be configured to keep alive processes.  So we might be able to do away with custom hacks to run EPICS servers as services.

 

Attachment 1: modbus__defaults.zip
Attachment 2: Dockerfile
FROM debian:latest

MAINTAINER Andrew Wade <awade@ligo.caltech.edu>


# This docker is a ready made modbus server built on an EPICS base.
# Versions used are:
# - base-3.15.5, asyn4-32 and modbusR2-10-1
#
# This should work as a standalone instance that is OS agnostic.  See README
... 58 more lines ...
  2326   Thu Apr 11 20:50:17 2019 ranaHowtoGeneralhow to learn quickly

https://maglab.caltech.edu/human-magnetic-reception-laboratory/

  2331   Tue Apr 30 19:52:14 2019 awadeHowtoWOPOConfiguring Zurich box server

As I couldn't find this on the 40m elog/wiki I'm putting notes here on how to configure a fresh webserver + python server for the Zurich box (model HF2LI) that runs an autobooting service job. 

The Zurich box (model HF2LI) has no front panel interface.  All controls are done from a USB interface to a host computer (running windows or Ubuntu/Debian).  This computer then hosts a web-server that runs an interface in a browser (through http) or responds to requests from python/matlab/labview/C API over the network.  

Installing data and webserver 

Set up on a Linux box is fast and easy from a fresh install.  A thin low powered computer is ideal. Start with a fresh install of Debian, use the latest stable release. Then download the latest stable release for the HF2LI, HF2IS, HF2PLL instruments from the Zurich downloads page.  You’ll probably want the 64bit linux. You can untar this file with

> tar xzvf LabOneLinux<arch>-<release>-<revision>.tar.gz

(Insert your filename details above)

Then cd into the directory it created and run

> sudo bash install.sh

It will ask a bunch of questions, just hit enter and y all the way through. The install should immediately boot the HF2 data server at the end.  You can check the data server is running with

> ziService status

Now plug in your Zurich box using the USB cable. Note: there are ethernet ports on the box, but these are NOT for network ethernet.  If the box is powered up the data server should find the box.  

Running the web server

In another terminal you’ll want to to start a Webserver so you can view the box status, settings and live data.  Go to another terminal and run

> ziWebServer

Your Zurich device should now be exposed on port 8006 of that machine.  You are read to go.

Now on that computer you can got to http://localhost:8006, alternatively on any other computer on the network you can go to the host machine’s IP address and see your Zurich interface.  I.e. if the computer IP is 192.168.1.121 then go to http://192.168.1.128:8006.  

Remote access

If you wanted to access the Zurich interface remotely (outside network) you can do some SSH forwarding if you have a gateway machine to outside the lab.  The standard command for this is 

> ssh -nNT -L <clientport>:localhost:<hostport> <controls>@<Host-IP-Address>

where controls is the username, Host-IP-Address is the IP address of the machine to be forwarded from, clientport is the port on your machine (the one you are ssh'ing from) and hostport is the port on the remote machine (for Zurich this is 8006).  Then when you go to http://localhost:<clientport> and you'll see Zurich interface.

Python API

Since the release 2.18 (Nov 2018) the python access tools are now just in Pypi.  You can install them with pip:

> pip install --upgrade zhinst

This should now allow you to use python API to access your Zurich box.

 

Setting up service to keep host alive from when box is booted

You’ll want to set up a service on your Debian box with systemd.  Make a unit

> cd /etc/systemd/system

> sudo vim ziServer.service

You must use sudo to be able to save the file here.

Paste the following in, this assumes that your username and its group is called controls on your machine:

[Unit]
Description=Zurich Instruments HF2LI data server
After=syslog.target network.target

[Service]
User=controls
Group=controls
WorkingDirectory=/home/controls/services/
ExecStart=/bin/bash -c "exec ziServer"
Restart=no
RestartSec=30

[Install]
WantedBy=multi-user.target


Tip: in vim you can type “:set paste” to get exact paste without auto indent etc.

Save the file and exit.  You'll also need to create the working director, or change the above to your desired directory

> mkdir /home/controls/services/

Finally, tell systemd to look for new things:

> systemctl daemon-reload

and enable the service,

> systemctl enable ziServer.service

and manually start the service,

> systemctl start myservice.service

It should be running, try to see if this is so:

> ps | grep ziServer

It should run on reboot of the machine and restart every 30 seconds if it crashes for whatever reason. Try rebooting the host machine to check it is still running

Configuring web-server service

Follow the above steps to also auto load the webserver with a unit file named /etc/systemd/system/ziWebServer.service:

[Unit]
Description=Zurich Instruments HF2LI web server
After=syslog.target network.target

[Service]
User=controls
Group=controls
WorkingDirectory=/home/controls/services/
ExecStart=/bin/bash -c "exec ziWebServer"
Restart=no
RestartSec=30

[Install]
WantedBy=multi-user.target

 Now you have a local network ready server for accessing the Zurich box through a web browser.

  2345   Thu May 16 16:52:46 2019 awadeHowtoWOPOZurich box python access

The Zurich box can also be accessed via a python API.  Its a little bit opaque in some points on how this works as their documentation is a little thin on actual examples.  I've included a jupyter notebook and equivalent .py file for future reference.  This code is tested and has worked with the Zurich box data server at IP address 10.0.1.23.  It shows exactly how settings can be modified and how data can be read back using their poll command.

Notebook includes all instructions for setting the Zurich HF2LI box up from scratch. 

 

Attachment 1: ZurichPythonAccess_MWE.zip
  2476   Wed Dec 11 15:53:48 2019 Aidan, Chris, RaymondHowtoCryo vacuum chamberProcedure to record photodiode output vs temperature

[Aidan, Chris, Ray]

  1. Add LN2 to cryo-chamber
  2. Turn on heater to 25W
  3. Wait for LN2 to boil off
  4. Turn on the REFPD bias switch, and enable a 200 mV bias on the JPL PD (set C4:TST-FM13_OFFSET to 200)
  5. Switch the readout to the transimpedance amplifier (relay control output from C4:TST-FM15 at 30k ct)
  6. Turn on the laser
    1. Power up the LDC201C and set it for half-power output (50 mA), with the modulation output from C4:TST-FM12 at zero
    2. Set C4:TST-FM12_OFFSET to 1 to go up to full power
  7. Monitor the PD output on oscilloscope and adjust horizontal and vertical alignment of laser beam so that the output of the PD is maximized (also adjust TIA gain if needed so the output is not saturated)
  8. Switch the readout to the Keithley (relay control output from C4:TST-FM15 at zero)
  9. Record bright PD response
    1. Turn on laser (set C4:TST-FM12_OFFSET to 1)
    2. Scan bias voltage and record the PD response using the source meter (scripts are located in $HOME/JPL_PD/scripts on qil-ws1)
      1. ./runsweep.py triggers the Keithley to sweep the bias (range of sweep is defined in the script)
      2. ./getdata.py FILENAME downloads data from the Keithley and writes it to FILENAME
    3. Record REF PD reading
    4. Record RTD resistance
  10. Record dark PD response
    1. Turn off laser (set C4:TST-FM12_OFFSET to -1)
    2. Repeat steps 9-2 through 9-4
  11. Switch the readout to the transimpedance amplifier (relay control output from C4:TST-FM15 at 30k ct)
  12. Measure dark noise vs bias (using either the SR785 or the cymac, TBD)
  13. Wait two minutes and repeat steps 6 through 12 (there is a script ./autorun.sh which continuously repeats steps 9 and 10)
  14. Continue until RTD reaches room temperature (approximately 60-90 minutes).
  2477   Wed Dec 11 19:50:25 2019 ranaHowtoCryo vacuum chamberProcedure to record photodiode output vs temperature

don't we also want to record the dark noise spectrum as a function of T and V_Bias ? I would guess that the dark noise doesn't always scale with dark current at low frequencies since its probably more like a random walk than shot noise.

  2535   Thu Mar 4 16:12:26 2021 AidanHowto2um PhotodiodesJPL PD set up tutorial video

I recorded a 15 minute overview that describes the JPL PD set up and how to operate it. I'm in the process of embellishing the operation procedure (previous version can be found here: eLOG 2476).

 

  2537   Fri Mar 12 08:31:05 2021 StephenHowtoCryo vacuum chamberQIL Cryo setup how to videos and photo album

Link to ligo.wbridge QIL Cryostat HowTo Playlist Cryostat on youtube - not super user-friendly as of yet, but populated with a couple of videos so far.

Link to ligo.wbridge QIL Cryostat Photo Album on google photos - not well curated, currently just a dump.

  2540   Tue Mar 16 20:50:14 2021 AidanHowtoTutorial videoHow to operate the PD pumping station

I added a 7 minute video to the DCC that shows how to operate the HiCube 80 Eco pumping station.

LIGO-G2100609

Also added a "Tutorial video" category to the elog.

  2719   Wed Feb 9 15:21:27 2022 ranaHowtoTempCtrlplots

In the plots comparing data and models, can you use the legend to indicate which is which? e.g. use dots for data and solid lines for models, and then label them as that in the legend. Also nice to include error bars on the temperautre measurements; I think there's a python way to plot this as a shaded region as well.

  1   Sun Oct 21 23:06:49 2007 ranaLab InfrastructureHVACIts too cold again
Friday evening it was a pleasant 70 deg F in the lab.

Tonight (Sunday evening) its back down to 61 deg F.

This happened ~a week ago; emailed Jeanne and Jo Ann and it got fixed. Will
try again and post results here.
  11   Wed Nov 28 16:20:04 2007 Andrey Lab InfrastructureGeneralEnclosure cleaning
Previous Tuesday, Nov. 20, I tried to wipe the curtain plastic enclosure around the optical table with the laser using methanol. It turned out, though, that methanol damages the surface of the enclosure, dissolving it and leaving lines/ traces. I stopped my activities with methanol after I realized that negative effect on three corner strips of enclosure.

Lesson for everyone: NEVER USE METHANOL FOR THOSE CURTAINS!

I tried 25% solution of isopropil alcohol in water on Wednesday, Nov. 21, and such mixture did not have any bad effect on the surface of the enclosure. I wiped the curtains, so they should be clean of dust now.

Andrey.
  12   Wed Dec 12 16:10:19 2007 tobinLab InfrastructureHVACLab Temperature
The lab temperature at 2pm was a comfortable 69 degrees.
  13   Wed Dec 12 16:19:00 2007 tobinLab InfrastructureHVACLab Temperature
I connected the particle counter to the Dell computer for PEM data logging (temperature, humidity, and particle count). The data shows that while the temperature is comfortable right now, it was quite warm in here yesterday (78 degrees). A plot is attached.

For this I made a serial cable using two DB9-to-RJ45 converters and a length of Cat5 ethernet cable. The computer end of the cable has a female connector; the particle counter end of the cable has a male connector. Only three conductors are connected: transmit (pin 2), receive (pin 3), and ground (pin 7 on the particle connector, pin 5 on the computer). I used the USB-to-serial dongle, which shows up in Linux as /dev/ttyUSB0.

Someone later can write a script to automatically poll the particle counter for new data. For now, I just emptied its internal buffer, which stores the last 200 measurements. The secret to communicating with the particle counter, which I learned by examining the c1psl statecode at the 40m, is to first transmit the letter "U". After this, the particle counter will listen to you and do what you say. In particular, sending a capital letter "A" will cause the counter to emit the next measurement from its buffer, until there are none left, at which time it will just respond with "#". To read the data I just ran a "cat /dev/ttyUSB0" command in one terminal, while in another terminal I ran a loop "while 1; echo -n A > /dev/ttyUSB0; sleep 1; end". I set the serial port parameters (9600BPS, 8N1) using Minicom.

Also, there's a Matlab script to parse and plot the output, in ~controls/tobin.
Attachment 1: temperature.pdf
temperature.pdf
  14   Thu Dec 13 18:47:02 2007 tobinLab InfrastructureHVACLab Temperature
Extech: 66.8F, 25%RH. Met One: 68F, 20%RH.

Here is the datalogger's contents:
A  121307 161942 0100 0.3 000000 0.5 000000 TMP 000680 R/H 000130 LOC 000000 C/S 000E54
A  121307 164641 0100 0.3 000000 0.5 000000 TMP 000680 R/H 000130 LOC 000000 C/S 000E53
A  121307 171340 0100 0.3 000000 0.5 000000 TMP 000685 R/H 000130 LOC 000000 C/S 000E52
A  121307 174039 0100 0.3 000000 0.5 000000 TMP 000680 R/H 000200 LOC 000000 C/S 000E53
A  121307 180738 0100 0.3 000000 0.5 000000 TMP 000680 R/H 000210 LOC 000000 C/S 000E57
A  121307 183437 0100 0.3 000000 0.5 000000 TMP 000680 R/H 000210 LOC 000000 C/S 000E56
A  121307 190136 0100 0.3 000000 0.5 000000 TMP 000680 R/H 000195 LOC 000000 C/S 000E5C
A  121307 192835 0100 0.3 000000 0.5 000000 TMP 000685 R/H 000195 LOC 000000 C/S 000E69
I'm not sure why it only starts at 12:13pm today. Also, looks like its clock is 50 minutes fast.
  15   Tue Dec 18 13:49:50 2007 tobinLab InfrastructureHVACLab Temperature
Extech: 68.6F, 57%RH. Met One: 68F, 53%RH. Drizzling outside.

Particle counter log shows stable temperature 67.5-69.5F over the last four days.
Attachment 1: temperature-20071218.pdf
temperature-20071218.pdf
  16   Fri Dec 21 21:27:12 2007 tobinLab InfrastructureHVACLab Temperature
Extech: 67.9F, 26%RH. Met One: 68F, 20%RH. Clear & cold outside.

Particle counter log looks stable.
  18   Wed Jan 2 15:10:24 2008 tobinLab InfrastructureHVACLab Temperature
The lab temperature appears to have been stable over the holiday, always between 68.5 and 70.0 degrees F. (There is no data from Dec 28-29 due to a computer reboot.)
  90   Tue Sep 9 15:49:22 2008 DmassLab InfrastructureHVACHEPA Filters
I had turned off the east HEPA filter with Masha for a noise measurement, and I forgot to turn it back on until today. Also, it looks like someone had unplugged the west HEPA filter and not plugged it back in. The latter I noticed while changing the power cabling, so it's possible that the west HEPA was running the whole time and I only noticed that I had just unplugged it...but I think this was a long term situation.

Also, the particle counter was reclaimed by the 40m during the vent after the earthquake, so we haven't had one on the table for some time. I had not been running the laser that much during the time when both filters may have been off, but it is worth noting in case there is unexplained dirtiness noticed in the future.
  110   Thu Apr 9 09:52:54 2009 alastairLab InfrastructureDAQDAQ up and running

Thanks to the help of all the people I've been hassling about this, the DAQ system is up and running.

I'll try to put together more of an 'idiot's guide to the RCG' at some point in future to supplement the information in the manual.  In the mean time for those that are interested in what's running, we have a model that looks something like the attached images (OMS.mdl which can be found in /cvs/cds/advLigo/src/epics/simLink/)

The model has four inputs from the ADC (the ADC is the lower BNC connector unit in the rack, labelled 'BNC anti-alias chassis'), followed by input filters on each channel.  These then go to an input matrix.  The ouput also has a filter on each channel followed by an output matrix.  The signals then go to the DAC.

I've tested the input with a siggen, and we can see realtime stuff in dataviewer, and frequency domain in DTT.  This is all working now.  It's running at 64khz at the moment and we'll be altering this down to 32 at some point soon.

I have also built some filters in foton, and after some fiddling with the settings they're running at the correct frequency.

Next up I want to make sure I can get a sensible signal back out of the DAC and then do some noise measurements on the input and output of the system.

Attachment 1: model1.png
model1.png
Attachment 2: model2.png
model2.png
  111   Thu Apr 9 10:02:24 2009 alastairLab InfrastructureGeneralAudio/mp3

We now have the right cable to connect audio equipment with a standard 2.5mm headphone jack (ipods etc) to the hi-fi.  Just set the stereo to 'game' and you're away.

  114   Fri Apr 17 20:05:59 2009 AidanLab InfrastructureGeneralAnother workbench and a filing cabinet

We're starting to accumulate a lot of loose data sheets and other paraphernalia. We should arrange to get a small filing cabinet down here. I'm sure Office Depot can serve us well on that one.

Also DMass and I think we should get a third IAC Industries workbench (the white ones with the Linux machines on them).

A.

 

 

  192   Wed Jul 22 20:40:13 2009 AidanLab InfrastructurefubarFiling cabinet lock engaged ... with no key

This happened mysteriously and had absolutely nothing to with me. The fact that I was the last person to open the filing cabinet before this happened is circumstantial and beside the point.

Will get the lockshop onto this in the next couple of days. In the meantime, just try and exercise your clairvoyance.

  224   Tue Aug 4 15:46:46 2009 DmassLab InfrastructureHVACTemperature update

It has been a brisk 72 degrees for a while (~1 week?) in lab. This is apparently the proper temperature for keeping graduate students awake, and lasers cool.

  236   Fri Aug 7 10:39:20 2009 MichelleLab Infrastructure Changing Lasers

We have to tweak the alignment of our PDH setup a bit, as well as change the cavity and profile the beam at different locations.

So we figure this is as good a time as any to stop using Aidan's laser and put in our one. We'll be working on that today, and we'll try to minimize the disruption this will cause to the fiber noise experiment.

  244   Mon Aug 10 20:14:11 2009 AidanLab InfrastructurefubarFiling cabinet lock engaged ... with no key

Quote:

This happened mysteriously and had absolutely nothing to with me. The fact that I was the last person to open the filing cabinet before this happened is circumstantial and beside the point.

Will get the lockshop onto this in the next couple of days. In the meantime, just try and exercise your clairvoyance.

 

 

Fixed! The key is now hanging in the second bay from the right above the main bench.

ELOG V3.1.3-