Metadata FieldDocument Information
StatusDraft
Created2026-11-24
Last Updated2026-11-24
AuthorDavide Cuneo
Rev. #1.0
ReviewersDavide

Introduction and Context

The COMBO power converters of FREIA are controlled by an FGC3 (Function Generator/Controller, third generation). This note explains how to operate it: properties, loads, states, reference functions, regulation parameters and the most useful commands. For the converter hardware, the rack and the physics of a magnet load, see 7. COMBO power converters; for the acronyms, see the Glossary.

Source documents.

  1. List of FGC Properties for FREIA Test Station, EDMS 2186846, v1.0 (2019-06). Called “FREIA property list” below.
  2. FGC2/3 Reduced List of Useful Commands, EDMS 1468438, rev. 1.7 (2018-03-26), Y. Thurel. Called “Reduced List” below.

Talking to the FGC: Properties

The FGC3 is operated by reading and writing properties:

  • g PROPERTY — get: reads a value. Harmless.
  • s PROPERTY value — set: changes a value. Changes the behaviour of the converter.

Property names are hierarchical: REF.PLEP.FINAL is the FINAL parameter of the PLEP function, in the REF family. Recognising the families makes any command list readable.

Table 1: Main property families.

FamilyContent
MODE, STATERequested state and actual state of the converter
LOADElectrical parameters of the magnet (R, L) and load selection
REFReference functions (PLEP, table, sine) and their execution
REGRegulation loop parameters
LIMITSProtection limits (current, rate, regulation error)
MEASMeasurements
FGC, DIAG, VSFaults and diagnostics of FGC and voltage source

Loads

One converter can be configured for several magnets. Each configuration is a load, identified by an index in square brackets: LOAD.HENRYS[1] is the inductance of load 1. A load is therefore not a file: it is the set of all the properties with the same index (load parameters, regulation parameters, limits). The FREIA FGCs have 4 loads (0–3): g load shows them as 4 columns.

LOAD.SELECT tells the FGC which load to use. According to the FREIA property list (2019), loads 0, 1 and 3 contain the configuration of MCBXFA, MCBXFB and MCBRD respectively. In November 2026 the TYPE field read MAGNET for load 0 and SHORT_CIRCUIT for load 2, used for the short circuit test (see 5. Short circuit test of a COMBO power converter). The content of the loads changes with the test campaigns: always read it with g load instead of relying on this list.

Full property names

Load properties must be written with their prefix: s load.ohms_ser[2] 5e-3 works, s ohms_ser[2] 5e-3 gives !17 unknown sym. Upper and lower case are equivalent (limits.i.CLOSELOOP = limits.i.closeloop).

The selected load must match the connected magnet

With the wrong load selected, the FGC regulates and protects as if another magnet were connected (wrong L and R, presumably wrong limits). Checking that the selected load matches the magnet physically connected is a fixed point of every session.

Converter States and Session Steps

The CERN documents do not describe the operational steps explicitly. Figure 1 and Table 2 reconstruct them from the FREIA property list, the Reduced List and the first tests at FREIA. The short commands s pc of and s pc il were verified in practice; the long forms s MODE.PC ... come from the FREIA property list and were not tested.

stateDiagram-v2
    OFF --> ON_STANDBY: s MODE.PC ON_STANDBY
    ON_STANDBY --> IDLE: s MODE.PC IDLE
    OFF --> IDLE: s pc il (verified)
    IDLE --> Armed: s REF.FUNC.TYPE ...
    Armed --> Running: s REF.RUN
    Running --> IDLE: end of function
    IDLE --> ON_STANDBY: s MODE.PC ON_STANDBY
    ON_STANDBY --> OFF: s MODE.PC OFF
    IDLE --> OFF: s pc of (verified)
    IDLE --> Fault: trip
    Fault --> OFF: reset

Figure 1: Simplified state machine of the converter.

From OFF directly to IDLE

At FREIA, s pc il sent with the converter OFF brings it to IDLE by itself: the FGC goes through the start-up states automatically (visible for a moment in the state line). It is not necessary to stop in ON_STANDBY first.

Table 2: Steps of a typical session and states of the converter.

