Add assertion

This commit is contained in:
Uwe Seimet 2023-11-02 10:06:52 +01:00
parent aa4b4ee102
commit d5998c4254

View File

@ -38,11 +38,10 @@ bool GPIOBUS::Init(mode_e mode)
//---------------------------------------------------------------------------
int GPIOBUS::CommandHandShake(vector<uint8_t> &buf)
{
GPIO_FUNCTION_TRACE
// Only works in TARGET mode
if (actmode != mode_e::TARGET) {
return 0;
}
assert(actmode == mode_e::TARGET);
GPIO_FUNCTION_TRACE
DisableIRQ();