libtiepie-hw  1.1.10

Functions for controlling the phase of a generator. More...

Collaboration diagram for Phase:

Functions

TIEPIE_HW_API tiepie_hw_bool tiepie_hw_generator_has_phase (tiepie_hw_handle handle)
 Check whether the specified generator and the current signal type of the specified generator support controlling the signal phase. More...
 
TIEPIE_HW_API double tiepie_hw_generator_get_phase_min (tiepie_hw_handle handle)
 Get the minimum signal phase of a specified generator. More...
 
TIEPIE_HW_API double tiepie_hw_generator_get_phase_max (tiepie_hw_handle handle)
 Get the maximum signal phase of a specified generator. More...
 
TIEPIE_HW_API double tiepie_hw_generator_get_phase (tiepie_hw_handle handle)
 Get the current signal phase of a specified generator. More...
 
TIEPIE_HW_API double tiepie_hw_generator_set_phase (tiepie_hw_handle handle, double value)
 Set the signal phase of a specified generator. More...
 

Detailed Description

Functions for controlling the phase of a generator.

The phase defines the starting point in the period of the signal that is generated, as well as the ending point. The phase of a generator can be set between a minimum and a maximum value. Use tiepie_hw_generator_get_phase_min() and tiepie_hw_generator_get_phase_max() to get the phase limits.

The phase is defined as a number between 0 and 1, where 0 defines the beginning of the period () and 1 defines the end of the period (360°).

Phase is not available on all instruments and all signal types. Use tiepie_hw_generator_has_phase() to check whether phase is available for your instrument and for the currently set signal type.

By default the phase is set to: 0.

Function Documentation

◆ tiepie_hw_generator_has_phase()

TIEPIE_HW_API tiepie_hw_bool tiepie_hw_generator_has_phase ( tiepie_hw_handle  handle)

Check whether the specified generator and the current signal type of the specified generator support controlling the signal phase.

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_phase_min
tiepie_hw_generator_get_phase_max
tiepie_hw_generator_get_phase
tiepie_hw_generator_set_phase
Since
1.0

◆ tiepie_hw_generator_get_phase_min()

TIEPIE_HW_API double tiepie_hw_generator_get_phase_min ( tiepie_hw_handle  handle)

Get the minimum signal phase of a specified generator.

Parameters
[in]handleA device handle identifying the generator.
Returns
The minimum signal phase, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_NOT_SUPPORTED The generator does not support phase 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_has_phase
tiepie_hw_generator_get_phase_max
tiepie_hw_generator_get_phase
tiepie_hw_generator_set_phase
Since
1.0

◆ tiepie_hw_generator_get_phase_max()

TIEPIE_HW_API double tiepie_hw_generator_get_phase_max ( tiepie_hw_handle  handle)

Get the maximum signal phase of a specified generator.

Parameters
[in]handleA device handle identifying the generator.
Returns
The maximum signal phase, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_NOT_SUPPORTED The generator does not support phase 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_has_phase
tiepie_hw_generator_get_phase_min
tiepie_hw_generator_get_phase
tiepie_hw_generator_set_phase
Since
1.0

◆ tiepie_hw_generator_get_phase()

TIEPIE_HW_API double tiepie_hw_generator_get_phase ( tiepie_hw_handle  handle)

Get the current signal phase of a specified generator.

Parameters
[in]handleA device handle identifying the generator.
Returns
The currently set signal phase, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_NOT_SUPPORTED The generator does not support phase 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_has_phase
tiepie_hw_generator_get_phase_min
tiepie_hw_generator_get_phase_max
tiepie_hw_generator_set_phase
Since
1.0

◆ tiepie_hw_generator_set_phase()

TIEPIE_HW_API double tiepie_hw_generator_set_phase ( tiepie_hw_handle  handle,
double  value 
)

Set the signal phase of a specified generator.

Parameters
[in]handleA device handle identifying the generator.
[in]valueThe requested signal phase, a number between 0 and 1.
Returns
The actually set signal phase, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_VALUE_CLIPPED The requested phase is outside the valid range and clipped to the closest limit.
TIEPIE_HW_STATUS_VALUE_MODIFIED The requested phase is within the valid range but not available. The closest valid value is set.
TIEPIE_HW_STATUS_NOT_SUPPORTED The generator does not support phase 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
Remarks
When the generator is active, changing the phase will shortly interrupt the output signal.
When signal type DC or Noise is active, setting phase is not available.
See also
tiepie_hw_generator_has_phase
tiepie_hw_generator_get_phase_min
tiepie_hw_generator_get_phase_max
tiepie_hw_generator_get_phase
Since
1.0