#StepCommands / checksState of the converter
1Check the permission to operate and that no fault is activeCooling interlock / PC_PERMIT; g fgc.faults, g statusOFF: power part off, no current. The FGC3 is powered and communicating. ADC auto-calibration runs every 24 h only in this state (or on demand with S CAL ADCS)
2Select the load and check that it matches the connected magnets load.select n, then read it back with g loadOFF
3Choose the regulation mode (current for a magnet)s reg.mode i (or v); read it back with g regOFF
4Switch on and go to IDLEs pc il (directly from OFF). Long form, not tested: s MODE.PC ON_STANDBY, then s MODE.PC IDLEON_STANDBY, passed through automatically: converter on, current presumably held at LIMITS.I.STANDBY of the selected load (?). Then IDLE: the converter regulates on a constant reference, ready for new functions
5Set the parameters of the functionPLEP, table or sine parameters (see Reference Functions)IDLE
6Arm the function and check for arming errorss REF.FUNC.TYPE ...; if refused: g REF.ERROR.FG_ERRArmed: the function is ready. Tables are armed in IDLE
7Start the function and follow its REF.RUNRunning
8End of functiong STATE.PC (?)Back to IDLE at the final value (?)
9Bring the current down with a descending PLEP (prudent practice) (?)PLEP to a low valueIDLE
10Switch offs pc ofOFF
–After a trips vs reset, or s pc of (which also resets the faults)Fault: the converter switches off; a reset is needed

The regulation mode is reset at switch-off

After s pc of the regulation mode goes back to current (I). If you need voltage mode (for example in a short circuit test), set s reg.mode v again before every start.

Switching off from high current

The FREIA property list only says “standby, then off”. It does not say what happens to the current, nor whether the current must first be ramped down. With a superconducting magnet storing energy this is not a detail. Until it is confirmed, ramp down to a low current with a PLEP before going to standby and OFF.

Reference Functions

Common pattern

All the reference functions of the FREIA property list follow the same pattern:

  1. Set the parameters of the function.
  2. Arm it: s REF.FUNC.TYPE PLEP / SINE (the FGC checks it against the limits).
  3. Run it: s REF.RUN 0, or simply S REF.RUN without argument.

REF.RUN contains the absolute time at which the armed function must start. A time in the past, or zero, starts it immediately.

If arming fails, g REF.ERROR.FG_ERR gives the reason. A refused function is not a fault: it is the protection doing its job, and the first thing to check when “it does not start”.

PLEP ramp

The PLEP is the standard ramp from one current to another. Its shape is made of up to four segments: Parabolic – Linear – Exponential – Parabolic.

  • Parabolic start: the current starts smoothly, with constant acceleration.
  • Linear: the current changes at constant rate (A/s).
  • Exponential: used in ramp-downs of a 1Q converter. As the current decreases, the fastest possible decay (at the limiting voltage) gets slower, and the reference must follow the natural exponential of the circuit.
  • Parabolic end: the current decelerates and lands on the final value without overshoot.

A short ramp may never reach the linear rate: it becomes PP. Without the exponential segment it is PLP, the normal shape of a ramp-up.

Table 3: PLEP parameters (FREIA property list, “Ramps”).

PropertyMeaning
REF.PLEP.FINALFinal value of the reference.
REF.PLEP.ACCELERATIONParabolic acceleration and deceleration. Always positive, even for a descending PLEP.
REF.PLEP.LINEAR_RATEMaximum linear rate of change. Always positive.
REF.PLEP.EXP_TCTime constant of the exponential segment. 0 disables it (PP or PLP only).
REF.PLEP.EXP_FINALOnly used if EXP_TC ≠ 0. Final value of the exponential segment: the steady-state current reached when the converter produces its limiting voltage.

Choosing EXP_TC and EXP_FINAL (to be verified)

From the physics, EXP_TC should correspond to the circuit time constant τ = L/R, and for a 1Q converter whose limiting voltage is 0 V, EXP_FINAL should be about 0 A. To be confirmed with the CERN experts.

Table function

A table is an arbitrary current profile, given as pairs time|value separated by commas (FREIA property list, sec. 4):

s REF.TABLE.FUNC.VALUE 0|I0,t1|I1,t2|I2,…

Rules:

  • the table is armed in IDLE;
  • the first time must be 0, and the first value must correspond to the present reference (the original wording, “within 1.0E-5 of the positive limit of the actual reference value”, is ambiguous);
  • each following time must increase by at least one FGC iteration period;
  • every segment is checked against the I and dI/dt limits; segments are numbered by their second point (the first segment has index 1);
  • if arming fails, read g REF.ERROR.FG_ERR; start with s REF.RUN 0.

Descending segments may be limited by the 1Q converter.

Sine function

