diff --git a/ArduCopter/ArduCopter.pde b/ArduCopter/ArduCopter.pde index aa316b935d..c256eec258 100644 --- a/ArduCopter/ArduCopter.pde +++ b/ArduCopter/ArduCopter.pde @@ -905,11 +905,6 @@ static uint8_t save_trim_counter; // Reference to the AP relay object - APM1 only AP_Relay relay; -// APM2 only -//#if USB_MUX_PIN > 0 -//static bool usb_connected; -//#endif - #if CLI_ENABLED == ENABLED static int8_t setup_show (uint8_t argc, const Menu::arg *argv); #endif diff --git a/ArduCopter/GCS_Mavlink.pde b/ArduCopter/GCS_Mavlink.pde index 7976521f28..27d744b07c 100644 --- a/ArduCopter/GCS_Mavlink.pde +++ b/ArduCopter/GCS_Mavlink.pde @@ -471,7 +471,7 @@ static bool telemetry_delayed(mavlink_channel_t chan) return false; } #if USB_MUX_PIN > 0 - if (chan == MAVLINK_COMM_0 && usb_connected) { + if (chan == MAVLINK_COMM_0 && system.usb_connected) { // this is an APM2 with USB telemetry return false; }