a.binder преди 5 години
родител
ревизия
c3bb27781f

+ 44 - 26
SE/stuff/P5_Automation_can-dev/P5_Automation_can-dev.ino

@@ -88,7 +88,7 @@
 //#define Active_ControllerID _Slave1_ID 
  
 #include "Slave_Ports_Status.h"
-    Slave_Ports_Status  Slave_Ports_Status_C;
+#include "Slave_Ports_QUEUE.h"  
     
 #include "_Slave_Ports_queue_task_type_LIST.h"
 #include "_Slave_Ports_Protocol.h"
@@ -190,15 +190,20 @@ MCP_CAN CAN0(CAN_CSpin);                          // Set CS to pin 10
 void setup() {
 
  Serial.begin(115200);
+ 
+   Slave_Ports_Status  Slave_Ports_Status_C;
+   Slave_Ports_QUEUE Slave_Ports_QUEUE_C;
+ 
  #include "_Slave_Ports_LOCAL_LIST.h"
   #if defined(HAS_LCD1602)
     lcd.begin(16, 2);
   #endif
- Slave_Ports_Status_T _add[] = { 1, Active_ControllerID, 0x01, 0x00, 1, 0x01, 0x01, 0x01 };
+ //Slave_Ports_Status_T _add[] = { 1, Active_ControllerID, 0x01, 0x00, 1, 0x01, 0x01, 0x01 };
  
 
-
-/*Slave_Ports_Status_C.add_port(
+     Serial.println("#200 adding ports");
+     
+Slave_Ports_Status_C.add_port(
              1, // int  Port_ID,
             Active_ControllerID,  //  int  _Slave_ID,
                 0x01, //  int  PortTypes,
@@ -208,13 +213,16 @@ void setup() {
                        0x01, // int  Exp_state_ttl,
                        0x01, //  int  Broadcast_state,
                        0x01, // int I2C_port,
-                      _NOT_USED_ ); //  int I2C_driver
-*/
-Slave_Ports_Status_C.add_port( 2, Active_ControllerID, 0x01, 0x00, 1, 0x01, 0x01, 0x01, 0x01, _NOT_USED_); // Slave_Ports_Status_C.I2C_driver_F(Adafruit_PWMServoDriver)
+                      I2C_driver_NOT_USED_ ); //  int I2C_driver
+
+Slave_Ports_Status_C.add_port( 2, Active_ControllerID, 0x01, 0x00, 1, 0x01, 0x01, 0x01, 0x01, I2C_driver_NOT_USED_); // Slave_Ports_Status_C.I2C_driver_F(Adafruit_PWMServoDriver)
+
+Slave_Ports_Status_C.add_port( 3, Active_ControllerID, 0x01, 0x00, 1, 0x01, 0x01, 0x01, 0x01, I2C_driver_Adafruit_PWMServoDriver ); // Slave_Ports_Status_C.I2C_driver_F(Adafruit_PWMServoDriver)
+
+Slave_Ports_Status_C.add_port( 4, _Slave1_ID, 0x01, 0x00, 1, 0x01, 0x01, 0x01, 0x01, I2C_driver_Adafruit_PWMServoDriver ); // Slave_Ports_Status_C.I2C_driver_F(Adafruit_PWMServoDriver)
+
 
-Slave_Ports_Status_C.add_port( 3, Active_ControllerID, 0x01, 0x00, 1, 0x01, 0x01, 0x01, 0x01, Adafruit_PWMServoDriver ); // Slave_Ports_Status_C.I2C_driver_F(Adafruit_PWMServoDriver)
 
-//Slave_Ports_Status_C.add_port( 4, _Slave1_ID, 0x01, 0x00, 1, 0x01, 0x01, 0x01, 0x01, Adafruit_PWMServoDriver ); // Slave_Ports_Status_C.I2C_driver_F(Adafruit_PWMServoDriver)
 
 
 
