Sfoglia il codice sorgente

Merge branch 'master' of https://gowone.dy.takin.cc/liyuezong/SmartPDCode

liyi 1 anno fa
parent
commit
ffa7f1a8c3
3 ha cambiato i file con 48 aggiunte e 5 eliminazioni
  1. 1 1
      pro/CMakeLists.txt
  2. 38 2
      pro/config/cfg.h
  3. 9 2
      pub

+ 1 - 1
pro/CMakeLists.txt

@@ -49,7 +49,7 @@ link_directories(${PROJECT_SOURCE_DIR}/sqlite/lib)
 link_directories(${PROJECT_SOURCE_DIR}/modbus/lib)
 include_directories (${STAGING_DIR}/usr/include/libnl3)
 
-add_definitions("-Wall -g")
+add_definitions("-Wall")
 
 set(PDU_SRC_LIST
 	${PROJECT_SOURCE_DIR}/letter/src/shell_cmd_list.c

+ 38 - 2
pro/config/cfg.h

@@ -17,7 +17,7 @@
 //#define PRJ_LITECH_AC_I1_O1
 //#define PRJ_LITECH_AC_I3_O1
 //#define PRJ_INSPUR_DC_I_DC_O
-#define PRJ_INSPUR_DC_I_DC_O_NEW_96
+//#define PRJ_INSPUR_DC_I_DC_O_NEW_96
 //#define PRJ_ANDERSON_AC_I3_O3
 //#define PRJ_HYPERTEC_AC_I3_O1
 //#define PRJ_SG_I3_O3
@@ -28,7 +28,9 @@
 //#define PRJ_Malaysia_AC_I3_O1
 //#define PRJ_TEST_AC_I3_O3
 //#define PRJ_ESOUTH_DC_I1_O4_RGB5
+#define PRJ_CHANGCHUN_AC_I1_O1_OLED
 
+//#define PRJ_TIDA_AC_I3_O1
 //#define PRJ_INST2302_DC_OLED
 //#define PRJ_INST2106_AC_I1_O1_OLED
 //#define PRJ_YST_AC_I1_O1
@@ -82,6 +84,22 @@
 
     #define PROD_POWER_TYPE                     0
     #define IN_INDEX_MAP                        {3,2,0,1}
+#elif (defined PRJ_TIDA_AC_I3_O1)
+    
+    #define LANGUAGE                            0           //english
+    #define SMPLE_TIME                          30          //ms
+    #define SAVE_TIME                           60000       //ms
+    #define CASCADE_CNT                         0
+
+    #define PHASE_GROUP                         8
+    #define CHANNEL_DELAY                       8
+    #define PROD_POWER_TYPE                 5
+
+    #define USE_BEEP                            1
+    #define USE_LED                             1
+
+    #define BRD_MAX                             6
+
 #elif (defined PRJ_USASL_AC_I3_O1) || (defined PRJ_USASL_AC_I3_O3)
     #define LANGUAGE                            1           //english
     #define SMPLE_TIME                          30          //ms
@@ -255,6 +273,24 @@
 
     #define USE_UI
 
+    
+#elif defined PRJ_CHANGCHUN_AC_I1_O1_OLED
+    #define LANGUAGE                            0           //chinese
+    #define SMPLE_TIME                          30          //ms
+    #define SAVE_TIME                           60000       //ms
+    #define CASCADE_CNT                         0
+
+    #define PHASE_GROUP                         9
+    #define CHANNEL_DELAY                      9
+
+    #define PROD_POWER_TYPE                     0
+
+    #define BRD_MAX                             5
+
+    #define ROTATE 180
+
+    #define USE_UI
+
 #elif defined PRJ_TEST_AC_I3_O1
     #define LANGUAGE                            0           //chinese
     #define SMPLE_TIME                          30          //ms
@@ -317,7 +353,7 @@
     #define USE_BEEP                            1
     #define USE_LED                             1
     
-    #define BRD_MAX                             10
+    #define BRD_MAX                             8
 
 #elif defined PRJ_IP_AC_I3_O3
     #define LANGUAGE                            0

+ 9 - 2
pub

@@ -9,7 +9,7 @@
 #PRJS="PRJ_USASL_AC_I3_O3"
 #PRJS="PRJ_HYPERTEC_AC_I3_O1"
 #PRJS="PRJ_INSPUR_DC_I_DC_O"
-PRJS="PRJ_INSPUR_DC_I_DC_O_NEW_96"
+#PRJS="PRJ_INSPUR_DC_I_DC_O_NEW_96"
 #PRJS="PRJ_RELEASE_DC_I_DC_O"
 #PRJS="PRJ_RELEASE_AC_I1_O1"
 #PRJS="PRJ_RELEASE_AC_I3_O1"
@@ -30,6 +30,8 @@ PRJS="PRJ_INSPUR_DC_I_DC_O_NEW_96"
 #PRJS="PRJ_DUALWIRES_AC_I3_O2"
 #PRJS="PRJ_Malaysia_AC_I3_O1"
 #PRJS="PRJ_2405_AC_I1_O1_OLED"
+PRJS="PRJ_CHANGCHUN_AC_I1_O1_OLED"
+#PRJS="PRJ_TIDA_AC_I3_O1"
 
 #PRJS="PRJ_USASL_AC_I3_O1 PRJ_USASL_AC_I3_O3"
 #PRJS="PRJ_XIAN_AC_I1_O1_P4 PRJ_XIAN_AC_I1_O1_P8"
@@ -189,6 +191,8 @@ function do_copy()
         name=ac_in3_out1_gowone_125A
     elif [ "$1" = "PRJ_DUALWIRES_AC_I3_O2" ];then
         name=ac_DualWires_in3_out2_release
+    elif [ "$1" = "PRJ_TIDA_AC_I3_O1" ];then
+	name=ac_tida_in3_out1_release
     elif [ "$1" = "PRJ_IP_CHONGQING_AC_I1_O1" ];then
         cp -f $custdir/logo/logo_gowone.png $appdir/image/logo.png
         name=ip_ac_chongqing_in1_out1_release
@@ -200,13 +204,16 @@ function do_copy()
         name=ip_dc_aosens_in1_out1_release
     elif [ "$1" = "PRJ_Malaysia_AC_I3_O1" ];then
         name=ac_Malaysia_in3_out1_release
-	cp -f $custdir/db/pdu_dat_malaysia_back.db $appdir/pdu_dat.db
+	cp -f $custdir/db/pdu_dat_malaysia_front.db $appdir/pdu_dat.db
 	cp -f $custdir/logo/logo_litech.png $appdir/image/logo.png
        	cp -f $custdir/qt/rgb_lcd/Qt_Test        $appdir/
         cp -f $custdir/qt/rgb_lcd/S90PDUApp      $rootdir/etc/init.d/
     elif [ "$1" = "PRJ_2405_AC_I1_O1_OLED" ];then
         name=ac_in1_out1_2405_OLED_release
 	rm -f $appdir/Qt_Test
+    elif [ "$1" = "PRJ_CHANGCHUN_AC_I1_O1_OLED" ];then
+        name=ac_in1_out1_changchun_OLED_release
+	rm -f $appdir/Qt_Test
     else
         echo error! $RPJ not define!!!
         exit 1