From the FREIA property list, sec. 5:

Table 4: Sine parameters.

PropertyMeaning
REF.TEST.AMPLITUDEPeak-to-peak amplitude, centred on the initial reference.
REF.TEST.NUM_PERIODSNumber of periods. NUM_PERIODS × PERIOD must not exceed 1E6.
REF.TEST.PERIODPeriod of the sine.
REF.FUNC.TYPE SINEArms the sine.

Load and Regulation Parameters

Section 1.3 of the Reduced List sets the parameters of load [0] for two cases: a pure resistor (a test load) and an R-L load (a magnet).

Load parameters: what the magnet is

PropertyMeaningExample
load.ohms_ser[n]Series resistance of the circuit (Ω)0.1 = 100 mΩ
load.henrys[n]Inductance (H)0.003 = 3 mH

For a pure resistor, L is set to about zero, or to 1 µH per metre of cable (rule of thumb from the source).

Regulation parameters: how to react

  • reg.i.period_div[n] — how often the FGC recomputes. The regulation period is the base iteration period multiplied by period_div. With period_div = 10 the FGC3 regulates every 1 ms, so its base iteration is 0.1 ms (10 kHz, consistent with the FGC3 specification, sec. 1.3). On the FGC2 the base period is already 1 ms.
  • reg.i.clbw[n] — how fast to react. Closed-loop bandwidth, in Hz: how quickly the current follows a change of reference and how quickly disturbances are corrected. A regulator too aggressive for its load overshoots and oscillates.
  • reg.i.clbw2[n] — second bandwidth parameter of the regulation algorithm, used when the load has a significant inductance: 0 for a pure resistor, 20 for a warm magnet. Its exact meaning in the FGC algorithm is not known (?).

Table 5: Regulation recipes for the FGC3 (Reduced List 1.3).

Loadclbwclbw2period_divRegulation period
Pure resistor15–30001–100.1–1 ms
Warm magnet6020101 ms
Superconducting magnet (“Supra”)111000100 ms

The Supra line is the closest to the FREIA case. A superconducting magnet has a large L and a tiny R, so τ is huge and the current changes slowly whatever the regulator does: a fast regulator would be useless, and could become unstable.

These property names do not exist on the FREIA FGCs

Table 5 reproduces the Reduced List (2018). On the FREIA FGC3s (November 2026), g reg.i does not list clbw, clbw2 or period_div. The current loop is described by other properties, one value per load:

Property (FREIA FGC)Load 0 (magnet)Probable meaning
REG.I.PERIOD_ITERS1000Regulation period in FGC iterations; probably the equivalent of period_div (?)
REG.I.INTERNAL.AUXPOLE1_HZ0.5Main pole of the regulator, i.e. its “bandwidth”: how fast it reacts (?)
REG.I.INTERNAL.AUXPOLES2_HZ, …AUXPOLES2_Z0.1, 0.5Second pair of poles of the regulator (?)
REG.I.EXTERNAL.CLBW, …Z, …MOD_MARGIN1, 0.1, 0.5Parameters of the external algorithm, which is DISABLED

The value of load 0 (PERIOD_ITERS = 1000) is consistent with the “Supra” recipe of Table 5. Example of a change made by the CERN expert on the short circuit load: s reg.i.internal.auxpole1_hz[2] 30 (from 0.7 to 30, because 0.7 is far too slow for a resistive load). Do not change these parameters without the CERN experts.

Other Useful Commands (Reduced List)

Table 6: Controlling the states (Reduced List 1.1).

CommandFunction
s vs resetReset the faults, if any (s pc of also resets them).
s vs.fasbort_unsafeReset the “fast abort unsafe” fault at the first AC connection (name as written in the source; possibly a typo).
s pc ofSend the converter to OFF.
s pc il / s pc dt / s pc cyStart in IDLE / DC direct / cycling mode.

Table 7: Diagnosing a trip (Reduced List 1.2). A trip can come from the FGC (regulation issue) or from the power source (internal fault, or external interlock).

CommandFunction
g fgc.faultsConverter faults (FGC + power module + DCCT).
g diag.faultsActive faults of the voltage source.
g diag.digDigital signals of the power source diagnostic card.
g diag.anaAnalogue signals of the power source diagnostic card.
g statusDetailed status: limits, faults, warnings.

Table 8: Current limits. Guidance from the Reduced List 1.4, property names as they appear on the FREIA FGCs (g limits.i, November 2026).

