Skip to content

stdlib/gridView source ↗

grid

52 items · generated by scribe fromstdlib/grid.fd· synced 2026-11-15

stdlib/grid52 items

Contents

LN_XCBR:

pub const LN_XCBR: i64 = 0;  // Circuit Breaker

Defined at line 24


LN_XSWI:

pub const LN_XSWI: i64 = 1;  // Switch / Disconnector

Defined at line 25


LN_MMXU:

pub const LN_MMXU: i64 = 2;  // Measurement (voltage, current, power)

Defined at line 26


LN_PTUV:

pub const LN_PTUV: i64 = 3;  // Voltage Time Protection

Defined at line 27


LN_PTOC:

pub const LN_PTOC: i64 = 4;  // Overcurrent Protection

Defined at line 28


LN_PDIS:

pub const LN_PDIS: i64 = 5;  // Distance Protection

Defined at line 29


LN_RREC:

pub const LN_RREC: i64 = 6;  // Disturbance Recorder

Defined at line 30


LN_RBRF:

pub const LN_RBRF: i64 = 7;  // Breaker Failure

Defined at line 31


LN_CSWI:

pub const LN_CSWI: i64 = 8;  // Control Switch

Defined at line 32


LN_CILO:

pub const LN_CILO: i64 = 9;  // Interlocking

Defined at line 33


LN_CSWI2:

pub const LN_CSWI2: i64 = 10;  // Control Switch (alternate)

Defined at line 34


iec61850_ln_name

Get logical node name.

