IscBattery

The IscBattery class provides access to an IPSA battery, to set and get data values and to retrieve load flow results.

Field Values

IscBattery Field Values

Type

Field Name

Description

Integer

FromUID

Gets the unique ID for busbar.

String

BusName

Gets the busbar name.

String

Name

Gets the synchronous machine name.

Integer

Status

Status:

  • 0 = Switched in

  • -1 = Switched out

Integer

Model

Sets and gets the model type for the battery:

  • 0 = Voltage type

  • 1 = Current type

Float

VoltPU

Sets and gets the battery terminal voltage in per unit.

Float

EmfPU

Sets and gets the battery internal EMF in per unit.

Float

ResistancePU

Sets and gets the internal battery resistance in per unit.

Float

CurrentPU

Sets and gets the battery current in per unit.

Float

InductancePU

Sets and gets the internal battery inductance in per unit.

IscBattery Class

class ipsa.IscBattery

Provides access to an Ipsa battery.

SetName(strName: str) bool

Sets the name as a string.

Parameters:

strName (str) – The selected string name.

Returns:

True if successful.

Return type:

bool

GetIValue(nFieldIndex: int) int

Returns an integer value for the enumerated field.

Parameters:

nFieldIndex (int) – The field index.

Returns:

The integer value.

Return type:

int

GetDValue(nFieldIndex: int) float

Returns a double value for the enumerated field.

Parameters:

nFieldIndex (int) – The field index.

Returns:

The double value.

Return type:

float

GetSValue(nFieldIndex: int) str

Returns a string value for the enumerated field.

Parameters:

nFieldIndex (int) – The field index.

Returns:

The string value.

Return type:

str

GetBValue(nFieldIndex: int) bool

Returns a boolean value for the enumerated field.

Parameters:

nFieldIndex (int) – The field index.

Returns:

The boolean value.

Return type:

bool

SetIValue(nFieldIndex: int, nValue: int) bool

Sets the value for the enumerated field from an integer.

Parameters:
  • nFieldIndex (int) – The field index.

  • nValue (int) – The given integer value.

Returns:

True if successful.

Return type:

bool

SetDValue(nFieldIndex: int, dValue: float) bool

Sets the value for the enumerated field from a double.

Parameters:
  • nFieldIndex (int) – The field index.

  • dValue (float) – The given double value.

Returns:

True if successful.

Return type:

bool

SetSValue(nFieldIndex: int, strValue: int) bool

Sets the value for the enumerated field from a string.

Parameters:
  • nFieldIndex (int) – The field index.

  • strValue (str) – The given string value.

Returns:

True if successful.

Return type:

bool

SetBValue(nFieldIndex: int, bValue: bool) bool

Sets the value for the enumerated field from boolean.

Parameters:
  • nFieldIndex (int) – The field index.

  • bValue (bool) – The given boolean value.

Returns:

True if successful.

Return type:

bool

GetRealPowerMW() float

Returns the battery output in MW.

Returns:

The battery output in MW.

Return type:

float

GetRealPowerkW() float

Returns the battery output in kW.

Returns:

The battery output in kW.

Return type:

float

GetTotalPowerMVA() float

Returns the battery produced total power in MVA.

Returns:

The battery produced total power in MVA.

Return type:

float

GetTotalPowerkVA() float

Returns the battery produced total power in kVA.

Returns:

The battery produced total power in kVA.

Return type:

float

GetVoltagePU() float

Returns the battery injected voltage in per unit.

Returns:

The battery injected voltage in per unit.

Return type:

float

GetCurrentPU() float

Returns the battery injected current in per unit.

Returns:

The battery injected current in per unit.

Return type:

float

GetCurrentkA() float

Returns the battery injected current in kA.

Returns:

The battery injected current in kA.

Return type:

float