aboutsummaryrefslogtreecommitdiffstats
path: root/conf.d/project
diff options
context:
space:
mode:
Diffstat (limited to 'conf.d/project')
-rw-r--r--conf.d/project/etc/smixer-test-config.json (renamed from conf.d/project/etc/smixer-4a-test-config.json)6
-rw-r--r--conf.d/project/htdocs/index.html136
-rw-r--r--conf.d/project/lua.d/smixer-test-simple.lua (renamed from conf.d/project/lua.d/softmixer-simple-test.lua)8
3 files changed, 17 insertions, 133 deletions
diff --git a/conf.d/project/etc/smixer-4a-test-config.json b/conf.d/project/etc/smixer-test-config.json
index 6caf228..3ed9f29 100644
--- a/conf.d/project/etc/smixer-4a-test-config.json
+++ b/conf.d/project/etc/smixer-test-config.json
@@ -3,15 +3,15 @@
"metadata": {
"uid": "Soft Mixer",
"version": "1.0",
- "api": "softmixer",
+ "api": "smixer",
"info": "Soft Mixer emulating hardware mixer"
},
"resources": [
{
"uid": "softmixer",
"info": "Map alsa-loop subdevices to 4A HAL streams",
- "spath": "./lib/plugins:./var",
- "libs": ["alsa-softmixer.ctlso", "softmixer-simple-test.lua"],
+ "spath": "./package/lib/plugins:./package/var:./lib/plugins:./var",
+ "libs": ["alsa-softmixer.ctlso", "smixer-test-simple.lua"],
"lua": {
"prefix": "smix",
"functions": ["_mixer_new_"]
diff --git a/conf.d/project/htdocs/index.html b/conf.d/project/htdocs/index.html
index 5709eb2..59fbbac 100644
--- a/conf.d/project/htdocs/index.html
+++ b/conf.d/project/htdocs/index.html
@@ -5,125 +5,11 @@
<script type="text/javascript" src="AFB-websock.js"></script>
<script type="text/javascript" src="AudioBinding.js"></script>
<script type="text/javascript">
-
- var frontend = {
- "devices": {
- "playback": 0,
- "capture": 1
- },
- "ramps": [
- {
- "uid": "ramp-fast",
- "delay": 50,
- "up": 10,
- "down": 3
- },
- {
- "uid": "ramp-slow",
- "delay": 250,
- "up": 3,
- "down": 1
- },
- {
- "uid": "ramp-normal",
- "delay": 100,
- "up": 6,
- "down": 2
- }
- ],
- "subdevs": [
- {
- "subdev": 0,
- "numid": 51
- },
- {
- "subdev": 1,
- "numid": 57
- },
- {
- "subdev": 2,
- "numid": 63
- },
- {
- "subdev": 3,
- "numid": 69
- },
- {
- "subdev": 4,
- "numid": 75
- },
- {
- "subdev": 5,
- "numid": 81
- },
- {
- "subdev": 6,
- "numid": 87
- },
- {
- "subdev": 7,
- "numid": 93
- }
- ]
- };
- var audio_defaults = {
- "rate": 48000
- };
- var usb_yamaha = {
- uid: "YAMAHA-APU70",
- devpath: "/dev/snd/by-id/usb-YAMAHA_Corporation_YAMAHA_AP-U70_USB_Audio_00-00",
- params: snd_params,
- sink: [
- {uid: "front-right", port: 0},
- {uid: "front-left", port: 1}
- ]
- };
- var zone_front = {
- uid: "front-seats",
- type: "playback",
- mapping: [
- {target: "front-right", channel: 0},
- {target: "front-left", channel: 1}
- ]
- };
-
- var stream_music = {
- uid: "multimedia",
- zone: "front-seats",
- ramp: "ramp-slow",
- volume: 60,
- mute: false
- };
-
- var stream_navigation = {
- uid: "navigation",
- zone: "front-seats",
- ramp: "ramp-normal",
- volume: 70,
- mute: false
- };
-
- var stream_emergency = {
- uid: "emergency",
- zone: "front-seats",
- ramp: "ramp-fast",
- volume: 80,
- mute: false
- };
-
- var my_test_mixer = {
- uid: 'simple_mixer',
- backend: usb_yamaha,
- frontend: frontend,
- zones: zone_front,
- streams: [stream_music, stream_navigation, stream_emergency]
- };
-
</script>
</head>
- <body onload="init('hal_registry', 'alsacore', 'hallist')">
+ <body onload="init()">
<h1>Simple Mixer Test</h1>
<button id="connected" onclick="init()">Binder WS Fail</button>
@@ -132,20 +18,18 @@
<h2>V3 API CALL</h2>
<ol>
- <li><button onclick="callbinder('softmixer', 'simple_mixer', {list: {streams: true}});">Streams List</button></li>
- <br>
- <li><button onclick="callbinder('softmixer', 'simple_mixer/multimedia', {toggle: true});">Stream Multimedia pause/resume</button></li>
- <li><button onclick="callbinder('softmixer', 'simple_mixer/navigation', {toggle: true});">Stream Navigation pause/resume</button></li>
+ <li><button onclick="callbinder('MyMixer', 'info', {streams: true});">Streams List</button></li>
+ <li><button onclick="callbinder('MyMixer', 'info', {ramps: true});">Ramps List</button></li>
+ <li><button onclick="callbinder('MyMixer', 'info', {zones: true});">Zones List</button></li>
<br>
- <li><button onclick="callbinder('softmixer', 'simple_mixer/multimedia', {volume: '+10'});">Stream Multimedia volume=+10"</button></li>
- <li><button onclick="callbinder('softmixer', 'simple_mixer/multimedia', {volume: '-10'});">Stream Multimedia volume=-10"</button></li>
+ <li><button onclick="callbinder('MyMixer', 'multimedia', {toggle: true});">Stream Multimedia pause/resume</button></li>
+ <li><button onclick="callbinder('MyMixer', 'navigation', {toggle: true});">Stream Navigation pause/resume</button></li>
<br>
- <li><button onclick="callbinder('softmixer', 'simple_mixer/multimedia', {ramp: 30});">Stream Multimedia ramp=30"</button></li>
- <li><button onclick="callbinder('softmixer', 'simple_mixer/multimedia', {ramp: 80});">Stream Multimedia ramp=80"</button></li>
+ <li><button onclick="callbinder('MyMixer', 'multimedia', {volume: '+10'});">Stream Multimedia volume=+10"</button></li>
+ <li><button onclick="callbinder('MyMixer', 'multimedia', {volume: '-10'});">Stream Multimedia volume=-10"</button></li>
<br>
- <li><button onclick="callbinder('softmixer', 'simple_mixer', {delete: true});">Close Mixer"</button></li>
- <li><button onclick="callbinder('softmixer', 'create',{uid:'simple_mixer', backend: usb_yamaha, frontend: frontend,
- zones: [zone_front],streams: [stream_music, stream_navigation, stream_emergency]});">New Mixer"</button></li>
+ <li><button onclick="callbinder('MyMixer', 'multimedia', {ramp: {uid:'ramp-slow', volume:30}});">Stream Multimedia ramp-slow=30"</button></li>
+ <li><button onclick="callbinder('MyMixer', 'multimedia', {ramp: {uid:'ramp-fast', volume:80}});">Stream Multimedia ramp-fast=80"</button></li>
</ol>
<div id="main" style="visibility:hidden">
diff --git a/conf.d/project/lua.d/softmixer-simple-test.lua b/conf.d/project/lua.d/smixer-test-simple.lua
index 87fb866..3a5dc98 100644
--- a/conf.d/project/lua.d/softmixer-simple-test.lua
+++ b/conf.d/project/lua.d/smixer-test-simple.lua
@@ -171,7 +171,7 @@ function _mixer_simple_test_ (source, args)
["uid"] = "multimedia",
["zone"]= "full-stereo",
["source"]= "loop-multimedia",
- ["volume"]= 60,
+ ["volume"]= 80,
["mute"] = false,
["params"]= audio_params.standard,
}
@@ -179,7 +179,7 @@ function _mixer_simple_test_ (source, args)
local stream_navigation= {
["uid"] = "navigation",
["zone"]= "front-seats",
- ["volume"]= 60,
+ ["volume"]= 80,
["mute"] = false,
}
@@ -195,7 +195,7 @@ function _mixer_simple_test_ (source, args)
["uid"] = "radio",
["zone"] = "full-stereo",
--["source"]= snd_usb_8ch.uid,
- ["volume"]= 60,
+ ["volume"]= 80,
["mute"] = false,
}
@@ -203,7 +203,7 @@ function _mixer_simple_test_ (source, args)
["uid"] = "pulseaudio",
["zone"] = "back-seats",
["source"]= "loop-legacy",
- ["volume"]= 60,
+ ["volume"]= 80,
["mute"] = false,
}