VIII - "Externals"


WinSPA's file formats

Instead of creating yet another proprietory binary file format, the usage of NetCDF was decided for WinSPA. This file format is

  • Self-Describing
  • Architecture-independent
  • Sharable
  • Direct-access

You can find many resources for and about this file format in the world wide web, for example

Even though in principle NetCDF files are self-describing, the variables in WinSPA files are described in detail below.

Note: If you want to import/export NetCDF files with the programming language Delphi, you can use the same interface library that was used for WinSPA. It is an improved version of the Delphi NetCDF interface declaration by Sandy Ballard of Sandia.

Global attributes

The global attributes are defined in all NetCDF files saved by WinSPA. They describe the type of the file and contain information about the WinSPA release the file was created with.

Name of NetCDF variable Full name Comments
Title Title of the file. This describes the type of the file.
History History of file changes. Contains only the creation by default.
Creator Program that created the file. Contains "WinSPA".
Version Version of the creating software. Version and date of the WinSPA release the file was created with.

The different file "types" WinSPA uses are:

  • 1D scan. Title is "one dimensional scan of electron diffraction pattern" in this case.
  • 2D scan. Title is "two dimensional scan of electron diffraction pattern" in this case.
  • RSM scan. Title is "reciprocal space map with SPA-LEED" in this case.
  • SEM scan. Title is "real space scan with SPA-LEED" in this case.
  • I(t) scan. Title is "observation of diffraction intensities versus time" in this case.

Note: WinSPA accepts also 2D scans with scan units Volts as SEM scan and vice versa.

General scan information

The general scan information parameters are the same for all WinSPA save files, independent of the scan type. They describe how the scan data were acquired (gate time, scan time, min/max counts, cycles, etc.).

Name of NetCDF variable Full name Units Comments
MinCnts Minimum number of counts within scan -- ...
MaxCnts Maximum number of counts within scan -- ...
CycleCnt Number of scan cycles with averaging -- ...
TStart Start time of scan Days since 12/30/1899 ...
TStop Stop time of scan Days since 12/30/1899 ...
TStartRel Relative start time of scan msecs. since t=0 of stop watch ...
GateTime Counter gate time msecs. ...
Interrupted Scan interrupted? 0 = no, 1 = yes ...
RawData Scan data unaltered? 0 = no, 1 = yes ...
Comment User's comment to scan None (string variable) As entered in the "comment" field in the respective "file settings" group box.
Usr1,Usr2,Usr3,Usr4 User defined values #1..#4 Unknown A legacy of Spa4.1d only. Not used or written by WinSPA. May only contains values, if a .d2d file was imported and saved as a WinSPA file.

Sample information

The global sample parameter settings are saved for documentation.

Name of NetCDF variable Full name Units
SName Surface name None (string variable)
SLConst Surface lattice constant Å
SSHeight Surface step height Å

Data scaling information

The original scan data and the scaling of the data are fundamentally distinguished in WinSPA. Consequently there are explicit variables which only affect the scaling of the scan data upon loading the respective scan data file.

Name of NetCDF variable Full name Units Comments
ScMinCnts Min. value to display Counts ...
ScMaxCnts Max. value to display Counts ...
MinXValue X axis start ... ...
MaxXValue X axis stop ... ...
SclType Type of scaling (lin/log) -- 0 = lin, 1 = log

The zoom for all 2D scan data (2D, SEM, RSM) is described by a rational fraction consisting of numerator and denominator, where both are small integer numbers.

Name of NetCDF variable Full name Units Comments
ScMinCnts Min. value to display Counts ...
ScMaxCnts Max. value to display Counts ...
CTIndex Index of used colour table -- As in table of color tables.
CTInvert Invert color table? -- 0 = no, 1 = yes
SclType Type of scaling (lin/log) -- 0 = lin, 1 = log
XZoomNum X zoom numerator -- X zoom factor.
XZoomDenom X zoom denominator -- X zoom divider. Yet unused
YZoomNum Y zoom numerator -- Y zoom factor.
YZoomDenom Y zoom denominator -- Y zoom divider. Yet unused

Scan data

For each of the five scan modes of WinSPA (1D, 2D, RSM, SEM, I(t)) there is one set of parameters for the range of the measurement and the scan data.

1D scan data

Name of NetCDF variable Full name Units
Cnts Scan data (counts) --
x0 kx scan center =kUnits
y0 ky scan center =kUnits
XYDist Scan size in k|| direction =kUnits
k k|| axis =kUnits
Points Number of scan points --
Angle Scan rotation (anti-clockwise) °
Energy Electron energy eV
Phase Scattering phase --

2D scan data

Name of NetCDF variable Full name Units
Cnts Scan data (counts) --
x0 kx scan center=kUnits
y0 ky scan center=kUnits
XDist kx scan size =kUnits
YDist ky scan size =kUnits
X kx axis =kUnits
Y ky axis =kUnits
PointsX Number of scan points in x direction--
PointsY Number of scan points in y direction--
Angle Scan rotation (anti-clockwise) °
Energy Electron energy eV
Phase Scattering phase --

SEM scan data

Name of NetCDF variable Full name Units
Cnts Scan data (counts) --
x0 X scan center =xUnits
y0 Y scan center =xUnits
XDist X scan size =xUnits
YDist Y scan size =xUnits
X X axis =xUnits
Y Y axis =xUnits
PointsX Number of scan points in kx direction--
PointsY Number of scan points in ky direction--
Angle Scan rotation (anti-clockwise) °
Energy Electron energy eV

RSM scan data

Name of NetCDF variable Full name Units
Cnts Scan data (counts) --
x0 X scan center =kUnits
y0 Y scan center =kUnits
XYDist XY scan size =kUnits
Z1 kz(1), scan start coordinate =zUnits
Z2 kz(2), scan stop coordinate =zUnits
kx k|| axis =kUnits
kz kz axis =zUnits
PointsXY Number of scan points in k|| direction --
PointsZ Number of scan points in kz direction --
Energies Electron energies eV
Angle Scan rotation (CCW) °
Energy Electron energy eV
Phase Scattering phase --

I(t) scan data

Name of NetCDF variable Full name Units
Cps# Intensities of spots (vs. time) Counts per second
kx# kx of spot # =kUnits
ky# ky of spot # =kUnits
t Time axis Seconds
points Number of measured data points --
x0 kx(0) for reference spot. =kUnits
y0 ky(0) for reference spot. =kUnits
Name# Name of LEED spot # None (string variables)
Energy Electron energy eV
Phase Scattering phase --
FWHM Assumed width of reference spot. =kUnits
MaxD Assumed maximum jump distance of reference spot. =kUnits
AlgNr Number of spot tracking algorith used. --
PtScan Point scan activated? 0 = no, 1 = yes
Thrshld Threshold for point scan activation. Counts per second


The configuration file

WinSPA saves all global settings into a configuration file (config.txt) in the program path. You can open this file with any text file editor and make changes in it. Specifically, if you want to add other surfaces to the presets list, just enter the parameters for name, step height and lattice constant into the config file, separated by " / " (space slash space).