diff --git a/libraries/net/VodafoneUSBModem/core/MtxCircBuffer.h b/libraries/net/VodafoneUSBModem/core/MtxCircBuffer.h index 1623de3647..8b86304719 100644 --- a/libraries/net/VodafoneUSBModem/core/MtxCircBuffer.h +++ b/libraries/net/VodafoneUSBModem/core/MtxCircBuffer.h @@ -55,19 +55,13 @@ public: void queue(T k) { mtx.lock(); - while (((write + 1) % size) == read) //if (isFull()) - { - /*while((((write + 1) % size) == read)) - {*/ - mtx.unlock(); - Thread::wait(10); - mtx.lock(); - /*}*/ - //read++; - //read %= size; - } buf[write++] = k; write %= size; + if (isFull()) + { + read++; + read %= size; + } mtx.unlock(); } diff --git a/workspace_tools/debugger/pyOCD/target/cortex_m.py b/workspace_tools/debugger/pyOCD/target/cortex_m.py index 8cdd9311be..f612e0f67d 100644 --- a/workspace_tools/debugger/pyOCD/target/cortex_m.py +++ b/workspace_tools/debugger/pyOCD/target/cortex_m.py @@ -167,7 +167,7 @@ class CortexM(Target): while True: r = self.transport.readDP(DP_REG['CTRL_STAT']) - if (r & (CDBGPWRUPACK | CSYSPWRUPACK)) != (CSYSPWRUPREQ | CDBGPWRUPREQ): + if (r & (CDBGPWRUPACK | CSYSPWRUPACK)) != (CDBGPWRUPACK | CSYSPWRUPACK): break self.transport.writeDP(DP_REG['CTRL_STAT'], CSYSPWRUPREQ | CDBGPWRUPREQ | TRNNORMAL | MASKLANE) diff --git a/workspace_tools/debugger/setup.py b/workspace_tools/debugger/setup.py index 06e0e5ee06..f61df3abaf 100644 --- a/workspace_tools/debugger/setup.py +++ b/workspace_tools/debugger/setup.py @@ -23,7 +23,7 @@ setup( description="CMSIS-DAP debugger for python", author="samux", author_email="samuel.mokrani@gmail.com", - license="MIT", + license="Apache 2.0", classifiers = [ "Development Status :: 4 - Beta", "License :: Apache 2.0",