WizziLab's serial protocol library

Dependents:   modem_ref_helper_for_v5_3_217 modem_ref_helper

Revision:
6:ed1ba668b6ef
Parent:
5:a06d239f3b3e
Child:
7:45fe755f52bc
--- a/WizziCom.cpp	Wed Sep 20 14:40:41 2017 +0000
+++ b/WizziCom.cpp	Wed Jul 31 16:48:55 2019 +0000
@@ -352,7 +352,7 @@
     if (_irq_out)
     {
         *(_irq_out) = 1;
-        Thread::wait(3);
+        ThisThread::sleep_for(3);
     }
     
     for (uint32_t i=0 ; i<len ; i++)
@@ -363,7 +363,7 @@
     if (_irq_out)
     {
         // Important to not release the ressource too soon
-        Thread::wait(2);   
+        ThisThread::sleep_for(2);   
         *(_irq_out) = 0;
     }
 }
@@ -423,7 +423,7 @@
         case WizziComPacketSysXon:
             FREE(packet);
             COM_DPRINT("XON\r\n");
-            _tx_thread.signal_set(XON_SIGNAL);
+            _tx_thread.flags_set(XON_SIGNAL);
             break;
         case WizziComPacketSysXoff:
             FREE(packet);
@@ -590,7 +590,7 @@
     while (true)
     {
         // wait for data available
-        _data_parsing.wait();
+        _data_parsing.try_acquire();
         
         if (_state == PARSE_HEADER)
         {