Karsten Wiese <annabellesgarden@yahoo.de>:

This has more features:
- PCM-Volume adjusted to MasteVolumeSlider setting at device start.
- Direct Monitoring Functions adjustable directly on the US428
- Alsa Sequencer Output port for applications to receive the US428 sliders
etc.
This commit is contained in:
Takashi Iwai 2003-10-24 14:01:45 +00:00
parent 08f4ff3ade
commit 4e978a5a7e
10 changed files with 369 additions and 52 deletions

View file

@ -31,6 +31,7 @@
#include <alsa/asoundlib.h>
#include "Cus428_ctls.h"
#include "Cus428State.h"
#include "Cus428Midi.h"
#define PROGNAME "us428control"
@ -41,6 +42,8 @@
int verbose = 1;
Cus428Midi Midi;
static void error(const char *fmt, ...)
{
@ -56,7 +59,7 @@ static void error(const char *fmt, ...)
static void usage(void)
{
printf("Tascam US-428 Contol\n");
printf("Tascam US-428 Control\n");
printf("version %s\n", VERSION);
printf("usage: "PROGNAME" [-v verbosity_level 0..2] [-c card] [-D device] [-u usb-device]\n");
}
@ -104,8 +107,10 @@ int US428Control(const char* DevName)
perror("mmap failed:");
return -ENOMEM;
}
Midi.CreatePorts();
us428ctls_sharedmem->CtlSnapShotRed = us428ctls_sharedmem->CtlSnapShotLast;
OneState = new Cus428State(us428ctls_sharedmem);
OneState->InitDevice();
while (1) {
int x = poll(&pfds,1,-1);
if (verbose > 1 || pfds.revents & (POLLERR|POLLHUP))