From 36d4e5f6c4a36f01575ce87d6e6bcfbdf7e28dec Mon Sep 17 00:00:00 2001 From: pblivingston <71585805+pblivingston@users.noreply.github.com> Date: Mon, 1 Dec 2025 11:17:58 -0500 Subject: [PATCH] Update bus.ps1 - sel - monitor - vaio - mono to int - levels.convert [float] -> [single] - device.asio $arg -> [string]$arg --- lib/bus.ps1 | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/bus.ps1 b/lib/bus.ps1 index 0ba086d..3697198 100644 --- a/lib/bus.ps1 +++ b/lib/bus.ps1 @@ -4,7 +4,8 @@ class Bus : IRemote { [Object]$levels Bus ([int]$index, [Object]$remote) : base ($index, $remote) { - AddBoolMembers -PARAMS @('mono', 'mute') + AddBoolMembers -PARAMS @('mute', 'sel', 'monitor') + AddIntMembers -PARAMS @('mono') AddStringMembers -PARAMS @('label') AddFloatMembers -PARAMS @('gain', 'returnreverb', 'returndelay', 'returnfx1', 'returnfx2') @@ -35,7 +36,7 @@ class BusLevels : IRemote { $this.offset = 8 } - [float] Convert([float]$val) { + [single] Convert([single]$val) { if ($val -gt 0) { return [math]::Round(20 * [math]::Log10($val), 1) } @@ -97,6 +98,8 @@ class PhysicalBus : Bus { PhysicalBus ([int]$index, [Object]$remote) : base ($index, $remote) { $this.device = [BusDevice]::new($index, $remote) + + AddBoolMembers -PARAMS @('vaio') } } @@ -126,7 +129,7 @@ class BusDevice : Device { -Value { return Write-Warning ("ERROR: $($this.identifier()).asio is write only") } -SecondValue { - param($arg) + param([string]$arg) return $this.Setter('asio', $arg) } -Force }