diff --git a/src/DebugToolDrivers/Protocols/CMSIS-DAP/VendorSpecific/EDBG/AVR/EdbgAvr8Interface.cpp b/src/DebugToolDrivers/Protocols/CMSIS-DAP/VendorSpecific/EDBG/AVR/EdbgAvr8Interface.cpp index 39d779a8..8c17c76f 100644 --- a/src/DebugToolDrivers/Protocols/CMSIS-DAP/VendorSpecific/EDBG/AVR/EdbgAvr8Interface.cpp +++ b/src/DebugToolDrivers/Protocols/CMSIS-DAP/VendorSpecific/EDBG/AVR/EdbgAvr8Interface.cpp @@ -266,8 +266,12 @@ namespace Bloom::DebugToolDrivers::Protocols::CmsisDap::Edbg::Avr this->activatePhysical(); } catch (const Avr8CommandFailure& activationException) { - if (this->targetConfig->physicalInterface == PhysicalInterface::DEBUG_WIRE - && activationException.code == Avr8CommandFailureCode::DEBUGWIRE_PHYSICAL_ERROR + if ( + this->targetConfig->physicalInterface == PhysicalInterface::DEBUG_WIRE + && ( + activationException.code == Avr8CommandFailureCode::DEBUGWIRE_PHYSICAL_ERROR + || activationException.code == Avr8CommandFailureCode::FAILED_TO_ENABLE_OCD + ) ) { throw DebugWirePhysicalInterfaceError( "Failed to activate the debugWire physical interface - check target connection. "