Browse Source

1、删除配置文件
2、删内网broker
3、解一个mqtt的bug

guohui 2 years ago
parent
commit
99cab2feca

+ 0 - 99
cust_data/cfg/cfg_anderson.h

@@ -1,99 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        1
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-//#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 111
cust_data/cfg/cfg_general.h

@@ -1,111 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_GENERAL
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 106
cust_data/cfg/cfg_hypertec.h

@@ -1,106 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-//#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 116
cust_data/cfg/cfg_inspur.h

@@ -1,116 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-//#define PRJ_GENERAL
-#define PRJ_INSPUR
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_GENERAL
-    #define SMTP_SEND_BUILTIN
-#endif
-
-#ifdef PRJ_INSPUR
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 118
cust_data/cfg/cfg_litech.h

@@ -1,118 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-#define PRJ_LITECH
-
-//#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_GENERAL
-    #define SMTP_SEND_BUILTIN
-#endif
-
-#ifdef PRJ_LITECH
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 106
cust_data/cfg/cfg_russia_itk.h

@@ -1,106 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-#define PRJ_RUSSIA_ITK
-//#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 114
cust_data/cfg/cfg_stsc.h

@@ -1,114 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-#define PRJ_STSC
-//#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-#ifdef PRJ_STSC
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 109
cust_data/cfg/cfg_test.h

@@ -1,109 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-//#define PRJ_GENERAL
-#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_MQTT
-    #define MQTT_SERVER_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 106
cust_data/cfg/cfg_usa_sl.h

@@ -1,106 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        1
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-//#define PRJ_XIAN_GOM037
-#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-//#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 108
cust_data/cfg/cfg_xian_p4.h

@@ -1,108 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-//#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-
-    #define IN_INDEX_MAP                {3,2,0,1}
-    
-    //#define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    #define GOM037PDU_GC20_04K_125H          //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

+ 0 - 108
cust_data/cfg/cfg_xian_p8.h

@@ -1,108 +0,0 @@
-#ifndef __CONFIG_Hx__
-#define __CONFIG_Hx__
-
-
-#define VERSION                         "V0.0.1"
-
-
-#define PROD_ID                         0
-#define PROD_TYPE                       1
-#define PROD_POWER_TYPE                 1
-
-
-#define LANGUAGE                        0
-#define SMPLE_TIME                      30          //ms
-#define SAVE_TIME                       60000       //ms
-#define CASCADE_CNT                     5
-
-#define MAX_CHN_COUNT                   16
-#define PHASE_GROUP_CNT                 8
-#define CHANNEL_DELAY_SEC               8
-
-#define USE_SMTP
-
-/////////////customer demannd//////////////////////
-#define PRJ_XIAN_GOM037
-//#define PRJ_USA_SL
-//#define PRJ_ANDERSON
-//#define PRJ_HYPERTEC
-//#define PRJ_RUSSIA_ITK
-//#define PRJ_GENERAL
-//#define PRJ_TEST
-
-
-#ifdef PRJ_TEST
-    #define SMTP_SEND_BUILTIN
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_XIAN_GOM037
-    #define SMTP_SEND_BUILTIN
-
-    #define IN_INDEX_MAP                {3,2,0,1}
-    
-    #define GOM037_PDU_GC10_08K_80H        //ac_in1_out1_40a_p8_5ch_nologo_cn
-    //#define GOM037PDU_GC20_04K_125H        //ac_in1_out1_40a_p4_5ch_nologo_cn
-  
-
-    #ifdef GOM037PDU_GC20_04K_125H
-        #undef CHANNEL_DELAY_SEC
-        #define CHANNEL_DELAY_SEC        5
-    #endif
-#endif
-
-#ifdef PRJ_USA_SL
-    #define SMTP_SEND_BUILTIN
-    
-    #define PDU_GC40_03K_125H           //ac_in3_out3_40a_p8_12ch_nologo_en
-
-    //#define PDU_GC60_04K_125H         //ac_in3_out1_40a_p4_24ch_nologo_en
-#endif
-
-
-#ifdef PRJ_RUSSIA_ITK
-    #define SMTP_SEND_BUILTIN
-#endif
-
-
-#ifdef PRJ_ANDERSON
-    //#define USE_MQTT
-    //#define MQTT_SERVER_BUILTIN
-
-    #define SMTP_SEND_BUILTIN
-
-    #define USE_NETSWITCH
-
-    #define SW_STATIC_PORT_START
-    #define SW_PORT_INDEX_START         0
-    #define SW_PORT_INDEX_END           21
-
-    //#define SW_STATIC_IP
-    #ifdef SW_STATIC_IP
-        #define SW_HOST_IP              "192.168.234.1"
-        #define SW_PDU_IP               "192.168.234.132"
-    #endif
-    
-    #undef MAX_CHN_COUNT
-    #define MAX_CHN_COUNT               24
-#endif
-
-
-#ifdef PRJ_HYPERTEC
-    //ac_in3_out1_36ch_nologo_en_hypertec
-    #define SMTP_SEND_BUILTIN
-    
-    #undef PHASE_GROUP_CNT
-    #undef CHANNEL_DELAY_SEC
-
-    #define PHASE_GROUP_CNT             6
-    #define CHANNEL_DELAY_SEC           6
-#endif
-
-
-#endif
-
-

