Client applications don't start the mm-detect service the same
way they start other multimedia components at specific times to perform various media tasks.
The QNX CAR platform uses the System Launch Monitor (SLM) service
to automate starting mm-detect during bootup.
Applications can start mm-detect manually for recovery purposes.
Starting mm-detect with specific command options during bootup
SLM automates process management by launching processes in an order that respects
their interprocess dependencies. The list of processes to launch and their
properties, including their command-line arguments and interprocess dependencies, is
written in a configuration file (/etc/slm-config-all.xml).
During bootup, SLM reads this file and carries out its instructions for starting
processes.
Using SLM to start mm-detect ensures the car infotainment system
is ready to play media when the system finishes booting up and that the media
detection service is started with the same command options and therefore behaves
consistently from one bootup to the next. For the full explanation of how SLM works,
refer to the release notes for the QNX CAR application platform 2.0 RR.
SLM is preconfigured to start mm-detect with specific command
options but you can change which command options are passed to mm-detect
to suit the usage needs of your car system and applications.
To change the command options passed by SLM to mm-detect:
-
From a command console connected to your car system,
navigate to and open the SLM configuration file, whose full path is:
/etc/slm-config-all.xml.
-
In the configuration file, locate the
component that specifies the properties for
mm-detect.
This component is the
<SLM:component> XML object with the name
"mmdetect".
-
Change the value of the <SLM:args> tag in the
"mmdetect" component to hold the new set of command-line
options to pass to mm-detect at startup.
For the full list of command-line options, see mm-detect command line.
-
Save the changes to the SLM configuration file and return to the console.
-
If you want the new configuration to take effect immediately, in the console,
enter reboot.
The system reboots and the SLM utility relaunches all the processes,
including mm-detect, with their respective command options
specified in the configuration file. When the system finishes reloading,
mm-detect is running with the new configuration.
If
you don't reboot immediately after changing the configuration file,
mm-detect continues to run with its previous configuration,
until you shut down the system and restart, at which point the new command
options take effect.