Skip to content

Commit

Permalink
Log AppleMIDI session invites only in debug mode
Browse files Browse the repository at this point in the history
Also align MW messages better in the UI
  • Loading branch information
rhargreaves committed Oct 10, 2021
1 parent 326da72 commit c83c0e0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/applemidi.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include <stdbool.h>
#include "comm_megawifi.h"
#include "memory.h"
#include "settings.h"

static mw_err unpackInvitation(
char* buffer, u16 length, AppleMidiExchangePacket* invite);
Expand All @@ -17,7 +18,10 @@ static mw_err processInvitation(u8 ch, char* buffer, u16 length)
if (err != MW_ERR_NONE) {
return err;
}
log_info("AM: Session invite on UDP ch %d", ch);

if (settings_debug_megawifi_init()) {
log_info("AM: Session invite on UDP ch %d", ch);
}
sendInviteResponse(ch, &packet);
return MW_ERR_NONE;
}
Expand Down
2 changes: 1 addition & 1 deletion src/ui.c
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ static void print_megawifi_info(void)
index2 = 5;
break;
}
drawText(MW_TEXT[index2], 8, MAX_EFFECTIVE_Y - 1);
drawText(MW_TEXT[index2], 16, MAX_EFFECTIVE_Y);
}

static void printCommMode(void)
Expand Down

0 comments on commit c83c0e0

Please sign in to comment.