dwfpy.application.Application

class Application(*args, **kwargs)[source]

Bases: _Singleton

WaveForms application.

Methods

get_last_error

Gets the last DWF API error code.

get_last_error_message

Gets the last DWF API error message.

get_logger

Gets the WaveForms logger.

get_parameter

Gets a global parameter.

get_version

Gets the DWF API version string.

set_parameter

Sets a global parameter.

Attributes

clock_mode

Specifies the clock mode: 0 internal, 1 output, 2 input, 3 IO.

enable_analog_out

Enables or disables the analog audio output.

enable_audio_output

Enables or disables audio output.

external_frequency

Specifies the external frequency in Hz.

frequency

Gets or sets the frequency in Hz.

led_brightness

Gets or sets the Digital Discovery LED brightness.

on_close_behavior

Gets or sets a value indicating the device close behavior.

usb_limit

Gets or sets the USB current limitation in mA.

usb_power_on_aux

Gets or sets a value to keep the USB power enabled even when AUX supply is connected.

property clock_mode: int

Specifies the clock mode: 0 internal, 1 output, 2 input, 3 IO.

Return type

int

property enable_analog_out: bool

Enables or disables the analog audio output.

Return type

bool

property enable_audio_output: bool

Enables or disables audio output.

Return type

bool

property external_frequency: int

Specifies the external frequency in Hz.

Return type

int

property frequency: int

Gets or sets the frequency in Hz.

Return type

int

static get_last_error()[source]

Gets the last DWF API error code.

Return type

Error

static get_last_error_message()[source]

Gets the last DWF API error message.

Return type

str

static get_logger()[source]

Gets the WaveForms logger.

Return type

Logger

static get_parameter(parameter)[source]

Gets a global parameter.

Return type

int

static get_version()[source]

Gets the DWF API version string.

Return type

str

property led_brightness: int

Gets or sets the Digital Discovery LED brightness.

Return type

int

property on_close_behavior: int

Gets or sets a value indicating the device close behavior. 0 = Continue, 1 = Stop, 2 = Shutdown.

Return type

int

static set_parameter(parameter, value)[source]

Sets a global parameter.

Return type

None

property usb_limit: int

Gets or sets the USB current limitation in mA.

Return type

int

property usb_power_on_aux: bool

Gets or sets a value to keep the USB power enabled even when AUX supply is connected. Applies to Analog Discovery 2

Return type

bool