pub fn iec61850_ln_name(ln_type: i64) -> str {

Parameters:

  • ln_type: i64

Returns: str

Defined at line 37


CDC_SPS:

pub const CDC_SPS: i64 = 0;  // Single Point Status

Defined at line 73


CDC_DPS:

pub const CDC_DPS: i64 = 1;  // Double Point Status

Defined at line 74


CDC_MV:

pub const CDC_MV: i64 = 2;  // Measured Value

Defined at line 75


CDC_ASG:

pub const CDC_ASG: i64 = 3;  // Analog Setting

Defined at line 76


CDC_ING:

pub const CDC_ING: i64 = 4;  // Integer Setting

Defined at line 77


CDC_ENG:

pub const CDC_ENG: i64 = 5;  // Enumerated Setting

Defined at line 78


CDC_SPC:

pub const CDC_SPC: i64 = 6;  // Single Point Controllable

Defined at line 79


CDC_DPC:

pub const CDC_DPC: i64 = 7;  // Double Point Controllable

Defined at line 80


CDC_INC:

pub const CDC_INC: i64 = 8;  // Integer Controllable

Defined at line 81


iec61850_cdc_name

Get CDC name.

pub fn iec61850_cdc_name(cdc: i64) -> str {

Parameters:

  • cdc: i64

Returns: str

Defined at line 84


XCBR

A circuit breaker logical node.

pub struct XCBR {

Fields:

NameType
namestr
ln_typei64
positioni64
healthi64
capable_of_opbool
op_cnti64
rated_currenti64

Defined at line 120


iec61850_xcbr_new

Create a new circuit breaker.

pub fn iec61850_xcbr_new(name: str, rated_current: i64) -> XCBR {

Parameters:

  • name: str
  • rated_current: i64

Returns: XCBR

Defined at line 135


iec61850_xcbr_set_pos

Set breaker position (0=open, 1=closed).

pub fn iec61850_xcbr_set_pos(breaker: & mut XCBR, pos: i64) -> void {

Parameters:

  • breaker: & mut XCBR
  • pos: i64

Returns: void

Defined at line 144


iec61850_xcbr_pos_name

Get breaker position name.

pub fn iec61850_xcbr_pos_name(breaker: XCBR) -> str {

Parameters:

  • breaker: XCBR

Returns: str

Defined at line 155


iec61850_xcbr_is_closed

Check if breaker is closed.

pub fn iec61850_xcbr_is_closed(breaker: XCBR) -> bool {

Parameters:

  • breaker: XCBR

Returns: bool

Defined at line 166


iec61850_xcbr_is_open

Check if breaker is open.

pub fn iec61850_xcbr_is_open(breaker: XCBR) -> bool {

Parameters:

  • breaker: XCBR

Returns: bool

Defined at line 171


iec61850_xcbr_set_health

Set breaker health.

pub fn iec61850_xcbr_set_health(breaker: & mut XCBR, health: i64) -> void {

Parameters:

  • breaker: & mut XCBR
  • health: i64

Returns: void

Defined at line 176


iec61850_xcbr_health_name

Get breaker health name.

pub fn iec61850_xcbr_health_name(breaker: XCBR) -> str {

Parameters:

  • breaker: XCBR

Returns: str

Defined at line 184


MMXU

A measurement logical node.

pub struct MMXU {

Fields:

NameType
namestr
ln_typei64
voltage_af64
voltage_bf64
voltage_cf64
current_af64
current_bf64
current_cf64
active_powerf64
reactive_powerf64
power_factorf64
frequencyf64

Defined at line 199


iec61850_mmxu_new

Create a new measurement node.

pub fn iec61850_mmxu_new(name: str) -> MMXU {

Parameters:

  • name: str

Returns: MMXU

Defined at line 224


iec61850_mmxu_set_voltage

Set three-phase voltage measurements.

pub fn iec61850_mmxu_set_voltage(mmxu: & mut MMXU, va: f64, vb: f64, vc: f64) -> void {

Parameters:

  • mmxu: & mut MMXU
  • va: f64
  • vb: f64
  • vc: f64

Returns: void

Defined at line 231


iec61850_mmxu_set_current

Set three-phase current measurements.

pub fn iec61850_mmxu_set_current(mmxu: & mut MMXU, ia: f64, ib: f64, ic: f64) -> void {

Parameters:

  • mmxu: & mut MMXU
  • ia: f64
  • ib: f64
  • ic: f64

Returns: void

Defined at line 238


iec61850_mmxu_set_power

Set power measurements.

pub fn iec61850_mmxu_set_power(mmxu: & mut MMXU, active: f64, reactive: f64, pf: f64) -> void {

Parameters:

  • mmxu: & mut MMXU
  • active: f64
  • reactive: f64
  • pf: f64

Returns: void

Defined at line 245


iec61850_mmxu_apparent_power

Calculate apparent power: sqrt(P² + Q²).

pub fn iec61850_mmxu_apparent_power(mmxu: MMXU) -> f64 {

Parameters:

  • mmxu: MMXU

Returns: f64

Defined at line 252


iec61850_mmxu_total_power

Calculate three-phase total active power: P = VaIa + VbIb + Vc*Ic (approx).

pub fn iec61850_mmxu_total_power(mmxu: MMXU) -> f64 {

Parameters:

  • mmxu: MMXU

Returns: f64

Defined at line 257


GOOSEMessage

A GOOSE message.

pub struct GOOSEMessage {

Fields:

NameType
app_idi64
goose_refstr
seq_numi64
timei64
st_numi64
dataVec<i64>

Defined at line 268


iec61850_goose_new

Create a new GOOSE message.

pub fn iec61850_goose_new(app_id: i64, ref: str) -> GOOSEMessage {

Parameters:

  • app_id: i64
  • ref: str

Returns: GOOSEMessage

Defined at line 282


iec61850_goose_add_data

Add a data value to the GOOSE message.

pub fn iec61850_goose_add_data(msg: & mut GOOSEMessage, value: i64) -> void {

Parameters:

  • msg: & mut GOOSEMessage
  • value: i64

Returns: void

Defined at line 289


iec61850_goose_update_data

Update a data value in the GOOSE message (increments seq_num).

pub fn iec61850_goose_update_data(msg: & mut GOOSEMessage, index: i64, value: i64) -> void {

Parameters:

  • msg: & mut GOOSEMessage
  • index: i64
  • value: i64

Returns: void

Defined at line 296


iec61850_goose_get_data

Get a data value from the GOOSE message.

pub fn iec61850_goose_get_data(msg: GOOSEMessage, index: i64) -> i64 {

Parameters:

  • msg: GOOSEMessage
  • index: i64

Returns: i64

Defined at line 305


iec61850_goose_data_count

Get the number of data values.

pub fn iec61850_goose_data_count(msg: GOOSEMessage) -> i64 {

Parameters:

  • msg: GOOSEMessage

Returns: i64

Defined at line 313


iec61850_goose_serialize

Serialize GOOSE message to a Vec of bytes (simplified format).

pub fn iec61850_goose_serialize(msg: GOOSEMessage) -> Vec<i64> {

Parameters:

  • msg: GOOSEMessage

Returns: Vec<i64>

Defined at line 318


iec61850_ref

Build an IEC 61850 object reference.

pub fn iec61850_ref(ld: str, ln: str, field: str) -> str {

Parameters:

  • ld: str
  • ln: str
  • field: str

Returns: str

Defined at line 356


iec61850_dataset_ref

Build a dataset reference.

pub fn iec61850_dataset_ref(ld: str, ds_name: str) -> str {

Parameters:

  • ld: str
  • ds_name: str

Returns: str

Defined at line 361


iec61850_control_ref

Build a control object reference.

pub fn iec61850_control_ref(ld: str, ln: str, co_name: str) -> str {

Parameters:

  • ld: str
  • ln: str
  • co_name: str

Returns: str

Defined at line 366


PTOC

Overcurrent protection settings.

pub struct PTOC {

Fields:

NameType
namestr
ln_typei64
pickup_currentf64
time_delayf64
inverse_curvebool
tdsf64
trippedbool

Defined at line 373


iec61850_ptoc_new

Create a new overcurrent protection element.

pub fn iec61850_ptoc_new(name: str, pickup: f64, delay: f64) -> PTOC {

Parameters:

  • name: str
  • pickup: f64
  • delay: f64

Returns: PTOC

Defined at line 388


iec61850_ptoc_check

Check if overcurrent condition is met.

pub fn iec61850_ptoc_check(ptoc: & mut PTOC, measured_current: f64) -> bool {

Parameters:

  • ptoc: & mut PTOC
  • measured_current: f64

Returns: bool

Defined at line 395


iec61850_ptoc_set_inverse

Set inverse time curve mode.

pub fn iec61850_ptoc_set_inverse(ptoc: & mut PTOC, tds: f64) -> void {

Parameters:

  • ptoc: & mut PTOC
  • tds: f64

Returns: void

Defined at line 404


iec61850_ptoc_trip_time

Calculate trip time for inverse time curve (IEC 60255 standard). Trip time = TDS * (A / ((I/Is)^p - 1) + B) For standard inverse: A=0.14, p=0.02, B=0

pub fn iec61850_ptoc_trip_time(ptoc: PTOC, measured_current: f64) -> f64 {

Parameters:

  • ptoc: PTOC
  • measured_current: f64

Returns: f64

Defined at line 412


Generated by scribe, the Fides documentation generator