
Zitat von
Keen
Ich hab mir den Quellcode mal durchgesehen.
Ich glaube, dass ist die wesentliche Stelle (demod_zvei.c)
Code:
void zvei_action(void) {
/* Aktion für ZVEI
* system ruft die auszufuehrende
* Datei mit Pfad auf */
...
while (1) {
if(strcmp(act->string, "(@rec)&")) {
time(&tp);
/* falls nicht bereits innerhalb der letzten 30 Sec. */
if (tp - act->value > 1) {//30
act->value = tp;
system(act->string);
}
}
else
record_start(al->code.zvei);
....
Die Funktion "record_start" findet sich in der unixinout.c.
In der demod_fms.c gibt es folgenden Abschitt:
Code:
case 2: /* ACTFMS */
if (*ss == '[') ss++;
actact = (*form)->action;
if (actact == NULL) {
actact = (Line *) malloc (sizeof(Line));
}
else {
actroot = actact;
while (actact->next != NULL) actact->next = actact->next->next;
actact->next = (Line *) malloc (sizeof(Line));
actact = actact->next;
}
memset(actact, 0, sizeof(Line));
strncat(actact->string, &c[2], 1);
while (*ss && *ss != ']') {
strncat(actact->string, ss, 1);
ss++;
}
if (strlen(actact->string) == 1) {
char zero[] = "ls > /dev/null";
strcat(actact->string, zero);
}
strncat(actact->string, c, 2);
if (actroot == NULL) (*form)->action = actact;
else
break;
und da müßte irgendwo eine Abfrage rein, ob das Schlüsselwort "@rec" in der Parameterzeile von ACTFMS steht, gefolgt vom Aufruf der Funktion "record_start".
Soweit die Theorie.
Aber wie gesagt: Meine C-Kentnisse reichen nicht aus, um die erforderlichen Änderungen sauber in die fms.c reinzuprogrammieren.
Welcher gewiefte C-Guru in diesem Forum kann helfen?
viele Grüße,
Andreas