diff --git a/faup1090.c b/faup1090.c index 1ca0a01..8a29f95 100644 --- a/faup1090.c +++ b/faup1090.c @@ -130,6 +130,22 @@ static void backgroundTasks(void) { modesNetPeriodicWork(); } +static void sendBeastSettings(struct client *c, const char *settings) { + int len; + char *buf, *p; + + len = strlen(settings) * 3; + buf = p = alloca(len); + + while (*settings) { + *p++ = 0x1a; + *p++ = '1'; + *p++ = *settings++; + } + + anetWrite(c->fd, buf, len); +} + // //========================================================================= // @@ -193,6 +209,8 @@ int main(int argc, char **argv) { exit (1); } + sendBeastSettings(c, "Cdfj"); // Beast binary, no filters, CRC checks on, no mode A/C + // Set up output connection on stdout fatsv_output = makeFatsvOutputService(); createGenericClient(fatsv_output, STDOUT_FILENO);