@@ -290,9 +298,10 @@ delay(1000);
  
   //if(CAN0.begin(MCP_STDEXT, CAN_500KBPS, MCP_16MHZ) == CAN_OK) {
   if(CAN0.begin(MCP_ANY, CAN_500KBPS, MCP_16MHZ) == CAN_OK) {
-     LCDarray1="MCP2515 Init Okay";
-     LCDarray2="500KBPS 16MHZ";
-   Serial.print(LCDarray1 + LCDarray2);
+     //LCDarray1="MCP2515 Init Okay";
+     //LCDarray2="500KBPS 16MHZ";
+    Serial.println("#303 MCP2515 Init Okay");
+    /*
     #if defined(HAS_LCD1602)
       LCD_print(LCDarray1, LCDarray2, LCDtim/5);
     #endif
@@ -302,13 +311,16 @@ delay(1000);
       display.print("MCP2515 Init Okay!!\r\n");
       delay(LCDtim); 
     #endif
+    */
   } else { 
-     LCDarray1 = "MCP2515 Init Failed";
+     /* LCDarray1 = "MCP2515 Init Failed";
      LCDarray2 = "CAN_CSpin: "; 
      LCDarray2.concat(CAN_CSpin);  
      LCDarray2.concat("CAN_INTpin: ");
      LCDarray2.concat(CAN_INTpin);    
-    Serial.print(LCDarray1);
+     */
+    Serial.println("#322 MCP2515 Init Failed");
+      /*
       #if defined(HAS_LCD1602)
           LCD_print(LCDarray1, LCDarray2, LCDtim / 2 ) ;
       #endif
@@ -321,9 +333,10 @@ delay(1000);
          display.print(LCDarray2);
          delay(LCDtim); 
       #endif
+      */
   }
 
-
+        /*AAA
        #if Active_ControllerID == _Slave1_ID 
         #include "_SlaveID_setup.h"
        #elif Active_ControllerID == _ControllerID
@@ -343,28 +356,35 @@ delay(1000);
 
           delay(LCDtim); 
          #endif
+         */
         CAN0.setMode(MCP_NORMAL);                // Change to normal mode to allow messages to be transmitted
         pinMode(CAN_INTpin, INPUT);                       // Setting pin 2 for /INT input
-
+       Serial.println("#362 set MCP_NORMAL");
   //EOF CAN
-   #if defined(HAS_LCD1602) 
+  
+    /*AA
+    #if defined(HAS_LCD1602) 
       LCDarray1 = "#323 loop.... ";
       //LCDarray2 = "....";
      LCD_print1(LCDarray1, LCDtim/10);
      
     #endif
-
-
+    */
+    
 //_Slave_Ports_queue.push(_LCD_print_queue.peek() + 1);
  Serial.println("#298 _Slave_Ports_queue__list");
- _Slave_Ports_queue__INIT(_Slave_Ports_queue_tasks_LIST);
-_Slave_Ports_queue__list(_Slave_Ports_queue_tasks_LIST);
-  int _Slave_Ports_queue_peek =  _Slave_Ports_queue.peek() ;
+ //AA _Slave_Ports_queue__INIT(_Slave_Ports_queue_tasks_LIST);
+//AA _Slave_Ports_queue__list(_Slave_Ports_queue_tasks_LIST);
+//AA  int _Slave_Ports_queue_peek =  _Slave_Ports_queue.peek() ;
 //  int _Slave_Ports_queue_push = _Slave_Ports_queue.push(_Slave_Ports_queue.peek() + 1) ; 
   //int _Slave_Ports_queue_peek_new = _Slave_Ports_queue.peek() ; _Slave_Ports_queue__add(  *_Slave_Ports_queue_tasks_LIST, 0x01 ,0x00 ,100, 5000 ) ;  // _Slave_Ports_queue_peek, _Slave_Ports_queue.push(_Slave_Ports_queue.peek() + 1), _Slave_Ports_queue.peek());
 //void _Slave_Ports_queue__add( _Slave_Ports_queue_tasksT* _Slave_Ports_queue_tasks_LIST,int _Slave_Ports_queue_task_type,int _Slave_Port_link,long time_seq_id, long time_min_run //, 