BIN
cust_data/db/ac_i1_o1_chinese.db


BIN
cust_data/db/ac_i1_o1_chinese_xian.db


BIN
cust_data/db/ac_i1_o1_english.db


BIN
cust_data/db/ac_i1_o1_russian.db


BIN
cust_data/db/ac_i3_o1_chinese.db


BIN
cust_data/db/ac_i3_o1_english.db


BIN
cust_data/db/ac_i3_o1_russian.db


BIN
cust_data/db/ac_i3_o3_chinese.db


BIN
cust_data/db/ac_i3_o3_english.db


BIN
cust_data/db/ac_i3_o3_russian.db


BIN
cust_data/db/dc_i_dc_o_chinese.db


+ 2 - 16
pro/src/dflt.c

@@ -57,26 +57,12 @@ smtp_send_t DFLT_SMTP_SEND={
 };
 
 mqtt_info_t DFLT_MQTT={
-
     .ser[0] = {
         .id = 0,
-        .mode = 1,
-        .cid = "",
-        .proto = "mqtt",
-        .name  = "server1",
-        .server = "192.168.2.4",
-        .port = "1883",
-        .cert = "",
-        .user = "gowone100",
-        .password = "gowone100",
-    },
-
-    .ser[1] = {
-        .id = 1,
-        .mode = 1,
+        .mode = 0,
         .cid = "",
         .proto = "mqtts",
-        .name  = "server2",
+        .name  = "server1",
         .server = "gaae4d7b.ala.cn-hangzhou.emqxsl.cn",
         .port = "8883",
         .cert = "-----BEGIN CERTIFICATE-----\r\n"

+ 2 - 1
pro/src/mqtt.c

@@ -366,10 +366,11 @@ static int my_send(mqtt_conn_t *conn)
     mqtt_handle_t *h=(mqtt_handle_t*)conn->h;
     list_node_t *ln=NULL;
 
-    r = xlist_get_node(h->list, &ln, 0);
+    r = xlist_take_node(h->list, &ln, 0);
     if(r==0) {
         mqtt_pkt_t *pkt=(mqtt_pkt_t*)ln->data.buf;
         my_pub(conn, pkt->topic, pkt->content);
+        xlist_back_node(h->list, ln);
     }
 
     return r;

+ 11 - 40
pub

@@ -15,14 +15,14 @@
 #PRJS="PRJ_RELEASE_AC_I3_O1"
 #PRJS="PRJ_RELEASE_AC_I3_O3"
 #PRJS="PRJ_STSC_I3_O3"
-#PRJS="PRJ_TEST"
+PRJS="PRJ_TEST"
 
 #PRJS="PRJ_USASL_AC_I3_O1 PRJ_USASL_AC_I3_O3"
 #PRJS="PRJ_XIAN_AC_I1_O1_P4 PRJ_XIAN_AC_I1_O1_P8"
 #PRJS="PRJ_ITK_AC_I1_O1 PRJ_ITK_AC_I3_O1"
 #PRJS="PRJ_LITECH_AC_I1_O1 PRJ_LITECH_AC_I3_O1"
 #PRJS="PRJ_RELEASE_DC_I_DC_O PRJ_RELEASE_AC_I1_O1 PRJ_RELEASE_AC_I3_O1 PRJ_RELEASE_AC_I3_O3"
-PRJS="PRJ_LITECH_AC_I1_O1 PRJ_LITECH_AC_I3_O1 PRJ_XIAN_AC_I1_O1_P4 PRJ_XIAN_AC_I1_O1_P8"
+#PRJS="PRJ_LITECH_AC_I1_O1 PRJ_LITECH_AC_I3_O1 PRJ_XIAN_AC_I1_O1_P4 PRJ_XIAN_AC_I1_O1_P8"
 
 
 fulldir=$(realpath $0)
@@ -55,104 +55,75 @@ function do_copy()
 {
     echo do_copy ...
     
-    flag=1
+    flag=0
     
     rm -f $curdir/output/t113i/etc/network/interfaces
     mkdir -p $curdir/output/t113i/root/run/app/image
-
-    rm -rf $curdir/output/t113i/root/run/web
-    cp -rf $custdir/web/general  $curdir/output/t113i/root/run/web
     
     if [ "$1" = "PRJ_XIAN_AC_I1_O1_P4" ]; then
         name=ac_in1_out1_p4_xian
-
-        #cp -f $custdir/db/ac_i1_o1_chinese_xian.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_XIAN_AC_I1_O1_P8" ]; then
         name=ac_in1_out1_p8_xian
-        
-        #cp -f $custdir/db/ac_i1_o1_chinese_xian.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_ITK_AC_I1_O1" ]; then
         name=ac_in1_out1_russia_itk
-
-        #cp -f $custdir/db/ac_i1_o1_russian.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_itk.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_ITK_AC_I3_O1" ]; then
         name=ac_in3_out1_russia_itk
-
-        #cp -f $custdir/db/ac_i3_o1_russian.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_itk.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_RELEASE_DC_I_DC_O" ]; then
         name=dc_in_dc_out_release
-        
-        #cp -f $custdir/db/dc_i_dc_o_chinese.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_RELEASE_AC_I1_O1" ]; then
         name=ac_in1_out1_release
-
-        cp -f $custdir/db/ac_i1_o1_chinese.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_RELEASE_AC_I3_O1" ]; then
         name=ac_in3_out1_release
-
-        cp -f $custdir/db/ac_i3_o1_chinese.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_RELEASE_AC_I3_O3" ]; then
         name=ac_in3_out3_release
-
-        #cp -f $custdir/db/ac_i3_o3_chinese.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_LITECH_AC_I1_O1" ]; then
         name=ac_in1_out1_litech
-
-        #cp -f $custdir/db/ac_i1_o1_english.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_litech.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_LITECH_AC_I3_O1" ]; then
         name=ac_in3_out1_litech
-
-        #cp -f $custdir/db/ac_i3_o1_english.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_litech.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_ANDERSON_AC_I3_O3" ]; then
         name=ac_in3_out3_anderson
-
-        #cp -f $custdir/db/ac_i3_o3_english.db $curdir/output/t113i/root/run/app/pdu_dat.db
+        flag=1
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_USASL_AC_I3_O1" ]; then
         name=ac_in3_out1_usa_sl
-        
-        #cp -f $custdir/db/ac_i3_o1_english.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_USASL_AC_I3_O3" ]; then
         name=ac_in3_out3_usa_sl
-        
-        #cp -f $custdir/db/ac_i3_o3_english.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_HYPERTEC_AC_I3_O1" ]; then
         name=ac_in3_out1_hypertec
-        
-        #cp -f $custdir/db/ac_i3_o1_english.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_hypertec.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_INSPUR_DC_I_DC_O" ]; then
         name=dc_in1_out1_inspur
-        
-        #cp -f $custdir/db/dc_i_dc_o_chinese.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_TEST" ]; then
         name=ac_in3_out1_test
-        
-        #cp -f $custdir/db/ac_i3_o1_english.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     elif [ "$1" = "PRJ_STSC_I3_O3" ]; then
         name=ac_in3_out3_stsc
-        
-        #cp -f $custdir/db/ac_i3_o3_english.db $curdir/output/t113i/root/run/app/pdu_dat.db
         cp -f $custdir/logo/logo_neuter.png $curdir/output/t113i/root/run/app/image/logo.png
     else
         echo error! $RPJ not define!!!
         exit 1
     fi
 
+    rm -rf $curdir/output/t113i/root/run/web
+    if [ $flag -gt 0 ]; then
+        cp -rf $custdir/web/general  $curdir/output/t113i/root/run/web
+    else
+        cp -rf $custdir/web/anderson  $curdir/output/t113i/root/run/web
+    fi
+
     prj_enable $1
 }