EasyCAT LAB - EtherCAT master very simple example

Dependencies:   SOEM

  • This repository contains a very basic example for the EasyCAT LAB , a complete educational and experimental EtherCAT® system, composed of one master and two slaves.

Note

  • This example uses two LAB 2 slaves.

Note

  • In this example, to keep things as simple as possible, only two bytes of data are exchanged between the slaves and the TFT display is not used .
Revision:
1:971b4897a4c5
Parent:
0:bc829777f1ea
Child:
2:368e7d4d8171
--- a/main.cpp	Tue Jul 09 16:25:27 2019 +0000
+++ b/main.cpp	Fri May 07 10:19:40 2021 +0000
@@ -44,7 +44,7 @@
                                   
 #define SysMilliS() (uint32_t)Kernel::get_ms_count()                                      
 
-Serial pc(USBTX,USBRX,115200);          // set the debug serial line speed to 115200
+UnbufferedSerial pc(USBTX,USBRX,115200);          // set the debug serial line speed to 115200
 
 
 
@@ -285,7 +285,7 @@
     while(1)
     {           
         LED_RED = !LED_RED;
-        wait_ms(100);    
+        ThisThread::sleep_for(100ms);   
     }
 }