-_Slave_Ports_queue__add(     _Slave_Ports_queue_tasks_LIST,  int(0x04) ,0x00 ,100, 5000 ) ;  //        "_Slave_Ports_broadcast", //4
-_Slave_Ports_queue__add(  _Slave_Ports_queue_tasks_LIST, 0x05 ,0x00 ,100, 5000 ) ;  //"_Slave_Ports_set_I2C" //5  - to set ports associated on PW
+//A_Slave_Ports_queue__add(     _Slave_Ports_queue_tasks_LIST,  int(0x04) ,0x00 ,100, 5000 ) ;  //        "_Slave_Ports_broadcast", //4
+int Slave_Ports_QUEUE_C_queue_id_current_broadcast = Slave_Ports_QUEUE_C.queue__add( TASK_TYPE_T_Slave_Ports_broadcast____,100, 5000 ) ;  //        "_Slave_Ports_broadcast", //4
+//_Slave_Ports_queue__add(  _Slave_Ports_queue_tasks_LIST, 0x05 ,0x00 ,100, 5000 ) ;  //"_Slave_Ports_set_I2C" //5  - to set ports associated on PW
+int Slave_Ports_QUEUE_C_queue_id_current_set_I2C = Slave_Ports_QUEUE_C.queue__add( TASK_TYPE_T_Slave_Ports_set_I2C______,100, 5000 ) ;  //        "_Slave_Ports_broadcast", //4
+
+delay(10000);
 
  //  _Slave_Ports_queue_peek =  _Slave_Ports_queue.peek() ; 
    //_Slave_Ports_queue_push =  _Slave_Ports_queue.push(_Slave_Ports_queue.peek() + 1) ;  
