File tree Expand file tree Collapse file tree 3 files changed +13
-1
lines changed
Expand file tree Collapse file tree 3 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -55,6 +55,8 @@ typedef enum {ASPECT_RATIOS} ENUM_ASPECT_RATIOS_TYPES;
5555#define SHELL_CMD_SCHEDULE_POWERDOWN " sched_shutdown"
5656#define SHELL_CMD_SET_LAUNCHER_GMENU2X " set_launcher gmenu2x"
5757#define SHELL_CMD_SET_LAUNCHER_RETROFE " set_launcher retrofe"
58+ #define SHELL_CMD_TURN_AMPLI_ON " start_audio_amp 1"
59+ #define SHELL_CMD_TURN_AMPLI_OFF " start_audio_amp 0"
5860
5961class FunkeyMenu
6062{
Original file line number Diff line number Diff line change @@ -178,6 +178,9 @@ int main(int /*argc*/, char * /*argv*/[]) {
178178 set_handler (SIGTERM, &quit_all);
179179 set_handler (SIGUSR1, &handle_sigusr1);
180180
181+ /* Stop Ampli */
182+ popen (SHELL_CMD_TURN_AMPLI_OFF, " r" );
183+
181184 char *home = getenv (" HOME" );
182185 if (home == NULL ) {
183186 ERROR (" Unable to find gmenu2x home directory. The $HOME variable is not defined.\n " );
Original file line number Diff line number Diff line change 11#include " launcher.h"
2-
2+ # include " funkeymenu.h "
33#include " debug.h"
44
55#include < cerrno>
@@ -32,6 +32,10 @@ Launcher::Launcher(vector<string> && commandLine, bool consoleApp)
3232
3333void Launcher::exec ()
3434{
35+
36+ /* Start audio amp */
37+ popen (SHELL_CMD_TURN_AMPLI_ON, " r" );
38+
3539 if (consoleApp) {
3640#ifdef BIND_CONSOLE
3741 /* Enable the framebuffer console */
@@ -55,12 +59,15 @@ void Launcher::exec()
5559#endif
5660 }
5761
62+ INFO (" Launching '" );
5863 vector<const char *> args;
5964 args.reserve (commandLine.size () + 1 );
6065 for (auto arg : commandLine) {
6166 args.push_back (strdup (arg.c_str ()));
67+ INFO (" %s " , args.back () );
6268 }
6369 args.push_back (nullptr );
70+ INFO (" '\n " );
6471
6572 execvp (commandLine[0 ].c_str (), (char * const *)args.data ());
6673 WARNING (" Failed to exec '%s': %s\n " ,
You can’t perform that action at this time.
0 commit comments