Back: fsc2 Forward: 2. GUI   FastBack: fsc2 Up: fsc2 FastForward: 2. GUI         Top: fsc2 Contents: Table of Contents Index: Index About: About This Document

1. Introduction

fsc2 is a program for controlling spectrometers. While, due to its history, it's a bit biased toward cw- and pulsed EPR spectrometers its design makes it easy to use it for a broad range of experiments not related to EPR.

Its central component is an interpreter that executes scripts describing experiments in a language which will be called EDL (Experiment Description Language) in the following. Making the execution of experiments completely controllable via scripts written in EDL is rather different from the approach trditionally taken by programs for spectrometer control. They normally have a graphical user interface where just a set of parameters for the experiment can be edited and then one of a (usually rather restricted) set of hard-coded experiments is started.

The obvious drawback of the traditional approach is that there's only a fixed set of experiments that can be done. Trouble starts when one needs to do an experiment the program was not written for. One either has to find some ways to "trick" the program into doing something it wasn't intended for or, if this fails, to change the program itself. This not only tends to take a lot of time (especially if the person who wrote the program isn't around anymore) but often also leads to the introduction of new bugs or even the realization that the program has not been written in a way that allows it to be adapted to the new requirements. In that case the old program becomes useless and a new one has to be written from scratch.

fsc2 is different since it wasn't developed with a certain set of experiments in mind. Instead, from the start it was intended to make it as easy as possible to do all kinds of experiments. Of course, this comes at a small price: one has to specify clearly how the experiment is to be done. This is done by writing a (usually rather short) script. fsc2 will interpret this script and do the experiment accordingly. Writing a script may sound difficult, especially when one has hardly any programming experience at all, but the EDL language used to describe experiments isn't very hard to learn. And when this hurdle has been taken you will have complete control over the way your experiments are going to be done and you're not at the mercy of the person that wrote the program.

Just to give a trivial example: sometimes e.g. EPR signals are distributed over a large field range with nothing of interest in between, so it would be rather useful to skip those regions. Most normal programs won't let you do this and you have to either record all the uninteresting field regions (thus losing lots of time) or manually restart the experiment for each of the regions of interest. In contrast, with fsc2 it shouldn't take more than a few minutes to write an EDL script that can not only skip these regions but also repeat the experiment as often as needed, and if necessary do different numbers of accumulations on different field regions (if, for example, the signals are huge in some while hardly detectable above the noise floor at others) or with automatically changing the lock-in amplifiers sensitivity or its time constant in between.

But one does not have to write a new script for every experiment one is going to do - for standard experiments, once such a script has been written, only the relevant parameters have to be changed. And because one can use variables in the script it's easy to have a block for defining the parameters somewhere at the start of the script and change only these as far as necessary.

If this is still too much hassle it is also possible to take an existing EDL script (after minor modifications) and automatically create from that a program that allows to set the parameters via a graphical user interface! Then this program will generate the appropriate EDL script automatically and pass it directly to fsc2 for execution. Once such a program has been written other users don't even have to learn how to write EDL scripts. Thereby all the convenience of the traditional type of control programs can be retained without sacrificing any of the flexibility fsc2 allows for. (Of course, you don't have to use the existing tools coming with fsc2 to add a graphical user interface to an EDL script - you can also write such tools yourself using fsc2s built-in interface to accept EDL scripts from external sources.)

Another common problem with the traditional type of program becomes obvious when new devices have to be integrated. Usually a limited set of devices is hard-coded into the program and adding a new one requires a major rewrite. In contrast, fsc2 has a strictly modular approach to the handling of devices. For each device a separate module exists that only gets loaded if needed (via a single line in the EDL script). Changing an EPR experiment to work with e.g. a different lock-in amplifier or digitizer usually doesn't require more than changing one or a few lines at most of an existing EDL script (at least if the devices aren't too different in their capabilities).

Moreover, this is also a major advantage when a new device has to be integrated: instead of changing the whole program only a new module for the new device has to be written. Writing such a module doesn't even require a thorough understanding of fsc2 but only knowledge about a few conventions (which are explained in detail in one of the later parts of this manual). Moreover, new modules can thus be tested independently of the main program and there is no danger of introducing new bugs into fsc2 itself.

The advantages of the approach taken in writing fsc2 have made it possible to use it successfully to control spectrometers in S-, X- and W-band and at 245 and 360 GHz, using completely different hardware, and for all kinds of experiments, ranging from cw-EPR, ENDOR, EPR on transient signals to experiments with pulsed microwave excitation and phase cycling, but e.g. also an (optical) single molecule or a Raman spectrometers.

The manual is organized along the following lines: the next chapter (see GUI) explains in detail the graphical user interface used for starting an EDL script and displaying the measured data. The following chapter (see Web Server) explains how to monitor fsc2's progress via the internet, just using a browser. Then follows a chapter (see EDL) that explains all about the EDL language. To give you an impression of how easy writing an EDL script is you may have a look at the first example (see Basics) which discusses a script for doing a simple cw-detected EPR experiment.

The next chapter (see Built-in Functions) lists all functions that are already built into fsc2. These include functions for displaying data, storing the measured data in one or more files, functions to extend the graphical user interface used during the experiment and, finally, mathematical and other useful utility functions. The following chapter (see Device Functions) discusses the functions that can be used to deal with the devices for which modules are already exist (at the time of writing this there are 29 different modules to choose from).

Experiments with pulsed microwave or RF excitation play an ever increasing role in modern EPR and fsc2 has an extensive set of commands and functions for dealing with pulses and pulse generators. These are explained in the chapter following the functions for other devices (see Using Pulsers).

The next chapter (see Command Line Options) lists all the command line options that fsc2 can be called with. The following chapter (see GUI-fying) explains in detail how to convert an EDL into a script with a graphical user interface for editing the relevant parameters. The chapters (see Cloning Devices tells how to deal with the case that you want to use two (or more) identical devices but there's only a single module for that type of device.

The final two capters, see Internals and see Writing Modules) first give you a short overview how fsc2 works internally, which may help you when writing a new module (but is not required), and then explain in detail everything there is to know about writing new modules.

Back: fsc2 Forward: 2. GUI   FastBack: fsc2 Up: fsc2 FastForward: 2. GUI

This document was generated by Jens Thoms Toerring on September 6, 2017 using texi2html 1.82.