From d7c4e0d888a0ff61ac9b7b3fb91b6bd28aed7dd1 Mon Sep 17 00:00:00 2001 From: Toshiaki Isogai Date: Fri, 23 Dec 2016 07:04:48 -0500 Subject: Integrate GENIVI Audio Manager Plugins for CES2017 demo. Change-Id: I56081180f8dc3bc10159492d4bc7e5fdd621ab27 Signed-off-by: Toshiaki Isogai --- ...ackagegroup-ivi-common-core-multimedia.bbappend | 4 + .../audiomanager-plugins-config/amcp_dbus.conf | 20 + .../audiomanager-plugins-config/amrp_dbus.conf | 21 + .../audiomanager-plugins-config/configuration.xml | 522 +++++++++++++++++++++ .../audiomanager-plugins-config/customtypes.xsd | 63 +++ ...org.genivi.audiomanager.routing.pulseaudio.conf | 35 ++ .../audiomanager-plugins-config_7.4.bb | 38 ++ .../audiomanager-plugins_git.bb | 59 +++ .../module-router/module-router_git.bb | 31 ++ 9 files changed, 793 insertions(+) create mode 100644 recipes-core/packagegroups/packagegroup-ivi-common-core-multimedia.bbappend create mode 100644 recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/amcp_dbus.conf create mode 100644 recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/amrp_dbus.conf create mode 100644 recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/configuration.xml create mode 100644 recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/customtypes.xsd create mode 100644 recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/org.genivi.audiomanager.routing.pulseaudio.conf create mode 100644 recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config_7.4.bb create mode 100644 recipes-multimedia/audiomanager-plugins/audiomanager-plugins_git.bb create mode 100755 recipes-multimedia/module-router/module-router_git.bb diff --git a/recipes-core/packagegroups/packagegroup-ivi-common-core-multimedia.bbappend b/recipes-core/packagegroups/packagegroup-ivi-common-core-multimedia.bbappend new file mode 100644 index 000000000..3623601c6 --- /dev/null +++ b/recipes-core/packagegroups/packagegroup-ivi-common-core-multimedia.bbappend @@ -0,0 +1,4 @@ +RDEPENDS_${PN} += "\ + audiomanager \ + " + \ No newline at end of file diff --git a/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/amcp_dbus.conf b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/amcp_dbus.conf new file mode 100644 index 000000000..49544d5e5 --- /dev/null +++ b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/amcp_dbus.conf @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + diff --git a/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/amrp_dbus.conf b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/amrp_dbus.conf new file mode 100644 index 000000000..6832d305e --- /dev/null +++ b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/amrp_dbus.conf @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + diff --git a/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/configuration.xml b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/configuration.xml new file mode 100644 index 000000000..3df7d5ca9 --- /dev/null +++ b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/configuration.xml @@ -0,0 +1,522 @@ + + + + + 0 + UNKNOWN + SourceTemplate + 0 + TRUE + UNKNOWN + SS_OFF + CF_GENIVI_STEREO + CF_GENIVI_MONO + IS_OFF + + A_AVAILABLE + AR_UNKNOWN + + + SP_GENIVI_TREBLE + 5 + + + SP_GENIVI_MID + 5 + + + SP_GENIVI_BASS + 5 + + + MSP_GENIVI_TREBLE + 5 + + + MSP_GENIVI_MID + 5 + + + MSP_GENIVI_BASS + 5 + + REG_TEMPLATE + TRUE + 1 + + MSP_UNKNOWN,SP_UNKNOWN + MSP_GENIVI_TREBLE,SP_GENIVI_TREBLE + + + + 1 + PulseAudio + mediaplayer + BASE + REG_ROUTER + + + 2 + PulseAudio + ALSA#Playback + BASE + REG_ROUTER + + + 3 + PulseAudio + music + BASE + REG_ROUTER + + + 4 + PulseAudio + Navi + INT + REG_ROUTER + + + 5 + PulseAudio + phone + PHONE + REG_ROUTER + + + + + 0 + UNKNOWN + SinkTemplate + 0 + TRUE + 100 + BASE + MS_UNMUTED + CF_GENIVI_STEREO + CF_GENIVI_MONO + + A_AVAILABLE + AR_GENIVI_NEWMEDIA + + + SP_GENIVI_TREBLE + 5 + + + SP_GENIVI_MID + 5 + + + SP_GENIVI_BASS + 5 + + + MSP_GENIVI_TREBLE + 5 + + + MSP_GENIVI_MID + 5 + + + MSP_GENIVI_BASS + 5 + + REG_TEMPLATE + TRUE + 1 + + 0,0.0 + 1,0.01 + 2,0.02 + 3,0.03 + 4,0.04 + 5,0.05 + 6,0.06 + 7,0.07 + 8,0.08 + 9,0.09 + 10,0.1 + 11,0.11 + 12,0.12 + 14,0.14 + 15,0.15 + 17,0.17 + 20,0.2 + 22,0.22 + 25,0.25 + 28,0.28 + 31,0.31 + 35,0.35 + 40,0.4 + 45,0.45 + 50,0.5 + 56,0.56 + 62,0.62 + 70,0.7 + 80,0.8 + 90,0.9 + 100,1.0 + + + 0.0,-192.0 + 0.01,-40.0 + 0.02,-34.0 + 0.03,-30.0 + 0.04,-27.0 + 0.05,-26.0 + 0.06,-24.0 + 0.07,-23.0 + 0.08,-22.0 + 0.09,-21.0 + 0.1,-20.0 + 0.11,-19.0 + 0.12,-18.0 + 0.14,-17.0 + 0.15,-16.0 + 0.17,-15.0 + 0.2,-14.0 + 0.22,-13.0 + 0.25,-12.0 + 0.28,-11.0 + 0.31,-10.0 + 0.35,-9.0 + 0.4,-8.0 + 0.45,-7.0 + 0.5,-6.0 + 0.56,-5.0 + 0.62,-4.0 + 0.7,-3.0 + 0.8,-2.0 + 0.9,-1.0 + 1.0,0.0 + + + MSP_UNKNOWN,SP_UNKNOWN + MSP_GENIVI_TREBLE,SP_GENIVI_TREBLE + + + + 1 + PulseAudio + rsnd-dai.0-ak4642-hifi#Analog#Stereo + BASE + REG_ROUTER + + + 2 + PulseAudio + Microchip#MOST:0#Multichannel + BASE + REG_ROUTER + + + + + + + + 0 + PulseAudio + org.genivi.audiomanager + pulseaudio + FALSE + TRUE + DS_CONTROLLED + REG_ROUTER + + + + + BASE + C_PLAYBACK + 1 + Microchip#MOST:0#Multichannel^rsnd-dai.0-ak4642-hifi#Analog#Stereo=mediaplayer^music^ALSA#Playback + + + INT + C_PLAYBACK + 2 + Microchip#MOST:0#Multichannel^rsnd-dai.0-ak4642-hifi#Analog#Stereo=Navi + + + PHONE + C_PLAYBACK + 3 + Microchip#MOST:0#Multichannel^rsnd-dai.0-ak4642-hifi#Analog#Stereo=phone + + + + + + + USER_CONNECTION_REQUEST + + name(CLASS, REQUESTING) EQ "BASE" + connectionState(CONNECTIONOFCLASS, REQUESTING, OTHERS) INC CS_CONNECTED + + ACTION_SUSPEND + + "BASE" + CS_CONNECTED + + + + + + + USER_CONNECTION_REQUEST + + name(CLASS, REQUESTING) EQ "INT" + + ACTION_LIMIT + + "BASE" + -2500 + 01 + + + + + name(CLASS, REQUESTING) EQ "INT" + connectionState(CONNECTIONOFCLASS, REQUESTING, OTHERS) INC CS_CONNECTED + priority(CONNECTIONOFCLASS, REQUESTING, OTHERS) LT priority(CONNECTION, REQUESTING) + + ACTION_PUSH + + "INT" + O_NEWEST + + + TRUE + + + name(CLASS, REQUESTING) EQ "INT" + connectionState(CONNECTIONOFCLASS, REQUESTING, OTHERS) INC CS_CONNECTED + + ACTION_PUSH + + "INT" + O_OLDEST + + + + + name(CLASS, REQUESTING) EQ "INT" + connectionState(CONNECTIONOFCLASS, "PHONE") INC CS_CONNECTED + + ACTION_MUTE + + REQUESTING + + + + ACTION_CONNECT + + REQUESTING + + + TRUE + + + + + USER_CONNECTION_REQUEST + + name(CLASS, REQUESTING) EQ "PHONE" + + ACTION_LIMIT + + "BASE" + -2500 + 02 + + + + + name(CLASS, REQUESTING) EQ "PHONE" + connectionState(CONNECTIONOFCLASS, "INT") INC CS_CONNECTED + + ACTION_MUTE + + "INT" + + + + + name(SINK, REQUESTING) EQ "AMP" + + ACTION_CONNECT + + REQUESTING + 5000 + + + TRUE + + + + + + USER_DISCONNECTION_REQUEST + + + ACTION_DISCONNECT + + REQUESTING + REQUESTING + + + + + name(CLASS, REQUESTING) EQ "INT" + + ACTION_UNLIMIT + + "BASE" + 01 + + + + + name(CLASS, REQUESTING) EQ "INT" + connectionState(CONNECTIONOFCLASS, REQUESTING, OTHERS) INC CS_CONNECTED + + ACTION_POP + + "INT" + O_OLDEST + + + + + name(CLASS, REQUESTING) EQ "PHONE" + connectionState(CONNECTIONOFCLASS, "INT") INC CS_CONNECTED + + ACTION_UNMUTE + + "INT" + + + + + name(CLASS, REQUESTING) EQ "PHONE" + + ACTION_UNLIMIT + + "BASE" + 02 + + + + + name(CLASS, REQUESTING) EQ "BASE" + connectionState(CONNECTIONOFCLASS, "BASE") INC CS_SUSPENDED + + ACTION_RESUME + + "BASE" + CS_SUSPENDED + + + + + + + USER_SET_VOLUME + + + ACTION_SET_VOLUME + + REQUESTING + + + + + + + + USER_SET_SINK_MUTE_STATE + + muteState(USER,REQUESTING) EQ MS_MUTED + + ACTION_MUTE + + REQUESTING + + + + + muteState(USER,REQUESTING) EQ MS_UNMUTED + + ACTION_UNMUTE + + REQUESTING + + + + + + + + USER_SET_SINK_MAIN_SOUND_PROPERTY + + + ACTION_SET_PROPERTY + + REQUESTING + + + + + + + + USER_SET_SOURCE_MAIN_SOUND_PROPERTY + + + ACTION_SET_PROPERTY + + REQUESTING + + + + + + + + USER_CONNECTION_REQUEST + + + ACTION_MUTE + + REQUESTING + 5000 + + + + ACTION_CONNECT + + REQUESTING + 5000 + + + + ACTION_UNMUTE + + REQUESTING + + + + + + + + + SYP_DEBUG_LOG + 5 + + + diff --git a/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/customtypes.xsd b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/customtypes.xsd new file mode 100644 index 000000000..2604fb71f --- /dev/null +++ b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/customtypes.xsd @@ -0,0 +1,63 @@ + + + + + This enumeration list the source/sink availability change reason. + + + + + + + This enumeration list the source and sink sound property. The sound properties of Genivi Audio manager can be extended to include project specific properties. Three sound properties like volume persistence, connection persistence and volume support are extended. + + + + + + + This enumeration lists the connection format for the source and sinks. + + + + + + + This enumeration contains the type of notification possible. + + + + + + + This enumeration lists the system properties. + + + + + 1 + + + + + + + + + + + + This enumeration lists the Main Properties for source and sinks. + + + + + + + + + + + + + diff --git a/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/org.genivi.audiomanager.routing.pulseaudio.conf b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/org.genivi.audiomanager.routing.pulseaudio.conf new file mode 100644 index 000000000..f77845a3a --- /dev/null +++ b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config/org.genivi.audiomanager.routing.pulseaudio.conf @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config_7.4.bb b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config_7.4.bb new file mode 100644 index 000000000..b8b76ec21 --- /dev/null +++ b/recipes-multimedia/audiomanager-plugins-config/audiomanager-plugins-config_7.4.bb @@ -0,0 +1,38 @@ +DESCRIPTION = "Configurations for Audiomanager Plugins for AGL Demo" +HOMEPAGE = "" +LICENSE = "Proprietary" +SECTION = "multimedia" + +LIC_FILES_CHKSUM = "file://${WORKDIR}/configuration.xml;md5=97090515005265aca5bddffcee4bc8a1" +RDEPENDS_${PN} = "libxml2 zlib dbus-lib" + +SRC_URI = " \ + file://amcp_dbus.conf \ + file://amrp_dbus.conf \ + file://configuration.xml \ + file://customtypes.xsd \ + file://org.genivi.audiomanager.routing.pulseaudio.conf \ +" + +FILES_${PN} = " \ + ${sysconfdir}/dbus-1/system.d/amcp_dbus.conf \ + ${sysconfdir}/dbus-1/system.d/amrp_dbus.conf \ + ${sysconfdir}/dbus-1/system.d/org.genivi.audiomanager.routing.pulseaudio.conf \ + ${sysconfdir}/audiomanager/control/configuration.xml \ + ${sysconfdir}/audiomanager/control/customtypes.xsd \ +" + +FILES_${PN}-dbg += " \ + /usr/lib/audiomanager/command/.debug \ + /usr/lib/audiomanager/routing/.debug \ +" + +do_install() { + install -d ${D}${sysconfdir}/dbus-1/system.d + install -m 644 ${WORKDIR}/amcp_dbus.conf ${D}${sysconfdir}/dbus-1/system.d/ + install -m 644 ${WORKDIR}/amrp_dbus.conf ${D}${sysconfdir}/dbus-1/system.d/ + install -m 644 ${WORKDIR}/org.genivi.audiomanager.routing.pulseaudio.conf ${D}${sysconfdir}/dbus-1/system.d/ + install -d ${D}${sysconfdir}/audiomanager/control + install -m 644 ${WORKDIR}/configuration.xml ${D}${sysconfdir}/audiomanager/control/ + install -m 644 ${WORKDIR}/customtypes.xsd ${D}${sysconfdir}/audiomanager/control/ +} diff --git a/recipes-multimedia/audiomanager-plugins/audiomanager-plugins_git.bb b/recipes-multimedia/audiomanager-plugins/audiomanager-plugins_git.bb new file mode 100644 index 000000000..c81f414b2 --- /dev/null +++ b/recipes-multimedia/audiomanager-plugins/audiomanager-plugins_git.bb @@ -0,0 +1,59 @@ +DESCRIPTION = "GENIVI Audio Manager Plugins" +HOMEPAGE = "http://projects.genivi.org/audio-manager/home" +LICENSE = "MPLv2" +SECTION = "multimedia" +DEPENDS = "audiomanager libxml2 dbus pulseaudio" +RDEPENDS_${PN} = "audiomanager-plugins-config" + +LIC_FILES_CHKSUM = "file://PluginControlInterfaceGeneric/LICENSE.txt;md5=815ca599c9df247a0c7f619bab123dad" + +SRC_URI = " \ + git://github.com/tisogai/AudioManagerPlugins.git;protocol=https;branch=unknown_element_support \ + " + +SRCREV = "bf5c5e8198b85e84363770150d5a02f553f43296" + +S = "${WORKDIR}/git" +inherit cmake +OECMAKE_CXX_FLAGS += "-std=c++11" +EXTRA_OECMAKE = " \ + -DWITH_COMMAND_INTERFACE_CAPI=OFF \ + -DWITH_COMMAND_INTERFACE_DBUS=ON \ + -DWITH_ROUTING_INTERFACE_ASYNC=OFF \ + -DWITH_ROUTING_INTERFACE_CAPI=OFF \ + -DWITH_ROUTING_INTERFACE_DBUS=ON \ + -DWITH_TEST_CONTROLLER=OFF \ + -DWITH_GENERIC_CONTROLLER=ON \ + -DCONTROLLER_CONFIG_DIR="/etc/audiomanager/control" \ +" + +# NOTE: The specific product should have a separate customtypes.xsd +# and should be appended to FILES_${PN} in product specific +# audiomanager-generic-controller_git.bbappend +FILES_${PN} = " \ + ${libdir}/audiomanager/control/libPluginControlInterfaceGeneric.so \ + ${sysconfdir}/audiomanager/control/audiomanagertypes.xsd \ + ${libdir}/audiomanager/command/libPluginCommandInterfaceDbus.so \ + ${libdir}/audiomanager/routing/libPluginRoutingInterfaceDbus.so \ + /usr/share/audiomanager/audiomanager/CommandInterface.xml \ + /usr/share/audiomanager/audiomanager/RoutingReceiver.xml \ +" + +# NOTE: The specific product should have a separate customtypes.h +# and should be appended to FILES_${PN}-dev in product specific +# audiomanager-generic-controller_git.bbappend +FILES_${PN}-dev = " \ + ${sysconfdir}/audiomanager/control/xsd2header.pl \ +" + +FILES_${PN}-dbg += " \ + ${libdir}/audiomanager/control/.debug/libPluginControlInterfaceGeneric.so \ + ${libdir}/audiomanager/command/.debug/libPluginCommandInterfaceDbus.so \ + ${libdir}/audiomanager/routing/.debug/libPluginRoutingInterfaceDbus.so \ +" + +# remove example configurations +do_install_append() { + rm -rf ${D}${sysconfdir}/audiomanager/control/*.xml + rm -rf ${D}${sysconfdir}/audiomanager/control/customtypes.xsd +} diff --git a/recipes-multimedia/module-router/module-router_git.bb b/recipes-multimedia/module-router/module-router_git.bb new file mode 100755 index 000000000..e84382408 --- /dev/null +++ b/recipes-multimedia/module-router/module-router_git.bb @@ -0,0 +1,31 @@ +DESCRIPTION = "Pulseaudio router module" +HOMEPAGE = "https://github.com/tisogai/module-router" +LICENSE = "LGPLv2" +SECTION = "multimedia" +DEPENDS = "pulseaudio" + +LIC_FILES_CHKSUM = "file://LICENSE;md5=fc178bcd425090939a8b634d1d6a9594" + +SRC_URI = " \ + git://github.com/tisogai/module-router.git;protocol=https;branch=master \ + " + +SRCREV = "10b9b8bbd890dcd9acb55d4bb12f80659e1338b6" + +S = "${WORKDIR}/git" +inherit cmake +OECMAKE_CXX_FLAGS += "-std=c++11" + +# NOTE: The specific product should have a separate customtypes.xsd +# and should be appended to FILES_${PN} in product specific +# audiomanager-generic-controller_git.bbappend +FILES_${PN} = " \ + ${libdir}/pulse-*/modules/module-router.so \ +" + + +FILES_${PN}-dbg += " \ + ${libdir}/pulse-*/modules/.debug/module-router.so \ +" + + -- cgit 1.2.3-korg