From 336f80ec03f1ba3e9d41f381ce60ab4cb1e1bb30 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Sat, 10 Oct 2015 05:28:47 +0200 Subject: added midi captureing code --- apps/dolmetschctl.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'apps/dolmetschctl.c') diff --git a/apps/dolmetschctl.c b/apps/dolmetschctl.c index e60dbcc..0fc9877 100644 --- a/apps/dolmetschctl.c +++ b/apps/dolmetschctl.c @@ -26,6 +26,8 @@ #include #include "osc.h" +#include "midi.h" + void print_version() { @@ -39,15 +41,17 @@ void print_version() #endif } - int main(int argc, char* argv[]) { lo_server_thread st = osc_init("7770"); + // TODO: check if this worked! + + midi_t m; + if(midi_init(&m, "hw:2,0,0")) + return -1; osc_start(st); - while (1) { - usleep(1000); - } + midi_run(&m); osc_stop(st); return 0; -- cgit v1.2.3