master:cinj parametersPSCAD Harmonic Current Injection
Every parameter of the PSCAD Harmonic Current Injection (master:cinj): 9 names, with the unit, the default and the meaning PSCAD gives each one. Copy a name into parameters().
What master:cinj is
Harmonic Current Injection, a component of PSCAD's Master Library, filed under meters and output.
- Definition
master:cinj- PSCAD name
- Harmonic Current Injection
- Category
- Meters and output
- Parameters
- 9, in 1 group; 5 carry a unit
- Read from
- PSCAD 5.0.0, 2026-11-07
Read and write master:cinj in Python
import mhi.pscad
pscad = mhi.pscad.connect() # the PSCAD that is open; launch() starts one
project = pscad.project("my_case") # a case loaded in the workspace
for comp in project.find_all("master:cinj"): # the exact definition, namespace first
params = comp.parameters() # every parameter, as PSCAD holds it
print(str(params["FInc"])) # Frequency Increment, in Hz
comp = project.find_all("master:cinj")[0]
comp.parameters(FInc="10 [Hz]") # a value that carries a unit is written with it
- A parameter is named exactly as in the table, letter case included:
parameters()gives every one of them in a dictionary, and a name the component does not have is refused. - A value that carries a unit comes back as a number whose unit is only in its text, so read it as text first (
str(...)) or the unit is lost. PSCAD keeps a written unit as it is given:"2500 [mohm]"stays in mohm. - A Choice is read and written as its symbol (the capitals in "Written as"), not as the words PSCAD shows in the dialog.
find_all()takes the exact definition only. A wildcard or a bare name withoutmaster:comes back empty; the Builder'spx_findwalks the pages for those.
The Builder's runtime does the same with the unit handled for you: px_get(comp, "FInc") and px_set(...), which also records the old value so the case is put back at the end. Getting started shows them.
Configuration
| Parameter | Unit | Default | Description |
|---|---|---|---|
CMagReal | · | 1.0 | Harmonic Current MagnitudeEnter the manitude of each harmonicAt least 0 |
FIncReal | Hz | 5.0 | Frequency IncrementFrequency increment between 2 harmonics. This will be used to get the actual maximum frequency if the number of increments between minimum and maximum is not a whole number.At least 1E-06 |
FMaxReal | Hz | 1000.0 | Maximum FrequencyFrequency of the higest harmonic. This may be adjusted automatically to satisty integer number of increments.At least 0 |
FMinReal | Hz | 5.0 | Minimum FrequencyFrequency of the lowest harmonicAt least 0 |
NameText | · | Source | Name for IdentificationEnter a name for identification |
PSReal | deg | 0.0 | Phase ShiftEntering non-zero value would help to avoid very large magnitudes. |
SeqChoice | · | POSITIVE | Sequence(s) to InjectSelect what sequences to injectWritten as POSITIVE (positive), ZERO (zero), NEGATIVE (negative), ALL (All) |
TRampReal | s | 0.2 | Ramp up TimeEnter the time to ramp up to the full magnitudeAt least 0 |
ViewChoice | · | SINGLE_LINE | Graphics DisplaySelect single line or 3 phase viewWritten as 3_PHASE (3 phase view), SINGLE_LINE (Single line view) |
Related
- All 345 definitions in the component reference
- Harmonics and THD from a PSCAD run
- PSCAD automation with Python: getting started
← master:freq-meas Frequency/Phase/RMS Meter · master:thd Harmonic Distortion Calculator →