hdspmixer - Automatic initialization of secondary cards

From debian bug#450805:

We are using Hammerfall DSP cards. After booting, their audio output
remains silent until hdspmixer is started. No interaction in the GUI
of hdspmixer is necessary to unmute the first HDSP card; however,
further cards are only unmuted when activating the respective GUI
page ("2", "3"). Apparently, hdspmixer does some automatic
initialization of the card when activating the page.

Since we'd like to have a fully automatic startup, the following
patch activates the page for each existing card on startup, thereby
initializing them. There are surely more elegant solutions, but this
patch is tested and solves the problem for us.
This commit is contained in:
Takashi Iwai 2007-11-14 13:04:34 +01:00
parent e978fc745e
commit d6d0775e8c
3 changed files with 18 additions and 16 deletions

View file

@ -700,6 +700,9 @@ HDSPMixerWindow::HDSPMixerWindow(int x, int y, int w, int h, const char *label,
Fl::atclose = atclose_cb;
Fl::add_handler(handler_cb);
Fl::add_timeout(0.030, readregisters_cb, this);
i = 0;
while (cards[i] != NULL)
inputs->buttons->cardselector->ActivateCard (i++);
}
int HDSPMixerWindow::handle(int e)