CommandFunction and guidance
g limits.iList the current limits of all the loads (one column per load).
s limits.i.pos[n] valueMaximum current = maximum current of the load.
s limits.i.pos v0,v1,v2,v3Sets the same property for all four loads in one command, e.g. s limits.i.pos 1500,1500,1500,1500.
s limits.i.neg[n] valueMinimum (negative) current: 0 on the FREIA 1Q converters.
s limits.i.standby[n] valueCurrent in ON_STANDBY (?). Replaces the limits.i.min of the Reduced List, which does not exist on the FREIA FGCs.
s limits.i.closeloop[n] valueCurrent above which the regulation loop is closed (Reduced List: ≈ min / 2).
s limits.i.low[n], s limits.i.zero[n]Thresholds for “low current” and “zero current” (?).
s limits.i.rate[n] valueMaximum dI/dt, typically 10–100 A/s.
s limits.i.err_warning[n] valueRegulation error giving a warning (typically err_fault / 10).
s limits.i.err_fault[n] valueRegulation error giving a fault, i.e. a trip (1–5 % of the converter current).

limits.i.acceleration, listed in the Reduced List, does not appear on the FREIA FGCs. The voltage limits are read with g limits.v (POS, NEG, RATE, ERR_WARNING, ERR_FAULT).

Changing limits

At FREIA, s limits.i.pos ... sent while the converter was not OFF was refused with !34 bad state, and accepted after s pc of (observed once) (?). Change the limits with the converter OFF.

Table 9: DC reference and regulation performance (Reduced List 1.5 and 1.7).

CommandFunction
s reg.mode v or iRegulate in voltage or in current (magnets: current). Verified at FREIA. The Reduced List writes s ref.func.reg_mode v, not tested. Read it back with g reg (field MODE).
s ref now,10In IDLE: go to 10 A (or 10 V in voltage mode). Verified at FREIA.
s ref now,10,d²x/dt²,dx/dtSame, with the given acceleration and rate (optional arguments).
s ref ltrim,10,dtIn IDLE: go to 10 A (or V) in a time dt.
s ref.ccv 10In DC direct mode: send the reference directly (error if incompatible with limits.i.rate).
g meas.max.abs_err zeroReset the maximum regulation error.
wait 1 min (or more)
g meas.max.abs_errMaximum regulation error over the period. The main figure of merit of the regulation.

Table 10: Messages of the FGC terminal seen at FREIA. A line starting with ! is an error: the command was not executed.

MessageMeaning
!17 unknown symUnknown property name (e.g. missing prefix: ohms_ser instead of load.ohms_ser).
!28 out of limitsThe requested value is outside a limit of the selected load.
!34 bad stateThe command is not allowed in the present state of the converter (e.g. in fault, or a setting that needs the converter OFF).
!55 pm in progressPost-mortem acquisition running after a trip: wait, then reset.

Validity of the Commands on the FREIA FGCs

The Reduced List dates from 2018 and was written for reception tests at CERN; the FREIA property list from 2019. Some names have changed since then. The table summarises what was checked on the FREIA FGC3s in November 2026.

Table 11: Commands of the CERN documents compared with the FREIA FGCs.

Command in the documentsOn the FREIA FGCsStatus
s pc of, s pc ilSame✅ Verified
s load.select nSame✅ Verified
load.ohms_ser[n], load.henrys[n]Same; the load. prefix is mandatory✅ Verified
s ref now,valueSame; the optional arguments can be omitted✅ Verified
Index [n], upper/lower caseSame; case does not matter✅ Verified
s ref.func.reg_mode v/is reg.mode v/i⚠️ Use reg.mode; the long form was not tested
s MODE.PC ON_STANDBY / IDLE / OFFs pc il / s pc of used instead; s pc il works directly from OFF⚠️ Long form not tested
reg.i.clbw, reg.i.clbw2, reg.i.period_divNot listed; replaced by REG.I.PERIOD_ITERS, REG.I.INTERNAL.AUXPOLE…❌ Different names
limits.i.minNot listed; LIMITS.I.STANDBY exists❌ Different name
limits.i.accelerationNot listed❌ Not present
s REF.FUNC.TYPE, s REF.RUN, PLEP, table, sineNot used during the tests❓ Not verified
g fgc.faults, g diag.*, g status, s vs resetNot used during the tests❓ Not verified

Feedback

Found an error or something outdated in this note? Please contact Davide Cuneo (davide.cuneo@physics.uu.se).