1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
\r
2 "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
\r
3 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
\r
5 <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />
\r
6 <meta name="generator" content="AsciiDoc 8.6.6" />
\r
7 <title>GENIVI_AudioManager</title>
\r
8 <style type="text/css">
\r
9 /* Shared CSS for AsciiDoc xhtml11 and html5 backends */
\r
13 font-family: Georgia,serif;
\r
17 h1, h2, h3, h4, h5, h6,
\r
18 div.title, caption.title,
\r
19 thead, p.table.header,
\r
21 #author, #revnumber, #revdate, #revremark,
\r
23 font-family: Arial,Helvetica,sans-serif;
\r
27 margin: 1em 5% 1em 5%;
\r
32 text-decoration: underline;
\r
48 h1, h2, h3, h4, h5, h6 {
\r
51 margin-bottom: 0.5em;
\r
56 border-bottom: 2px solid silver;
\r
76 border: 1px solid silver;
\r
81 margin-bottom: 0.5em;
\r
87 ul > li { color: #aaa; }
\r
88 ul > li > * { color: black; }
\r
102 #revnumber, #revdate, #revremark {
\r
107 border-top: 2px solid silver;
\r
108 padding-top: 0.5em;
\r
113 padding-bottom: 0.5em;
\r
117 padding-bottom: 0.5em;
\r
122 margin-bottom: 1.5em;
\r
124 div.imageblock, div.exampleblock, div.verseblock,
\r
125 div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
\r
126 div.admonitionblock {
\r
128 margin-bottom: 1.5em;
\r
130 div.admonitionblock {
\r
132 margin-bottom: 2.0em;
\r
137 div.content { /* Block element content. */
\r
141 /* Block element titles. */
\r
142 div.title, caption.title {
\r
147 margin-bottom: 0.5em;
\r
153 td div.title:first-child {
\r
156 div.content div.title:first-child {
\r
159 div.content + div.title {
\r
163 div.sidebarblock > div.content {
\r
164 background: #ffffee;
\r
165 border: 1px solid #dddddd;
\r
166 border-left: 4px solid #f0f0f0;
\r
170 div.listingblock > div.content {
\r
171 border: 1px solid #dddddd;
\r
172 border-left: 5px solid #f0f0f0;
\r
173 background: #f8f8f8;
\r
177 div.quoteblock, div.verseblock {
\r
178 padding-left: 1.0em;
\r
179 margin-left: 1.0em;
\r
181 border-left: 5px solid #f0f0f0;
\r
185 div.quoteblock > div.attribution {
\r
186 padding-top: 0.5em;
\r
190 div.verseblock > pre.content {
\r
191 font-family: inherit;
\r
192 font-size: inherit;
\r
194 div.verseblock > div.attribution {
\r
195 padding-top: 0.75em;
\r
198 /* DEPRECATED: Pre version 8.2.7 verse style literal block. */
\r
199 div.verseblock + div.attribution {
\r
203 div.admonitionblock .icon {
\r
204 vertical-align: top;
\r
207 text-decoration: underline;
\r
209 padding-right: 0.5em;
\r
211 div.admonitionblock td.content {
\r
212 padding-left: 0.5em;
\r
213 border-left: 3px solid #dddddd;
\r
216 div.exampleblock > div.content {
\r
217 border-left: 3px solid #dddddd;
\r
218 padding-left: 0.5em;
\r
221 div.imageblock div.content { padding-left: 0; }
\r
222 span.image img { border-style: none; }
\r
223 a.image:visited { color: white; }
\r
227 margin-bottom: 0.8em;
\r
232 font-style: normal;
\r
235 dd > *:first-child {
\r
240 list-style-position: outside;
\r
243 list-style-type: decimal;
\r
246 list-style-type: lower-alpha;
\r
249 list-style-type: upper-alpha;
\r
252 list-style-type: lower-roman;
\r
255 list-style-type: upper-roman;
\r
258 div.compact ul, div.compact ol,
\r
259 div.compact p, div.compact p,
\r
260 div.compact div, div.compact div {
\r
262 margin-bottom: 0.1em;
\r
274 margin-bottom: 0.8em;
\r
277 padding-bottom: 15px;
\r
279 dt.hdlist1.strong, td.hdlist1.strong {
\r
283 vertical-align: top;
\r
284 font-style: normal;
\r
285 padding-right: 0.8em;
\r
289 vertical-align: top;
\r
291 div.hdlist.compact tr {
\r
297 background: yellow;
\r
300 .footnote, .footnoteref {
\r
304 span.footnote, span.footnoteref {
\r
305 vertical-align: super;
\r
309 margin: 20px 0 20px 0;
\r
310 padding: 7px 0 0 0;
\r
313 #footnotes div.footnote {
\r
319 border-top: 1px solid silver;
\r
328 padding-right: 0.5em;
\r
329 padding-bottom: 0.3em;
\r
330 vertical-align: top;
\r
332 div.colist td img {
\r
337 #footer-badges { display: none; }
\r
341 margin-bottom: 2.5em;
\r
349 margin-bottom: 0.1em;
\r
352 div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 {
\r
369 span.aqua { color: aqua; }
\r
370 span.black { color: black; }
\r
371 span.blue { color: blue; }
\r
372 span.fuchsia { color: fuchsia; }
\r
373 span.gray { color: gray; }
\r
374 span.green { color: green; }
\r
375 span.lime { color: lime; }
\r
376 span.maroon { color: maroon; }
\r
377 span.navy { color: navy; }
\r
378 span.olive { color: olive; }
\r
379 span.purple { color: purple; }
\r
380 span.red { color: red; }
\r
381 span.silver { color: silver; }
\r
382 span.teal { color: teal; }
\r
383 span.white { color: white; }
\r
384 span.yellow { color: yellow; }
\r
386 span.aqua-background { background: aqua; }
\r
387 span.black-background { background: black; }
\r
388 span.blue-background { background: blue; }
\r
389 span.fuchsia-background { background: fuchsia; }
\r
390 span.gray-background { background: gray; }
\r
391 span.green-background { background: green; }
\r
392 span.lime-background { background: lime; }
\r
393 span.maroon-background { background: maroon; }
\r
394 span.navy-background { background: navy; }
\r
395 span.olive-background { background: olive; }
\r
396 span.purple-background { background: purple; }
\r
397 span.red-background { background: red; }
\r
398 span.silver-background { background: silver; }
\r
399 span.teal-background { background: teal; }
\r
400 span.white-background { background: white; }
\r
401 span.yellow-background { background: yellow; }
\r
403 span.big { font-size: 2em; }
\r
404 span.small { font-size: 0.6em; }
\r
406 span.underline { text-decoration: underline; }
\r
407 span.overline { text-decoration: overline; }
\r
408 span.line-through { text-decoration: line-through; }
\r
417 font-family: monospace;
\r
418 font-size: inherit;
\r
424 margin-bottom: 1.5em;
\r
426 div.tableblock > table {
\r
427 border: 3px solid #527bbd;
\r
429 thead, p.table.header {
\r
436 /* Because the table frame attribute is overriden by CSS in most browsers. */
\r
437 div.tableblock > table[frame="void"] {
\r
438 border-style: none;
\r
440 div.tableblock > table[frame="hsides"] {
\r
441 border-left-style: none;
\r
442 border-right-style: none;
\r
444 div.tableblock > table[frame="vsides"] {
\r
445 border-top-style: none;
\r
446 border-bottom-style: none;
\r
456 font-family: monospace;
\r
457 font-size: inherit;
\r
463 margin-bottom: 1.5em;
\r
465 thead, p.tableblock.header {
\r
474 border-spacing: 0px;
\r
475 border-style: solid;
\r
476 border-color: #527bbd;
\r
477 border-collapse: collapse;
\r
479 th.tableblock, td.tableblock {
\r
482 border-style: solid;
\r
483 border-color: #527bbd;
\r
486 table.tableblock.frame-topbot {
\r
487 border-left-style: hidden;
\r
488 border-right-style: hidden;
\r
490 table.tableblock.frame-sides {
\r
491 border-top-style: hidden;
\r
492 border-bottom-style: hidden;
\r
494 table.tableblock.frame-none {
\r
495 border-style: hidden;
\r
498 th.tableblock.halign-left, td.tableblock.halign-left {
\r
501 th.tableblock.halign-center, td.tableblock.halign-center {
\r
502 text-align: center;
\r
504 th.tableblock.halign-right, td.tableblock.halign-right {
\r
508 th.tableblock.valign-top, td.tableblock.valign-top {
\r
509 vertical-align: top;
\r
511 th.tableblock.valign-middle, td.tableblock.valign-middle {
\r
512 vertical-align: middle;
\r
514 th.tableblock.valign-bottom, td.tableblock.valign-bottom {
\r
515 vertical-align: bottom;
\r
525 padding-top: 0.5em;
\r
526 padding-bottom: 0.5em;
\r
527 border-top: 2px solid silver;
\r
528 border-bottom: 2px solid silver;
\r
531 border-style: none;
\r
533 body.manpage div.sectionbody {
\r
538 body.manpage div#toc { display: none; }
\r
541 <script type="text/javascript">
\r
543 var asciidoc = { // Namespace.
\r
545 /////////////////////////////////////////////////////////////////////
\r
546 // Table Of Contents generator
\r
547 /////////////////////////////////////////////////////////////////////
\r
549 /* Author: Mihai Bazon, September 2002
\r
550 * http://students.infoiasi.ro/~mishoo
\r
552 * Table Of Content generator
\r
555 * Feel free to use this script under the terms of the GNU General Public
\r
556 * License, as long as you do not remove or alter this notice.
\r
559 /* modified by Troy D. Hanson, September 2006. License: GPL */
\r
560 /* modified by Stuart Rackham, 2006, 2009. License: GPL */
\r
562 // toclevels = 1..4.
\r
563 toc: function (toclevels) {
\r
565 function getText(el) {
\r
567 for (var i = el.firstChild; i != null; i = i.nextSibling) {
\r
568 if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants.
\r
570 else if (i.firstChild != null)
\r
571 text += getText(i);
\r
576 function TocEntry(el, text, toclevel) {
\r
579 this.toclevel = toclevel;
\r
582 function tocEntries(el, toclevels) {
\r
583 var result = new Array;
\r
584 var re = new RegExp('[hH]([2-'+(toclevels+1)+'])');
\r
585 // Function that scans the DOM tree for header elements (the DOM2
\r
586 // nodeIterator API would be a better technique but not supported by all
\r
588 var iterate = function (el) {
\r
589 for (var i = el.firstChild; i != null; i = i.nextSibling) {
\r
590 if (i.nodeType == 1 /* Node.ELEMENT_NODE */) {
\r
591 var mo = re.exec(i.tagName);
\r
592 if (mo && (i.getAttribute("class") || i.getAttribute("className")) != "float") {
\r
593 result[result.length] = new TocEntry(i, getText(i), mo[1]-1);
\r
603 var toc = document.getElementById("toc");
\r
608 // Delete existing TOC entries in case we're reloading the TOC.
\r
609 var tocEntriesToRemove = [];
\r
611 for (i = 0; i < toc.childNodes.length; i++) {
\r
612 var entry = toc.childNodes[i];
\r
613 if (entry.nodeName == 'div'
\r
614 && entry.getAttribute("class")
\r
615 && entry.getAttribute("class").match(/^toclevel/))
\r
616 tocEntriesToRemove.push(entry);
\r
618 for (i = 0; i < tocEntriesToRemove.length; i++) {
\r
619 toc.removeChild(tocEntriesToRemove[i]);
\r
622 // Rebuild TOC entries.
\r
623 var entries = tocEntries(document.getElementById("content"), toclevels);
\r
624 for (var i = 0; i < entries.length; ++i) {
\r
625 var entry = entries[i];
\r
626 if (entry.element.id == "")
\r
627 entry.element.id = "_toc_" + i;
\r
628 var a = document.createElement("a");
\r
629 a.href = "#" + entry.element.id;
\r
630 a.appendChild(document.createTextNode(entry.text));
\r
631 var div = document.createElement("div");
\r
632 div.appendChild(a);
\r
633 div.className = "toclevel" + entry.toclevel;
\r
634 toc.appendChild(div);
\r
636 if (entries.length == 0)
\r
637 toc.parentNode.removeChild(toc);
\r
641 /////////////////////////////////////////////////////////////////////
\r
642 // Footnotes generator
\r
643 /////////////////////////////////////////////////////////////////////
\r
645 /* Based on footnote generation code from:
\r
646 * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html
\r
649 footnotes: function () {
\r
650 // Delete existing footnote entries in case we're reloading the footnodes.
\r
652 var noteholder = document.getElementById("footnotes");
\r
656 var entriesToRemove = [];
\r
657 for (i = 0; i < noteholder.childNodes.length; i++) {
\r
658 var entry = noteholder.childNodes[i];
\r
659 if (entry.nodeName == 'div' && entry.getAttribute("class") == "footnote")
\r
660 entriesToRemove.push(entry);
\r
662 for (i = 0; i < entriesToRemove.length; i++) {
\r
663 noteholder.removeChild(entriesToRemove[i]);
\r
666 // Rebuild footnote entries.
\r
667 var cont = document.getElementById("content");
\r
668 var spans = cont.getElementsByTagName("span");
\r
671 for (i=0; i<spans.length; i++) {
\r
672 if (spans[i].className == "footnote") {
\r
674 var note = spans[i].getAttribute("data-note");
\r
676 // Use [\s\S] in place of . so multi-line matches work.
\r
677 // Because JavaScript has no s (dotall) regex flag.
\r
678 note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
\r
679 spans[i].innerHTML =
\r
680 "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
\r
681 "' title='View footnote' class='footnote'>" + n + "</a>]";
\r
682 spans[i].setAttribute("data-note", note);
\r
684 noteholder.innerHTML +=
\r
685 "<div class='footnote' id='_footnote_" + n + "'>" +
\r
686 "<a href='#_footnoteref_" + n + "' title='Return to text'>" +
\r
687 n + "</a>. " + note + "</div>";
\r
688 var id =spans[i].getAttribute("id");
\r
689 if (id != null) refs["#"+id] = n;
\r
693 noteholder.parentNode.removeChild(noteholder);
\r
695 // Process footnoterefs.
\r
696 for (i=0; i<spans.length; i++) {
\r
697 if (spans[i].className == "footnoteref") {
\r
698 var href = spans[i].getElementsByTagName("a")[0].getAttribute("href");
\r
699 href = href.match(/#.*/)[0]; // Because IE return full URL.
\r
701 spans[i].innerHTML =
\r
702 "[<a href='#_footnote_" + n +
\r
703 "' title='View footnote' class='footnote'>" + n + "</a>]";
\r
709 install: function(toclevels) {
\r
712 function reinstall() {
\r
713 asciidoc.footnotes();
\r
715 asciidoc.toc(toclevels);
\r
719 function reinstallAndRemoveTimer() {
\r
720 clearInterval(timerId);
\r
724 timerId = setInterval(reinstall, 500);
\r
725 if (document.addEventListener)
\r
726 document.addEventListener("DOMContentLoaded", reinstallAndRemoveTimer, false);
\r
728 window.onload = reinstallAndRemoveTimer;
\r
732 asciidoc.install();
\r
736 <body class="article">
\r
738 <h1>GENIVI_AudioManager</h1>
\r
739 <span id="author">Christian Linke <christian.linke@bmw.de></span><br />
\r
742 <div class="sect1">
\r
743 <h2 id="_copyright">Copyright</h2>
\r
744 <div class="sectionbody">
\r
745 <div class="paragraph"><p>Copyright © 2012, GENIVI Alliance, Inc.
\r
746 Copyright © 2012, BMW AG</p></div>
\r
747 <div class="paragraph"><p>This file is part of GENIVI Project AudioManager.</p></div>
\r
748 <div class="paragraph"><p>Contributions are licensed to the GENIVI Alliance under one or more
\r
749 Contribution License Agreements or MPL 2.0 .</p></div>
\r
750 <div class="paragraph"><p>© Copyright
\r
751 This Source Code Form is subject to the terms of the
\r
752 Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with
\r
753 this file, You can obtain one at <a href="http://mozilla.org/MPL/2.0/">http://mozilla.org/MPL/2.0/</a>.</p></div>
\r
754 <div class="paragraph"><p>author Christian Mueller, <a href="mailto:christian.linke@bmw.de">christian.linke@bmw.de</a> BMW 2011,2012</p></div>
\r
755 <div class="paragraph"><p>For further information see <a href="http://projects.genivi.org/audio-manager/">http://projects.genivi.org/audio-manager/</a>.</p></div>
\r
758 <div class="sect1">
\r
759 <h2 id="_license">License</h2>
\r
760 <div class="sectionbody">
\r
761 <div class="paragraph"><p>The licenses of this project are split into two parts:
\r
762 1) the AudioManagerDaemon, licensed under MPL 2.0
\r
763 2) all other parts that serve as example code that can be taken to build up an own project with it -
\r
764 these parts are licensed with the MIT license</p></div>
\r
765 <div class="paragraph"><p>Contribution is done under GENIVI CLA or MPL2.0.</p></div>
\r
768 <div class="sect1">
\r
769 <h2 id="_version">Version</h2>
\r
770 <div class="sectionbody">
\r
771 <div class="paragraph"><p>The current version can be taken out of the git. The version 1.0.0 is the first GENIVI compliant code,in the compliance statement of discovery (2.0).
\r
772 For every GENIVI release, there is a release of the AudioManager, each of the releases have an own bugfix branch that will get the most important fixes.
\r
773 Development is done on the master branch.</p></div>
\r
774 <div class="sect2">
\r
775 <h3 id="_versioning_scheme">Versioning Scheme</h3>
\r
776 <div class="paragraph"><p>The versioning scheme was decided in the February face2face 2012.
\r
777 The firs number describes the release branch. This is 1 for discovery, 2 for excalibur and 3 for photon. For major features or release, the second number will be increased.
\r
778 Each new GENIVI version (releases are every half year, around april and october) will get the current HEAD (for example 2.0.34 for excalibur) and release with the increase of the second number (2.1).
\r
779 The next commit on the master branch gets then the new first numner (3) and starts from zero.</p></div>
\r
780 <div class="paragraph"><p>For the daemon the third number (for example 1.0.X) describes the patch version. The versions are automatically created by git during the build process.
\r
781 The versioning scheme is used for the AudioManager daemon itself and for each of it’s interfaces. The versioning of the Interfaces in EA is defined via the tag "version" and the name of the interfaceversion versionName, for example "CommandReceiveVersion". This information is generated into the interface header files and is used then by cmake to set the interface versions.
\r
782 Whenever changes are done, the minor version of the interface needs to be incremented.</p></div>
\r
786 <div class="sect1">
\r
787 <h2 id="_documentation">Documentation</h2>
\r
788 <div class="sectionbody">
\r
789 <div class="paragraph"><p>A very detailed documentation is provided by doxygen. In order to use this, please compile the AudioManager with</p></div>
\r
790 <div class="listingblock">
\r
791 <div class="content">
\r
792 <pre><tt>cmake -DWITH_DOCUMENTATION=ON
\r
797 <div class="sect1">
\r
798 <h2 id="_compile_programs">COMPILE PROGRAMS</h2>
\r
799 <div class="sectionbody">
\r
800 <div class="sect2">
\r
801 <h3 id="_compile_options">Compile Options</h3>
\r
802 <div class="paragraph"><p>These are the compile options with default values:</p></div>
\r
803 <div class="literalblock">
\r
804 <div class="content">
\r
805 <pre><tt>BUILD_SHARED_LIBS OFF
\r
807 CMAKE_INSTALL_PREFIX /usr/local
\r
808 COMMON_API_DBUS_LIBRARY /usr/local/lib/libCommonAPI-DBus.so
\r
809 COMMON_API_LIBRARY /usr/local/lib/libCommonAPI.so
\r
810 GLIB_DBUS_TYPES_TOLERANT ON
\r
812 WITH_COMMAND_INTERFACE_COMMON_ ON
\r
813 WITH_DATABASE_STORAGE OFF
\r
815 WITH_DOCUMENTATION ON
\r
816 WITH_ENABLED_IPC CAPI
\r
819 WITH_OXF_ANIMATION OFF
\r
821 WITH_PLUGIN_COMMAND ON
\r
822 WITH_PLUGIN_CONTROL ON
\r
823 WITH_PLUGIN_ROUTING ON
\r
824 WITH_ROUTING_INTERFACE_ASYNC OFF
\r
825 WITH_ROUTING_INTERFACE_CAPI ON
\r
826 WITH_SYSTEMD_WATCHDOG OFF
\r
829 WITH_TEST_CONTROLLER OFF
\r
830 gmock_build_tests OFF
\r
831 gtest_build_samples OFF
\r
832 gtest_build_tests OFF
\r
833 gtest_disable_pthreads OFF
\r
834 gtest_force_shared_crt OFF</tt></pre>
\r
837 <div class="sect2">
\r
838 <h3 id="_passing_options_to_cmake">Passing options to cmake:</h3>
\r
839 <div class="paragraph"><div class="title">-DVERSION="XXX"</div><p>When building the AudioManager without taking it from the git (and thus having a .git folder), you can set the version via passing <em>-DVERSION="XXX"</em> to cmake.</p></div>
\r
840 <div class="paragraph"><div class="title">-DDBUS_SERVICE_PREFIX="XXX"</div><p>sets the service prefix for Dbus, default "org.genivi.audiomanager\0"</p></div>
\r
841 <div class="paragraph"><div class="title">-DDBUS_SERVICE_OBJECT_PATH="XXX"</div><p>sets the object path for Dbus, default "/org/genivi/audiomanager\0"</p></div>
\r
842 <div class="paragraph"><div class="title">-DDEFAULT_TELNETPORT="XXX"</div><p>sets the default telnetport, default 6060. Can be overwriten by command line parameter</p></div>
\r
843 <div class="paragraph"><div class="title">-DMAX_TELNETCONNECTIONS="XXX"</div><p>sets the default maximum number of telnetconnections, default is 3</p></div>
\r
844 <div class="paragraph"><div class="title">-DNSM_PATH="XXX"</div><p>sets the path of the NSM DBUS interface</p></div>
\r
845 <div class="paragraph"><div class="title">-DNSM_INTERFACE="XXX"</div><p>sets the interface to the NSM DBUS interface</p></div>
\r
846 <div class="paragraph"><p>In order to change these options, you can modify this values with ccmake, do the appropriate changes in
\r
847 CmakeList.txt or via the commandline for cmake or (when installed via ccmake)</p></div>
\r
849 <div class="sect2">
\r
850 <h3 id="_build_dependencies">Build dependencies</h3>
\r
851 <div class="paragraph"><p>Basically, all build dependencies are optional- but you might need to use some if you want to have support for Dbus,
\r
852 for example…</p></div>
\r
853 <div class="paragraph"><p>You will need optionally fullfill some dependencies in order to comile the GENIVI AudioManager Daemon, these are:</p></div>
\r
854 <div class="ulist"><ul>
\r
857 dbus (only when DBUS_WRAPPER==ON) [tested on version 1.2.16]
\r
862 sqlite3 [tested on version 3.6.22] (only when WITH_DATABASE_STORAGE==ON)
\r
867 automotive-dlt [greater 2.5.0] (only when WITH_DLT==ON)
\r
872 doxygen [tested on version 1.6.3] (only when WITH_DOCUMENTATION==ON)
\r
877 commonAPI [version > 2.1] (only with WITH_ENABLED_IPC CAPI), more information here <a href="http://projects.genivi.org/commonapi/">http://projects.genivi.org/commonapi/</a>
\r
881 <div class="paragraph"><p>To install them in a build environment like Ubuntu you can use:</p></div>
\r
882 <div class="listingblock">
\r
883 <div class="content">
\r
884 <pre><tt>sudo apt-get install libdbus-1-dev libsqlite3-dev doxygen git cmake build-essential</tt></pre>
\r
887 <div class="sect2">
\r
888 <h3 id="_the_nodestatemanager">The NodeStateManager</h3>
\r
889 <div class="paragraph"><p>The nodestatemanager headers are needed to compile the audiomanager. If the nodestatemanagerincludes are not found,
\r
890 the headers shipped with the audiomanager are used.
\r
891 The nodestatemanager can be retrieved from projects.genivi.org . You can install the headers on you system by</p></div>
\r
892 <div class="listingblock">
\r
893 <div class="content">
\r
894 <pre><tt>sudo make install-includeHEADERS</tt></pre>
\r
896 <div class="paragraph"><p>For building the tests, you will need the following packages:</p></div>
\r
897 <div class="ulist"><ul>
\r
900 python [tested on version 2.6, should work on higher versions as well]
\r
904 <div class="paragraph"><p>GoogleMock and GoogleTest are as source code integrated in the sourcetree
\r
905 To install them in a build environment like Ubuntu you can use:</p></div>
\r
906 <div class="listingblock">
\r
907 <div class="content">
\r
908 <pre><tt>sudo apt-get install python2.6-dev</tt></pre>
\r
910 <div class="paragraph"><p>For compiling, you will need a compiler, linker etc. On most linux systems you will get this via</p></div>
\r
911 <div class="listingblock">
\r
912 <div class="content">
\r
913 <pre><tt>sudo apt-get install build-essential</tt></pre>
\r
915 <div class="paragraph"><p>More details in the CMake Files CmakeList.txt in the projects.</p></div>
\r
917 <div class="sect2">
\r
918 <h3 id="_compiling">Compiling</h3>
\r
919 <div class="paragraph"><p>To compile open a shell, browse to the AudioManager folder and</p></div>
\r
920 <div class="listingblock">
\r
921 <div class="content">
\r
922 <pre><tt>mkdir /build
\r
927 <div class="paragraph"><p>After the script finished, you should have:</p></div>
\r
928 <div class="ulist"><ul>
\r
931 a bin/ folder which contains all executables and the libraries:
\r
936 a build/ folder which has all build objects (erase that if you need a clean build)
\r
941 a doc/ folder in case you turned the documentation on
\r
945 <div class="paragraph"><p>In order to install the AudioManager, you can do</p></div>
\r
946 <div class="listingblock">
\r
947 <div class="content">
\r
948 <pre><tt>sudo make install</tt></pre>
\r
950 <div class="paragraph"><p>Package generation is supported via CPack. To build packages, you have to</p></div>
\r
951 <div class="listingblock">
\r
952 <div class="content">
\r
953 <pre><tt>make genivi_package</tt></pre>
\r
955 <div class="paragraph"><p>This will create one package if your CMake version is < 2.8.5 (all binaries stripped):</p></div>
\r
956 <div class="listingblock">
\r
957 <div class="content">
\r
958 <pre><tt>AudioManager-<git verison>-Linux.deb</tt></pre>
\r
960 <div class="paragraph"><p>If your version is above 2.8.5, you will get 4 packages (all binaries stripped) :</p></div>
\r
961 <div class="ulist"><ul>
\r
964 AudioManager-<git verison>-Linux-bin.deb [AudioManager binary]
\r
969 AudioManager-<git verison>-Linux-dev.deb [header files needed to compile plugins]
\r
974 AudioManager-<git verison>-Linux-sampleplugins.deb [sample plugins]
\r
979 AudioManager-<git verison>-Linux-tests.deb [tests including tests for sample plugins, installed in the ~/AudioMAnagerTests]
\r
983 <div class="paragraph"><p>In order to create a tar.gz file of all sources (not including .git, build and bin folder,config files), you can do:</p></div>
\r
984 <div class="listingblock">
\r
985 <div class="content">
\r
986 <pre><tt>make package_source</tt></pre>
\r
988 <div class="paragraph"><p>This will create the following package:
\r
989 <em>AudioManager-<git verison>-Source.tar.gz</em></p></div>
\r
990 <div class="paragraph"><p>All packages will be placed in a folder called packages</p></div>
\r
992 <div class="sect2">
\r
993 <h3 id="_adding_own_plugins">Adding own plugins</h3>
\r
994 <div class="paragraph"><p>Since the AudioManager needs to be completed with on plugins before it can be used, it provides a mechanism to keep the own sources away from the GENIVI code but compile them together.</p></div>
\r
995 <div class="admonitionblock">
\r
998 <div class="title">Tip</div>
\r
1000 <td class="content">Using this feature is simple:<br />
\r
1001 Just add a folder with the name <em>ProjectSpecific</em> (be sure to name it excactly like this!) on the main level of the AudioManager folder. CMake will look for CMakeLists.txt in this folder and add all files that it finds in /include to the include path. You can use this to add subfolders with your own plugins and includes, and overwrite productspecific.h for example.</td>
\r
1004 <div class="listingblock">
\r
1005 <div class="title">Here is a sample CMakeLists.txt that can be placed in ProjectSpecific folder:</div>
\r
1006 <div class="content">
\r
1007 <pre><tt>cmake_minimum_required(VERSION 2.6)
\r
1009 ### set your own buildflags:
\r
1010 set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -Wall -Wextra -std=c++98 -D_GNU_SOURCE -pedantic -Wno-variadic-macros")
\r
1012 ##overwrite priojecttypes.h:
\r
1013 CONFIGURE_FILE( ${CMAKE_SOURCE_DIR}/ProjectSpecific/overwrite/projecttypes.h ${CMAKE_SOURCE_DIR}/include/projecttypes.h COPYONLY)
\r
1015 if(WITH_PLUGIN_ROUTING)
\r
1016 add_subdirectory (../PluginRoutingInterfaceMyRoutingPlugin ${CMAKE_CURRENT_BINARY_DIR}/PluginRoutingInterfaceMyRoutingPlugin )
\r
1017 endif(WITH_PLUGIN_ROUTING)
\r
1019 if(WITH_PLUGIN_CONTROL)
\r
1020 add_subdirectory ( ../PluginControlInterfaceMyControlPlugin ${CMAKE_CURRENT_BINARY_DIR}/PluginControlInterfaceMyControlPlugin)
\r
1021 endif(WITH_PLUGIN_CONTROL)</tt></pre>
\r
1024 <div class="sect2">
\r
1025 <h3 id="_commandline_options">CommandLine options</h3>
\r
1026 <div class="paragraph"><p>The commandline options of the AudioManager:</p></div>
\r
1027 <div class="listingblock">
\r
1028 <div class="content">
\r
1029 <pre><tt>AudioManagerDaemon Version: 3.0.11
\r
1030 Usage: AudioManagerDaemon [options]
\r
1032 -h: print this message
\r
1033 -i: info about current settings
\r
1035 -d: daemonize AudioManager
\r
1036 -T: DbusType to be used by CAmDbusWrapper (0=DBUS_SESSION[default], 1=DBUS_SYSTEM)
\r
1037 -p<path> path for sqlite database (default is in memory)
\r
1038 -t<port> port for telnetconnection
\r
1039 -m<max> number of max telnetconnections
\r
1040 -c<Name> use controllerPlugin <Name> (full path with .so ending)
\r
1041 -l<Name> replace command plugin directory with <Name> (full path)
\r
1042 -r<Name> replace routing plugin directory with <Name> (full path)
\r
1043 -L<Name> add command plugin directory with <Name> (full path)
\r
1044 -R<Name> add routing plugin directory with <Name> (full path)</tt></pre>
\r
1049 <div class="sect1">
\r
1050 <h2 id="_telnet_server">Telnet Server</h2>
\r
1051 <div class="sectionbody">
\r
1052 <div class="paragraph"><p>The audiomanager has a build- in telnetserver that serves for debuggin purposes.
\r
1053 If you compile your AudioManager with TelnetServer support (cmake -DWITH_TELNET=ON), you will be able to
\r
1054 set with commandline argument -t the port number and with -m the maximum supported connections.
\r
1055 The default telnet port is 6060.</p></div>
\r
1056 <div class="literalblock">
\r
1057 <div class="title">For example, launch a telnet session on port 6060:</div>
\r
1058 <div class="content">
\r
1059 <pre><tt>telnet localhost 6060</tt></pre>
\r
1061 <div class="literalblock">
\r
1062 <div class="content">
\r
1063 <pre><tt>#>Welcome to GENIVI AudioManager ver-0.0.1-37-ga004215
\r
1066 <div class="literalblock">
\r
1067 <div class="title">press <em>help</em> to get a list of all supported commands on this level:</div>
\r
1068 <div class="content">
\r
1069 <pre><tt>#>help
\r
1070 ####################################################
\r
1071 ####### The following commands are supported: ######
\r
1072 ####################################################
\r
1074 #exit - quit telnet session
\r
1075 #get - Go into 'get'-submenu
\r
1076 #help - show all possible commands
\r
1077 #info - Go into 'info'-submenu
\r
1078 #list - Go into 'list'-submenu
\r
1079 #set - Go into 'set'-submenu
\r
1083 <div class="literalblock">
\r
1084 <div class="title">Now type one of these commands, for example <em>get</em>, followed with another <em>help</em> to get a list of supported commands:</div>
\r
1085 <div class="content">
\r
1086 <pre><tt>#\>get
\r
1089 ####################################################
\r
1090 ####### The following commands are supported: ######
\r
1091 ####################################################
\r
1093 #.. - one step back in menu tree (back to root folder)
\r
1094 #exit - close telnet session
\r
1095 #help - show all possible commands
\r
1096 #recv - show receiverversion
\r
1097 #routing - show current routing
\r
1098 #sendv - show senderversion
\r
1100 #\Get></tt></pre>
\r
1102 <div class="literalblock">
\r
1103 <div class="title">You can also execute several commands in a line:</div>
\r
1104 <div class="content">
\r
1105 <pre><tt>#\Get>recv sendv .. help exit
\r
1106 # Receiver versions:
\r
1107 # Ctrl: 1 | Cmd: 1 | Routing: 1
\r
1108 # Sender versions:
\r
1109 # Ctrl: 1 | Cmd: 1 | Routing: 1
\r
1110 ####################################################
\r
1111 ######## The following commands are supported: ######
\r
1112 ####################################################
\r
1114 #exit - quit telnet session
\r
1115 #get - Go into 'get'-submenu
\r
1116 #help - show all possible commands
\r
1117 #info - Go into 'info'-submenu
\r
1118 #list - Go into 'list'-submenu
\r
1119 #set - Go into 'set'-submenu
\r
1121 #Your wish is my command ... bye!
\r
1122 #Connection closed by foreign host.</tt></pre>
\r
1126 <div class="sect1">
\r
1127 <h2 id="_code_formatting">Code Formatting</h2>
\r
1128 <div class="sectionbody">
\r
1129 <div class="paragraph"><p>The source code if formatted with eclipse, the style sheet used can be found in the cmake folder:</p></div>
\r
1130 <div class="listingblock">
\r
1131 <div class="content">
\r
1132 <pre><tt>cmake/AudioManager_Codestyle.xml</tt></pre>
\r
1136 <div class="sect1">
\r
1137 <h2 id="_working_on_the_code_amp_contribution">Working on the code & contribution</h2>
\r
1138 <div class="sectionbody">
\r
1139 <div class="literalblock">
\r
1140 <div class="title">First get the code from the git:</div>
\r
1141 <div class="content">
\r
1142 <pre><tt>git clone</tt></pre>
\r
1144 <div class="literalblock">
\r
1145 <div class="title">Get an overview of all branches:</div>
\r
1146 <div class="content">
\r
1147 <pre><tt>git branch</tt></pre>
\r
1149 <div class="literalblock">
\r
1150 <div class="title">Switch to the branch you want to work on (see versioning schmeme, the master is the feature branch) and verify that it has switched (* changed)</div>
\r
1151 <div class="content">
\r
1152 <pre><tt>git checkout <your branch>
\r
1153 git branch</tt></pre>
\r
1155 <div class="literalblock">
\r
1156 <div class="title">Best practice is to create a local branch based on the current branch:</div>
\r
1157 <div class="content">
\r
1158 <pre><tt>git branch working_branch</tt></pre>
\r
1160 <div class="paragraph"><p>Start working, best practice is to commit smaller, compilable peaced during the work that makes it easier to
\r
1161 handle later on.</p></div>
\r
1162 <div class="literalblock">
\r
1163 <div class="title">If you want to commit you changes, send them to the audiomanager-dev list, you can create a patch like this:</div>
\r
1164 <div class="content">
\r
1165 <pre><tt>git format-patch working_branch <your branch></tt></pre>
\r
1167 <div class="paragraph"><p>This creates a set of patches that are published via the mailing list.The patches will be discussed and then merged & uploaded on the git by the maintainer.</p></div>
\r
1168 <div class="paragraph"><p>Patches can be accepted either under GENIVI Cla or MPL 2.0 (see section License). Please be sure that the signed-off-by is set correctly. For more, check out <a href="http://gerrit.googlecode.com/svn/documentation/2.0/user-signedoffby.html">http://gerrit.googlecode.com/svn/documentation/2.0/user-signedoffby.html</a></p></div>
\r
1169 <div class="listingblock">
\r
1170 <div class="content">
\r
1171 <pre><tt> _ _ _ __ __
\r
1172 / \ _ _ __| (_) ___ | \/ | __ _ _ __ __ _ __ _ ___ _ __
\r
1173 / _ \| | | |/ _` | |/ _ \| |\/| |/ _` | '_ \ / _` |/ _` |/ _ \ '__|
\r
1174 / ___ \ |_| | (_| | | (_) | | | | (_| | | | | (_| | (_| | __/ |
\r
1175 /_/ \_\__,_|\__,_|_|\___/|_| |_|\__,_|_| |_|\__,_|\__, |\___|_|
\r
1191 )4QQQQ^ .yQQQQ, QQQQQQQ
\r
1192 aa 4QQQW' )?QQQP' gmQQma
\r
1194 ???? aQQQ6p _aQQQQa "??"+
\r
1195 qaaa, ]QQQQQQ jQQQQQQf -aaaap
\r
1196 jQQWWQ )????' )4QQQQP' mQWQWQf
\r
1197 ]WQQQQ jaaa QQQQQQf
\r
1198 )WQQQQ yQQWWQp ayQQQap QQQQQQf
\r
1199 )QQQQQ QQQQQQf ]QQQQQQQ, QQQQQQf
\r
1200 ]QQQQD QQQQQQf ]QQQQQQQ[ QQQQQQf
\r
1201 ??': QQQQQQf ]QQQQQQQ[ 4QQQQQf
\r
1202 QQQQQQf ]QQQQQQQ[ =????'I
\r
1204 .4QQQQQ' ]QQQQQQQ[
\r
1209 qaayQQQQQQQQQwaa ]mmmmmmmmmmmmmm ]mmmmmmg, ]mmm[ ]mmmm 4mmmg ymmm' ]mmmm pwLq
\r
1210 jQQQQD???????QWWQf ]QQQP?????????? ]QQQWQQQQp ]QQQf ]QQQQ 4QQQ6. _yQQQ' ]QQQQ \!'a'
\r
1211 ]QQQf )???' ]QQQ6aaaaaaaaap ]QQQf)4QQQ6, ]QQQf ]QQQQ |4QQQ6 jmQQQ'v ]QQQQ
\r
1212 ]QQQ[ ]QQQQWWQQf ]QQQQQQQWQWQWQf ]QQQf ?QQQQa ]QQQf ]QQQQ i4QQQ6 qQQQQ' ]QQQQ
\r
1213 ]QQQ6, . qQQQf ]QQQf ]QQQf ]4QQQ6jQQQf ]QQQQ 4QQQ6gQWQQ' ]QQQQ
\r
1214 4QQQQQQQQQQQQQQW' ]QQQQQQWQWQWQWQ ]QQQf i?QQQQQQQf ]QQQQ ]QQQQQQQ' ]QQQQ
\r
1215 ++"??????????` ]""!"""""""""""S ]""!' ]"""!""' -""!" """!""' ]""!"</tt></pre>
\r
1220 <div id="footnotes"><hr /></div>
\r
1222 <div id="footer-text">
\r
1223 Last updated 2013-09-12 10:26:35 CEST
\r