summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan Aillet <jonathan.aillet@iot.bzh>2019-07-18 15:24:01 +0200
committerJonathan Aillet <jonathan.aillet@iot.bzh>2019-07-18 17:39:10 +0200
commit0273ce03b2e44cbb53e8c2f321aba72a2a513edb (patch)
tree9474e63b78ce688ce0e6088d6ae9b143abcacfce
parent1caeb47ccc3f4241cd97be12d31081a18db27f1b (diff)
Add information about attach verb json format. BUG-AGL: SPEC-2653 Change-Id: I6e1e47f8572d135226cccb39ee8c14e5425f470f Signed-off-by: Jonathan Aillet <jonathan.aillet@iot.bzh>
-rw-r--r--README.md60
1 files changed, 60 insertions, 0 deletions
diff --git a/README.md b/README.md
index 34eb934..90e342d 100644
--- a/README.md
+++ b/README.md
@@ -12,6 +12,66 @@ Softmixer controller for 4A (AGL Advance Audio Architecture).
* Usage of streams to access audio zones
* Direct read from HW capture devices (eg radio chips & microphones)
+## Attach verb json format (TO UPDATE)
+
+* The `uid` field will be the name of the mixer corresponding to your hal.
+* The `mixerapi` field should contain the name of the api to call for reaching the mixer
+ (not need to be changed if you use '4a-softmixer').
+* The `prefix` field is not mandatory, it is where you precise the prefix that will be applied
+when the mixer attach call happens. All the streams the mixer creates will be prefixed with this field.
+* In `ramps` section:
+* Define the ramp that you can use in your mixer (ramps in example files can be used).
+* The `uid` field is where you specify the name of the ramp.
+* The ramp will set the current volume to the targeted volume step by step:
+ * The `delay` field is the delay between two volume modification.
+ * The `up` field is the volume increase in one step (when increasing volume is requested).
+ * The `down` field is the volume decrease in one step (when decreasing volume is requested).
+* The `playbacks` section will contain your output audio information (such as the path to you alsa audio device
+and the configuration of your device):
+* A `uid` field that will be used by the mixer to identify the playback.
+* The `params` field is an optional field where you can specify some parameters
+ for your playback (such as rate).
+* The `sink` field is where you describe your playback:
+ * The `controls` field must contain the alsa control labels
+ that the mixer will use to set/mute volume on your audio device.
+ * The `channels` field must contain an object that will link an `uid` to
+ a physical output audio `port` that will be used in zone.
+* The `captures` section will contain your input audio information (such as the path to you alsa audio device
+and the configuration of your device):
+* A `uid` field that will be used by the mixer to identify the capture.
+* The `params` field is an optional field where you can specify some parameters
+ for your capture (such as rate).
+* The `sink` field is where you describe your capture:
+ * The `controls` field must contain the alsa control labels
+ that the mixer will use to set/mute volume on your audio device.
+ * The `channels` field must contain an object that will link an `uid` to
+ a physical input audio `port` that will be used in zone.
+* In `zones` section: (zones in example files can be used):
+* You can define the zones that you want for your mixer.
+* You must define which sink will be used in these zones.
+* These zones will be used to define streams.
+* The `sink` field must contain objects that will link a physical ouput audio port
+ (defined in `playbacks` section) using `target` field to a logical output audio `channel`
+ that will be used in zone.
+* The `source` field must contain objects that will link a physical input audio port
+ (defined in `captures` section) using `target` field to a logical input audio `channel`
+ that will be used in zone.
+* In `streams` section: (streams in example files can be used):
+* You can define the streams that you want for your mixer.
+* Mandatory fields:
+ * A `uid` field, it is the name used by the mixer to identify streams (e.g. when using `info` verb)
+ * The `verb` field is the name used by the mixer to declare the stream verb
+ (but prefixing it with `prefix` if defined).
+ It is also used by the hal to declare a verb to make it accessible from a hal point of view.
+ * The `zone` field must correspond to the wanted zone of the stream.
+* Optional fields:
+ * The `source` is where you can precise which loop to use for this stream (not the default one).
+ The loop are defined in the mixer configuration file.
+ * The `params` is where you can specify some parameters for your stream (such as rate).
+ * `volume` and `mute` fields are initiate values of the stream.
+
+NOTE : This json format is used by 4a-hal-generic.
+
## Compile
```
mkdir build