a.binder пре 5 година
родитељ
комит
2e43e569c2

+ 10 - 10
SE/stuff/P5_Automation_can-dev-res/P5_Automation_can-dev-res.ino

@@ -130,9 +130,9 @@
 
 #include "___template/__STORAGE_ARRAY_func.h" //testing
 
-#define  _ControllerID   0x101 
+#define  _ControllerID   0x11 
 
-#define  _Slave1_ID   0x103 
+#define  _Slave1_ID   0x13 
 
 
 
@@ -161,15 +161,15 @@
 
 #endif
 
-#if Active_ControllerID == 0x101 
+#if Active_ControllerID == 0x11 
     const int Active_ControllerID_HEX = 0x11 ;
-     #include "___CONFIG/0x101/config_Active_ControllerID_0x101.h"
+     #include "___CONFIG/0x11/config_Active_ControllerID_0x11.h"
 #endif
 
 
-#if Active_ControllerID == 0x103 
+#if Active_ControllerID == 0x13 
     const int Active_ControllerID_HEX = 0x13 ;
-    #include "___CONFIG/0x103/config_Active_ControllerID_0x103.h"  //there kleep config of this id device
+    #include "___CONFIG/0x13/config_Active_ControllerID_0x13.h"  //there kleep config of this id device
 #endif
 
 
@@ -343,13 +343,13 @@
 #include "___CONFIG/config_Slave_Ports_LOCAL_init.h"
 
 
-#if Active_ControllerID == 0x101 
-     #include "___CONFIG/0x101/config_Slave_Ports_LOCAL_0x101_init.h"
+#if Active_ControllerID == 0x11 
+     #include "___CONFIG/0x11/config_Slave_Ports_LOCAL_0x11_init.h"
 #endif
 
 
-#if Active_ControllerID == 0x103 
-    #include "___CONFIG/0x103/config_Slave_Ports_LOCAL_0x103_init.h"
+#if Active_ControllerID == 0x13 
+    #include "___CONFIG/0x13/config_Slave_Ports_LOCAL_0x13_init.h"
 #endif
 
 

+ 1 - 1
SE/stuff/P5_Automation_can-dev-res/_DISPLAY_func.h