@@ -441,5 +461,3 @@ void loop() {
 
 
 
-#include "_PCINT_func.h"
-#include "_Slave_Ports_func.h"

+ 2 - 0
SE/stuff/P5_Automation_can-dev/P5_Automation_can-dev.xpr

@@ -8,6 +8,8 @@
         <folder name="Arduino">
             <folder path="../../../../Arduino/"/>
         </folder>
+        <folder path="../P5_Automation_can-dev-2/"/>
+        <folder path="../P5_Automation_can-dev-3/"/>
         <folder path="."/>
     </projectTree>
 </project>

+ 53 - 56
SE/stuff/P5_Automation_can-dev/Slave_Ports_Status.cpp

@@ -33,8 +33,10 @@ void Slave_Ports_Status::push() { //
 Slave_Ports_Status::Slave_Ports_Status(){
     Serial.print("#35 Slave_Ports_Status::Slave_Ports_Status():");
     _count = 0 ;
-    Slave_Ports_Status_T Slave_Ports_Status_A[10];
-    
+   Slave_Ports_Status_T Slave_Ports_Status_A[10];
+   // Slave_Ports_Status_QUEUE_T Slave_Ports_Status_QUEUE_A[10] ;
+    //_queue_id_current = 0 ;
+    //_queue_count = 0;
 }
 
 
@@ -59,36 +61,29 @@ inline int Slave_Ports_Status::add(Slave_Ports_Status_T item)
 }
 */
 
- bool Slave_Ports_Status::I2C_driver_F(I2C_driver_T  I2C_driver_A) {
-    
-    
- //    Serial.print("I2C_driver_A: [");
- //    Serial.print(I2C_driver_A.CNF1);
- //    Serial.println("] "); 
-     return I2C_driver_A.CNF1 ;
- }
- 
 
-  char* Slave_Ports_Status::I2C_driver_FS(int  I2C_driver) {
+ 
+/*
+  void Slave_Ports_Status::I2C_driver_FS(int  I2C_driver) { //char*
   
    
     // Serial.print("I2C_driver_FS[");
      //Serial.print(I2C_driver_F(_NOT_USED_));
-     if(I2C_driver_F(_NOT_USED_) == I2C_driver) {
+     if(I2C_driver_NOT_USED_  == I2C_driver) {
        Serial.println("_NOT_USED_");
                        
       // I2C_driver_FT =  "_NOT_USED______________";
-       return  "_NOT_USED______________";
+       //return  "_NOT_USED______________";
      }
-       else if(I2C_driver_F(Adafruit_PWMServoDriver)==I2C_driver) {
+       else if( I2C_driver_Adafruit_PWMServoDriver == I2C_driver) {
        Serial.println("Adafruit_PWMServoDriver");
                        //12345678901234567890134
      //   I2C_driver_FT = "Adafruit_PWMServoDriver";
-       return  "Adafruit_PWMServoDriver";
+      // return  "Adafruit_PWMServoDriver";
      } else {
         Serial.print("_UNKNOWN_");
        //  I2C_driver_FT = "_UNKNOWN_______________";
-        return  "_UNKNOWN_______________";
+      //  return  "_UNKNOWN_______________";
      }
    
      
@@ -96,7 +91,7 @@ inline int Slave_Ports_Status::add(Slave_Ports_Status_T item)
  // return I2C_driver_FT;
  }
  
-
+*/
 
 
  void Slave_Ports_Status::add_port(
@@ -110,22 +105,22 @@ inline int Slave_Ports_Status::add(Slave_Ports_Status_T item)
                 int  Broadcast_state,
                 int I2C_port,
                 //int I2C_driver
-                I2C_driver_T I2C_driver
+                int I2C_driver
                 )
 {
   
   Serial.print("add_port   _count["); Serial.print(_count);
    Serial.print("]  _count + 1["); Serial.print(_count + 1);
    Serial.print("] Port_ID["); Serial.print(Port_ID);
-   Serial.print("] _Slave_ID[0x"); Serial.print( _Slave_ID, HEX );
-   Serial.print("] PortTypes["); Serial.print(PortTypes, HEX);
-   Serial.print("] Address["); Serial.print(Address, HEX);
-   Serial.print("] LocalPort["); Serial.print(LocalPort, HEX);
-   Serial.print("] Exp_state["); Serial.print(Exp_state, HEX);
-   Serial.print("] Exp_state_ttl["); Serial.print(Exp_state_ttl, HEX);
-   Serial.print("] Broadcast_state["); Serial.print(Broadcast_state, HEX);
-   Serial.print("] I2C_port["); Serial.print(I2C_port, HEX);
-   Serial.print("] I2C_driver["); Serial.print(I2C_driver_F(I2C_driver));
+   Serial.print("] _Slave_ID[0x"); Serial.print( _Slave_ID);
+   Serial.print("] PortTypes["); Serial.print(PortTypes);
+   Serial.print("] Address["); Serial.print(Address);
+   Serial.print("] LocalPort["); Serial.print(LocalPort);
+   Serial.print("] Exp_state["); Serial.print(Exp_state);
+//   Serial.print("] Exp_state_ttl["); Serial.print(Exp_state_ttl);
+//   Serial.print("] Broadcast_state["); Serial.print(Broadcast_state);
+//   Serial.print("] I2C_port["); Serial.print(I2C_port);
+ //  Serial.print("] I2C_driver["); I2C_driver_FS(I2C_driver);
    //Serial.print("] I2C_driver_Rev["); 
       //unsigned char LCDarray1buf[24];
       //LCDarray1.toCharArray(LCDarray1buf, 24);
@@ -135,19 +130,19 @@ inline int Slave_Ports_Status::add(Slave_Ports_Status_T item)
     
     if(_count == 0) {
     
-     Slave_Ports_Status_A[_count ].Port_ID=0x00;
-     Slave_Ports_Status_A[_count ]._Slave_ID=0x00;
-     Slave_Ports_Status_A[_count ].PortTypes=0x00;
-     Slave_Ports_Status_A[_count ].Address=0x00;
-     Slave_Ports_Status_A[_count ].LocalPort=0x00;
-     Slave_Ports_Status_A[_count ].Exp_state=0x00;
-     Slave_Ports_Status_A[_count ].Exp_state_ttl=0x00;
-     Slave_Ports_Status_A[_count ].Broadcast_state=0x00;
-     Slave_Ports_Status_A[_count ].I2C_port=0x00;
-     Slave_Ports_Status_A[_count ].I2C_driver=0x00;
+     this->Slave_Ports_Status_A[_count ].Port_ID=0x00;
+     this->Slave_Ports_Status_A[_count ]._Slave_ID=0x00;
+     this->Slave_Ports_Status_A[_count ].PortTypes=0x00;
+     this->Slave_Ports_Status_A[_count ].Address=0x00;
+     this->Slave_Ports_Status_A[_count ].LocalPort=0x00;
+     this->Slave_Ports_Status_A[_count ].Exp_state=0x00;
+     this->Slave_Ports_Status_A[_count ].Exp_state_ttl=0x00;
+     this->Slave_Ports_Status_A[_count ].Broadcast_state=0x00;
+     this->Slave_Ports_Status_A[_count ].I2C_port=0x00;
+     this->Slave_Ports_Status_A[_count ].I2C_driver=0x00;
      //_count ++;
      
-     _count ++;
+     this->_count ++;
     /* Slave_Ports_Status::add_port(
                   Port_ID,
                   _Slave_ID,
@@ -163,18 +158,18 @@ inline int Slave_Ports_Status::add(Slave_Ports_Status_T item)
      */
     }
     
-    Slave_Ports_Status_A[_count + 1].Port_ID = Port_ID ;
-    Slave_Ports_Status_A[_count + 1]._Slave_ID = _Slave_ID ;
-    Slave_Ports_Status_A[_count + 1].PortTypes = PortTypes ;
-    Slave_Ports_Status_A[_count + 1].Address = Address ;
-    Slave_Ports_Status_A[_count + 1].LocalPort = LocalPort ;
-    Slave_Ports_Status_A[_count + 1].Exp_state = Exp_state ;
-    Slave_Ports_Status_A[_count + 1].Exp_state_ttl = Exp_state_ttl ;
-    Slave_Ports_Status_A[_count + 1].Broadcast_state = Broadcast_state ;
-    Slave_Ports_Status_A[_count + 1].I2C_port = I2C_port ;
-//    Slave_Ports_Status_A[_count + 1].I2C_driver = I2C_driver ;
-    Slave_Ports_Status_A[_count + 1].I2C_driver = I2C_driver_F(I2C_driver) ;
-    _count ++;
+    this->Slave_Ports_Status_A[_count + 1].Port_ID = Port_ID ;
+    this->Slave_Ports_Status_A[_count + 1]._Slave_ID = _Slave_ID ;
+    this->Slave_Ports_Status_A[_count + 1].PortTypes = PortTypes ;
+    this->Slave_Ports_Status_A[_count + 1].Address = Address ;
+    this->Slave_Ports_Status_A[_count + 1].LocalPort = LocalPort ;
+    this->Slave_Ports_Status_A[_count + 1].Exp_state = Exp_state ;
+    this->Slave_Ports_Status_A[_count + 1].Exp_state_ttl = Exp_state_ttl ;
+    this->Slave_Ports_Status_A[_count + 1].Broadcast_state = Broadcast_state ;
+    this->Slave_Ports_Status_A[_count + 1].I2C_port = I2C_port ;
+    this->Slave_Ports_Status_A[_count + 1].I2C_driver = I2C_driver ;
+//    Slave_Ports_Status_A[_count + 1].I2C_driver = I2C_driver_F(I2C_driver) ;
+    this->_count ++;
   
 }
 
@@ -202,9 +197,10 @@ void Slave_Ports_Status::list_ports()
         Serial.print("] Exp_state_ttl["); Serial.print(Slave_Ports_Status_A[i].Exp_state_ttl, HEX);
          Serial.print("] Broadcast_state["); Serial.print(Slave_Ports_Status_A[i].Broadcast_state, HEX);
          Serial.print("] I2C_port["); Serial.print(Slave_Ports_Status_A[i].I2C_port, HEX);
-         Serial.print("] I2C_driver[");//  Serial.print(Slave_Ports_Status_A[i].I2C_driver, HEX);
-           I2C_driver_FT[24]  = I2C_driver_FS(Slave_Ports_Status_A[i].I2C_driver);
-            Serial.print(I2C_driver_FT[24]);
+      //   Serial.print("] I2C_driver[");   Serial.print(Slave_Ports_Status_A[i].I2C_driver.CNF1);
+         
+          // I2C_driver_FT[24]  = I2C_driver_FS(Slave_Ports_Status_A[i].I2C_driver);
+          //  Serial.print(I2C_driver_FT[24]);
          Serial.println("]"); 
          
          
@@ -213,7 +209,7 @@ void Slave_Ports_Status::list_ports()
    
 }
 
-
+/*
 
 Slave_Ports_Status_S Slave_Ports_Status::get_port(int  Port_ID)
 {
@@ -227,7 +223,7 @@ Slave_Ports_Status_S Slave_Ports_Status::get_port(int  Port_ID)
 }
 
 
-
+*/
 
 Slave_Ports_Status::~Slave_Ports_Status(){
      delete[] Slave_Ports_Status_A;
@@ -246,3 +242,4 @@ int Slave_Ports_Status::get_count()
  byte Slave_Ports_Status::_Slave_Ports_Protocol_CAN_broadcast_F() {
 }
 */
+

+ 38 - 35
SE/stuff/P5_Automation_can-dev/Slave_Ports_Status.h

@@ -3,6 +3,14 @@
 #define SLAVE_PORTS_STATUS_H
 
 
+
+
+
+ #define    I2C_driver_NOT_USED_  0x00
+ #define    I2C_driver_Adafruit_PWMServoDriver    0x01
+
+
+
 #include <Arduino.h>
 
 
@@ -108,6 +116,14 @@ enum class Mode : uint8_t
 
 
 
+
+
+#include "Slave_Ports_Status_QUEUE.h"
+
+
+
+
+
 class Slave_Ports_Status
 {
 
@@ -121,8 +137,16 @@ private:
   //  static Slave_Ports_Status *first;
     //static Slave_Ports_Status *_data;
 public:
-        Slave_Ports_Status_T *Slave_Ports_Status_A;
         int _count;
+        
+        
+         //   int _queue_id_current  ;
+         //   int _queue_count ;
+            
+            
+         Slave_Ports_Status_T *Slave_Ports_Status_A;
+         //Slave_Ports_Status_QUEUE_T *Slave_Ports_Status_QUEUE_A ;
+       
        
         //  void push(Slave_Ports_Status_S const &item);
           //void push();
@@ -131,6 +155,9 @@ public:
           //voidfuncptr_t func;					// address of coroutine function
           Slave_Ports_Status();
           
+          
+         
+          
          /* inline int add(
             Slave_Ports_Status_LIST_T Slave_Ports_Status_LIST_A , 
             Slave_Ports_Status_T Slave_Ports_Status_A
@@ -147,51 +174,27 @@ public:
                 int  Exp_state_ttl,
                 int  Broadcast_state,
                 int I2C_port,
-                //int I2C_driver
-                I2C_driver_T I2C_driver
+                int I2C_driver
+                //I2C_driver_T I2C_driver
                 );
           bool add_empty();
           void print_ports();
           void list_ports();
-          Slave_Ports_Status_S get_port(int Port_ID);
+        //  Slave_Ports_Status_S get_port(int Port_ID);
         //  int get_count();
            
-            bool I2C_driver_F(I2C_driver_T  I2C_driver_A);
-           char* I2C_driver_FS(int  I2C_driver) ;
+           
+          // void I2C_driver_FS(int  I2C_driver) ;//char*
            
            // byte _Slave_Ports_Protocol_CAN_broadcast_F();
            
           ~Slave_Ports_Status();
-};
-
+                    
+          
+       //   int queue__add_A(Slave_Ports_Status_QUEUE_T QUEUE_A);
+       //   int queue__add(TASK_TYPE_T, long int, long int);
 
-/*
-class Slave_Ports_Status  {
-     private:
-    int _front, _back, _count;
-    T *_data;
-    int _maxitems;
-  public:
-    Queue(int maxitems = 256) { 
-      _front = 0;
-      _back = 0;
-      _count = 0;
-      _maxitems = maxitems;
-      _data = new T[maxitems + 1];   
-    }
-    ~Queue() {
-      delete[] _data;  
-    }
-    inline int count();
-    inline int front();
-    inline int back();
- //   void push(const T &item);
- //   T peek();
- //   T pop();
- //   void clear();
- //   T pop_item(const T &item);
-}        
+};
 
-*/
 
 #endif

+ 11 - 0
SE/stuff/P5_Automation_can-dev/TFT_ILI9163C..h

@@ -20,3 +20,14 @@
 
  // TFT_ILI9163C display = TFT_ILI9163C(TFT_ILI9163C_CSpin, TFT_ILI9163C_DCpin, TFT_ILI9163C__RSTpin);
  // float p = 3.1415926;
+
+  
+  TFT_ILI9163C display = TFT_ILI9163C(TFT_ILI9163C_CSpin, TFT_ILI9163C_DCpin, TFT_ILI9163C__RSTpin);
+  float p = 3.1415926;
+     display.begin();
+     display.clearScreen();
+     display.setCursor(0,0);
+     display.print(LCDarray1);
+     display.setCursor(0,10);
+     display.print(LCDarray2);
+     delay(LCDtim); 

+ 1 - 1
SE/stuff/P5_Automation_can-dev/_Slave_Ports_LOCAL_LIST.h

@@ -1,5 +1,5 @@
 
-Slave_Ports_Status  Slave_Ports_Status_C;
+//Slave_Ports_Status  Slave_Ports_Status_C;
 
 
  #if ! defined(Active_ControllerID)