Welcome to the online documentation of Open VnmrJ for the Bridge12 Single Channel NMR (SCN) spectrometer. Open VnmrJ is an open-source software package designed for the acquisition, analysis, and processing of NMR data.
Bridge12 uses Open VnmrJ to control the Bridge12 SCN spectrometer. For Overhauser-DNP enhanced NMR spectroscopy, the Bridge12 Microwave Power Source (MPS) can also be controlled through OVJ.
The documentation provided here covers basic experiments, mainly focusing on the acquisition of Overhauser-DNP enhanced 1H NMR spectra.
For an in-depth documentation of OVJ please visit the Open VnmrJ website or consult the pdf documentation installed with the software.
1 - Overview
Brief Introduction to Open VnmrJ
Open VnmrJ (OVJ)
Open VnmrJ (OVJ) is an open-source software package designed for the acquisition, analysis, and processing of nuclear magnetic resonance (NMR) spectral data. It is an extension of the popular VnmrJ software, which was originally developed by Varian (later Agilent) for NMR data processing and acquisition. OVJ provides a flexible and customizable platform for researchers to acquire, perform advanced data analysis, and visualize NMR experiments.
OVJ offers a wide range of features and tools to facilitate NMR data processing. It includes functionalities for Fourier transformation, baseline correction, peak picking, spectral fitting, and data manipulation. OVJ supports various 1D or multi-dimensional NMR experiment types, for solution- and solid-state NMR spectroscopy.
OVJ is entirely open source. The software’s source code is freely available and can be modified and customized by the user community. This allows researchers to adapt the software to their specific needs, add new functionalities, or contribute to the development and improvement of the software itself.
The software provides a user-friendly interface, making it easily accessible to both novice and experienced users. It offers a range of visualization tools, such as 1D and 2D spectral displays, contour plots, and integration windows, to aid in data interpretation. Additionally, the software supports automation and scripting capabilities, enabling users to streamline their workflows and automate repetitive tasks.
OVJ Resources
Further information is available on the Open VnmrJ webpage.
To contribute to the project check out the How to join this project webpage for more information.
Setting up the Hard- and Software for the Bridge12 SCN Spectrometer
2.1 - Installing Open VnmrJ (Bridge12 Version)
Installing the Bridge12 version of Open VnmrJ (OVJ_B12)
The following pages provide a step-by-step guide how to install the Bridge12 version of OVJ and getting the computer ready for your first NMR experiment.
This installation guide assumes that you are installing OVJ_B12 on a clean installation of Ubuntu 20.04 LTS. To install OVJ, please create an user account called vnmr1 during the installation process. This should be an account with administrator rights.
Once the Ubuntu installation is finished, please log in as this user.
2.1.1 - Installing OVJ-B12
Installing the Bridge12 version of Open VnmrJ (OVJ-B12)
Note
Open VnmrJ is automatically installed when installing OVJ-B12, the Bridge12 version of OVJ. OVJ does not have to be installed separately.
Bridge12 does not offer a pre-compiled version of OVJ-B12. Instead, the package has to be build on the computer that is used to operate the spectrometer. However, the installation process is streamlined and does not require any specific programming skills besides navigating through some terminal windows.
Preparing the System
Start by opening a terminal window and update all installed packages to the latest version:
1
2
sudo apt-get update
sudo apt upgrade
The best way to install OVJ-B12 is by using the GitHub repository. Updates are pushed to the GitHub repository and can be installed by the user from there.
Install git and python3-pip
1
2
sudo apt install python3-pip
sudo apt install git
To communicate with the NMR spectrometer and the Bridge12 MPS a serial connection to the periphery is required. OVJ-B12 uses Python and the pyserial Python package for this purpose, which can be installed through pip.
1
sudo pip3 install pyserial==3.5
Cloning the Repository
To clone the GitHub repository, open a terminal window
Once the repository is downloaded change into the directory …..
Building the OVJ-B12 Package
Build the package. As a first step in the installation, the OpenVnmrJ and ovjTools repositories will be automatically downloaded. The complete build processes takes about 10 minutes.
1
sudo ./buildb12
We recommend opening a new console tab in the terminal window to monitor the build process. To do this copy and paste the command (tail -f) with the corresponding file shown in the console after starting the build process into the new console tab of the terminal window.
Once the build is finished check the build process with
1
./whatsin
The output should report 0 Errors and 0 Build Terminations for a successful build.
If the build succeeded the folder ~/ovjbuild/dvdimageB12 is created.
Install OVJ-B12
To install OVJ-B12 change to the dvdimageB12 directory and execute ./load.nmr
1
2
cd ~/ovjbuild/dvdimageB12
./load.nmr
A popup window will appear, press install to continue with the installation.
When asked to update users start the vnmrjAdmin program located on the Desktop. The program should start automatically. In vnmrjAdmin go to
Configure -> Users -> Update users …
and add all users (vnmr1, service and walkup if they were created) to the right side. Then press “update users”
Once all users are updated, the bottom status line in OpenVnmrJAdmin will show “Update User Completed All Requested Users”. Once you see this message, close OpenVnmrJAdmin.
After this, the system will open a new terminal window and the user has to answer a few questions. Please answer both questions with y(yes).
1
2
Standard configurations include the walkup and service accounts.
Would you like to make them now? (y/n)
1
2
Shall this system be configured as a spectrometer (see image below).
Would you like to configure it now? (y/n)
Installing NMRPipe is optional and can be answered with n(no).
We recommend to install the OVJ manuals. When asked to install the manuals please answer the question with y(yes).
Finish Installation
Once the load.nmr script has finished the upgrade.nmr script should be executed
1
./upgrade.nmr
The installation scripts places two icons to the Desktop: vnmrj and vnmrjAdmin. vnmrj can either be launched by double-clicking on the desktop icon or from the command line:
1
vnmrj
It is convenient to add Open VnmrJ to the quicklaunch menu. This can be done by by searching for “openvnmr” and then dragging the program icon to the quicklaunch bar.
OVJ-B12 is now installed and ready for its first experiment.
2.2 - Setting Up the Hardware
Setting Up the Bridge12 SCN Hardware
System Description
Front Panel Connectors
The NMR probe is connected to the Bridge12 SCN using the SMA connector located on the front panel of the system.
Back Panel Connectors
Most connections for the Bridge12 SCN are located on the back panel.
Connector Label
Style
Description
USB
USB-B
USB connection to spectrometer computer
PWR
Circular
System power connection. The input voltage for the system is 24 VDC, 1.25 A. To power the system, please use the power (desktop) adapter that was delivered with the system.
FILT IN FILT OUT
SMA(f)
Receiver input filter (bandpass). The bandpass filter is used to reduce the noise in the system. By default the Bridge12 SCN comes with a bandpass filter for 1H NMR spectroscopy. If you like to operate the system at a different Larmor frequency the filter has to be replaced with a bandpass filter for the desired frequency. Additional filters can be found on the MiniCircuits webpage.
λ/4
SMA(f)
Connection for the λ/4 cable. The Bridge12 SCN uses a passive Transmit/Receive (T/R) switch to protect the receiver. For this an appropriate λ/4 needs to be conneted to the two connectors. By default the system comes with a λ/4 cable for 1H NMR spectroscopy. If you wish to study other nuclei you need to replace the 1H with a cable with a different length. Instructions to make your own cable can be found on the webpage for the OpenTRSwitch or contact Bridge12 at support@bridge12.com.
AMP IN
SMA(f)
External amplifier input.
AMP OUT
SMA(f)
External amplifier output.
AMP BLNK
SMA(f)
Blanking gate for external amplifier. The blanking gate is active low. If you have questions about how to connect an external amplifier please contact Bridge12 at support@bridge12.com
MPS TRIG
SMA(f)
Trigger pulse for the Bridge12 MPS to modulate the output power. The trigger is active high.
A fuse holder is located on the back panel of the SCN. If necessary, the user can replace the fuse. The dimensions are 5x20mm and the fuse should have a rating of 1.25A.
Placing the System
Place the Bridge12 SCN close to the EPR spectrometer. It is recommended to keep the length of the cable connecting the probe to the system at a minimum length.
The system should rest on a stable surface.
TRIG/STAT Channel Explanations
1 - 10 MHz Reference:
The 10 MHz reference is the master oscillator output
4 - Hardware Trigger:
When this is pulled to GND an acquisition resumes or starts
5 - Hardware Reset:
When this is pulled to GND the pulse program is reset - as long as this is low no pulses are generated and sent out
6/7/8/9 - Ground
Connecting the System
Electrical Connections
To power the SCN connect the external power supply to the PWR connection.
then connect the USB-C port to a PC.
Connect the input of a bandpass filter corresponding to your NMR frequency to the ‘FILT OUT’ connector and the output of the bandpass filter to the ‘FILT IN’ connector.
Connect a \(\lambda\)/4 filter (e.g. a cable with the correct length) for your NMR frequency to the \(\lambda\)/4 connectors.
Connecting the NMR Probe Circuit
Changing the RF Filters
Not sure if we need this right now.
2.2.1 - Connecting the NMR Probe
How to Connect the NMR Probe to the Bridge12 SCN Hardware
The connector to connect the NMR probe to the Bridge12 SCN spectrometer is located on the front panel. The input impedance is 50 Ω.
If your probe has a BNC connector please use a SMA-BNC Adpater and a BNC cable to connect the probe.
2.2.2 - Connecting an External Amplifier
Connecting an External Amplifier to the Bridge12 SCN Hardware
The Bridge12 SCN has an internal RF power delivering up to 2 W output power. For many (low frequency) experiments this power is sufficient.
If the available power from the internal amplifier is not sufficient, an external high-power RF amplifier can be connected to the system.
To connect an external amplifier the input of the external device must be connected to the AMP OUT connection on the back panel of the SCN. The output of the external amplifier must be connected to the AMP IN connection located on the back panel.
To blank the external amplifier, connect the blanking gate to the AMP BLNK output of the SCN. The blanking gate is active low.
Specifying the Amplifier pre-Blanking Time rof1
To use an external amplifier with blanking, the amplifier needs to be unblanked before sending the RF pulse. Amplifiers typically require a short time unblank. This time can be specified using the OVJ parameter rof1. The value is typically given by the manufacturer in the data sheet of the amplifier.
The value can be set from the OVJ command line:
1
rof1=1000
If the required value is larger than the default value, for rof1 can be changed using the setlimit command as shown below.
1
setlimit('rof1',MAX_VALUE,MIN_VALUE,STEP)
Enabling the External Amplifier and Setting the Drive Level
OVJ needs to be connected to use the external amplifier. This is done from the OVJ command line:
1
B12SCNControl('extamp 1')
The B12SCNControl('state?) command can be used to query the state of the amplifier. If the system returns “extamp” the external amplifier is enabled.
1
B12SCNControl('state?')
The drive level (input power) of the external amplifier can be set using the OVJ command line by specifying the value stored by tpwrf.
1
tpwrf=1
To disable the internal amplifier from the OVJ command line enter this command:
1
2
B12SCNControl('extamp 0')B12SCNControl('state?')
If the command B12SCNControl('state?) returns “intamp”, the internal amplifier is used. The tpwrf value is automatically set to 100 (the maximum).
Warning
The drive level for the external amplifier is by default set to 3 dBm (2 mW - corresponding to tpwrf=3.25). This value can be changed using the tpwrf command from the OVJ command line. Please consult the data sheet of the external amplifier to find out the correct drive level for you amplifier model. The value in tpwrf is a linear scaling factor.
2.2.3 - External Trigger
Using an External Trigger
The acquisition of an NMR spectrum by the Bridge12 SCN system can be triggered using an external trigger. The external trigger is connected to the TRIG/STAT connector located on the back panel. The pinout for the connector is given in the section describing the Back Panel Connectors.
The trigger is active low on the falling edge. This means, pulling pin 7 on the TRIG/STAT connector to GND will start the acquisition of an NMR spectrum. By default every acquisition needs to be triggered. If you require a different behavior (e.g. trigger 4 acquisitions to complete a phase cycle) the pulse program need to be changed accordingly. For further information please contact Bridge12 at support@bridge12.com.
The system also has a hardware reset, accessible through pin 9 on the TRIG/STAT back panel connector. When this pin is pulled to GND, the pulse program will reset.
As long as the hardware reset of the SCN (pin 9) is pulled to GND no RF pulses are generated and send to the amplifier. Acquisition of an NMR spectrum is not possible.
Enabling the External Trigger
The external trigger needs to be enabled in OVJ for the user to be used. This is done either:
from the OVJ command line:
1
B12HWTriggerFlag=1
by setting the value in the Enable HW Trigger (in the Acquisition tab) to 1
or by activating the HW Trigger checkbox in the 1H tab
Disabling the External Trigger
To disable the external trigger use the command
1
B12HWTriggerFlag=0
or set the value in the Enable HW Trigger box to 0 (Acquisition tab) or disable the checkbox in the Default 1H tab.
3 - Getting Started
First Steps with Open VnmrJ
The following section gives an overview how to start OVJ, tune the probe to the correct frequency, and how to acquire a simple 1D 1H NMR spectrum.
3.1 - Launching OVJ
Launching OVJ and setting the spectrometer frequency.
Launching OVJ
OVJ can be launched in two different ways: 1) by double-clicking the vnmrj icon on the desktop or, 2) by opening a terminal window and launching it from the command line by typing:
1
vnmr
Setting the Spectrometer Frequency
If this is the first time you are using OVJ, the spectrometer frequency has to be set to the correct value.
Note
The first time you launch OVJ the spectrometer frequency has to be set. Once the spectrometer frequency has been set the value will be stored by OVJ and does not have to be entered every time the user starts OVJ.
In OVJ, the spectrometer is historically set by setting the frequency of the deuterium (2H) lock frequency.
The ratio between the (1H) and (2H) frequency is approximately 6.51. For example, to set the spectrometer to a 1H frequency of 14.5 MHz the user has to set the spectrometer frequency to 14.5/6.51 = 2.227 MHz. To set the spectrometer frequency:
In OVJ go to Edit -> System Settings
In the window that appears enter the deuterium (2H) lock frequency in MHz.
Alternatively, the spectrometer frequency can be set from the OVJ command line using the lockfrequency parameter:
The following section describes how to tune the NMR probe to the correct spectrometer frequency. This requires disconnecting the NMR probe from the spectrometer.
Make sure all experiments have been finished and no pulses are transmitted anymore before disconnecting the NMR probe from the spectrometer.
Tuning the NMR Probe
To tune the NMR probe to the spectrometer frequency follow these steps:
Note down the spectrometer frequency. This does not have to be an exact value, but should be close (within 0.1 MHz of the operating frequency).
Switch on the nanoVNA and set the center frequency to the spectrometer frequency (set it to the frequency of the nucleus you want to observe, not the 2H lock frequency). Set the span to a value of 1-2 MHz.
For instructions on how to setup the center frequency, span, marker position, etc. see the page with the setup instructions for the nanoVNA.
If this is the first time using the nanoVNA you should calibrate the device. This calibration needs to be repeated every time you change the center frequency or span.
Disconnect the NMR probe from the Bridge12 SCN spectrometer and connect it to channel 0 (CH0) of the nanoVNA.
You should see a ‘Tuning Dip’ on the nanoVNA. If you do not see a tuning dip try one of the following things:
Increase the span of the VNA to scan a broader frequency range
Change the matching on your probe
Use the slider at the top of the nanoVNA to move the marker to the spectrometer frequency (within +/- 0.1MHz). The marker will tell you the absolute value of the S11 parameter at the spectrometer frequency (see image below, S11 = -7.8 dB).
Turn the tune and match capacitor of your probe to achieve a minimum reflection. In general, the tune capacitor will shift the dip up in down with frequency, while changing the match capacitor value will increase the depth of the dip. Optimize both capacitor values for a minimum in reflected power. The probe is tuned once you achieve the lowest value for S11 (see image below, S11 = -40.9 dB)
The Bridge12 SCN is delivered with the nanoVNA, a pocket-size vector network analyzer (VNA) to tune the probe to the transmitter frequency of the spectrometer.
The nanoVNA has two channel and has many different ways to display the (complex) S parameters. However, in the following we provide a brief set of instructions to setup the nanoVNA display to:
Only show the reflected power from the probe (S11)
How to calibrate the nanoVNA.
The nanoVNA will store these settings, so you only have to go once through these instructions.
To navigate through the different menus of the nanoVNA you can either use the wheel located at the top of the device or using the touch screen. The touch screen is best used with a stylus pen.
Setting up the Display
To setup the display:
Tap the touchscreen to show the menu
Tap the Display button (top right corner)
Tap the Trace button on the display
For convenience, select only Trace 0 by tapping on it. The selected trace is highlighted with a colored background (yellow for Trace 0). Unselect any other traces by tapping on the button.
To leave the menu tap somewhere on the touchscreen.
Setting the Frequency Range
Tap on the touchscreen to show the menu
Tap on the Stimulus button
Next, tap the Center button
On the next screen, enter the spectrometer frequency using the number pad and press the M button to indicate that the entered frequency is given in MHz.
Next, tap the Span button and enter the frequency range to observe the resonator tuning dip. Typically 1-2 MHz is a good range to start with.
Calibrating the nanoVNA
Important
The nanoVNA should be calibrated frequently. The calibration is only valid for a given set of parameters (e.g. span, center frequency, number of points ….). If one of these parameters is changed, the device needs to be recalibrated.
The device will still work even with a calibration that is “slightly off”. For example, the spectrometer frequency will not change drastically on a day to day basis and using the same configuration is ok. However, if you require accurate values for S11 we recommend calibrating the device before taking the measurement.
We recommend calibrating the device once and then not changing the measurement parameters. This should be good for a day-to-day operation.
The nanoVNA is calibrated using a basic OPEN-SHORT-LOAD protocol. Three SMA connectors are included with the nanoVNA, used for calibrating the device (see image below).
SHORT - Left, used to shorten the input of the VNA. This connector is all metal on the inside.
OPEN - Middle, used to create an open port. This connector does not have a middle pin.
LOAD - Right, used to simulate a 50 Ω load. This connector has a middle pin and a white teflon ring around it.
From the protocols tab drag the PROTON experiment into the plotting window, or double click on the PROTON protocol.
Alternatively, the pulse sequence can be set using the OVJ command line:
1
seqfil='s2pul'
The PROTON sequence calls a pulse program s2pul. This is a general, two-pulse sequence used to run variety of different experiments such as a single pulse NMR experiment or an inversion-recover sequence.
Next, the user has to set the length and power of the RF pulse to properly acquire a 1D 1H spectrum. In OVJ the pulse parameters can be changed from the OVJ command line or from the acquisition panel.
Note
Make sure that the spectrometer frequency is set correctly. The spectrometer frequency is set by adjusting the lockfreq. For experiments at 14.79 MHz, this parameter has a value 2.271 MHz (2H frequency corresponding to a 1H frequency of 14.78 MHz). This value should be ideally set to a precision of three to four significant digits.
See the Launching OVJ section in the Getting Started section for more details.
The length of the observe pulse is given by the parameter pw. From the OVJ command line set the pulse length:
1
pw=3
corresponding to a pulse length of 3 µs.
Note
If the pulse length corresponding to a 90 degree pulse is unknown, it can be determined by performing a nutation experiment to calibrate the correct pulse length. Typically, the probehead manufacturer will provide the length and power level for the 90 degree pulse.
Next some of the acquisition parameters need to be set. Go to the Acquire tab and click on Acquisition. Here, basic acquisition parameters can be adjusted. Alternatively, the values can be entered in the OVJ command line.
Spectral Width: Parameter sw
Acquisition Time: Parameter at
Complex Points: Parameter np
For example
1
2
sw=50000np=4096
will set the spectral width to 50000 Hz (50 kHz) and the number of points acquired in the time domain to 4096.
Note
In OVJ the number of points corresponds to the total number of real and imaginary points. To acquire a total of 2048 (complex) points, np has to be set to 4096 (twice the number of complex points).
Set the number of transients (nt) to 4. In general, OVJ will add a CYCLOPS phase cycle to each sequence automatically to remove DC offsets and correct for phase imbalances. Therefore, the parameter nt should always be set as a multiple of 4.
1
nt=4
On the Acquire tab click Channels to set the transmitter offset tof parameter. To get started, set this value to 0
1
tof=0
With the transmitter offset set to 0, the spectrum, if excited on resonance, appears in the center of the window. To center the spectrum adjust the tof value. Alternatively, you can click with the mouse on the peak (single red line cursor) and enter the command movetof in the OVJ command line. OVJ will automatically adjust tof so that the NMR spectrum in the next acquisition is at the center of the window.
Start the acquisition by either pressing the GO button or by typing
1
go
in the OVJ command line. The acquisition will start and the data is displayed and processed on the screen.
Note
In OVJ the acquisition of the NMR spectrum can be started using the go or ga command. In this version of OVJ the two commands are identical. This may be different on other (older) NMR spectrometers running vnmrj.
Phasing a spectrum
Once the acquisition is finished, the spectrum most likely needs to be phased to show just the real part of the complex spectrum (see figure below). This can be done automatically using the autophase command aph or manually.
Using the Autophase Routine
To autophase the spectrum type the following command in the OVJ command line and press enter:
1
aph
to autophase the spectrum.
Manually Phasing the Spectrum
Sometimes, the autophase routine fails and the spectrum needs to be phased manually. To manually phase an NMR spectrum:
Click the Phase button in the toolbar to the left
Click the spectrum with the left mouse button and keep the button pressed. Two red cursors appear to the left and right of the peak. Phase the peak by moving the mouse up and down. This will adjust the 0th order phase correction (frequency-independent phase correction). Alternatively, the phase can be adjusted from the OVJ command line by typing:
1
rp=11.5
To adjust the 1st order phase correction (frequency-dependent phase correction) click the Phase button in the toolbar to the left. Next, select the peak by moving the mouse cursor to the NMR peak and click the right mouse button. The point selected is the pivot point used to adjust the 1st order phase correction. By moving the mouse up and down the phase of the rest of the spectrum can be adjusted. To adjust the 1st order phase correction lp from the OVJ command line type:
1
lp=157
The proper phased spectrum is shown below.
Note
Start phasing the spectrum with rp and lp set to 0. First, adjust the 0th order phase and then the 1st order phase correction. Note that rp=360 is equivalent to rp=0. This is also true for lp.
DNPLab is a Python package to process NMR data. The software was developed by Bridge12 and is open-source, free to use. DNPLab can be used for offline processing of OVJ data.
Below, a brief example is shown how to load and process a 1D NMR spectrum. For a complete reference and many more processing examples visit the DNPLab Online Documentation.
Installling DNPLab
DNPLab requires a working Python installation and can be simply installed using pip:
1
pip3 install dnplab
All requirements are automatically installed.
Processing 1D Spectra
A typical processing and plotting script is shown below:
Line 3: Load the NMR spectrum. DNPLab can import many different spectrometer formats. The format is automatically detected and a dnpdata object is created.
Line 4: The attribute of the spectrum needs to be changed to nmr_spectrum to ensure that the plot function fancy_plot works properly (this line will not be required in the future).
Line 6-7: Fourier transform the spectrum and apply an autophase routine.
Line 8: Remove DC offset from spectrum.
Line 10-11: Plot the NMR spectrum
The result is shown below.
DNPLab has many more features for processing and analyzing NMR data. It can also be used to process EPR data. For more information check out the Online Documentation.
3.4 - Saving the NMR Spectrum
Saving the NMR Spectrum in OVJ
OVJ provides two different options to save the NMR data:
by using the OVJ GUI
by using the OVJ command line.
Saving Data using the OVJ GUI
To save the NMR experiment using the GUI:
Go to the Acquire Tab and select Future Actions
Click on save FID (see image below)
Saving Data from the OVJ Command Line
To save the NMR experiment from the OVJ command line:
Type the command save
Enter a name (e.g. mydata). Do not add an extension to the file name
Press return
The data will be saved and a study is created automatically.
Location of Saved Data
Assuming a default installation of OVJ, the data can be found in the ‘mydata’ subfolder in the vnmrsys/data folder:
1
~/vnmrsys/data/
4 - Advanced Experiments
Advanced Experiments in OVJ
This section provides some examples of advanced experiments and data acquisition schemes.
4.1 - Arraying Parameters
Arraying Parameters in OVJ
For many experiments a parameter needs to be varied (e.g. the delay (recovery) time in an inversion-recovery experiment to measure the 1H longitudinal relaxation time T1.
In OVJ, this can be done specifying an array of parameters. An array can be either specified through an OVJ GUI or the command line.
It is helpful to first take a look at the pulse sequence to decide, which parameter needs to be arrayed. Either click the ‘Sequence diagram’ button in OVJ or type dps in the OVJ command line. A typical, two pulse experiment is shown in the figure below.
d1: Repetition time.
p1: Pulse length of the first pulse. For an inversion recovery experiment, this is the pulse length of the first 180 degree pulse.
d2: Recovery delay.
pw: Pulse length of the detection pulse.
Arraying Parameters using the GUI
To use the GUI to define an array of parameters to vary follow these steps:
In the Acquire Tab click the array button or select Parameter Arrays from the Acquisition menu
In the window, enter the parameter name to array in the field Param Name. In this example we will vary the parameter d2. The description will be automatically filled in.
Enter three of the four parameters (Array Size, First Value, Increment, Last Value). The fourth parameter will be calculated once three values are entered.
The values of the array is shown in the box to the right. Use the scroll bar see all values of the array.
Click the Close button.
The window will close. The value of the parameter (here d2) will now be displayed as “Array” to indicate an array of values instead of a single value.
Arraying Parameter using the OVJ Command Line
From the OVJ command line, an array can be defined using the array command.
1
array(parameter,number_of_steps,start,step)
For example, to array the parameter d2, starting at 0.05 s, with steps of 0.05 s for a total of 30 points enter the following command:
1
array('d2',30,0.05,0.05)
another possibility to create arrays with arbitrary values is using the syntax $value=val1,val2,…
1
d2=1,4,42
4.2 - Calibrating the 90º Pulse Length
Calibrating the 90º Pulse Length in OVJ
Calibrating the 90º pulse length is a good example for arraying parameters in OVJ. If you haven’t read the section about how to array parameters in OVJ, we would suggest doing this first before you start to follow this example.
To calibrate the 90 degree pulse length follow these steps:
Insert a water sample into the probe.
Select the PROTON sequence in OVJ.
Set the following parameters in OVJ.
Set the sweep width (sw) to a value that the NMR signal (here a single peak from the water sample) is fully within the sweep width of the experiment and some noise is shown left and right to the peak.
Set the number of scans (nt) to a value to obtain a clear signal (not too noisy).
Set the number of acquired points np to 4096, to acquire 2048 complex points.
Array the parameter pw from 0 to about three times the expected pulse length for the 90 degree pulse. In this example we set the array the parameter from 0 to 15 µs with a step size of 0.25 µs.
Start the acquisition of the experiment and save the data once the experiment has finished.
The obtained data can be either analyzed in OVJ or dnplab to determine the length of the 90 degree pulse.
Determining the 90 Degree Pulse Length in OVJ
To process the nutation experiment in OVJ follow these steps:
After the acquisition select the ‘Process’ tab
Select Display and set the display mode for the spectrum to ‘Phased’
Select a spectrum that with sufficient signal-to-noise and phase the spectrum. Use a spectrum with a shorter pulse length, don’t use the last spectrum of the nutation experiment. The same phase correction is applied to all spectra in the array.
If the sweep width of the spectrum is large, zoom into the region with the peak.
Move the mouse cursor to the left of the peak and press the left mouse button. Next, move the mouse cursor to the right of the peak and click the right mouse button. The selected region is shown between the two red lines.
Click on the zoom button in the toolbar to the left to zoom into the region defined by the two red lines.
To show all spectra horizontally aligned, together with their respective pulse length
Press the |||| button to show all spectra next to each other
Next, click # to cycle through the acquisition number or the array parameter
To show all spectra of the array press the # button in the toolbar
The spectrum with the largest peak corresponds to the 90 degree pulse width. In this example the optimum pulse length is 4.75 µs.
Determining the 90 Degree Pulse Length in DNPlab
The nutation experiment can also be analyzed in DNPLab. If you haven’t installed DNPLab, this can be easily done using pip:
1
pip3 install dnplab
A typical DNPLab script to determine the 90 degree pulse length is given below:
importdnplabasdnpdata=dnp.load('path/to/folder/PROTON_XY.fid')data.attrs['experiment_type']='nmr_spectrum'data=dnp.fourier_transform(data)data=dnp.autophase(data,dim='t1')fig,ax=dnp.plt.subplots(1,2)dnp.plt.sca(ax[0])dnp.fancy_plot(data)noise_start_ppm=-1000#change this according to your spectrumnoise_end_ppm=-500#change this according to your spectrumsignal_start_ppm=-50#change this according to your spectrumsignal_end_ppm=50#change this according to your spectrumdata=dnp.remove_background(data,dim='f2',regions=[(noise_start_ppm,noise_end_ppm)])data=dnp.integrate(data,regions=[(signal_start_ppm,signal_end_ppm)])dnp.plt.sca(ax[1])dnp.fancy_plot(data)dnp.plt.xlabel('PW (us)')dnp.plt.ylabel('Signal (a.u.)')dnp.show()
This processing script first will load the data and does a Fourier transformation of the FID. Next, a DC offset will be removed using the remove_background function. Next, the NMR peak intensity is integrated using the integrate function and the data is plotted using the fancy_plot function.
In the example the 90 degree pulse length is about 2.35 µs, and the 180 degree pulse length is about 4.7 µs.
Note
Different probes will have different pulse lengths for the 90 degree pulse. The pulse length also depends on the RF power. Higher RF power will result in a short pulse length. However, you should not exceed the maximum pulse power specified by the manufacturer to avoid damaging the probe.
4.3 - Inversion Recovery Experiments in OVJ
Performing an Inversion Recovery Experiment in OVJ
The longitudinal relaxation time T1 can be determined from an inversion-recovery experiment. This is another good example to demonstrate the arrying capabilities in OVJ. If you haven’t read the section about how to array parameters in OVJ, we would suggest doing this first before you start to follow this example.
The following pre-requisites are assumed:
A sample is inserted in the probe.
The 90 degree pulse length is know. To determine the correct pulse length please follow the steps outlined in the section Calibrating a 90º Pulse.
Acquire the Inversion Recovery Data
To perform the inversion-recovery experiment follow these steps:
Select the PROTON experiment (seqfile='s2pul').
Enter the pulse for the 90 degree pulse (pw) and the 180 degree inversion pulse (d1).
Enter a value for d1. This is the repetition time of the experiment and it should typically be set to a value of 5 times the T1 relaxation time of the nucleus. For example, if the relaxation time of the water protons is about 1 s, the value for d1 should be set to 5 s. This ratio can be reduced to speed up the experiment, however, if the repetition time is too short, the measured value for T1 will be incorrect.
For the inversion-recovery experiment we will array the d2 parameter
1
array('d2',30,0.05,0.05)
Press ‘Go’ to start the acquisition or type go and press enter in the OVJ command line.
Once the aquisition is finished save the data.
Determining T1 in OVJ
To determine T1 in OVJ follow these steps:
Select the last spectrum of the array using the ds command. Here, we use spectrum number 15. Alternatively, you can select any spectrum with sufficient signal-to-noise.
1
ds(15)
Phase the spectrum using the autophase function aph:
1
aph
Once all spectra are phased, you can display all spectra horizontally using the dssh command:
1
dssh
The result should like like the example below
If the spectra look like the data shown in the image proceed to the next step.
Select the last spectrum using the ds(15) command.
Next, we need to set a threshold for the peak picking algorithm. The threshold is set using the th parameter. In this example, we will set a threshold of 10.
1
th=10
You can also use the horizontal line marker to adjust a threshold. Set the threshold to a value that only one peak is above the threshold.
In the next step the peak amplitudes for each spectrum are determined using the dll and fp (find peak) command. Only peaks are considered that are above the threshold value.
1
2
dll
fp
To get the T1 relaxation time, the t1 OVJ macro can be used. To run the macro, enter t1 in the OVJ command line and press enter.
1
t1
Display the fitting results using these OVJ command line commands:
1
2
center
expl
You should see a result similar to the one shown below.
The fit values returned by the t1 macro can be seen in the Process tab under Text output.
The t1 macro will create an output file located in the current experiment folder. The path the folder is (N corresponds to the experiment number). The number of the current experiment can be seen in the top left part of the display tab or using the curexp? command in the OVJ command line.
1
~/vnmrsys/expN/analyze.list
Evaluation with dnplab
The inversion-recovery experiment can also be analyzed using DNPLab. First, make sure DNPLab is installed:
importdnplabasdnpdata=dnp.load('path/to/FID/folder')data=dnp.fourier_transform(data)data=dnp.autophase(data,dim='t1')fig,ax=dnp.plt.subplots(1,2)dnp.plt.sca(ax[0])dnp.fancy_plot(data)noise_start_ppm=-1000#change this according to your spectrumnoise_end_ppm=-500#change this according to your spectrumsignal_start_ppm=-50#change this according to your spectrumsignal_end_ppm=50#change this according to your spectrumdata=dnp.processing.offset.remove_background(data,dim='f2',regions=[(noise_start_ppm,noise_end_ppm)])data=dnp.processing.integration.integrate(data,regions=[(signal_start_ppm,signal_end_ppm)])data.attrs['experiment_type']='inversion_recovery'dnp.plt.sca(ax[1])dnp.fancy_plot(data)dnp.show()
The first subfigure can be used to determine the noise and signal region.
The second figure shows the T1 recovery curve. An example for the second figure is shown below.
4.4 - Creating a Study in OVJ
Creating a Study in OVJ
If the user wants to run a series of experiments a Study should be created in OVJ by the user. The study can be started using the go command and each experiment is automatically saved.
To create a study in OVJ follow these steps:
Click ‘New study’ in the ‘Study Queue’ tab.
Enter a Sample name in the ‘Start’ tab.
Drag an experiment (e.g. PROTON) from the Experimentor Selector Tree into the Study Queue.
when the the PROTON_001 sequence is selected (double click) one can adjust all settings for the sequence (Array parameters, change MPS settings, etc..) and when pressing the save button the settings are saved.
These settings will be the default settings for all experiments in this study. To save the data automatically go to the ‘Acquire’ tab and select ‘Future Actions’.
In the ‘When experiment finished’ line enter procsaveplot (select process/plot/save from the dropdown menu) or save to save the data after each ‘go’. Alternatively this can be set with the commandline
1
wexp='procsaveplot'
To start the acquisition of experiments in the study, press the Submit button to start the acquisition.
5 - DNP Experiments using OVJ
Performing DNP Experiments in OVJ
(Overhauser) DNP-enhanced NMR experiments can be conveniently performed in OVJ. Here, OVJ not only controls the NMR hardware, but also the Brigde12 Microwave Power Source (MPS). From OVJ it is possible to:
In this section we demonstrate a couple of simple DNP experiments and how to incorporate automating the MPS control into OVJ pulse programs.
5.1 - Controlling the MPS from OVJ
How to use the OVJ panel to control the MPS
The Brigde12 MPS can be completely remote controlled from within OVJ. Make sure, the MPS is connected to the computer running OVJ using a USB cable.
The Bridge12 MPS is controlled from a dedicated panel within OVJ. To access the panel:
Select the tab label Start from the panel
Click on MPS to access the panel
Most controls in this panel are labeled identically to the front panel labels of the MPS.
WG: This check box controls the waveguide status. OVJ will allow the use to only check one box at a time. For example, if the DNP box is checked, the EPR box will be unchecked and vice versa.
RF: This check box controls the microwave power output status:
Off: The microwave power is disabled
On: The microwave power is enabled
Ext: The MPS is waiting for an external trigger signal to enable the microwave power
Frequency (GHz): Microwave frequency in GHz
Power (dBm): Microwave power in dBm. If your are not familiar with the dBm scale, a conversion table is available in the MPS documentation
Reflected power: The value printed here indicates the amount of reflected power from the cavity.
Frequency lock: This check box enables the software-AFC feature of the MPS.
MPS Reset: This will trigger the MPS to reboot.
OVJ calculates the 1H frequency from the microwave frequency that the MPS is set to. It is displayed as H1 MHz (from MPS). The frequency is given in MHz. Under it, the current OVJ 1H frequency is given. In most cases, these two values should be close. To set the spectrometer frequency to the calculated 1H frequency from the MPS, hit the button labeled Set H1.
5.2 - 1H ODNP Spectroscopy
Acquiring an ODNP-enhanced NMR Spectrum with OVJ
In this first example we demonstrate how to record an NMR spectrum with and without microwave power. Here, it is assumed that the microwave resonator is properly connected to the MPS, and that the resonator is properly tuned and matched.
Warning
Before enabling the microwave power on the MPS, make sure the microwave resonator is properly coupled to the MPS. While the MPS has a safety feature to disable the microwave power if the reflected power exceeds a safe value, exceeding this value can cause permanent damage to the MPS.
The NMR signal recorded without microwave power is often referred to as the Off Signal, or the thermal equilibrium (TE) signal, while the signal recorded with microwave power is often referred to as the On Signal. In most cases, optimizing the spectral parameters using the On Signal is simpler due to the increased signal-to-noise of the spectrum.
Sample: For this example we use a sample of 10 mM TEMPO dissolved in water. The sample is loaded in the appropriate sample tube and inserted into the resonator.
Prior to recording a DNP spectrum the user has to:
Adjust the microwave coupling to minimize the reflected microwave power.
If necessary, record an EPR spectrum of the sample
Adjust the magnetic field strength so the microwave radiation is on-resonance with an EPR transition
Recording the On Signal
To record the On Signal:
Select the PROTON experiment (seqfile=‘s2pul’) and set the NMR acquisition parameters ((nt, sw, tof, np, d1, pw, etc.) to some common values.
Go to the Start tab and select the MPS panel.
Select the DNP checkmark (under WG) in the MPS tab. This will set the waveguide switch to select the microwave path for DNP. A waveguide switch is commonly installed in systems that are based on an EPR spectrometer. Your system configuration may differ.
In the MPS panel, enter the microwave frequency. This is the same frequency that the EPR resonator is tuned to.
Enter the microwave power (see this table for conversion of mW to dBm). The power requirement for a DNP experiment strongly depends on the nature of the sample. A good starting value is 23 dBm (200 mW).
Make sure the MPS mode is set to Manual.
To enable the microwave power, click on the On check box under RF.
Acquire an NMR spectrum by clicking the go button or by typing the go command in the OVJ terminal.
Phase the spectrum. Note: Typically, the off-signal is phased so the NMR signal has a positive amplitude. In an ODNP experiment, the enhanced peak will be inverted.
The ODNP-enhanced spectrum is shown in the figure below.
Next, optimize the acquisition parameters of the NMR experiment.
Recording the Off Signal
Once the acquisition parameters are optimized you can record the off-signal, the NMR signal without microwave power. Typically, the signal-to-noise ratio will be much lower and often more averaging is required. To record the off-signal:
Turn off the microwave power by clicking the Off check box under RF.
Acquire an NMR spectrum by clicking the go button or by typing the go command in the OVJ terminal.
If the signal-to-noise ratio is not sufficient, increase the number of acquisitions (OVJ parameter nt).
Keep in mind, to calculate the DNP enhancement, either both, the on and the off spectrum have to be recorded with the same number of transients, or the signals have to be properly normalized.
5.3 - DNP Power Build-UP (Saturation) Cruve
Recording the DNP microwave power saturation behavior
A commonly performed DNP experiment is to record the NMR signal intensity with respect to the microwave power. The result is the DNP power saturation behavior.
In this example we will automatically record the DNP saturation curve for a sample of 10 mM TEMPO in water.
To record the DNP saturation experiment:
Select the PROTON experiment (seqfile=‘s2pul’) and set the NMR acquisition parameters ((nt, sw, tof, np, d1, pw, etc.) to some common values.
Connect the MPS TRIG output to the MPS Ext. Trig input using a BNC cable.
Go to the Start tab and select the MPS panel.
Select the DNP checkmark (under WG) in the MPS tab. This will set the waveguide switch to select the microwave path for DNP. A waveguide switch is commonly installed in systems that are based on an EPR spectrometer. Your system configuration may differ.
In the MPS panel, enter the microwave frequency. This is the same frequency that the EPR resonator is tuned to.
Select Ext. mode from the MPS mode dropdown menu.
We will use continuous microwave radiation during the experiment. To turn the microwave power on permanently during the experiment set the xm variable to the value ‘yyy’
1
xm='yyy'
Next, we will create an array in OVJ with the microwave power values. For this the parameter mpspower needs to be arrayed. Create an array from 0 to 40 with a stepsize of 1, resulting in a total of 40 elements.
Note
Keep in mind a microwave power level of 0 dBm corresponds to 1 mW of microwave power, not 0 mW.
Start the experiment by clicking the go button or by typing the go command in the OVJ terminal
Once the experiment is finished, the results can be conveniently displayed using the dssh command
5.4 - Using the External MPS Trigger
Using the external MPS trigger in DNP experiments
The Bridge12 MPS microwave source can be controlled by an external trigger to enable and disable the microwave power programmatically through the NMR pulse sequence.
To be able to use the external trigger, connect the MPS TRIG output from the SCN backpanel to the MPS Ext. Trig input of the MPS backpanel, using a BNC cable.
To enable the external trigger:
Select a pulse sequence.
In the MPS panel select the Ext mode from the dropdown menu.
Select the checkmark Ext under RF
Now, the MPS is set to accept an external trigger signal. In this mode the RF output set by the status() command during the pulsesequence. In OVJ, every pulse sequence is divided into three different sections, labeled A, B, and C. This label is shown in the bottom row when displaying a pulse sequency in OVJ using the dsp command.
The microwave status (on or off) for these sections is controlled by the xm variable in the pulse program.
1
xm
To enable the microwave power during Status(A) in the pulse program, but disable the power during Status(B), and Status(C) the xm variable has to be set to
1
xm='ynn'
When only a single character is given the status() is set for A,B,C to the same value.
When the xm variable is set, the status can be seen in the display of the pulsesequence by typing
1
dps
An additional line labeled MW appears, indicating the status of the microwave output during each segment of the pulse sequency. In this example, the microwave power is enabled (ON) during Status(A) but disabled during Status(B), and Status(C).
Note that the position of the status() statement in the pulsesequence determines where a state starts and ends. As an example the following modified ‘s2pul’ includes p1 in status A and pw in status B
// Copyright (C) 2022 Bridge12Technologies
// You may distribute under the terms of either the GNU General Public
/* s2pul - standard two-pulse sequence with modified status */#include<standard.h>voidpulsesequence(){/* equilibrium period */status(A);hsdelay(d1);/* --- tau delay --- */pulse(p1,zero);status(B);hsdelay(d2);/* --- observe period --- */pulse(pw,oph);status(C);}
6 - Reference
Open VnmrJ Command Reference
6.1 - OVJ Commands
Commonly Used OVJ Commands
General Command Structure
OVJ commands are entered at the command line. Some commands require arguments or parameters, which can enclosed in parentheses.
To change a parameter value, the parameter is entered followed by an equal sign (=), followed by the value of the parameter (real, integer, or string).
String values are always enclosed in parentheses and surrounded by single quotes.
Multiple command and parameter settings can be entered consecutively, separated by spaces.
Command Examples:
1
2
3
aph
wft
wft aph dc vsadj
Example of Setting a Parameter Value:
1
2
lb= 0.2
sampe='MySample'
Commonly Used OVJ Parameters
The following sections provide a list of commonly OVJ commands and parameters. For a complete list of commands see the VnmrJ Command and Parameter Reference.
Commands
Spectrometer Control and Data Acquisition Parameters
Command
Description/Example
aa
abort current running experiment immediately. Recommended to use in most occasions over sa except when some experiments are queued
cexp(n)
create new experiment from current one Example: cexp(2) copy current parameters and create experiment number 2 (#2 must not exist)
dg
display group of acquisition/processing parameters in Process→Text Output window
dps
display pulse sequence
ga
start experiment and autoprocess the data when data are available
go
start experiment using acquisition parameters
jexp(n)
join (or go to) specified experiment Example: jexp(2) join exp#2. exp#2 must exist
movesw
move new spectral window (sw) to the area enclosed by the two red cursors
movetof
move transmitter offset freqeuency (tof) to the cursor position
su
setup experiment. Force hardware to changes according to current parameter settings Example: load=‘MySpectrum’ su - change shims to current values in parameter file Example: tn=‘C13’ su - change direct detection to C13
time
displays total experiment time with current parameters
time(hours,minutes)
displays number of scans (nt) required for a given time of experiment Example: time(1,10) - displays number of scans needed for a one hour 10 mins experiment
unlock(exp_number)
remove interactive lock and join an experiment. Useful to remove lockup of an experiment, sometimes due to user failure to exit vnmrJ before logging out Linux
Data Processing and Display Commands
Command
Description/Example
aph
automatic phasing of both zero (constant) and first-order (linear with frequency) terms
aph0
automatic phasing with zero-order term only to achieve absorptive mode spectrum. Zero-order phase value (rp) is the same across the spectrum
array
Enter this command to set an arrayed experiment where a parameter is varied and an experiment is collected with each parameter. Enter parameter name, initial value, number of steps, and stepsize. All other parameters are kept constant
bc
1D or 2D baseline correction with a spline or 2nd to 20th order polynomial function. Needs to define baseline regions (regions in between the integral areas covering peaks)
centersw
With full spectrum displayed and in single cursor mode, centers moves the cursor to the center (transmitter) of the spectrum
cz
clear integral reset points
da
display acquisition parameter array in Plot→Text Output window
dc
Apply a simple drift correction (with a straight line function) so that the spectrum baseline is close to zero. Level (lvl) and tilt (tlt) parameters are adjusted
df
display a single FID (default index is 1) Example: df displays the 1st FID or df(10) displays #10 FID in the array
dli
display list of integrals
dll
displays line frequency and intensities (peaks have to picked)
dpir
display integral values below spectrum
dpf
adjust threshold and display peaks so that a maximum 20 highest peaks are found and the minimum height cutoff is 5 times above noise level
dres
calculates peak resolution/linewidth
ds
display processed spectrum without preprocessing
dssa
display arrayed spectra in a stack plot Example: wft dssa
Label displayed arrayed spectra with index number Example: wft dssh dssl
dsn
measure and display signal-to-noise ratio in region enclosed by two cursor lines
f
display the full spectrum
fbc
apply baseline correction for each spectrum in an spectrum array
full
display spectrum with full window size. The range of the spectrum is not changed Example: f full - display the full spectrum with full window size
fp
find peaks in arrayed dataset according to the refrence peaks found by dll
isadj
automatic adjustment of integral vertical display height to fit page
mf
move FID file from one experiment to another Example: mf(1,2) move fid from exp #1 to #2
mp
Move all parameters from one experiment to another Example: mp(1,2)
nl
move cursor line to nearest peak/line position
th
set a threshold for peaks in dll command
thadj(maxpks,noise_mult)
Adjust the threshold th so that no more than maxpks number of peaks are found with a minimum of noise_mult factor above noise level. Example: thadj(20,5)
peak
Find tallest peak in current display region Example: peak - display tallest peak position and height in current displayed spectrum region Example: peak:$height,$freq - find tallest peak in current displayed region and save height and frequency in the variables $height and $freq. $heigt? or $freq? shows the values
vsadj
automatic vertical scale adjustment so that the highest peak fits the window height
setref
set reference ppm of any nucleus by the chemical shift of the deuterium signal from the solvent, according to IUPAC standard indirect referencing to TMS 1H signal
wft
Weighted Fourier transform (FT). Weighting is applying a window function to the profile of the FID to enhance resolution or signal-to-noise and to reduce truncation artifacts from finite data collection
Plotting Commands
Command
Description/Example
page
submit plot to printer and change plotter page. Usually last command in printing command chain
pap
plot “all” parameters in table format
pir
plot integrals below spectrum
pl
plot spectrum
pll
plot frequency line list in a table format
pltext
plot user comment/notes. Not necessary if ppa command is used
ppa
plot basic parameters in plain english format
pps
plot pulse sequence
ppf
plot peak frequencies over the spectrum
Parameters
Acquisition parameters
Parameter
Description/Example
at
acquisition time in seconds
bs
block size of data (number of transients) periodically read and stored on disk Example: bs=4 stores data every 4 scans
ct
current transient (or scan) number. ct is displayed at the bottom of vnmrJ screen during a running experiment. If the experiment is stopped before all transients are done, ct (stored in the parameter file procpar) is the number of scans completed
d1
1st delay period in pulse sequence. Typically this is the recycle time (in seconds) between scans
dn
1st decoupler nucleus
gain
receiver gain. If gain=‘n’, auto-gain adjustment is set before data acquisition. Autogain cannot be used for arrayed experiment. Gain values go from 0 to 60. Too high a gain setting causes receiver overflow, leading to severe artifacts in the spectrum Example: gain=36 sets gain to 36
nt
number of transients or scans
pad
preacquisition delay (in seconds). pad is the additional delay time set before the 1st recycle delay (d1) before the start of an experiment. If pad=60, the experiment will start after 60 secs
rattn
receiver attenuation, the attenuation can be set from 0 to 95, a too high value will attenuate all signals. A too small value will increase noise without increasing the signal strength.
ss
number of steady-state transients or dummy scans before start of experiment. It’s used to establish a steady-state for the spins before data collection
sw
spectral width of direct detection dimension, in Hz be default Example: sw=6000 or sw=15p to specify 15ppm width
sw1
spectral width of 1st indirect detection dimension, in Hz be default
solvent
name of solvent Example: solvent=‘cdcl3’ or solvent=‘c6d6’
tn
observe transmitter nucleus
tof
observe transmitter offset (center of spectrum)
Processing and display parameters
Parameter
Description/Example
axis
axis label in display and plots. Values include ‘h’ for Hz, ‘p’ for ppm Example: axis=‘p’ or axis=‘ppm’ set axis to ppm display
cr
cursor position in direct detected dimension Example: cr=8.0p set cursor position to 8ppm
date
date of experiment
delta
In two-cursor (box cursor) mode, delta stores the width in Hz between the two cursors Example: delta=1000 sets the separation between two cursors to 1000 Hz, or delta? to see the cursor separation value
ho
horizontal offset (in mm) between a set of spectra in stacked display mode for arrayed spectra
intmod
integral display mode. Value is ‘off’, ‘full’, or ‘partial’ Example: intmod=‘off’
lb
line broadening amount for exponential weighting function (Hz) Example: lb=0.2
lp
1st order (or linear) phase in directly detected dimension, adjusted during phasing process Example: lp=0 sets linear phase correction to zero, useful to reset linear phase to zero to correct accidental introduction of large lp value during manual phasing
rp
zero order phase correction in degree, adjusted during phasing process Examples: rp=45 set zero-order phase to 45 degree or rp=rp+45 to change phase by 45 degree
vo
vertical offset (in mm) between a set of spectra in stacked display mode for arrayed spectra
vp
vertical position of spectrum, in mm Example: vp=60 sets spectrum baseline roughly in the middle of the display along Y-axis Example: vp=vp+20 moves the spectrum up by 20 mm
vs
vertical scale of spectrum Example: vs=vs*2 - set vertical scale to double peak height Example: vs=vs*0.5 - set vertical scale to halve peak height
6.2 - Pulse Programming
Pulse Programming in OVJ
General Concept
Pulse sequences are written in C, a high-level programming language that allows considerable sophistication in the way pulse sequences are created and executed.
A new pulse sequence is written as a C function called pulsesequence. The file containing this function is compiled and linked with an object library that contains the definitions for all pulse-sequence statements, the PSG. A compiled C sequence is executed on the Linux workstation at the start of acquisition, so-called run-time. At run-time, the sequence reads values from a parameter table and constructs a second real-time program of acodes, whose purpose will be to run the SpinCore controller board.
The PSG library contains C code to run the pulsesequence function and to run spectra corresponding to arrays of parameter values. The user need not program these loops explicitly. At the start of the acquisition, all of the variables and statements of the compiled C program, including the C loops and conditionals, are resolved and fixed into acodes, without the possibility of further input or calculation. A complex program with many choices, using the C if-else-endifstatement, may resolve into a very few acodes, because the acodes in the non-selected branches are never created. A pulse program with multidimensional looping and/or parameter arrays will produce a separate set of acodes for every increment.
The real-time acode program is automatically looped over the number of scans for each multidimensional increment or array element. Special real-time integer tables, t1 to t10, are used to increment phases and other values that might change scan-to-scan. These tables and variables are initialized and manipulated by special pulse-sequence statements, the real-time math statements.
Writing pulse sequences
Pulse sequence text files are stored in a directory named psglib in either the system directory (/vnmr/psglib) or in a user directory (/home/vnmr1/vnmrsys/psglib for the user vnmr1). A pulse sequence file has the extension .c to indicate that it contains C language source code. Pulse sequences may also be saved in the psglib directory of an applications directory, which may have any name and path. An applications directory is made accessible through the Edit Applications tool of the Files pull down menu. A pulse sequence text file can be modified using the Linux tool vi, the standard Linux editor gedit, or by an available text editor or development package.
The template for all pulse sequences is:
1
2
3
4
5
6
7
#include"standard.h"voidpulsesequence(){// Pulse elements
}
Since it is a C function, any C construction may be used. The available pulse elements are described below. For examples, see the pulse sequences in /vnmr/psglib
Compiling pulse sequences
After writing a pulse sequence, the source code is compiled by one of the following methods:
By entering seqgen(filename<.c>) on the OpenVnmrJ command line.
By entering seqgen on the OpenVnmrJ command line, with seqfil=‘filename’
By entering seqgen filename<.c> from a Linux shell
For example, enter seqgen('s2pul') to compile the s2pul.c sequence in OpenVnmrJ. A full path is not necessary from the command line. Alternatively, you can enter
1
seqgen s2pul
in a Linux shell. The seqgen command will first search the user, then the available applications directories, and then the system for a file with a .c extension.
During compilation, the system performs the following steps:
Extensions are added to the pulse sequence to allow a graphical display of the sequence, using the dps command.
The source code is checked for syntax, variable consistency, and the correct usage of functions.
The source code is converted into compiled object code.
If the conversion is successful, the object code is combined with the necessary system PSG object libraries (libparam.so and libpsglib.so), to be linked at run-time. If the compilation of the pulse sequence with the dps extensions fails, the pulse sequence is recompiled without the dps extensions.
The executable code is stored in the user seqlib directory (e.g. /home/vnmr1/vnmrsys/seqlib). If the user does not have a seqlib directory, it is automatically created. A copy of the source code is also saved in vnmrsys/seqlib of the user directory. If desired, you can copy the compiled sequence to /vnmr/seqlib or to the seqlib directory in an applications directory.
Standard compiled sequences are supplied in /vnmr/seqlib and the source code for each of these sequences is found in /vnmr/psglib. To recompile one of these sequences or to modify it, first copy the sequence into the user psglib, make the required modifications, and then recompile the sequence using seqgen. Sequences can only be compiled from a user directory. If you attempt to compile a system sequence, a local copy will be created. The seqgenupdate command performs a seqgen as the first step, and will then attempt to move the resulting seqlib entries back to the application directory from which they were taken.
The source files that are used to create the PSG object library are contained in the system directory /vnmr/psg. In principle, a user can customize and recompile the PSG source files, but most users do not do so. It is easier to add the user source code in a separate file using the standard C #include statement. User #include files should be stored in the ~/vnmrsys/psg directory of a user or an applications directory.
6.2.1 - Pulse Elements
Pulse Elements for Pulse Programming
Pulse sequences are constructed from pulse elements, which specify controls for the NMR hardware. The “C-style” signature for these elements is defined below.
Delay
1
2
3
voiddelay(doubletime)# Delay for "time" seconds. If 0.0 is passed, the delay is ignored.
# The minimum delay time is about 67 ns.
Examples:
1
2
3
delay(0.1);delay(d1);delay(d2/2.0);
Pulse
1
2
3
4
5
voidpulse(doubletime,intphase)# Turn on the RF for duration of "time" seconds with the RF phase set to the
# value of the "phase" argument. A delay of "rof1" is done prior to turning
# on the RF pulse to allow the amplifier to switch on. A delay of "rof2" is
# done following the pulse to allow for probe ring-down.
voidrgpulse(doubletime,intphase,doublerg1,doublerg2)# Turn on the RF for duration of "time" seconds with the RF phase set to the
# value of the "phase" argument. A delay of rg1 is done prior to turning
# on the RF pulse to allow the amplifier to switch on. A delay of rg2 is
# done following the pulse to allow for probe ring-down.
# rgpulse(p1,zero,rof1,rof2) is equivalent to pulse(p1,zero).
voidoffset(doublefrequency)// Not yet implemented
# Offset the RF frequency to the supplied value.
Acquire
1
2
3
4
5
6
voidacquire(doubledatapnts,doubledwell)# Start acquiring data points. The number of data points is defined
# by the np parameter. The dwell period to acquire one complex pair is 1/sw.
# A delay of alfa is done prior to the acquire to account for filter
# delays. If a pulse sequence does not include an acquire pulse element,
# one will be automatically added at the end of the sequence.
Examples:
1
acquire(np,1.0/sw);
Power
1
2
3
4
5
6
7
voidpower(doubleamp)# Control the power of the amplifier during an RF pulse. The supplied
# amp can be in the range of 0.0 (no power) to 100.0 (full power).
# The power adjustment uses the pulse shaping capability of the SpinCore
# board. The power controls the amplitude of a rectangular shaped pulse.
# Only four power levels can be used, one of which is the full power
# pulse.
Settable
1
2
3
4
5
6
voidsettable(inttable,intcnt,intphases[])# The "table" argument is one of the phase table names t1-t10.
# The "cnt" argument is the number of phase elements to be assigned
# to the phase table. It is the number of elements in the array specified
# by the third argument. The phases[] arguemnt is a pre-defined array
# of phase elements. For an example, see the "Phase cycling" section.
Status
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
voidstatus(intstate)# Controls the on/off state of the microwave source. The microwave source
# is selected by the systemglobal bnc, which can be set with the config
# program to BNC0 or BNC1. The parameter xm controls the on/off state.
# It can have multiple states: status(A) sets the status described by
# the first letter of the xm parameter, status(B) uses the second letter,
# etc. If a pulse sequence has more status statements than there are
# letters in the xm parameter, control reverts back to the last letter
# of the parameter value. For example, xm='nyn' will turn the microwave
# source off during status A, on during status B, and off during
# status C. Any status higher than C (D-Z) will select the final character
# of the xm string (n) and turn the microwave source off.
# The states do to need to increase monotonically during a pulse
# sequence. One can write a pulse sequence that starts with status(A),
# goes later to status(B), returns to status(A) and then goes to status(C).
Example:
1
2
3
status(A);delay(d1);status(B);
will turn the microwave source on during the d1 delay if xm=‘yn’, It will turn the microwave source off during the d1 delay if xm=‘nn’
Getstr
1
2
3
4
5
6
7
8
voidgetstr(constchar*variable,charbuf[])voidgetstrnwarn(constchar*variable,charbuf[])# Get the value of a string parameter. The first argument is the name
# of the string parameter and the second argument is a character array
# of length MAXSTR. If the parameter does not exist, a null
# string is returned. The getstr() element will give a warning if the
# parameter does not exist. The getstrnwarn() will not give a
# warning if the parameter does not exist.
Example:
1
2
charmyFlag[MAXSTR];getstr("flag",myFlag);
Getval
1
2
3
4
5
6
7
doublegetval(constchar*variable)doublegetvalnwarn(constchar*variable)# Get the value of a real valued parameter. The argument is the name
# of the parameter. If the parameter does not exist, a 0.0
# is returned. The getval() element will give a warning if the
# parameter does not exist. The getvalnwarn() will not give a
# warning if the parameter does not exist.
Example:
1
doublemyVal=getval("val");
6.2.2 - Phase Cycling
There are several phase variables that control the phase of RF pulses and the phase of the receiver. These are:
zero, one, two, three
t1, t2, t3, t4, t5, t6, t7, t8, t9, and t10
oph
The constants PH0, PH90, PH160, PH270 are used to select the 0, 90, 180,and 270 degree phase. The constants ZERO, ONE, TWO, and THREE similarly represent the 0, 90, 180, and 270 degree phase. These are present for compatibility with Varian/Agilent pulse sequences.
There are also phase tables t1-t10 and oph. These tables may contain any number of phase elements. The particular element used is determined by the current transient (CT) being acquired. The tranisients increment from 0 to (nt-1) where nt is the total number of transients.
The zero, one, two, and three phase variables are initialized to ZERO, ONE, TWO, and THREE, respectively. The oph phase table controls the phase of the receiver. It is initialized to the four values {ZERO,ONE,TWO,THREE}, which represents the “cyclops” phase cycle. The t1-t10 tables are only used if they are defined by the pulse sequence.
The cp parameter (cycle phase) is typically set to ‘y’. If it is set to ’n’, the cycling of the receiver phase (oph) is turned off. That is, only the first element of the oph table is used. This is usually only used during FID shimming and wobble.
The second argument to the pulse element is the phase. For example:
1
pulse(pw, zero);
That second argument can to zero, one, two, or three. Equivalently, it can be PH0, PH90, PH180, or PH270. It can also be oph, in which case the phase of the pulse tracks the receiver phase. Phase tables t1-t10 can also be used. For example:
By setting oph to a table, one can alter the receiver phase.
1
settable(oph,4,ph1);
6.2.3 - Pulse Sequence Parameters
The following parameters are used by all pulse sequences. The global parameters do not exist and the defaults are the
normal values.
Parameter Name
Description
B12_BoardNum
global parameter specifying the SpinCore board number. default is 0
B12_BypassFIR
global parameter specifying whether to bypass the SpinCore FIR filter. default is 1
B12_ADC
global parameter specifying the SpinCore ADC frequency in MHz. default is 75.0
mps
set the state of the MPS when the experiment starts. At the end of the experiment, the state of the MPS will be returned to its original state. The mps parameter can be set to one of four values. manual - leave the MPS in the state it has been manually set to. off - turn the MPS off (rfstatus=0) on - turn the MPS on (wgstatus=1 rfstatus=1) ext - turn the MPS to ext state (wgstatus=1 rfstatus=2)
If mps=‘manual’ and the MPS is set in the “EXT” state or if mps=‘ext’, then pulse sequences will be able to control the MPS with the status() pulse element. Also, the mpspower parameter will be active. The default value for mps is ’ext’.
Experiment parameters used by all pulse sequences include:
Parameter Name
Description
exppath
the path name of the experiment where data will be stored. This is normally set when one does a “jexp” or join experiment.
arraydim
The total number of FIDs to be acquired for this experiment. This parameter is automatically set when one arrays a parameter.
sfrq
base frequency of the RF channel. This is normally a calculated value based on the selected nucleus (tn), the lockfreq, and any additional offset (tof).
np
the number of points in an acquired FID (total points, sum of reals and imaginaries). Number of complex pairs is np/2.
mpspower
the power of the MPS. Range is 0-60. If mpspower=-1, the MPS will be set to the “OFF” state. The mpspower parameter is only active if mps=‘ext’ or if mps=‘manual’ and the MPS unit has been manually set to the “EXT” state.
nt
number of transients.
sw
spectral width, in Hz.
tpwrf
amplitude of an RF pulse. Values range from 100.0 (full power) to 0.0 (no power). If tpwrf does not exist, or if it is set to “Not used” (tpwrf=‘n’), full power hard pulses are used. If tpwrf is set to a number between 0 and 100, the “shaped pulse” feature of the SpinCore board is used. The shape is a rectangular shape and tpwrf controls the amplitude of this shape. This allows for less than full power pulses.
rattn
controls the additional “Receiver attenuator” hardware. If rattn does not exist or is set to “Not used” (rattn=‘n’), then no instructions are sent to the additional attenuator. If rattn is a value between 0 and 120, then that value is sent to the attenuator. Setting rattn=0 means no attenuation of the incoming signal. Setting rattn=120 means adding 120 dBm of attenuation to the incoming signal.
rof1
time prior to an RF pulse to allow for the amplifier turnon time.
rof2
time following an RF pulse. Often reflects probe ringdown time.
alfa
delay prior to acquiring data. Often used to account for filter group delay.
cp
cycle phase, controls the behavior of the oph phase table. For cp=‘y’, the oph phase table uses all elements of the table. If cp=‘n’, only the first element of the table is used.
array
used to determine what parameters, if any, are arrayed.
ni
number of increments in the first indirect dimension. This identifies a 2D experiment.
ix
current increment. It’s values will range from 1 to arraydim. It can be used to select alternate sequences for an arrayed experiment. For example, to acquire data where every other FID has the microwave source turned on, one could do something like the following:
1
2
3
4
if(ix%2)status(A);elsestatus(B);|
Other parameter associated with a pulse sequence are used within the pulse sequence itself. For example, the s2pul.c pulse sequence uses
Parameter Name
Description
d1
relaxation delay prior to the first pulse.
p1
pulse width of the first pulse.
d2
delay between the first and second pulse.
pw
pulse width of the second pulse.
If custom parameters are defined for a pulse sequence, their values may be obtained with the getval() and getstr() pulse elements.
Processing parameters:
Parameter Name
Description
wexp
specify action to take at the completion of the data acquisition.
werr
specify action to take if an error occurs during data acquisition.
6.2.4 - ACODE
ACODE generation
When the OpenVnmrJ “go” command is executed, the parameter seqfil is used toselect the pulse sequence to execute. For example, if seqfil=‘s2pul’, then a binary file named s2pul is looked for in ~/vnmrsys/seqlib and /vnnmr/seqlib. If it is found, it is started and the parameters from the “joined” experiment, along with the global parameters are sent to the s2pul binary. The s2pul program then generates a set of acodes, based on the parameters and the details of the pulsesequence function. The acodes are keyword - value pairs. For example, running s2pul with just a single transient (nt=1) may generate a set of acodes such as
The values following each keyword are determined from the parameters that were sent to the pulse sequence program (s2pul). The acodes are reproduced below with the operative parameters noted.
DEBUG 0"debug flag set by whether go or go('debug') is called"BOARD_NUMBER 0"global B12_BoardNum parameter"BLANK_BIT 2"global B12_BlankBit parameter"BYPASS_FIR 1"global B12_BypassFIR parameter"ADC_FREQUENCY 75"global B12_ADC parameter"FILE /home/vnmr1/vnmrsys/exp2/acqfil "exppath parameter"ARRAYDIM 1"arraydim parameter"MPS ext "mps parameter"PULSEPROG_START 1"keyword indicating start of experiment.""Index indicates which array element is being collected""It would range from 1 to ARRAYDIM."SPECTROMETER_FREQUENCY 14.0005 "sfrq parameter"NUMBER_POINTS 32768"np parameter"NUMBER_OF_SCANS 1"nt parameter"SPECTRAL_WIDTH 8012.82 "sw parameter"POWERS 11000 -1 -1 -1 "values of the shaped pulse amplitudes"PULSE_ELEMENTS START "Keyword indicating start of pulsesequence"PHASE_RESET 1"Keyword to reset phases. Called once for each element in array."DELAY 1"d1 parameter"PULSE 4.9e-06 0 1e-05 "pw parameter, first element of oph phase table, rof1 parameter"DELAY 3.4875e-05 "sum of parameters rof2 and alfa"ACQUIRE 0"Keyword to trigger data acquisition. 0 argument is the""current transient (ct). It ranges from 0 to NUMBER_OF_SCANS-1""It is there to simplify acode parsing"PULSEPROG_DONE 1"Keyword to indicate acodes for FID 1 is done.""It also is an instruction to get the data from the""SpinCore system and save it to FILE"
Phase cycling is handled by incrementing the index used when accessing the phase tables. Note that the actual phase tables are not included in the acodes. Only the values of the indexed phase tables are in theacodes. To avoid multiple copies of the acodes where the only differences are the phase values, the PSG first scans the pulse sequence to determine the longest phase cycle used, and then uses the SpinCore looping mechanism to loop over the pulse elements the proper number of times.
To illustrate, the following are the acodes for s2pul with nt=10. The longest phase cycle used by s2pul is 4 for the receiver (oph) phase cycle. The acodes loop twice over four transients and then the remaining two transients follow. Acodes with no comments are the same as for the seqfil=‘s2pul’ and nt=1 case.
When the go command is executed, it generates the acode file as described above and a second file used by “the procs” to handle experiment queueing and monitoring. When the controlling Expproc determines that it is time to start an experiment, it checks its queue and starts B12proc, passing the name of the acode file to use.
The B12proc program reads the acode file line by line. Each keyword causes some action. Some keywords, such as BOARD_NUMBER, BLANK_BIT, BYPASS_FIR, ADC_FREQUENCY, FILE, NUMBER_POINTS, NUMBER_OF_SCANS, SPECTRAL_WIDTH, and POWER just set parameters. Other keywords cause SpinCore elements to be executed.
The PULSEPROG_START acode causes the SpinCore initialization functions to be called. It also initializes the internal current transient (ct) counter. The PULSE_ELEMENTS acode calls the pb_start_programming(PULSE_PROGRAM) SpinCore function.
The PULSEPROG_DONE acode calls the pb_stop_programming() function and also uses the pb_get_data() function to collect the data from the SpinCore board and save it to a file defined by the FILE keyword.
Other keywords, such as DELAY, PULSE, and ACQUIRE cause appropriate pb_inst_radio_shape() functions to be called .
6.2.5 - Hardware Control
Triggers of the SpinCore Board
The SpinCore board has four TTL lines, named Flag0 to Flag3. They have been assigned the following functions.
Name
Usage
Flag0
Trigger line to the MPS if the “mps” parameter is set to “ext” It is triggered by the status pulse element when the xm parameter for that status period is ‘y’.
Flag1
This controls the receiver unblanking. It goes high after the alfa delay when the SpinCore board is triggered to start data acquisition.
Flag2
This controls the amplifier unblanking. It goes high at the beginning of the rof1 delay prior to turning on the RF. It goes low after the RF is turned off.
Flag3
The controls setting the system into tune mode for RF turning. It goes high at the beginning of the “mtune” process and goes low when “mtune” completes. There is a delay of d1 duration prior to the start of the RF tuning process where Flag3 is also high. This gives the system time to switch into tune mode.
Receiver Attenuator
The “receiver attenuator” is a USB device controlled by the /vnmr/bin/mcl_RUDAT command. The range of values is 0 to 120 (in dB) in 0.25 steps. One can set the attenuator directly from a terminal with the command /vnmr/bin/mcl_RUDAT <value>.
The attenuator is controlled from a pulse sequence with the rattn parameter.
6.3 - OVJ Manuals
Below is a collection of Open VnmrJ manuals relevant to the Bridge12 SCN spectrometer. Many more manuals are available for Open VnmrJ. You can access those through the help menu in Open VnmrJ.
Manual
Description
Link
VnmrJ 4.2 Familarization Guide G7446-90569)
This guide provides an overview of the Open VnmrJ software and how you use it to acquire and process NMR spectra. Descriptions of the Open VnmrJ program user interface, toolbars, and menu items are included, along with general overview and description of the Open VnmrJ workflow.
This Guide contains information on how to administer the Open VnmrJ 4.2 software, including Account administration, Printer configuration, Spectrometer calibration, and VnmrJ terminology.