mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-09 08:14:58 +01:00
reduce verbosity of -D mackie in the presence of continued handshaking/keepalive messages.
This commit is contained in:
parent
45119f5422
commit
4717080aee
2 changed files with 14 additions and 5 deletions
|
|
@ -1630,7 +1630,7 @@ MackieControlProtocol::midi_input_handler (IOCondition ioc, MIDI::Port* port)
|
||||||
|
|
||||||
if (ioc & IO_IN) {
|
if (ioc & IO_IN) {
|
||||||
|
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("something happend on %1\n", port->name()));
|
// DEBUG_TRACE (DEBUG::MackieControl, string_compose ("something happend on %1\n", port->name()));
|
||||||
|
|
||||||
/* Devices using regular JACK MIDI ports will need to have
|
/* Devices using regular JACK MIDI ports will need to have
|
||||||
the x-thread FIFO drained to avoid burning endless CPU.
|
the x-thread FIFO drained to avoid burning endless CPU.
|
||||||
|
|
@ -1647,7 +1647,7 @@ MackieControlProtocol::midi_input_handler (IOCondition ioc, MIDI::Port* port)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("data available on %1\n", port->name()));
|
// DEBUG_TRACE (DEBUG::MackieControl, string_compose ("data available on %1\n", port->name()));
|
||||||
framepos_t now = session->engine().sample_time();
|
framepos_t now = session->engine().sample_time();
|
||||||
port->parse (now);
|
port->parse (now);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -675,8 +675,6 @@ Surface::handle_midi_sysex (MIDI::Parser &, MIDI::byte * raw_bytes, size_t count
|
||||||
{
|
{
|
||||||
MidiByteArray bytes (count, raw_bytes);
|
MidiByteArray bytes (count, raw_bytes);
|
||||||
|
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("handle_midi_sysex: %1\n", bytes));
|
|
||||||
|
|
||||||
if (_mcp.device_info().no_handshake()) {
|
if (_mcp.device_info().no_handshake()) {
|
||||||
turn_it_on ();
|
turn_it_on ();
|
||||||
}
|
}
|
||||||
|
|
@ -693,6 +691,9 @@ Surface::handle_midi_sysex (MIDI::Parser &, MIDI::byte * raw_bytes, size_t count
|
||||||
|
|
||||||
switch (bytes[5]) {
|
switch (bytes[5]) {
|
||||||
case 0x01:
|
case 0x01:
|
||||||
|
if (!_active) {
|
||||||
|
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("handle_midi_sysex: %1\n", bytes));
|
||||||
|
}
|
||||||
/* MCP: Device Ready
|
/* MCP: Device Ready
|
||||||
LCP: Connection Challenge
|
LCP: Connection Challenge
|
||||||
*/
|
*/
|
||||||
|
|
@ -700,12 +701,17 @@ Surface::handle_midi_sysex (MIDI::Parser &, MIDI::byte * raw_bytes, size_t count
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, "Logic Control Device connection challenge\n");
|
DEBUG_TRACE (DEBUG::MackieControl, "Logic Control Device connection challenge\n");
|
||||||
write_sysex (host_connection_query (bytes));
|
write_sysex (host_connection_query (bytes));
|
||||||
} else {
|
} else {
|
||||||
|
if (!_active) {
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("Mackie Control Device ready, current status = %1\n", _active));
|
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("Mackie Control Device ready, current status = %1\n", _active));
|
||||||
|
}
|
||||||
turn_it_on ();
|
turn_it_on ();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x06:
|
case 0x06:
|
||||||
|
if (!_active) {
|
||||||
|
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("handle_midi_sysex: %1\n", bytes));
|
||||||
|
}
|
||||||
/* Behringer X-Touch Compact: Device Ready
|
/* Behringer X-Touch Compact: Device Ready
|
||||||
*/
|
*/
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("Behringer X-Touch Compact ready, current status = %1\n", _active));
|
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("Behringer X-Touch Compact ready, current status = %1\n", _active));
|
||||||
|
|
@ -713,6 +719,7 @@ Surface::handle_midi_sysex (MIDI::Parser &, MIDI::byte * raw_bytes, size_t count
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x03: /* LCP Connection Confirmation */
|
case 0x03: /* LCP Connection Confirmation */
|
||||||
|
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("handle_midi_sysex: %1\n", bytes));
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, "Logic Control Device confirms connection, ardour replies\n");
|
DEBUG_TRACE (DEBUG::MackieControl, "Logic Control Device confirms connection, ardour replies\n");
|
||||||
if (bytes[4] == 0x10 || bytes[4] == 0x11) {
|
if (bytes[4] == 0x10 || bytes[4] == 0x11) {
|
||||||
write_sysex (host_connection_confirmation (bytes));
|
write_sysex (host_connection_confirmation (bytes));
|
||||||
|
|
@ -721,11 +728,13 @@ Surface::handle_midi_sysex (MIDI::Parser &, MIDI::byte * raw_bytes, size_t count
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 0x04: /* LCP: Confirmation Denied */
|
case 0x04: /* LCP: Confirmation Denied */
|
||||||
|
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("handle_midi_sysex: %1\n", bytes));
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, "Logic Control Device denies connection\n");
|
DEBUG_TRACE (DEBUG::MackieControl, "Logic Control Device denies connection\n");
|
||||||
_active = false;
|
_active = false;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("handle_midi_sysex: %1\n", bytes));
|
||||||
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("unknown device ID byte %1", (int) bytes[5]));
|
DEBUG_TRACE (DEBUG::MackieControl, string_compose ("unknown device ID byte %1", (int) bytes[5]));
|
||||||
error << "MCP: unknown sysex: " << bytes << endmsg;
|
error << "MCP: unknown sysex: " << bytes << endmsg;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue