libtiepie-hw  1.1.10

Functions for controlling the phase of a demo signal. More...

Collaboration diagram for Phase:

Functions

TIEPIE_HW_API tiepie_hw_bool tiepie_hw_oscilloscope_channel_demo_has_phase (tiepie_hw_handle handle, uint16_t ch)
 Check whether the currently selected demo signal type supports setting the phase. More...
 
TIEPIE_HW_API double tiepie_hw_oscilloscope_channel_demo_get_phase (tiepie_hw_handle handle, uint16_t ch)
 Get the currently selected demo signal phase of a specified demo oscilloscope channel. More...
 
TIEPIE_HW_API double tiepie_hw_oscilloscope_channel_demo_set_phase (tiepie_hw_handle handle, uint16_t ch, double value)
 Set the demo signal phase of a specified demo oscilloscope channel. More...
 

Detailed Description

Functions for controlling the phase of a demo signal.

The phase defines the starting point in the period of the signal that is generated, as well as the ending point.

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°).

Several of the demo signal types support setting the signal phase, but others don't. Use tiepie_hw_oscilloscope_channel_demo_has_phase() to find out whether the selected demo signal type supports setting the phase.

By default the phase is set to: 0.

Function Documentation

◆ tiepie_hw_oscilloscope_channel_demo_has_phase()

TIEPIE_HW_API tiepie_hw_bool tiepie_hw_oscilloscope_channel_demo_has_phase ( tiepie_hw_handle  handle,
uint16_t  ch 
)

Check whether the currently selected demo signal type supports setting the phase.

Parameters
[in]handleA device handle identifying the oscilloscope.
[in]chThe channel number identifying the channel, 0 to tiepie_hw_oscilloscope_get_channel_count() - 1.
Returns
TIEPIE_HW_BOOL_TRUE if setting the phase is supported, TIEPIE_HW_BOOL_FALSE if not.
Status values
TIEPIE_HW_STATUS_INVALID_CHANNEL
TIEPIE_HW_STATUS_INVALID_HANDLE The handle is not a valid oscilloscope handle.
TIEPIE_HW_STATUS_OBJECT_GONE
TIEPIE_HW_STATUS_LIBRARY_NOT_INITIALIZED
TIEPIE_HW_STATUS_SUCCESS
See also
tiepie_hw_oscilloscope_channel_demo_get_phase
tiepie_hw_oscilloscope_channel_demo_set_phase
Since
1.0

◆ tiepie_hw_oscilloscope_channel_demo_get_phase()

TIEPIE_HW_API double tiepie_hw_oscilloscope_channel_demo_get_phase ( tiepie_hw_handle  handle,
uint16_t  ch 
)

Get the currently selected demo signal phase of a specified demo oscilloscope channel.

Parameters
[in]handleA device handle identifying the oscilloscope.
[in]chThe channel number identifying the channel, 0 to tiepie_hw_oscilloscope_get_channel_count() - 1.
Returns
The currently set demo signal phase, a number between 0 and 1.
Status values
TIEPIE_HW_STATUS_NOT_SUPPORTED The currently selected demo signal type does not support getting the demo signal phase.
TIEPIE_HW_STATUS_INVALID_CHANNEL
TIEPIE_HW_STATUS_INVALID_HANDLE The handle is not a valid oscilloscope handle.
TIEPIE_HW_STATUS_OBJECT_GONE
TIEPIE_HW_STATUS_LIBRARY_NOT_INITIALIZED
TIEPIE_HW_STATUS_SUCCESS
See also
tiepie_hw_oscilloscope_channel_demo_has_phase
tiepie_hw_oscilloscope_channel_demo_set_phase
Since
1.0

◆ tiepie_hw_oscilloscope_channel_demo_set_phase()

TIEPIE_HW_API double tiepie_hw_oscilloscope_channel_demo_set_phase ( tiepie_hw_handle  handle,
uint16_t  ch,
double  value 
)

Set the demo signal phase of a specified demo oscilloscope channel.

Parameters
[in]handleA device handle identifying the oscilloscope.
[in]chThe channel number identifying the channel, 0 to tiepie_hw_oscilloscope_get_channel_count() - 1.
[in]valueThe requested demo signal phase, a number between 0 and 1.
Returns
The actually set phase.
Status values
TIEPIE_HW_STATUS_NOT_SUPPORTED The currently selected demo signal type does not support setting the demo signal phase.
TIEPIE_HW_STATUS_INVALID_VALUE The requested signal phase is not valid.
TIEPIE_HW_STATUS_INVALID_CHANNEL
TIEPIE_HW_STATUS_INVALID_HANDLE The handle is not a valid oscilloscope handle.
TIEPIE_HW_STATUS_OBJECT_GONE
TIEPIE_HW_STATUS_LIBRARY_NOT_INITIALIZED
TIEPIE_HW_STATUS_SUCCESS
See also
tiepie_hw_oscilloscope_channel_demo_has_phase
tiepie_hw_oscilloscope_channel_demo_get_phase
Since
1.0