Next: , Up: STOutput: The Actuator Abstraction   [Contents]


B.5.1 STOutput Lifecycle Management

Function: STOutput * st_output_new (const gchar *name, const gchar *description, STUnit unit, gdouble min, gdouble max, gdouble step, gdouble val, guint64 flags, GError **error)

Creates a commandable endpoint. Parameters match st_input_new.

name

Stable identifier (unique within the service).

description

Human-readable text.

unit

Quantity kind.

min

Inclusive lower bound.

max

Inclusive upper bound.

step

Resolution grid.

val

Initial commanded value.

flags

Policy bits (see api-io-flags).

error

Optional GError out-parameter.

Returns: A new STOutput, or NULL with error set on invalid metadata.

Function: STOutput * st_output_dup (const STOutput *self)

Deep-copies an output.

self

Source output.

Returns: Newly allocated STOutput.

Function: void st_output_set_notify_context (STOutput *self, GMainContext *context)

Sets notify affinity (same semantics as inputs).

self

The output.

context

Affinity context, or NULL for default.

Returns: Nothing.

Function: GMainContext * st_output_get_notify_context (STOutput *self)

Reads notify affinity.

self

The output.

Returns: Borrowed GMainContext.