@@ -389,7 +389,7 @@ void DISPLAY__print_menu(DISPLAY_T* DISPLAY_A ,
                                   if(DISPLAY_PHYSICAL_CHAR_A.DISPLAY_MENU_A[DISPLAY_MENU_ITEM_INDEX_A].DISPLAY_MENU_ITEM_A[i].DISPLAY_MENU_SELECTOR_STATUS_A & DISPLAY_MENU_SELECTOR_ITEM_OPTIONS_USE_LEVEL_FLAG) {
                                     DISPLAY_DEV.fillRect(  
                                     ( DISPLAY_PHYSICAL_CHAR_A.DISPLAY_MENU_A[DISPLAY_MENU_ITEM_INDEX_A].DISPLAY_MENU_ITEM_A[i].Exp_state_level_A / 3)
-                                    , maxYi ,  (( DISPLAY_PHYSICAL_CHAR_A.DISPLAY_MENU_A[DISPLAY_MENU_ITEM_INDEX_A].DISPLAY_MENU_ITEM_A[i].Exp_state_level_A / 3) + 30) //maxXi
+                                    , maxYi ,  (( DISPLAY_PHYSICAL_CHAR_A.DISPLAY_MENU_A[DISPLAY_MENU_ITEM_INDEX_A].DISPLAY_MENU_ITEM_A[i].Exp_state_level_A / 3) + 10) //maxXi
                                     ,  minYi, YELLOW );
                                   } else if(DISPLAY_PHYSICAL_CHAR_A.DISPLAY_MENU_A[DISPLAY_MENU_ITEM_INDEX_A].DISPLAY_MENU_ITEM_A[i].DISPLAY_MENU_SELECTOR_STATUS_A & DISPLAY_MENU_SELECTOR_ITEM_OPTIONS_FLAG) {
                                                 

+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x101/config_Active_ControllerID_0x101.h → SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x11/config_Active_ControllerID_0x11.h


+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x101/config_Slave_Ports_LOCAL_0x101_init.h → SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x11/config_Slave_Ports_LOCAL_0x11_init.h


+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x103/config_Active_ControllerID_0x103.h → SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x13/config_Active_ControllerID_0x13.h


+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x103/config_Slave_Ports_LOCAL_0x103_init.h → SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x13/config_Slave_Ports_LOCAL_0x13_init.h


+ 14 - 0
SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x14/config_Active_ControllerID_0x14.h

@@ -0,0 +1,14 @@
+
+//there kleep config of this id device
+#define HAS_TFT_ILI9163C 
+// #define HAS_LCD1602 
+//#define HAS_ROTTARY_SW
+//#define HAS__PCINT_setup //to allow interrupts
+
+#define HAS_I2C_driver_Adafruit_PWMServoDriver 
+
+
+//#define DEBUG 5 
+//#define DISABLE_LOOP //To debug and disable any output
+
+#define DISABLE_TASK_TYPE_T_DISPLAY_queue_pop________

+ 114 - 0
SE/stuff/P5_Automation_can-dev-res/___CONFIG/0x14/config_Slave_Ports_LOCAL_0x14_init.h

@@ -0,0 +1,114 @@
+
+ARDUINO_FUNCT_INIT_RESULT_T _Slave_Ports_LOCAL_init(
+                Slave_Ports_Status_T* Slave_Ports_Status_A ,
+                Slave_Ports_Status_T_ARDUINO_ATTR_ARRAY_T &Slave_Ports_Status_T_ARDUINO_ATTR_ARRAY_A ,
+                 Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_TABLE_T*            Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_TABLE_A,
+                 Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_T_TO_DELETE_T*      Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_T_TO_DELETE_A,
+                 Slave_Ports_Status_T_ARDUINO_ARRAY_ASSOC_TABLE_S_Port_ID_T*  Slave_Ports_Status_T_ARDUINO_ARRAY_ASSOC_TABLE_S_Port_ID_A,
+                
+                DISPLAY_T*  DISPLAY_A ,  DISPLAY_T_ARDUINO_ATTR_ARRAY_T &DISPLAY_T_ARDUINO_ATTR_ARRAY_A
+                //,*DISPLAY_PHYSICAL_CHAR_A //DISPLAY_PHYSICAL_CHAR_T 
+                ) {
+
+   //DISPLAY_T_ARDUINO_ATTR_ARRAY_A[ARDUINO_ATTR_ARRAY_S_INDEX].ARDUINO_ARRAY_INDEX_CURRENT_INIT ++;
+     #if defined(DEBUG) 
+                                  if(DEBUG > 6) {  
+                Serial.println("#4444 _Slave_Ports_LOCAL_init");
+                }
+     #endif
+      
+                  Slave_Ports_Status_add_port(
+                                Slave_Ports_Status_A ,
+                                Slave_Ports_Status_T_ARDUINO_ATTR_ARRAY_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_TABLE_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_T_TO_DELETE_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_ASSOC_TABLE_S_Port_ID_A,
+                                1,  // int  Port_ID,
+                                Active_ControllerID_HEX ,  //int  _Slave_ID,
+                                PortTypes_PWM_EXP_I2C, // PortTypes_SERVO , //int  PortTypes,
+                                0x40 ,  //int  Address,
+                                1 , //int  LocalPort,
+                                Exp_state_OFF, //int  Exp_state,
+                                Exp_state_ttl_TO_REFRESH, //int  Exp_state_ttl,
+                                Broadcast_state_TO_REFRESH, //int  Broadcast_state,
+                                I2C_port_DEFAULT, //int I2C_port,
+                                I2C_driver_Adafruit_PWMServoDriver ,//int I2C_driver
+                                IS_Local_TRUE 
+                                );
+                                
+                           /*     
+                  Slave_Ports_Status_add_port(
+                                Slave_Ports_Status_A ,
+                                Slave_Ports_Status_T_ARDUINO_ATTR_ARRAY_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_TABLE_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_T_TO_DELETE_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_ASSOC_TABLE_S_Port_ID_A,
+                                2,  // int  Port_ID,
+                                Active_ControllerID ,  //int  _Slave_ID,
+                                PortTypes_P2M_EXP_I2C , //int  PortTypes,
+                                0x40 ,  //int  Address,
+                                2 , //int  LocalPort,
+                                Exp_state_OFF, //int  Exp_state,
+                                Exp_state_ttl_TO_REFRESH, //int  Exp_state_ttl,
+                                Broadcast_state_TO_REFRESH, //int  Broadcast_state,
+                                I2C_port_DEFAULT, //int I2C_port,
+                                I2C_driver_Adafruit_PWMServoDriver ,//int I2C_driver
+                                IS_Local_TRUE 
+                                );
+                                
+                                 Slave_Ports_Status_add_port(
+                                Slave_Ports_Status_A ,
+                                Slave_Ports_Status_T_ARDUINO_ATTR_ARRAY_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_TABLE_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_INDEX_T_TO_DELETE_A,
+                                    Slave_Ports_Status_T_ARDUINO_ARRAY_ASSOC_TABLE_S_Port_ID_A,
+                                3,  // int  Port_ID,
+                                Active_ControllerID ,  //int  _Slave_ID,
+                                PortTypes_P2M_EXP_I2C , //int  PortTypes,
+                                0x40 ,  //int  Address,
+                                3 , //int  LocalPort,
+                                Exp_state_BLINK, //int  Exp_state,
+                                Exp_state_ttl_TO_REFRESH, //int  Exp_state_ttl,
+                                Broadcast_state_TO_REFRESH, //int  Broadcast_state,
+                                I2C_port_DEFAULT, //int I2C_port,
+                                I2C_driver_Adafruit_PWMServoDriver ,//int I2C_driver
+                                IS_Local_TRUE 
+                                );
+                                
+                                
+                                
+                           */     
+                    /*    DISPLAY__print_ANY(
+                    DISPLAY_T_ARDUINO_ATTR_ARRAY_A , 
+                    DISPLAY_PHYSICAL_CHAR_A,
+                    DISPLAY_pos_seq_A_NEXT,
+                    "#4 _Slave_Ports_LOCAL_init");             
+                 
+                 */
+                 
+                                              //1234567890123456
+                  // DISPLAY_array16_T DISPLAY_array16_AA ;
+                  //DISPLAY_array16_AA[16]= "#50 Added ports ";
+                 
+                  #if  defined(DISABLE_DISPLAY__add_record)
+               #else  
+                 DISPLAY__add_record(
+                       DISPLAY_A ,
+                      DISPLAY_T_ARDUINO_ATTR_ARRAY_A , 
+                      DISPLAY_PHYSICAL_CHAR_A, 
+                          DISPLAY_pos_seq_A_NEXT ,
+                         //"012345678901234" , //
+                         "#50 Added ports ",//DISPLAY_array16_A
+                          DISPLAY_TARGET_DISPLAY128,
+                          millis(), //time_seq_id_A,
+                           millis() + 5000 //time_min_run_A =
+                           //QUEUE
+                           , Slave_Ports_Status_QUEUE_A, Slave_Ports_Status_QUEUE_T_ARDUINO_ATTR_ARRAY_A ,
+                            TASK_TYPE_T__EMPTY__JUST_PASSED_ARG__,
+                            TASK_PORT_ASSOC_EMPTY
+                 );
+                #endif 
+                    
+    return true ;
+
+}

+ 0 - 11
SE/stuff/P5_Automation_can-dev-res/___CONFIG/config_Active_ControllerID_0x103.h

@@ -1,11 +0,0 @@
-
-//there kleep config of this id device#define HAS_TFT_ILI9163C 
-// #define HAS_LCD1602 
-//#define HAS_ROTTARY_SW
-
-#define HAS_I2C_driver_Adafruit_PWMServoDriver 
-
-
-#define DEBUG 5 
-#define DISABLE_LOOP //To debug and disable any output
-

+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x101/___DEBUG_DISABLE_INIT__0x101.h → SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x11/___DEBUG_DISABLE_INIT__0x11.h


+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x101/___DEBUG_DISABLE_LOOP__0x101.h → SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x11/___DEBUG_DISABLE_LOOP__0x11.h


+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x101/___DEBUG_DISABLE_SETUP__0x101.h → SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x11/___DEBUG_DISABLE_SETUP__0x11.h


+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x103/___DEBUG_DISABLE_INIT__0x103.h → SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x13/___DEBUG_DISABLE_INIT__0x13.h


+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x103/___DEBUG_DISABLE_LOOP__0x103.h → SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x13/___DEBUG_DISABLE_LOOP__0x13.h


+ 0 - 0
SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x103/___DEBUG_DISABLE_SETUP__0x103.h → SE/stuff/P5_Automation_can-dev-res/___DEBUG/0x13/___DEBUG_DISABLE_SETUP__0x13.h