(read only)


This property returns all Winding currents (ph1, wdg1, wdg2,... ph2, wdg1, wdg2 ...) in an array of floating point (doubles) values.


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';

DSSXfmr = DSSCircuit.Transformers;

% Activates the first transformer on the list

j = DSSXfmr.First;

% Get the currents on each winding (complex)

myCurrents = DSSXfmr.WdgCurrents;

myCols = size(myCurrents)/DSSXfmr.NumWindings;

% Format complex data into mag - angle

myAmpsMagAng = [];

for k = 1:DSSXfmr.NumWindings,

    myRow = [];

    myShift = myCols(2) * (k - 1);

    for a = 1:2:myCols(2),

        myMag = abs(myCurrents(1,a + myShift) + i*myCurrents(1,a + myShift + 1));

        myAng = angle(myCurrents(1,a + myShift) + i*myCurrents(1,a + myShift + 1)) * 180/pi;

        myRow = [myRow, [myMag, myAng]];

    end;

    myAmpsMagAng = [myAmpsMagAng; myRow];

end;