aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorcbdev <cb@cbcdn.com>2020-03-17 23:58:06 +0100
committercbdev <cb@cbcdn.com>2020-03-17 23:58:06 +0100
commitdaf9ac5b883cf981a163654d58932bfbdce619d9 (patch)
tree16d6ebd1a2ded4294d432c8767786ae56fffd67a
parent636a9592eab1963c2b1a77bd59eaff317fa55b75 (diff)
downloadmidimonster-daf9ac5b883cf981a163654d58932bfbdce619d9.tar.gz
midimonster-daf9ac5b883cf981a163654d58932bfbdce619d9.tar.bz2
midimonster-daf9ac5b883cf981a163654d58932bfbdce619d9.zip
Output routing info to log
-rw-r--r--configs/launchctl-sacn.cfg2
-rw-r--r--midimonster.c9
2 files changed, 10 insertions, 1 deletions
diff --git a/configs/launchctl-sacn.cfg b/configs/launchctl-sacn.cfg
index dedfc0f..10a736a 100644
--- a/configs/launchctl-sacn.cfg
+++ b/configs/launchctl-sacn.cfg
@@ -7,7 +7,7 @@
name = MIDIMonster
[backend sacn]
-bind = 0.0.0.0
+bind = 0.0.0.0 5568 local
[midi lc]
read = Launch Control
diff --git a/midimonster.c b/midimonster.c
index 1691671..5109eab 100644
--- a/midimonster.c
+++ b/midimonster.c
@@ -456,6 +456,7 @@ static int core_loop(){
int main(int argc, char** argv){
int rv = EXIT_FAILURE;
char* cfg_file = DEFAULT_CFG;
+ size_t u, n = 0, max = 0;
//parse commandline arguments
if(args_parse(argc, argv, &cfg_file)){
@@ -494,6 +495,14 @@ int main(int argc, char** argv){
signal(SIGINT, signal_handler);
+ //count and report mappings
+ for(u = 0; u < sizeof(routing.map) / sizeof(routing.map[0]); u++){
+ n += routing.entries[u];
+ max = max(max, routing.entries[u]);
+ }
+ LOGPF("Routing %" PRIsize_t " sources, largest bucket has %" PRIsize_t " entries",
+ n, max);
+
if(!fds){
fprintf(stderr, "No descriptors registered for multiplexing\n");
}