diff options
Diffstat (limited to 'AudioManagerPoC/resources/scripts')
-rwxr-xr-x | AudioManagerPoC/resources/scripts/getconnections.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/getvolumes_val.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/playCarReverse.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/playmusic.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/playnav.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/playtel.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/playtts.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/setvolume.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/stopCarReverse.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/stopmusic.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/stopnav.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/stoptel.sh | 22 | ||||
-rwxr-xr-x | AudioManagerPoC/resources/scripts/stoptts.sh | 22 | ||||
-rw-r--r-- | AudioManagerPoC/resources/scripts/tabs.js | 36 |
14 files changed, 322 insertions, 0 deletions
diff --git a/AudioManagerPoC/resources/scripts/getconnections.sh b/AudioManagerPoC/resources/scripts/getconnections.sh new file mode 100755 index 0000000..6e51bc3 --- /dev/null +++ b/AudioManagerPoC/resources/scripts/getconnections.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +dbus-send --session --print-reply --dest=org.genivi.audiomanager /org/genivi/audiomanager/commandinterface org.genivi.audiomanager.commandinterface.GetListMainConnections | awk '/struct/ {getline;getline;SOURCE=$2;getline;SINK=$2;getline;getline;STATUS=$2;print "Source"SOURCE"-->Sink"SINK"(Status"STATUS")";}' | sed 's/Source100/MediaPlayer/g' | sed 's/Source101/NaviPlayer/g' | sed 's/Source102/TTSPlayer/g' | sed 's/Source103/Skype/g' | sed 's/Source104/ReverseBeep/g' | sed 's/Sink100/AlsaPrimary/g' | sed 's/Sink101/AlsaSecondary/g' | sed 's/Status1/Connecting/g' | sed 's/Status2/Connected/g' | sed 's/Status3/Disconnecting/g' | sed 's/Status4/Disconnected/g' | sed 's/Status5/Suspended/g' diff --git a/AudioManagerPoC/resources/scripts/getvolumes_val.sh b/AudioManagerPoC/resources/scripts/getvolumes_val.sh new file mode 100755 index 0000000..f44cb74 --- /dev/null +++ b/AudioManagerPoC/resources/scripts/getvolumes_val.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +dbus-send --session --print-reply --dest=org.genivi.audiomanager /org/genivi/audiomanager/commandinterface org.genivi.audiomanager.commandinterface.GetListMainSinks | awk '/struct/ {getline; FS="\""; getline;NAME=$2; getline; getline; getline; getline;FS=" "; getline;print NAME","$2}' diff --git a/AudioManagerPoC/resources/scripts/playCarReverse.sh b/AudioManagerPoC/resources/scripts/playCarReverse.sh new file mode 100755 index 0000000..b91acbc --- /dev/null +++ b/AudioManagerPoC/resources/scripts/playCarReverse.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +PULSE_PROP="media.role='reverse'" aplay /opt/audiomanager-poc/audio-files/car_reverse.wav diff --git a/AudioManagerPoC/resources/scripts/playmusic.sh b/AudioManagerPoC/resources/scripts/playmusic.sh new file mode 100755 index 0000000..8f15e7e --- /dev/null +++ b/AudioManagerPoC/resources/scripts/playmusic.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +PULSE_PROP="media.role='MEDIA'" aplay /opt/audiomanager-poc/audio-files/UNKLE_-_Burn_My_Shadow.wav diff --git a/AudioManagerPoC/resources/scripts/playnav.sh b/AudioManagerPoC/resources/scripts/playnav.sh new file mode 100755 index 0000000..40d7e3d --- /dev/null +++ b/AudioManagerPoC/resources/scripts/playnav.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +PULSE_PROP="media.role='NAVI'" aplay /opt/audiomanager-poc/audio-files/navigation.wav diff --git a/AudioManagerPoC/resources/scripts/playtel.sh b/AudioManagerPoC/resources/scripts/playtel.sh new file mode 100755 index 0000000..1d73bd3 --- /dev/null +++ b/AudioManagerPoC/resources/scripts/playtel.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +PULSE_PROP="media.role='skype'" aplay /opt/audiomanager-poc/audio-files/telephone-ring.wav diff --git a/AudioManagerPoC/resources/scripts/playtts.sh b/AudioManagerPoC/resources/scripts/playtts.sh new file mode 100755 index 0000000..ec8eb8a --- /dev/null +++ b/AudioManagerPoC/resources/scripts/playtts.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +PULSE_PROP="media.role='TextToSpeach'" aplay /opt/audiomanager-poc/audio-files/tts.wav diff --git a/AudioManagerPoC/resources/scripts/setvolume.sh b/AudioManagerPoC/resources/scripts/setvolume.sh new file mode 100755 index 0000000..8c9db7b --- /dev/null +++ b/AudioManagerPoC/resources/scripts/setvolume.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +RESULT=`python -c 'import dbus; print dbus.SessionBus().call_blocking("org.genivi.audiomanager", "/org/genivi/audiomanager/commandinterface", "org.genivi.audiomanager.commandinterface", "SetVolume", "ui", (dbus.UInt32(100), dbus.UInt32('$1') ))'` diff --git a/AudioManagerPoC/resources/scripts/stopCarReverse.sh b/AudioManagerPoC/resources/scripts/stopCarReverse.sh new file mode 100755 index 0000000..d5dce81 --- /dev/null +++ b/AudioManagerPoC/resources/scripts/stopCarReverse.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +ps aux | grep [c]ar_reverse.wav | awk '{print $2}' | xargs kill -9 diff --git a/AudioManagerPoC/resources/scripts/stopmusic.sh b/AudioManagerPoC/resources/scripts/stopmusic.sh new file mode 100755 index 0000000..a1d546e --- /dev/null +++ b/AudioManagerPoC/resources/scripts/stopmusic.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +ps aux | grep [U]NKLE | awk '{print $2}' | xargs kill -9 diff --git a/AudioManagerPoC/resources/scripts/stopnav.sh b/AudioManagerPoC/resources/scripts/stopnav.sh new file mode 100755 index 0000000..dd4894e --- /dev/null +++ b/AudioManagerPoC/resources/scripts/stopnav.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +ps aux | grep [n]avigation.wav | awk '{print $2}' | xargs kill -9 diff --git a/AudioManagerPoC/resources/scripts/stoptel.sh b/AudioManagerPoC/resources/scripts/stoptel.sh new file mode 100755 index 0000000..d6db116 --- /dev/null +++ b/AudioManagerPoC/resources/scripts/stoptel.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +ps aux | grep [t]elephone | awk '{print $2}' | xargs kill -9 diff --git a/AudioManagerPoC/resources/scripts/stoptts.sh b/AudioManagerPoC/resources/scripts/stoptts.sh new file mode 100755 index 0000000..2bc12b7 --- /dev/null +++ b/AudioManagerPoC/resources/scripts/stoptts.sh @@ -0,0 +1,22 @@ +#!/bin/sh + +# SPDX license identifier: MPL-2.0 +# +# Copyright (C) 2011-2014, Wind River Systems +# Copyright (C) 2014, GENIVI Alliance +# +# This file is part of GENIVI AudioManager PoC. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License (MPL), v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# For further information see http://www.genivi.org/. +# +# List of changes: +# +# 21.09.2014, Adrian Scarlat, First version of the code; +# Added Copyright and License information; +# + +ps aux | grep [t]ts.wav | awk '{print $2}' | xargs kill -9 diff --git a/AudioManagerPoC/resources/scripts/tabs.js b/AudioManagerPoC/resources/scripts/tabs.js new file mode 100644 index 0000000..836744a --- /dev/null +++ b/AudioManagerPoC/resources/scripts/tabs.js @@ -0,0 +1,36 @@ +/** + * SPDX license identifier: MPL-2.0 + * + * Copyright (C) 2011-2014, Wind River Systems + * Copyright (C) 2014, GENIVI Alliance + * + * This file is part of GENIVI AudioManager PoC. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License (MPL), v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * For further information see http://www.genivi.org/. + * + * List of changes: + * + * 21.09.2014, Adrian Scarlat, First version of the code; + * Added Copyright and License information; + * + */ + +var tabIDS = new Array(); + +var oldSelectedTab = null; +var oldSelectedTabContent; + +function tabSelected(newSelectedTab, newSelectedTabContent) +{ + console.log("newSelectedTab, newSelectedTabContent", newSelectedTab, newSelectedTabContent); + if (oldSelectedTab) + { + oldSelectedTab.visible = false; + } + + oldSelectedTab = newSelectedTab; +} |