Mode
(read/write)
This property sets/gets the Monitor mode (bitmask integer). It can be one of the following:
0 = Voltages and currents at designated terminal
1 = Powers at designated terminal
2 = Tap Position (Transformer Device only)
3 = State Variables (PCElements only)
4 = Flicker level and severity index (Pst) for voltages. No adders apply. Flicker level at simulation time step, Pst at 10-minute time step.
5 = Solution variables (Iterations, etc). Normally, these would be actual phasor quantities from solution.
6 = Capacitor Switching (Capacitors only)
7 = Storage state vars (Storage device only)
8 = All winding currents (Transformer device only)
9 = Losses, watts and var (of monitored device)
10 = All Winding voltages (Transformer device only) Normally, these would be actual phasor quantities from solution.
11 = All terminal node voltages and line currents of monitored device
Combine mode with adders below to achieve other results for terminal quantities:
+16 = Sequence quantities
+32 = Magnitude only
+64 = Positive sequence only or avg of all phases
Mix adder to obtain desired results. For example:
Mode=112 will save positive sequence voltage and current magnitudes only
Mode=48 will save all sequence voltages and currents, but magnitude only.
Example
% Create DSS object
DSSObject = actxserver('OpenDSSEngine.DSS')
if ~DSSObject.Start(0),
disp('Unable to start openDSS');
return
end;
DSSText = DSSObject.Text;
DSSCircuit = DSSObject.ActiveCircuit;
% Compile a model
DSSText.Command = 'Compile C:\myPath\myModel.dss';
DSSText.Command = 'solve mode=daily';
DSSMonitors = DSSCircuit.Monitors;
% select the first monitor on the list
i = DSSMonitors.First;
% gets the active monitor's mode
myMode = DSSMonitors.Mode;