libtiepie-hw  1.1.4
Symmetry

Functions for controlling the signal symmetry of a generator. More...

Collaboration diagram for Symmetry:

Functions

TIEPIE_HW_API tiepie_hw_bool tiepie_hw_generator_has_symmetry (tiepie_hw_handle handle)
 Check whether the current signal type of a specified generator supports controlling the signal symmetry. More...
 
TIEPIE_HW_API double tiepie_hw_generator_get_symmetry_min (tiepie_hw_handle handle)
 Get the minimum signal symmetry of a specified generator. More...
 
TIEPIE_HW_API double tiepie_hw_generator_get_symmetry_max (tiepie_hw_handle handle)
 Get the maximum signal symmetry of a specified generator. More...
 
TIEPIE_HW_API double tiepie_hw_generator_get_symmetry (tiepie_hw_handle handle)
 Get the current signal symmetry of a specified generator. More...
 
TIEPIE_HW_API double tiepie_hw_generator_set_symmetry (tiepie_hw_handle handle, double value)
 Set the signal symmetry of a specified generator. More...
 

Detailed Description

Functions for controlling the signal symmetry of a generator.

The symmetry of a signal defines the ratio between the length of positive part of a period and the length of the negative part of a period of the generated signal. The symmetry of a generator can be set between a minimum and a maximum value. Use tiepie_hw_generator_get_symmetry_min() and tiepie_hw_generator_get_symmetry_max() to get the symmetry limits.

The symmetry is defined as a number between 0 and 1, where 0 defines a symmetry of 0% (no positive part) and 1 defines a symmetry of 100% (no negative part).

When signal type Pulse, DC, Noise or Arbitrary is active, setting symmetry is not available. Use tiepie_hw_generator_has_symmetry() to check whether symmetry is available for the currently set signal type.

By default the symmetry is set to: 0.5 (50%).

Function Documentation

◆ tiepie_hw_generator_has_symmetry()

TIEPIE_HW_API tiepie_hw_bool tiepie_hw_generator_has_symmetry ( tiepie_hw_handle  handle)

Check whether the current signal type of a specified generator supports controlling the signal symmetry.

Parameters
[in]handleA device handle identifying the generator.
Returns
TIEPIE_HW_BOOL_TRUE if supported, TIEPIE_HW_BOOL_FALSE if not.
Status values
TIEPIE_HW_STATUS_INVALID_HANDLE The handle is not a valid generator handle.
TIEPIE_HW_STATUS_OBJECT_GONE
TIEPIE_HW_STATUS_LIBRARY_NOT_INITIALIZED
TIEPIE_HW_STATUS_SUCCESS
See also
tiepie_hw_generator_get_symmetry_min
tiepie_hw_generator_get_symmetry_max
tiepie_hw_generator_get_symmetry
tiepie_hw_generator_set_symmetry
Since
1.0

◆ tiepie_hw_generator_get_symmetry_min()

TIEPIE_HW_API double tiepie_hw_generator_get_symmetry_min ( tiepie_hw_handle  handle)

Get the minimum signal symmetry of a specified generator.

Parameters
[in]handleA device handle identifying the generator.
Returns
The minimum signal symmetry, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_NOT_SUPPORTED The generator does not support symmetry for the current signal type.
TIEPIE_HW_STATUS_INVALID_HANDLE The handle is not a valid generator handle.
TIEPIE_HW_STATUS_OBJECT_GONE
TIEPIE_HW_STATUS_LIBRARY_NOT_INITIALIZED
TIEPIE_HW_STATUS_SUCCESS
See also
tiepie_hw_generator_get_symmetry_max
tiepie_hw_generator_get_symmetry
tiepie_hw_generator_set_symmetry
Since
1.0

◆ tiepie_hw_generator_get_symmetry_max()

TIEPIE_HW_API double tiepie_hw_generator_get_symmetry_max ( tiepie_hw_handle  handle)

Get the maximum signal symmetry of a specified generator.

Parameters
[in]handleA device handle identifying the generator.
Returns
The maximum signal symmetry, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_NOT_SUPPORTED The generator does not support symmetry for the current signal type.
TIEPIE_HW_STATUS_INVALID_HANDLE The handle is not a valid generator handle.
TIEPIE_HW_STATUS_OBJECT_GONE
TIEPIE_HW_STATUS_LIBRARY_NOT_INITIALIZED
TIEPIE_HW_STATUS_SUCCESS
See also
tiepie_hw_generator_get_symmetry_min
tiepie_hw_generator_get_symmetry
tiepie_hw_generator_set_symmetry
Since
1.0

◆ tiepie_hw_generator_get_symmetry()

TIEPIE_HW_API double tiepie_hw_generator_get_symmetry ( tiepie_hw_handle  handle)

Get the current signal symmetry of a specified generator.

Parameters
[in]handleA device handle identifying the generator.
Returns
The currently set signal symmetry, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_NOT_SUPPORTED The generator does not support symmetry for the current signal type.
TIEPIE_HW_STATUS_INVALID_HANDLE The handle is not a valid generator handle.
TIEPIE_HW_STATUS_OBJECT_GONE
TIEPIE_HW_STATUS_LIBRARY_NOT_INITIALIZED
TIEPIE_HW_STATUS_SUCCESS
See also
tiepie_hw_generator_get_symmetry_min
tiepie_hw_generator_get_symmetry_max
tiepie_hw_generator_set_symmetry
Since
1.0

◆ tiepie_hw_generator_set_symmetry()

TIEPIE_HW_API double tiepie_hw_generator_set_symmetry ( tiepie_hw_handle  handle,
double  value 
)

Set the signal symmetry of a specified generator.

Parameters
[in]handleA device handle identifying the generator.
[in]valueThe requested signal symmetry, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_VALUE_CLIPPED The requested symmetry is outside the valid range and clipped to the closest limit.
TIEPIE_HW_STATUS_VALUE_MODIFIED The requested symmetry is within the valid range but not available. The closest valid value is set.
TIEPIE_HW_STATUS_NOT_SUPPORTED The generator does not support symmetry for the current signal type.
TIEPIE_HW_STATUS_NOT_CONTROLLABLE
TIEPIE_HW_STATUS_INVALID_HANDLE The handle is not a valid generator handle.
TIEPIE_HW_STATUS_OBJECT_GONE
TIEPIE_HW_STATUS_LIBRARY_NOT_INITIALIZED
TIEPIE_HW_STATUS_SUCCESS
Returns
The actually set signal symmetry, a number between 0 and 1.
Remarks
When the generator is active, changing the symmetry will shortly interrupt the output signal.
See also
tiepie_hw_generator_get_symmetry_min
tiepie_hw_generator_get_symmetry_max
tiepie_hw_generator_get_symmetry
Since
1.0