AB&T / EasyCAT_lib

Dependents:   TestEasyCAT_SM_sync TestEasyCAT_LoopBack TestEasyCAT_DC_sync TestEasyCAT

Files at this revision

API Documentation at this revision

Comitter:
EasyCAT
Date:
Sat Apr 10 14:49:17 2021 +0000
Parent:
2:e0fc1b098ce8
Commit message:
Updated for OS6 compatibility

Changed in this revision

EasyCAT.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/EasyCAT.cpp	Thu Mar 28 08:32:57 2019 +0000
+++ b/EasyCAT.cpp	Sat Apr 10 14:49:17 2021 +0000
@@ -111,7 +111,12 @@
   Spi.frequency(14000000);						          // SPI speed 14MHz  
   Spi.format(8,0);	  							          // 8 bit mode 0
   
-  wait_ms(100);
+  
+  #if (MBED_MAJOR_VERSION != 2)
+	ThisThread::sleep_for(100ms);
+  #else
+    wait_ms(100);        
+  #endif    
  
   SPIWriteRegisterDirect (RESET_CTL, DIGITAL_RST);        // LAN9252 reset