jdxi_editor.midi.data.parameter.digital.common

Module: AddressParameterDigitalCommon

This module defines the AddressParameterDigitalCommon class, which represents common parameters for Digital/SuperNATURAL synth tones. These parameters are shared across all partials and define various synthesizer settings, such as tone name, tone level, performance parameters, partial switches, and additional effects.

The class provides methods to:

  • Retrieve a human-readable digital name for each parameter.

  • Identify if a parameter is a switch (binary or enum).

  • Get appropriate digital text for switch values.

  • Validate and convert parameter values within their defined range.

  • Retrieve the partial number (1-3) for partial-specific parameters.

  • Get a parameter by its name.

Parameters include: - Tone name parameters (12 ASCII characters) - Tone level - Performance parameters (e.g., Portamento switch, Mono switch) - Partial switches (e.g., Partial 1 switch, Partial 2 switch) - Additional effect parameters (e.g., Ring Mod, Unison, Analog Feel)

Usage example:

# Initialize a parameter object param = AddressParameterDigitalCommon(address=0x00, min_val=0, max_val=127)

# Get the digital name for the parameter print(param.display_name)

# Validate and convert a value for the parameter valid_value = param.validate_value(64)

# Get the switch text for a given value switch_text = param.get_switch_text(1)

Classes

DigitalCommonParam

Common parameters for Digital/SuperNATURAL synth tones.

Module Contents

class jdxi_editor.midi.data.parameter.digital.common.DigitalCommonParam(address: int, min_val: int, max_val: int, display_min: int | None = None, display_max: int | None = None, description: str | None = None, display_name: str | None = None, options: list | None = None, values: list | None = None)[source]

Bases: picomidi.sysex.parameter.address.AddressParameter

Common parameters for Digital/SuperNATURAL synth tones. These parameters are shared across all partials.

address[source]
min_val[source]
max_val[source]
tooltip[source]
display_min[source]
display_max[source]
_display_name = None[source]
options = None[source]
values = None[source]
get_tooltip() str[source]

Return tooltip string for UI. Base may return options list; we always return self.tooltip.

TONE_NAME_1[source]
TONE_NAME_2[source]
TONE_NAME_3[source]
TONE_NAME_4[source]
TONE_NAME_5[source]
TONE_NAME_6[source]
TONE_NAME_7[source]
TONE_NAME_8[source]
TONE_NAME_9[source]
TONE_NAME_10[source]
TONE_NAME_11[source]
TONE_NAME_12[source]
TONE_LEVEL[source]
PORTAMENTO_SWITCH[source]
PORTAMENTO_TIME[source]
MONO_SWITCH[source]
OCTAVE_SHIFT[source]
PITCH_BEND_UP[source]
PITCH_BEND_DOWN[source]
PARTIAL1_SWITCH[source]
PARTIAL1_SELECT[source]
PARTIAL2_SWITCH[source]
PARTIAL2_SELECT[source]
PARTIAL3_SWITCH[source]
PARTIAL3_SELECT[source]
RING_SWITCH[source]
UNISON_SWITCH[source]
PORTAMENTO_MODE[source]
LEGATO_SWITCH[source]
ANALOG_FEEL[source]
WAVE_SHAPE[source]
TONE_CATEGORY[source]
UNISON_SIZE[source]
property display_name: str[source]

Get digital name for the parameter (from ParameterSpec or fallback).

property is_switch: bool[source]

Returns True if parameter is address binary/enum switch

get_switch_text(value: int) str[source]

Get digital text for switch values

validate_value(value: int) int[source]

Validate and convert parameter value

get_partial_number() int | None[source]

Returns the partial number (1-3) if this is address partial parameter, None otherwise

static get_by_name(param_name)[source]

Get the Parameter by name.

get_address_for_partial(partial_number: int = 0)[source]