10 Commits f6af40d7e8 ... f963a346f3

Tác giả SHA1 Thông báo Ngày
  kevin f963a346f3 MC124的电流传感器系数修改为0.36 2 năm trước cách đây
  kevin 9bff407d40 mc100 v1更新 2 năm trước cách đây
  kevin 5a79ba7602 霍尔电流采样系数配置放到bsp.h中 2 năm trước cách đây
  kevin ec7d94f69b 修改电流采集系数的宏定义名称 2 năm trước cách đây
  kevin b15097d885 1 MC124母线电流极性修改 2 năm trước cách đây
  kevin f719932a01 加入configs文件夹,存放不同电机的autogen_config.h 和 yml配置 2 năm trước cách đây
  kevin 6cf8c73d2d 电门最小电压判断使用mc_conf.c.min_dc_vol 2 năm trước cách đây
  kevin 5ed7398203 mc_config 默认配置加入扭矩过零的默认值 2 năm trước cách đây
  kevin 698730378d 支持A1电机外特性 2 năm trước cách đây
  kevin 4fbe23cc5b add MC124 support 2 năm trước cách đây

+ 1 - 1
Applications/app/app.c

@@ -64,7 +64,7 @@ static void app_print_log(void) {
 	//sample_log();
 	//throttle_log();
 	sys_debug("Trq: %f-%f-%f\n", motor.controller.input_torque.target, motor.controller.input_torque.interpolation, motor.controller.input_torque.step);
-	sys_debug("contr %d\n", motor.controller.b_start);
+	sys_debug("acc %d\n", get_acc_vol());
 	//F_debug();
 	//eCtrl_debug_log();
 	//sys_debug("enc err %d, %d\n", foc_observer_enc_errcount(), foc_observer_sensorless_stable());

+ 4 - 4
Applications/bsp/at32/board_at_mc100_v1.h

@@ -92,7 +92,7 @@
 #define PWM_BRAKE_RCU 	RCU_GPIOB
 #define PWM_BRAKE_MODE 	GPIO_MODE_IN_FLOATING
 
-#define HALL_SENSOR_CEOF 0.32F
+#define CONFIG_CURRENT_SENSOR_CEOF 0.32F
 
 /* 高边电流传感器采样 */
 #define HIGH_SIDE_CURRENT_SENSOR
@@ -110,8 +110,8 @@
 #define W_PHASE_ADC_RCU 	RCU_GPIOA
 #define W_PHASE_ADC_MODE 	GPIO_MODE_AIN
 
-#define ADC_TO_CURR_ceof1  (HALL_SENSOR_CEOF)
-#define ADC_TO_CURR_ceof2  (HALL_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof1  (CONFIG_CURRENT_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof2  (CONFIG_CURRENT_SENSOR_CEOF)
 
 #define CONFIG_PWM_UV_SWAP 1
 
@@ -139,7 +139,7 @@
 #define VBUS_I_ADC_PIN 		GPIO_PIN_4
 #define VBUS_I_ADC_RCU 		RCU_GPIOA
 #define VBUS_I_ADC_MODE 	GPIO_MODE_AIN
-#define VBUS_I_CEOF         (HALL_SENSOR_CEOF)
+#define VBUS_I_CEOF         (CONFIG_CURRENT_SENSOR_CEOF)
 
 
 /* MOS 温度采集 */

+ 5 - 5
Applications/bsp/at32/board_at_mc105_v3.h

@@ -105,7 +105,7 @@
 #define PWM_BRAKE_RCU 	CRM_GPIOB_PERIPH_CLOCK
 #define PWM_BRAKE_MODE 	GPIO_MODE_INPUT
 
-#define HALL_SENSOR_CEOF 0.32F
+#define CONFIG_CURRENT_SENSOR_CEOF 0.32F
 
 /* 高边电流传感器采样 */
 #define HIGH_SIDE_CURRENT_SENSOR
@@ -123,8 +123,8 @@
 #define W_PHASE_ADC_RCU 			CRM_GPIOC_PERIPH_CLOCK
 #define W_PHASE_ADC_MODE 			GPIO_MODE_ANALOG
 
-#define ADC_TO_CURR_ceof1  			(HALL_SENSOR_CEOF)
-#define ADC_TO_CURR_ceof2 			(HALL_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof1  			(CONFIG_CURRENT_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof2 			(CONFIG_CURRENT_SENSOR_CEOF)
 
 #define CONFIG_PWM_UV_SWAP 		   	1
 
@@ -152,8 +152,8 @@
 #define VBUS_I_ADC_PIN 				GPIO_PINS_0
 #define VBUS_I_ADC_RCU 				CRM_GPIOA_PERIPH_CLOCK
 #define VBUS_I_ADC_MODE 			GPIO_MODE_ANALOG
-#define VBUS_I_CEOF         		(HALL_SENSOR_CEOF)
-#define VBUS_I_POSITIVE     		1
+#define VBUS_I_CEOF         		(CONFIG_CURRENT_SENSOR_CEOF)
+#define CONFIG_VBUS_I_POSITIVE     		1
 
 /* MOS 温度采集 */
 #define MOS_TEMP_ADC_CHAN    		ADC_CHANNEL_8

+ 3 - 6
Applications/bsp/gd32/board_mc100_v1.h

@@ -100,9 +100,6 @@
 #define PWM_BRK_IRQHandler  TIMER0_BRK_IRQHandler
 #endif
 
-
-#define HALL_SENSOR_CEOF 0.32F
-
 /* 高边电流传感器采样 */
 #define HIGH_SIDE_CURRENT_SENSOR
 
@@ -119,8 +116,8 @@
 #define W_PHASE_ADC_RCU 	RCU_GPIOA
 #define W_PHASE_ADC_MODE 	GPIO_MODE_AIN
 
-#define ADC_TO_CURR_ceof1  (HALL_SENSOR_CEOF)
-#define ADC_TO_CURR_ceof2  (HALL_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof1  (CONFIG_CURRENT_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof2  (CONFIG_CURRENT_SENSOR_CEOF)
 
 #define CONFIG_PWM_UV_SWAP 1
 
@@ -148,7 +145,7 @@
 #define VBUS_I_ADC_PIN 		GPIO_PIN_4
 #define VBUS_I_ADC_RCU 		RCU_GPIOA
 #define VBUS_I_ADC_MODE 	GPIO_MODE_AIN
-#define VBUS_I_CEOF         (HALL_SENSOR_CEOF)
+#define VBUS_I_CEOF         (CONFIG_CURRENT_SENSOR_CEOF)
 
 
 /* MOS 温度采集 */

+ 4 - 9
Applications/bsp/gd32/board_mc105_v3.h

@@ -6,7 +6,7 @@
 #include "gd32e10x.h"
 #endif
 
-#define CONFIG_HW_MAX_DC_VOLTAGE 115.0F
+#define CONFIG_HW_MAX_DC_VOLTAGE CONFIG_BOARD_MAX_DC
 #define CONFIG_HW_MAX_DC_CURRENT 250.0f
 #define CONFIG_HW_MAX_CHRG_CURRENT (-100.0f)
 #define CONFIG_HW_MAX_MOTOR_RPM      9000.0f
@@ -110,9 +110,6 @@
 #define PWM_BRK_IRQHandler  TIMER0_BRK_IRQHandler
 #endif
 
-
-#define HALL_SENSOR_CEOF 0.303F
-
 /* 高边电流传感器采样 */
 #define HIGH_SIDE_CURRENT_SENSOR
 
@@ -129,8 +126,8 @@
 #define W_PHASE_ADC_RCU 	RCU_GPIOC
 #define W_PHASE_ADC_MODE 	GPIO_MODE_AIN
 
-#define ADC_TO_CURR_ceof1  (HALL_SENSOR_CEOF)
-#define ADC_TO_CURR_ceof2  (HALL_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof1  (CONFIG_CURRENT_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof2  (CONFIG_CURRENT_SENSOR_CEOF)
 
 #define CONFIG_PWM_UV_SWAP 1
 
@@ -158,9 +155,7 @@
 #define VBUS_I_ADC_PIN 		GPIO_PIN_0
 #define VBUS_I_ADC_RCU 		RCU_GPIOA
 #define VBUS_I_ADC_MODE 	GPIO_MODE_AIN
-#define VBUS_I_CEOF         (0.303f)
-#define VBUS_I_POSITIVE     1
-
+#define VBUS_I_CEOF         (CONFIG_CURRENT_SENSOR_CEOF)
 /* MOS 温度采集 */
 #define MOS_TEMP_ADC_CHAN    ADC_CHANNEL_8
 #define MOS_TEMP_ADC_GROUP 	 GPIOB

+ 14 - 5
Applications/bsp/gd32/bsp.h

@@ -28,18 +28,27 @@
 #elif defined (YUANQU_HW_V1)
 #include "bsp/board_yuanqu.h"
 #elif defined (MC100_HW_V1)
+#define CONFIG_CURRENT_SENSOR_CEOF 0.32F
 #include "bsp/gd32/board_mc100_v1.h"
 #define CONFIG_BOARD_MCXXX
 #define CONFIG_BOARD_NAME "MC100"
 #define CONFIG_MC105_HW_VERSION 2
-#elif defined (MC105_HW_V3)
+
+#elif defined (CONFIG_MC105_HW_V3)
+#define CONFIG_BOARD_MAX_DC 115.0F
+#define CONFIG_VBUS_I_POSITIVE 1
+#define CONFIG_CURRENT_SENSOR_CEOF 0.303F
 #include "bsp/gd32/board_mc105_v3.h"
 #define CONFIG_BOARD_MCXXX
-#ifdef CONFIG_SERVO_MOTOR
-#define CONFIG_BOARD_NAME "MC105_SERVO"
-#else
 #define CONFIG_BOARD_NAME "MC105"
-#endif
+#define CONFIG_MC105_HW_VERSION 3
+
+#elif defined (CONFIG_BOARD_MC124)
+#define CONFIG_BOARD_MAX_DC 84.0F
+#define CONFIG_CURRENT_SENSOR_CEOF 0.36F
+#include "bsp/gd32/board_mc105_v3.h"
+#define CONFIG_BOARD_MCXXX
+#define CONFIG_BOARD_NAME "MCXXX"
 #define CONFIG_MC105_HW_VERSION 3
 #endif
 #endif /* __BSP_GD32_H__ */

+ 5 - 5
Applications/bsp/n32/board_n32_mc105_v3.h

@@ -97,7 +97,7 @@
 
 
 
-#define HALL_SENSOR_CEOF 0.32F
+#define CONFIG_CURRENT_SENSOR_CEOF 0.32F
 
 /* 高边电流传感器采样 */
 #define HIGH_SIDE_CURRENT_SENSOR
@@ -115,8 +115,8 @@
 #define W_PHASE_ADC_RCU 	RCU_GPIOC
 #define W_PHASE_ADC_MODE 	GPIO_MODE_AIN
 
-#define ADC_TO_CURR_ceof1  (HALL_SENSOR_CEOF)
-#define ADC_TO_CURR_ceof2  (HALL_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof1  (CONFIG_CURRENT_SENSOR_CEOF)
+#define ADC_TO_CURR_ceof2  (CONFIG_CURRENT_SENSOR_CEOF)
 
 #define CONFIG_PWM_UV_SWAP 1
 
@@ -144,8 +144,8 @@
 #define VBUS_I_ADC_PIN 		GPIO_PIN_0
 #define VBUS_I_ADC_RCU 		RCU_GPIOA
 #define VBUS_I_ADC_MODE 	GPIO_MODE_AIN
-#define VBUS_I_CEOF         (HALL_SENSOR_CEOF)
-#define VBUS_I_POSITIVE     1
+#define VBUS_I_CEOF         (CONFIG_CURRENT_SENSOR_CEOF)
+#define CONFIG_VBUS_I_POSITIVE     1
 
 /* MOS 温度采集 */
 #define MOS_TEMP_ADC_CHAN    ADC_CH_3  //adc2

+ 0 - 4
Applications/config.h

@@ -16,11 +16,7 @@
 #define  CAN_NODE_ADDR_CCU  		0x43
 #define  CAN_NODE_ADDR_PC  			0x45
 #define  CAN_NODE_ADDR_CCU_AUX      0x46
-#ifdef CONFIG_SERVO_MOTOR
-#define  CAN_NODE_ADDR_MCU  		0x4E
-#else
 #define  CAN_NODE_ADDR_MCU  		0x4D
-#endif
 #define  CAN_NODE_ADDR_DCU  		0x50	/* MCU of the display panel */
 #define  CAN_NODE_ADDR_BLE  		0x51	/*radar*/
 #define  CAN_NODE_ADDR_RCU  		0x52	/*radar*/

+ 5 - 0
Applications/foc/mc_config.c

@@ -267,6 +267,11 @@ void mc_conf_default(void) {
 	EnReco_Config_default(8);
 	EnReco_Config_default(9);
 
+	conf.cz.low = CONFIG_CrossZero_Low;
+	conf.cz.high = CONFIG_CrossZero_High;
+	conf.cz.min_step = CONFIG_CrossZero_MinStep;
+	conf.cz.normal_step = CONFIG_CrossZero_NorStep;
+
 	conf.crc = crc16_get((u8 *)&conf, (u8 *)&conf.crc - (u8 *)&conf);
 }
 

+ 2 - 0
Applications/foc/motor/A1_motor_config.c

@@ -1,3 +1,5 @@
+#define MOTOR_STATOR_5N
+
 #ifndef MOTOR_STATOR_5N
 static torque_map_t mtpa_fw_map[11][10] = {
  { // 转速:0-2000

+ 1 - 1
Applications/foc/motor/motor.c

@@ -103,7 +103,7 @@ static void MC_Check_MosVbusThrottle(void) {
 	if (vbus_vol >= mc_conf()->c.max_dc_vol) {
 		mc_set_critical_error(FOC_CRIT_ACC_OV_Err);
 	}
-	if (vbus_vol <= CONFIG_ACC_MIN_VOL) {
+	if (vbus_vol <= mc_conf()->c.min_dc_vol) {
 		mc_set_critical_error(FOC_CRIT_ACC_Un_Err);
 	}
 	if (throttle_is_all_error()) {

+ 2 - 2
Applications/foc/motor/motor_param.c

@@ -7,6 +7,7 @@
 #include "libs/logger.h"
 
 #if defined(CONFIG_MOTOR_TORQUE_CONF)
+#include CONFIG_MOTOR_TORQUE_CONF
 #define MOT_HAVE_MAPS
 #define MOT_USE_PHASE_I //表示使用电流矢量和RPM查表,获取D轴电流,iq = 开根号(电流矢量的平方 - D轴电流的平方)
 #ifndef MOTOR_STATOR_5N
@@ -19,7 +20,6 @@ static int map_rpm[] = {2000, 3000, 4000, 4500, 5000, 5500, 6000, 6500, 7000, 75
 #define TRQ_MAX_IDX 10
 static int map_rpm[] = {4000, 4500, 5000, 5500, 6000, 6500, 7000, 7500, 8000, 8500, 9000};
 #endif
-#include CONFIG_MOTOR_TORQUE_CONF
 #endif
 
 /* 根据电机外特性map,获取当前转速下的最大扭矩,主要给计算当前扭矩需求使用 */
@@ -161,7 +161,7 @@ static void get_torque_range(s16 z, int index, int max_index, int *left, int *ri
 	*right = low_right;
 }
 
-void motor_mpta_fw_lookup(float rpm, float torque, DQ_t *dq_out) {
+void motor_mpta_fw_lookup(float rpm, float torque, dq_t *dq_out) {
 	bool neg_trq = false;
 	s16 itorque = torque * 10;
 	if (itorque < 0) {

+ 3 - 4
Applications/foc/samples.c

@@ -41,11 +41,11 @@ void samples_init(void){
 	_vref.value = 0;
 	_vref.lowpass = 0.01f;
 	sample_vref();
-	_vbus.value = ((float)adc_get_vbus() * VBUS_VOL_CEOF);
+	_vbus.value = sample_vbus_raw();
 	_vbus.filted_value = _vbus.value;
 	_vbus.lowpass = (0.01f);
 #ifdef ACC_V_CHAN
-	acc_vol.value = ((float)adc_get_acc() * VBUS_VOL_CEOF);
+	acc_vol.value = sample_acc_vol_raw();
 	acc_vol.filted_value = acc_vol.value;
 	acc_vol.lowpass = (0.01f);
 #endif
@@ -201,7 +201,6 @@ float sample_acc_vol_raw(void) {
 }
 
 void sample_vbus(void){
-	u32 ticks = task_ticks_abs();
 	_vbus.value = sample_vbus_raw();
 	LowPass_Filter(_vbus.filted_value, _vbus.value, _vbus.lowpass);
 	_vbus.filted_int = (int)_vbus.filted_value;
@@ -213,7 +212,7 @@ void sample_vbus(void){
 }
 
 float sample_ibus_raw(void) {
-#ifdef VBUS_I_POSITIVE
+#ifdef CONFIG_VBUS_I_POSITIVE
 	s16 vadc = adc_get_ibus() - _ibus.adc_offset;
 #else
 	s16 vadc = _ibus.adc_offset - adc_get_ibus();

+ 1 - 1
Project/MC105_V3.uvprojx

@@ -337,7 +337,7 @@
             <v6Rtti>0</v6Rtti>
             <VariousControls>
               <MiscControls>--gnu</MiscControls>
-              <Define>USE_STDPERIPH_DRIVER,GD32F30X_CL,MC105_HW_V3,CONFIG_CAN_IAP</Define>
+              <Define>USE_STDPERIPH_DRIVER,GD32F30X_CL,CONFIG_MC105_HW_V3,CONFIG_CAN_IAP</Define>
               <Undefine></Undefine>
               <IncludePath>..\Librarys\CMSIS\Include,..\Librarys\CMSIS\GD\GD32F30x\Include,..\Librarys\GD32F30x_Drivers\include,..\Applications;..\Simulink\PMSM_Controller_ert_rtw</IncludePath>
             </VariousControls>

+ 1 - 1
Project/MC105_V3_SERVO.uvoptx

@@ -171,7 +171,7 @@
 
   <Group>
     <GroupName>Application</GroupName>
-    <tvExp>0</tvExp>
+    <tvExp>1</tvExp>
     <tvExpOptDlg>0</tvExpOptDlg>
     <cbSel>0</cbSel>
     <RteFlg>0</RteFlg>

+ 1 - 1
Project/MC105_V3_SERVO.uvprojx

@@ -337,7 +337,7 @@
             <v6Rtti>0</v6Rtti>
             <VariousControls>
               <MiscControls>--gnu -DCONFIG_MOT_ADV_ANGLE=30</MiscControls>
-              <Define>USE_STDPERIPH_DRIVER,GD32F30X_CL,MC105_HW_V3,CONFIG_CAN_IAP,CONFIG_SERVO_MOTOR</Define>
+              <Define>USE_STDPERIPH_DRIVER,GD32F30X_CL,CONFIG_MC105_HW_V3,CONFIG_CAN_IAP,CONFIG_SERVO_MOTOR</Define>
               <Undefine></Undefine>
               <IncludePath>..\Librarys\CMSIS\Include,..\Librarys\CMSIS\GD\GD32F30x\Include,..\Librarys\GD32F30x_Drivers\include,..\Applications;..\Simulink\PMSM_Controller_ert_rtw</IncludePath>
             </VariousControls>

+ 1116 - 0
Project/MC124.uvoptx

@@ -0,0 +1,1116 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
+<ProjectOpt xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="project_optx.xsd">
+
+  <SchemaVersion>1.0</SchemaVersion>
+
+  <Header>### uVision Project, (C) Keil Software</Header>
+
+  <Extensions>
+    <cExt>*.c</cExt>
+    <aExt>*.s*; *.src; *.a*</aExt>
+    <oExt>*.obj; *.o</oExt>
+    <lExt>*.lib</lExt>
+    <tExt>*.txt; *.h; *.inc</tExt>
+    <pExt>*.plm</pExt>
+    <CppX>*.cpp</CppX>
+    <nMigrate>0</nMigrate>
+  </Extensions>
+
+  <DaveTm>
+    <dwLowDateTime>0</dwLowDateTime>
+    <dwHighDateTime>0</dwHighDateTime>
+  </DaveTm>
+
+  <Target>
+    <TargetName>GD32F305RC</TargetName>
+    <ToolsetNumber>0x4</ToolsetNumber>
+    <ToolsetName>ARM-ADS</ToolsetName>
+    <TargetOption>
+      <CLKADS>12000000</CLKADS>
+      <OPTTT>
+        <gFlags>1</gFlags>
+        <BeepAtEnd>1</BeepAtEnd>
+        <RunSim>0</RunSim>
+        <RunTarget>1</RunTarget>
+        <RunAbUc>0</RunAbUc>
+      </OPTTT>
+      <OPTHX>
+        <HexSelection>1</HexSelection>
+        <FlashByte>65535</FlashByte>
+        <HexRangeLowAddress>0</HexRangeLowAddress>
+        <HexRangeHighAddress>0</HexRangeHighAddress>
+        <HexOffset>0</HexOffset>
+      </OPTHX>
+      <OPTLEX>
+        <PageWidth>79</PageWidth>
+        <PageLength>66</PageLength>
+        <TabStop>8</TabStop>
+        <ListingPath>.\Listings\</ListingPath>
+      </OPTLEX>
+      <ListingPage>
+        <CreateCListing>1</CreateCListing>
+        <CreateAListing>1</CreateAListing>
+        <CreateLListing>1</CreateLListing>
+        <CreateIListing>0</CreateIListing>
+        <AsmCond>1</AsmCond>
+        <AsmSymb>1</AsmSymb>
+        <AsmXref>0</AsmXref>
+        <CCond>1</CCond>
+        <CCode>0</CCode>
+        <CListInc>0</CListInc>
+        <CSymb>0</CSymb>
+        <LinkerCodeListing>0</LinkerCodeListing>
+      </ListingPage>
+      <OPTXL>
+        <LMap>1</LMap>
+        <LComments>1</LComments>
+        <LGenerateSymbols>1</LGenerateSymbols>
+        <LLibSym>1</LLibSym>
+        <LLines>1</LLines>
+        <LLocSym>1</LLocSym>
+        <LPubSym>1</LPubSym>
+        <LXref>0</LXref>
+        <LExpSel>0</LExpSel>
+      </OPTXL>
+      <OPTFL>
+        <tvExp>0</tvExp>
+        <tvExpOptDlg>0</tvExpOptDlg>
+        <IsCurrentTarget>1</IsCurrentTarget>
+      </OPTFL>
+      <CpuCode>0</CpuCode>
+      <DebugOpt>
+        <uSim>0</uSim>
+        <uTrg>1</uTrg>
+        <sLdApp>1</sLdApp>
+        <sGomain>1</sGomain>
+        <sRbreak>1</sRbreak>
+        <sRwatch>1</sRwatch>
+        <sRmem>1</sRmem>
+        <sRfunc>1</sRfunc>
+        <sRbox>1</sRbox>
+        <tLdApp>1</tLdApp>
+        <tGomain>1</tGomain>
+        <tRbreak>1</tRbreak>
+        <tRwatch>1</tRwatch>
+        <tRmem>1</tRmem>
+        <tRfunc>0</tRfunc>
+        <tRbox>1</tRbox>
+        <tRtrace>1</tRtrace>
+        <sRSysVw>1</sRSysVw>
+        <tRSysVw>1</tRSysVw>
+        <sRunDeb>0</sRunDeb>
+        <sLrtime>0</sLrtime>
+        <bEvRecOn>1</bEvRecOn>
+        <bSchkAxf>0</bSchkAxf>
+        <bTchkAxf>0</bTchkAxf>
+        <nTsel>0</nTsel>
+        <sDll></sDll>
+        <sDllPa></sDllPa>
+        <sDlgDll></sDlgDll>
+        <sDlgPa></sDlgPa>
+        <sIfile></sIfile>
+        <tDll></tDll>
+        <tDllPa></tDllPa>
+        <tDlgDll></tDlgDll>
+        <tDlgPa></tDlgPa>
+        <tIfile></tIfile>
+        <pMon>BIN\UL2CM3.DLL</pMon>
+      </DebugOpt>
+      <TargetDriverDllRegistry>
+        <SetRegEntry>
+          <Number>0</Number>
+          <Key>UL2CM3</Key>
+          <Name>UL2CM3(-S0 -C0 -P0 -FD20000000 -FC1000 -FN1 -FF0GD32F30x_CL -FS08000000 -FL040000 -FP0($$Device:GD32F305RC$Flash\GD32F30x_CL.FLM))</Name>
+        </SetRegEntry>
+      </TargetDriverDllRegistry>
+      <Breakpoint/>
+      <Tracepoint>
+        <THDelay>0</THDelay>
+      </Tracepoint>
+      <DebugFlag>
+        <trace>0</trace>
+        <periodic>0</periodic>
+        <aLwin>0</aLwin>
+        <aCover>0</aCover>
+        <aSer1>0</aSer1>
+        <aSer2>0</aSer2>
+        <aPa>0</aPa>
+        <viewmode>0</viewmode>
+        <vrSel>0</vrSel>
+        <aSym>0</aSym>
+        <aTbox>0</aTbox>
+        <AscS1>0</AscS1>
+        <AscS2>0</AscS2>
+        <AscS3>0</AscS3>
+        <aSer3>0</aSer3>
+        <eProf>0</eProf>
+        <aLa>0</aLa>
+        <aPa1>0</aPa1>
+        <AscS4>0</AscS4>
+        <aSer4>0</aSer4>
+        <StkLoc>0</StkLoc>
+        <TrcWin>0</TrcWin>
+        <newCpu>0</newCpu>
+        <uProt>0</uProt>
+      </DebugFlag>
+      <LintExecutable></LintExecutable>
+      <LintConfigFile></LintConfigFile>
+      <bLintAuto>0</bLintAuto>
+      <bAutoGenD>0</bAutoGenD>
+      <LntExFlags>0</LntExFlags>
+      <pMisraName></pMisraName>
+      <pszMrule></pszMrule>
+      <pSingCmds></pSingCmds>
+      <pMultCmds></pMultCmds>
+      <pMisraNamep></pMisraNamep>
+      <pszMrulep></pszMrulep>
+      <pSingCmdsp></pSingCmdsp>
+      <pMultCmdsp></pMultCmdsp>
+    </TargetOption>
+  </Target>
+
+  <Group>
+    <GroupName>Application</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>1</GroupNumber>
+      <FileNumber>1</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\main.c</PathWithFileName>
+      <FilenameWithoutPath>main.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>1</GroupNumber>
+      <FileNumber>2</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\app\app.c</PathWithFileName>
+      <FilenameWithoutPath>app.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>1</GroupNumber>
+      <FileNumber>3</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\app\nv_storage.c</PathWithFileName>
+      <FilenameWithoutPath>nv_storage.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>1</GroupNumber>
+      <FileNumber>4</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\app\factory.c</PathWithFileName>
+      <FilenameWithoutPath>factory.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>Foc</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>5</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\commands.c</PathWithFileName>
+      <FilenameWithoutPath>commands.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>6</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\samples.c</PathWithFileName>
+      <FilenameWithoutPath>samples.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>7</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\svpwm.c</PathWithFileName>
+      <FilenameWithoutPath>svpwm.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>8</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\mc_error.c</PathWithFileName>
+      <FilenameWithoutPath>mc_error.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>9</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\limit.c</PathWithFileName>
+      <FilenameWithoutPath>limit.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>10</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\smo_observer.c</PathWithFileName>
+      <FilenameWithoutPath>smo_observer.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>11</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\foc_observer.c</PathWithFileName>
+      <FilenameWithoutPath>foc_observer.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>12</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\adrc.c</PathWithFileName>
+      <FilenameWithoutPath>adrc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>13</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\ladrc_observer.c</PathWithFileName>
+      <FilenameWithoutPath>ladrc_observer.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>14</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\F_Calc.c</PathWithFileName>
+      <FilenameWithoutPath>F_Calc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>15</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\etcs.c</PathWithFileName>
+      <FilenameWithoutPath>etcs.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>16</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\controller.c</PathWithFileName>
+      <FilenameWithoutPath>controller.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>2</GroupNumber>
+      <FileNumber>17</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\core\foc.c</PathWithFileName>
+      <FilenameWithoutPath>foc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>Motor</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>3</GroupNumber>
+      <FileNumber>18</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\motor\encoder.c</PathWithFileName>
+      <FilenameWithoutPath>encoder.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>3</GroupNumber>
+      <FileNumber>19</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\motor\motor.c</PathWithFileName>
+      <FilenameWithoutPath>motor.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>3</GroupNumber>
+      <FileNumber>20</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\ntc.c</PathWithFileName>
+      <FilenameWithoutPath>ntc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>3</GroupNumber>
+      <FileNumber>21</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\motor\current_ics.c</PathWithFileName>
+      <FilenameWithoutPath>current_ics.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>3</GroupNumber>
+      <FileNumber>22</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\motor\motor_param.c</PathWithFileName>
+      <FilenameWithoutPath>motor_param.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>3</GroupNumber>
+      <FileNumber>23</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\motor\mot_params_ind.c</PathWithFileName>
+      <FilenameWithoutPath>mot_params_ind.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>3</GroupNumber>
+      <FileNumber>24</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\mc_config.c</PathWithFileName>
+      <FilenameWithoutPath>mc_config.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>3</GroupNumber>
+      <FileNumber>25</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\foc\motor\throttle.c</PathWithFileName>
+      <FilenameWithoutPath>throttle.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>Proto</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>4</GroupNumber>
+      <FileNumber>26</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\prot\can_message.c</PathWithFileName>
+      <FilenameWithoutPath>can_message.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>4</GroupNumber>
+      <FileNumber>27</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\prot\can_pc_message.c</PathWithFileName>
+      <FilenameWithoutPath>can_pc_message.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>4</GroupNumber>
+      <FileNumber>28</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\prot\can_foc_msg.c</PathWithFileName>
+      <FilenameWithoutPath>can_foc_msg.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>Math</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>5</GroupNumber>
+      <FileNumber>29</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\math\fast_math.c</PathWithFileName>
+      <FilenameWithoutPath>fast_math.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>5</GroupNumber>
+      <FileNumber>30</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\math\sin_table.c</PathWithFileName>
+      <FilenameWithoutPath>sin_table.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>5</GroupNumber>
+      <FileNumber>31</FileNumber>
+      <FileType>4</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\math\arm_cortexM4lf_math.lib</PathWithFileName>
+      <FilenameWithoutPath>arm_cortexM4lf_math.lib</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>5</GroupNumber>
+      <FileNumber>32</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\math\Fir.c</PathWithFileName>
+      <FilenameWithoutPath>Fir.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>BSP</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>33</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\adc.c</PathWithFileName>
+      <FilenameWithoutPath>adc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>34</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\bsp.c</PathWithFileName>
+      <FilenameWithoutPath>bsp.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>35</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\can.c</PathWithFileName>
+      <FilenameWithoutPath>can.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>36</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\enc_intf.c</PathWithFileName>
+      <FilenameWithoutPath>enc_intf.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>37</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\fan_pwm.c</PathWithFileName>
+      <FilenameWithoutPath>fan_pwm.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>38</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\fmc_flash.c</PathWithFileName>
+      <FilenameWithoutPath>fmc_flash.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>39</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\gd32_bkp.c</PathWithFileName>
+      <FilenameWithoutPath>gd32_bkp.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>40</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\gpio.c</PathWithFileName>
+      <FilenameWithoutPath>gpio.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>41</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\mc_irqs.c</PathWithFileName>
+      <FilenameWithoutPath>mc_irqs.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>42</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\pwm.c</PathWithFileName>
+      <FilenameWithoutPath>pwm.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>43</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\sched_timer.c</PathWithFileName>
+      <FilenameWithoutPath>sched_timer.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>44</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\gd32\uart.c</PathWithFileName>
+      <FilenameWithoutPath>uart.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>6</GroupNumber>
+      <FileNumber>45</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\bsp\delay.c</PathWithFileName>
+      <FilenameWithoutPath>delay.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>Libs</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>7</GroupNumber>
+      <FileNumber>46</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\libs\circle_buffer.c</PathWithFileName>
+      <FilenameWithoutPath>circle_buffer.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>7</GroupNumber>
+      <FileNumber>47</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\libs\logger.c</PathWithFileName>
+      <FilenameWithoutPath>logger.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>7</GroupNumber>
+      <FileNumber>48</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\libs\crc16.c</PathWithFileName>
+      <FilenameWithoutPath>crc16.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>7</GroupNumber>
+      <FileNumber>49</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\libs\byte_queue.c</PathWithFileName>
+      <FilenameWithoutPath>byte_queue.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>7</GroupNumber>
+      <FileNumber>50</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\libs\time_measure.c</PathWithFileName>
+      <FilenameWithoutPath>time_measure.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>OS</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>8</GroupNumber>
+      <FileNumber>51</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\os\heap_4.c</PathWithFileName>
+      <FilenameWithoutPath>heap_4.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>8</GroupNumber>
+      <FileNumber>52</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\os\queue.c</PathWithFileName>
+      <FilenameWithoutPath>queue.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>8</GroupNumber>
+      <FileNumber>53</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Applications\os\os_task.c</PathWithFileName>
+      <FilenameWithoutPath>os_task.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>GD32F30x_Drivers</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>54</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_adc.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_adc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>55</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_bkp.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_bkp.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>56</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_can.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_can.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>57</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_dma.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_dma.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>58</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_exti.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_exti.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>59</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_fmc.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_fmc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>60</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_fwdgt.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_fwdgt.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>61</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_gpio.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_gpio.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>62</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_i2c.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_i2c.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>63</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_misc.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_misc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>64</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_rcu.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_rcu.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>65</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_rtc.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_rtc.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>66</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_timer.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_timer.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>67</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_usart.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_usart.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>68</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_pmu.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_pmu.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>9</GroupNumber>
+      <FileNumber>69</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\GD32F30x_Drivers\source\gd32f30x_dbg.c</PathWithFileName>
+      <FilenameWithoutPath>gd32f30x_dbg.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+  <Group>
+    <GroupName>StartUp</GroupName>
+    <tvExp>0</tvExp>
+    <tvExpOptDlg>0</tvExpOptDlg>
+    <cbSel>0</cbSel>
+    <RteFlg>0</RteFlg>
+    <File>
+      <GroupNumber>10</GroupNumber>
+      <FileNumber>70</FileNumber>
+      <FileType>1</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\CMSIS\GD\GD32F30x\Source\system_gd32f30x.c</PathWithFileName>
+      <FilenameWithoutPath>system_gd32f30x.c</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>10</GroupNumber>
+      <FileNumber>71</FileNumber>
+      <FileType>2</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\CMSIS\GD\GD32F30x\Source\ARM\startup_gd32f30x_hd.s</PathWithFileName>
+      <FilenameWithoutPath>startup_gd32f30x_hd.s</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+    <File>
+      <GroupNumber>10</GroupNumber>
+      <FileNumber>72</FileNumber>
+      <FileType>2</FileType>
+      <tvExp>0</tvExp>
+      <tvExpOptDlg>0</tvExpOptDlg>
+      <bDave2>0</bDave2>
+      <PathWithFileName>..\Librarys\CMSIS\GD\GD32F30x\Source\ARM\startup_gd32f30x_cl.s</PathWithFileName>
+      <FilenameWithoutPath>startup_gd32f30x_cl.s</FilenameWithoutPath>
+      <RteFlg>0</RteFlg>
+      <bShared>0</bShared>
+    </File>
+  </Group>
+
+</ProjectOpt>

+ 856 - 0
Project/MC124.uvprojx

@@ -0,0 +1,856 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
+<Project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="project_projx.xsd">
+
+  <SchemaVersion>2.1</SchemaVersion>
+
+  <Header>### uVision Project, (C) Keil Software</Header>
+
+  <Targets>
+    <Target>
+      <TargetName>GD32F305RC</TargetName>
+      <ToolsetNumber>0x4</ToolsetNumber>
+      <ToolsetName>ARM-ADS</ToolsetName>
+      <pCCUsed>5060750::V5.06 update 6 (build 750)::.\ARMCC</pCCUsed>
+      <uAC6>0</uAC6>
+      <TargetOption>
+        <TargetCommonOption>
+          <Device>GD32F305RC</Device>
+          <Vendor>GigaDevice</Vendor>
+          <PackID>GigaDevice.GD32F30x_DFP.2.2.3</PackID>
+          <PackURL>https://gd32mcu.com/data/documents/pack/</PackURL>
+          <Cpu>IRAM(0x20000000,0x018000) IROM(0x08000000,0x040000) CPUTYPE("Cortex-M4") FPU2 CLOCK(12000000) ELITTLE</Cpu>
+          <FlashUtilSpec></FlashUtilSpec>
+          <StartupFile></StartupFile>
+          <FlashDriverDll>UL2CM3(-S0 -C0 -P0 -FD20000000 -FC1000 -FN1 -FF0GD32F30x_CL -FS08000000 -FL040000 -FP0($$Device:GD32F305RC$Flash\GD32F30x_CL.FLM))</FlashDriverDll>
+          <DeviceId>0</DeviceId>
+          <RegisterFile>$$Device:GD32F305RC$Device\Include\gd32f30x.h</RegisterFile>
+          <MemoryEnv></MemoryEnv>
+          <Cmp></Cmp>
+          <Asm></Asm>
+          <Linker></Linker>
+          <OHString></OHString>
+          <InfinionOptionDll></InfinionOptionDll>
+          <SLE66CMisc></SLE66CMisc>
+          <SLE66AMisc></SLE66AMisc>
+          <SLE66LinkerMisc></SLE66LinkerMisc>
+          <SFDFile>$$Device:GD32F305RC$SVD\GD32F30x_CL.svd</SFDFile>
+          <bCustSvd>0</bCustSvd>
+          <UseEnv>0</UseEnv>
+          <BinPath></BinPath>
+          <IncludePath></IncludePath>
+          <LibPath></LibPath>
+          <RegisterFilePath></RegisterFilePath>
+          <DBRegisterFilePath></DBRegisterFilePath>
+          <TargetStatus>
+            <Error>0</Error>
+            <ExitCodeStop>0</ExitCodeStop>
+            <ButtonStop>0</ButtonStop>
+            <NotGenerated>0</NotGenerated>
+            <InvalidFlash>1</InvalidFlash>
+          </TargetStatus>
+          <OutputDirectory>.\Objects\</OutputDirectory>
+          <OutputName>MC124</OutputName>
+          <CreateExecutable>1</CreateExecutable>
+          <CreateLib>0</CreateLib>
+          <CreateHexFile>1</CreateHexFile>
+          <DebugInformation>1</DebugInformation>
+          <BrowseInformation>1</BrowseInformation>
+          <ListingPath>.\Listings\</ListingPath>
+          <HexFormatSelection>1</HexFormatSelection>
+          <Merge32K>0</Merge32K>
+          <CreateBatchFile>0</CreateBatchFile>
+          <BeforeCompile>
+            <RunUserProg1>0</RunUserProg1>
+            <RunUserProg2>0</RunUserProg2>
+            <UserProg1Name></UserProg1Name>
+            <UserProg2Name></UserProg2Name>
+            <UserProg1Dos16Mode>0</UserProg1Dos16Mode>
+            <UserProg2Dos16Mode>0</UserProg2Dos16Mode>
+            <nStopU1X>0</nStopU1X>
+            <nStopU2X>0</nStopU2X>
+          </BeforeCompile>
+          <BeforeMake>
+            <RunUserProg1>1</RunUserProg1>
+            <RunUserProg2>0</RunUserProg2>
+            <UserProg1Name>SharkFwVersion gen ..\Applications\version.h  .\version_mc124.cfg</UserProg1Name>
+            <UserProg2Name></UserProg2Name>
+            <UserProg1Dos16Mode>0</UserProg1Dos16Mode>
+            <UserProg2Dos16Mode>0</UserProg2Dos16Mode>
+            <nStopB1X>0</nStopB1X>
+            <nStopB2X>0</nStopB2X>
+          </BeforeMake>
+          <AfterMake>
+            <RunUserProg1>1</RunUserProg1>
+            <RunUserProg2>1</RunUserProg2>
+            <UserProg1Name>fromelf --bin --output ./Output/MC124.bin ./Objects/MC124.axf</UserProg1Name>
+            <UserProg2Name>SharkFwVersion copy  ./Output/MC124.bin</UserProg2Name>
+            <UserProg1Dos16Mode>0</UserProg1Dos16Mode>
+            <UserProg2Dos16Mode>0</UserProg2Dos16Mode>
+            <nStopA1X>0</nStopA1X>
+            <nStopA2X>0</nStopA2X>
+          </AfterMake>
+          <SelectedForBatchBuild>0</SelectedForBatchBuild>
+          <SVCSIdString></SVCSIdString>
+        </TargetCommonOption>
+        <CommonProperty>
+          <UseCPPCompiler>0</UseCPPCompiler>
+          <RVCTCodeConst>0</RVCTCodeConst>
+          <RVCTZI>0</RVCTZI>
+          <RVCTOtherData>0</RVCTOtherData>
+          <ModuleSelection>0</ModuleSelection>
+          <IncludeInBuild>1</IncludeInBuild>
+          <AlwaysBuild>0</AlwaysBuild>
+          <GenerateAssemblyFile>0</GenerateAssemblyFile>
+          <AssembleAssemblyFile>0</AssembleAssemblyFile>
+          <PublicsOnly>0</PublicsOnly>
+          <StopOnExitCode>3</StopOnExitCode>
+          <CustomArgument></CustomArgument>
+          <IncludeLibraryModules></IncludeLibraryModules>
+          <ComprImg>1</ComprImg>
+        </CommonProperty>
+        <DllOption>
+          <SimDllName>SARMCM3.DLL</SimDllName>
+          <SimDllArguments> -REMAP -MPU</SimDllArguments>
+          <SimDlgDll>DCM.DLL</SimDlgDll>
+          <SimDlgDllArguments>-pCM4</SimDlgDllArguments>
+          <TargetDllName>SARMCM3.DLL</TargetDllName>
+          <TargetDllArguments> -MPU</TargetDllArguments>
+          <TargetDlgDll>TCM.DLL</TargetDlgDll>
+          <TargetDlgDllArguments>-pCM4</TargetDlgDllArguments>
+        </DllOption>
+        <DebugOption>
+          <OPTHX>
+            <HexSelection>1</HexSelection>
+            <HexRangeLowAddress>0</HexRangeLowAddress>
+            <HexRangeHighAddress>0</HexRangeHighAddress>
+            <HexOffset>0</HexOffset>
+            <Oh166RecLen>16</Oh166RecLen>
+          </OPTHX>
+        </DebugOption>
+        <Utilities>
+          <Flash1>
+            <UseTargetDll>1</UseTargetDll>
+            <UseExternalTool>0</UseExternalTool>
+            <RunIndependent>0</RunIndependent>
+            <UpdateFlashBeforeDebugging>1</UpdateFlashBeforeDebugging>
+            <Capability>1</Capability>
+            <DriverSelection>4096</DriverSelection>
+          </Flash1>
+          <bUseTDR>1</bUseTDR>
+          <Flash2>BIN\UL2CM3.DLL</Flash2>
+          <Flash3></Flash3>
+          <Flash4></Flash4>
+          <pFcarmOut></pFcarmOut>
+          <pFcarmGrp></pFcarmGrp>
+          <pFcArmRoot></pFcArmRoot>
+          <FcArmLst>0</FcArmLst>
+        </Utilities>
+        <TargetArmAds>
+          <ArmAdsMisc>
+            <GenerateListings>0</GenerateListings>
+            <asHll>1</asHll>
+            <asAsm>1</asAsm>
+            <asMacX>1</asMacX>
+            <asSyms>1</asSyms>
+            <asFals>1</asFals>
+            <asDbgD>1</asDbgD>
+            <asForm>1</asForm>
+            <ldLst>0</ldLst>
+            <ldmm>1</ldmm>
+            <ldXref>1</ldXref>
+            <BigEnd>0</BigEnd>
+            <AdsALst>1</AdsALst>
+            <AdsACrf>1</AdsACrf>
+            <AdsANop>0</AdsANop>
+            <AdsANot>0</AdsANot>
+            <AdsLLst>1</AdsLLst>
+            <AdsLmap>1</AdsLmap>
+            <AdsLcgr>1</AdsLcgr>
+            <AdsLsym>1</AdsLsym>
+            <AdsLszi>1</AdsLszi>
+            <AdsLtoi>1</AdsLtoi>
+            <AdsLsun>1</AdsLsun>
+            <AdsLven>1</AdsLven>
+            <AdsLsxf>1</AdsLsxf>
+            <RvctClst>0</RvctClst>
+            <GenPPlst>0</GenPPlst>
+            <AdsCpuType>"Cortex-M4"</AdsCpuType>
+            <RvctDeviceName></RvctDeviceName>
+            <mOS>0</mOS>
+            <uocRom>0</uocRom>
+            <uocRam>0</uocRam>
+            <hadIROM>1</hadIROM>
+            <hadIRAM>1</hadIRAM>
+            <hadXRAM>0</hadXRAM>
+            <uocXRam>0</uocXRam>
+            <RvdsVP>2</RvdsVP>
+            <RvdsMve>0</RvdsMve>
+            <RvdsCdeCp>0</RvdsCdeCp>
+            <hadIRAM2>0</hadIRAM2>
+            <hadIROM2>0</hadIROM2>
+            <StupSel>8</StupSel>
+            <useUlib>1</useUlib>
+            <EndSel>0</EndSel>
+            <uLtcg>0</uLtcg>
+            <nSecure>0</nSecure>
+            <RoSelD>3</RoSelD>
+            <RwSelD>3</RwSelD>
+            <CodeSel>0</CodeSel>
+            <OptFeed>0</OptFeed>
+            <NoZi1>0</NoZi1>
+            <NoZi2>0</NoZi2>
+            <NoZi3>0</NoZi3>
+            <NoZi4>0</NoZi4>
+            <NoZi5>0</NoZi5>
+            <Ro1Chk>0</Ro1Chk>
+            <Ro2Chk>0</Ro2Chk>
+            <Ro3Chk>0</Ro3Chk>
+            <Ir1Chk>1</Ir1Chk>
+            <Ir2Chk>0</Ir2Chk>
+            <Ra1Chk>0</Ra1Chk>
+            <Ra2Chk>0</Ra2Chk>
+            <Ra3Chk>0</Ra3Chk>
+            <Im1Chk>1</Im1Chk>
+            <Im2Chk>0</Im2Chk>
+            <OnChipMemories>
+              <Ocm1>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </Ocm1>
+              <Ocm2>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </Ocm2>
+              <Ocm3>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </Ocm3>
+              <Ocm4>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </Ocm4>
+              <Ocm5>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </Ocm5>
+              <Ocm6>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </Ocm6>
+              <IRAM>
+                <Type>0</Type>
+                <StartAddress>0x20000000</StartAddress>
+                <Size>0x18000</Size>
+              </IRAM>
+              <IROM>
+                <Type>1</Type>
+                <StartAddress>0x8000000</StartAddress>
+                <Size>0x40000</Size>
+              </IROM>
+              <XRAM>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </XRAM>
+              <OCR_RVCT1>
+                <Type>1</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </OCR_RVCT1>
+              <OCR_RVCT2>
+                <Type>1</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </OCR_RVCT2>
+              <OCR_RVCT3>
+                <Type>1</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </OCR_RVCT3>
+              <OCR_RVCT4>
+                <Type>1</Type>
+                <StartAddress>0x8002000</StartAddress>
+                <Size>0x40000</Size>
+              </OCR_RVCT4>
+              <OCR_RVCT5>
+                <Type>1</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </OCR_RVCT5>
+              <OCR_RVCT6>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </OCR_RVCT6>
+              <OCR_RVCT7>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </OCR_RVCT7>
+              <OCR_RVCT8>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </OCR_RVCT8>
+              <OCR_RVCT9>
+                <Type>0</Type>
+                <StartAddress>0x20000000</StartAddress>
+                <Size>0x18000</Size>
+              </OCR_RVCT9>
+              <OCR_RVCT10>
+                <Type>0</Type>
+                <StartAddress>0x0</StartAddress>
+                <Size>0x0</Size>
+              </OCR_RVCT10>
+            </OnChipMemories>
+            <RvctStartVector></RvctStartVector>
+          </ArmAdsMisc>
+          <Cads>
+            <interw>1</interw>
+            <Optim>4</Optim>
+            <oTime>1</oTime>
+            <SplitLS>0</SplitLS>
+            <OneElfS>1</OneElfS>
+            <Strict>0</Strict>
+            <EnumInt>0</EnumInt>
+            <PlainCh>0</PlainCh>
+            <Ropi>0</Ropi>
+            <Rwpi>0</Rwpi>
+            <wLevel>2</wLevel>
+            <uThumb>0</uThumb>
+            <uSurpInc>0</uSurpInc>
+            <uC99>1</uC99>
+            <uGnu>1</uGnu>
+            <useXO>0</useXO>
+            <v6Lang>3</v6Lang>
+            <v6LangP>3</v6LangP>
+            <vShortEn>1</vShortEn>
+            <vShortWch>1</vShortWch>
+            <v6Lto>0</v6Lto>
+            <v6WtE>0</v6WtE>
+            <v6Rtti>0</v6Rtti>
+            <VariousControls>
+              <MiscControls>--gnu</MiscControls>
+              <Define>USE_STDPERIPH_DRIVER,GD32F30X_CL,CONFIG_BOARD_MC124,CONFIG_CAN_IAP</Define>
+              <Undefine></Undefine>
+              <IncludePath>..\Librarys\CMSIS\Include,..\Librarys\CMSIS\GD\GD32F30x\Include,..\Librarys\GD32F30x_Drivers\include,..\Applications;..\Simulink\PMSM_Controller_ert_rtw</IncludePath>
+            </VariousControls>
+          </Cads>
+          <Aads>
+            <interw>1</interw>
+            <Ropi>0</Ropi>
+            <Rwpi>0</Rwpi>
+            <thumb>0</thumb>
+            <SplitLS>0</SplitLS>
+            <SwStkChk>0</SwStkChk>
+            <NoWarn>0</NoWarn>
+            <uSurpInc>0</uSurpInc>
+            <useXO>0</useXO>
+            <ClangAsOpt>1</ClangAsOpt>
+            <VariousControls>
+              <MiscControls></MiscControls>
+              <Define></Define>
+              <Undefine></Undefine>
+              <IncludePath></IncludePath>
+            </VariousControls>
+          </Aads>
+          <LDads>
+            <umfTarg>1</umfTarg>
+            <Ropi>0</Ropi>
+            <Rwpi>0</Rwpi>
+            <noStLib>0</noStLib>
+            <RepFail>1</RepFail>
+            <useFile>0</useFile>
+            <TextAddressRange>0x08000000</TextAddressRange>
+            <DataAddressRange>0x20000000</DataAddressRange>
+            <pXoBase></pXoBase>
+            <ScatterFile></ScatterFile>
+            <IncludeLibs></IncludeLibs>
+            <IncludeLibsPath></IncludeLibsPath>
+            <Misc></Misc>
+            <LinkerInputFile></LinkerInputFile>
+            <DisabledWarnings></DisabledWarnings>
+          </LDads>
+        </TargetArmAds>
+      </TargetOption>
+      <Groups>
+        <Group>
+          <GroupName>Application</GroupName>
+          <Files>
+            <File>
+              <FileName>main.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\main.c</FilePath>
+            </File>
+            <File>
+              <FileName>app.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\app\app.c</FilePath>
+            </File>
+            <File>
+              <FileName>nv_storage.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\app\nv_storage.c</FilePath>
+            </File>
+            <File>
+              <FileName>factory.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\app\factory.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>Foc</GroupName>
+          <Files>
+            <File>
+              <FileName>commands.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\commands.c</FilePath>
+            </File>
+            <File>
+              <FileName>samples.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\samples.c</FilePath>
+            </File>
+            <File>
+              <FileName>svpwm.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\svpwm.c</FilePath>
+            </File>
+            <File>
+              <FileName>mc_error.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\mc_error.c</FilePath>
+            </File>
+            <File>
+              <FileName>limit.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\limit.c</FilePath>
+            </File>
+            <File>
+              <FileName>smo_observer.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\smo_observer.c</FilePath>
+            </File>
+            <File>
+              <FileName>foc_observer.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\foc_observer.c</FilePath>
+            </File>
+            <File>
+              <FileName>adrc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\adrc.c</FilePath>
+            </File>
+            <File>
+              <FileName>ladrc_observer.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\ladrc_observer.c</FilePath>
+            </File>
+            <File>
+              <FileName>F_Calc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\F_Calc.c</FilePath>
+            </File>
+            <File>
+              <FileName>etcs.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\etcs.c</FilePath>
+            </File>
+            <File>
+              <FileName>controller.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\controller.c</FilePath>
+            </File>
+            <File>
+              <FileName>foc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\core\foc.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>Motor</GroupName>
+          <Files>
+            <File>
+              <FileName>encoder.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\motor\encoder.c</FilePath>
+            </File>
+            <File>
+              <FileName>motor.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\motor\motor.c</FilePath>
+            </File>
+            <File>
+              <FileName>ntc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\ntc.c</FilePath>
+            </File>
+            <File>
+              <FileName>current_ics.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\motor\current_ics.c</FilePath>
+            </File>
+            <File>
+              <FileName>motor_param.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\motor\motor_param.c</FilePath>
+            </File>
+            <File>
+              <FileName>mot_params_ind.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\motor\mot_params_ind.c</FilePath>
+            </File>
+            <File>
+              <FileName>mc_config.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\mc_config.c</FilePath>
+            </File>
+            <File>
+              <FileName>throttle.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\foc\motor\throttle.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>Proto</GroupName>
+          <Files>
+            <File>
+              <FileName>can_message.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\prot\can_message.c</FilePath>
+            </File>
+            <File>
+              <FileName>can_pc_message.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\prot\can_pc_message.c</FilePath>
+            </File>
+            <File>
+              <FileName>can_foc_msg.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\prot\can_foc_msg.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>Math</GroupName>
+          <Files>
+            <File>
+              <FileName>fast_math.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\math\fast_math.c</FilePath>
+            </File>
+            <File>
+              <FileName>sin_table.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\math\sin_table.c</FilePath>
+            </File>
+            <File>
+              <FileName>arm_cortexM4lf_math.lib</FileName>
+              <FileType>4</FileType>
+              <FilePath>..\Applications\math\arm_cortexM4lf_math.lib</FilePath>
+            </File>
+            <File>
+              <FileName>Fir.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\math\Fir.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>BSP</GroupName>
+          <Files>
+            <File>
+              <FileName>adc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\adc.c</FilePath>
+            </File>
+            <File>
+              <FileName>bsp.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\bsp.c</FilePath>
+            </File>
+            <File>
+              <FileName>can.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\can.c</FilePath>
+            </File>
+            <File>
+              <FileName>enc_intf.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\enc_intf.c</FilePath>
+            </File>
+            <File>
+              <FileName>fan_pwm.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\fan_pwm.c</FilePath>
+            </File>
+            <File>
+              <FileName>fmc_flash.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\fmc_flash.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32_bkp.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\gd32_bkp.c</FilePath>
+            </File>
+            <File>
+              <FileName>gpio.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\gpio.c</FilePath>
+            </File>
+            <File>
+              <FileName>mc_irqs.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\mc_irqs.c</FilePath>
+            </File>
+            <File>
+              <FileName>pwm.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\pwm.c</FilePath>
+            </File>
+            <File>
+              <FileName>sched_timer.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\sched_timer.c</FilePath>
+            </File>
+            <File>
+              <FileName>uart.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\gd32\uart.c</FilePath>
+            </File>
+            <File>
+              <FileName>delay.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\bsp\delay.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>Libs</GroupName>
+          <Files>
+            <File>
+              <FileName>circle_buffer.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\libs\circle_buffer.c</FilePath>
+            </File>
+            <File>
+              <FileName>logger.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\libs\logger.c</FilePath>
+            </File>
+            <File>
+              <FileName>crc16.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\libs\crc16.c</FilePath>
+            </File>
+            <File>
+              <FileName>byte_queue.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\libs\byte_queue.c</FilePath>
+            </File>
+            <File>
+              <FileName>time_measure.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\libs\time_measure.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>OS</GroupName>
+          <Files>
+            <File>
+              <FileName>heap_4.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\os\heap_4.c</FilePath>
+            </File>
+            <File>
+              <FileName>queue.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\os\queue.c</FilePath>
+            </File>
+            <File>
+              <FileName>os_task.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Applications\os\os_task.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>GD32F30x_Drivers</GroupName>
+          <Files>
+            <File>
+              <FileName>gd32f30x_adc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_adc.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_bkp.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_bkp.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_can.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_can.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_dma.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_dma.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_exti.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_exti.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_fmc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_fmc.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_fwdgt.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_fwdgt.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_gpio.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_gpio.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_i2c.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_i2c.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_misc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_misc.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_rcu.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_rcu.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_rtc.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_rtc.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_timer.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_timer.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_usart.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_usart.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_pmu.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_pmu.c</FilePath>
+            </File>
+            <File>
+              <FileName>gd32f30x_dbg.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\GD32F30x_Drivers\source\gd32f30x_dbg.c</FilePath>
+            </File>
+          </Files>
+        </Group>
+        <Group>
+          <GroupName>StartUp</GroupName>
+          <Files>
+            <File>
+              <FileName>system_gd32f30x.c</FileName>
+              <FileType>1</FileType>
+              <FilePath>..\Librarys\CMSIS\GD\GD32F30x\Source\system_gd32f30x.c</FilePath>
+            </File>
+            <File>
+              <FileName>startup_gd32f30x_hd.s</FileName>
+              <FileType>2</FileType>
+              <FilePath>..\Librarys\CMSIS\GD\GD32F30x\Source\ARM\startup_gd32f30x_hd.s</FilePath>
+              <FileOption>
+                <CommonProperty>
+                  <UseCPPCompiler>2</UseCPPCompiler>
+                  <RVCTCodeConst>0</RVCTCodeConst>
+                  <RVCTZI>0</RVCTZI>
+                  <RVCTOtherData>0</RVCTOtherData>
+                  <ModuleSelection>0</ModuleSelection>
+                  <IncludeInBuild>0</IncludeInBuild>
+                  <AlwaysBuild>2</AlwaysBuild>
+                  <GenerateAssemblyFile>2</GenerateAssemblyFile>
+                  <AssembleAssemblyFile>2</AssembleAssemblyFile>
+                  <PublicsOnly>2</PublicsOnly>
+                  <StopOnExitCode>11</StopOnExitCode>
+                  <CustomArgument></CustomArgument>
+                  <IncludeLibraryModules></IncludeLibraryModules>
+                  <ComprImg>1</ComprImg>
+                </CommonProperty>
+                <FileArmAds>
+                  <Aads>
+                    <interw>2</interw>
+                    <Ropi>2</Ropi>
+                    <Rwpi>2</Rwpi>
+                    <thumb>2</thumb>
+                    <SplitLS>2</SplitLS>
+                    <SwStkChk>2</SwStkChk>
+                    <NoWarn>2</NoWarn>
+                    <uSurpInc>2</uSurpInc>
+                    <useXO>2</useXO>
+                    <ClangAsOpt>0</ClangAsOpt>
+                    <VariousControls>
+                      <MiscControls></MiscControls>
+                      <Define></Define>
+                      <Undefine></Undefine>
+                      <IncludePath></IncludePath>
+                    </VariousControls>
+                  </Aads>
+                </FileArmAds>
+              </FileOption>
+            </File>
+            <File>
+              <FileName>startup_gd32f30x_cl.s</FileName>
+              <FileType>2</FileType>
+              <FilePath>..\Librarys\CMSIS\GD\GD32F30x\Source\ARM\startup_gd32f30x_cl.s</FilePath>
+            </File>
+          </Files>
+        </Group>
+      </Groups>
+    </Target>
+  </Targets>
+
+  <RTE>
+    <apis/>
+    <components/>
+    <files/>
+  </RTE>
+
+  <LayerInfo>
+    <Layers>
+      <Layer>
+        <LayName>&lt;Project Info&gt;</LayName>
+        <LayDesc></LayDesc>
+        <LayUrl></LayUrl>
+        <LayKeys></LayKeys>
+        <LayCat></LayCat>
+        <LayLic></LayLic>
+        <LayTarg>0</LayTarg>
+        <LayPrjMark>1</LayPrjMark>
+      </Layer>
+    </Layers>
+  </LayerInfo>
+
+</Project>

+ 3 - 0
Project/version_mc124.cfg

@@ -0,0 +1,3 @@
+project: MC124
+version: 01
+debug: 0

+ 218 - 0
configs/autogen_config_servo.h

@@ -0,0 +1,218 @@
+/* auto gen 2023/10/12 9:52:09*/
+#ifndef _AUTOGEN_CONFIG_H__
+#define _AUTOGEN_CONFIG_H__
+
+#define CONFIG_Version 1
+#define CONFIG_Motor_Poles  4
+#define CONFIG_Motor_Ld  3.2E-05f
+#define CONFIG_Motor_Lq  7.3E-05f
+#define CONFIG_Motor_Rs  0.009f
+#define CONFIG_Motor_Flux  0.019f
+#define CONFIG_Motor_PLLBand  200
+#define CONFIG_Motor_EpmPLL  400
+#define CONFIG_Motor_PosPLL  500
+#define CONFIG_Motor_VehicleW  190
+#define CONFIG_Motor_WheelC  145
+#define CONFIG_Motor_GearRatio  6.25f
+#define CONFIG_Motor_MaxFwDCurr  100
+#define CONFIG_Motor_MaxTorque  200
+#define CONFIG_Motor_EncOffset  -103
+#define CONFIG_Foc_MaxDCVol  110
+#define CONFIG_Foc_MinDCVol  60
+#define CONFIG_Foc_MaxPhaseCurr  300
+#define CONFIG_Foc_MaxRPM  9000
+#define CONFIG_Foc_MaxEPMRPM  300
+#define CONFIG_Foc_MaxEPMTorque  100
+#define CONFIG_Foc_MaxEPMRPMBk  170
+#define CONFIG_Foc_MaxEPMTorqueBk  80
+#define CONFIG_Foc_MaxTorque  200
+#define CONFIG_Foc_MaxEbrkTorque  40
+#define CONFIG_Foc_MaxIDC  100
+#define CONFIG_Foc_MaxAutoHoldTorque  100
+#define CONFIG_Foc_ThroStartVol  0.85f
+#define CONFIG_Foc_ThroEndVol  4.15f
+#define CONFIG_Foc_ThroMinVol  0.4f
+#define CONFIG_Foc_ThroMaxVol  4.6f
+#define CONFIG_Foc_CurrCtrlBandWith  800
+#define CONFIG_Foc_ThroDecTime  10
+#define CONFIG_Foc_PID_VelLim_Kp 0.5f
+#define CONFIG_Foc_PID_VelLim_Ki 2.5f
+#define CONFIG_Foc_PID_VelLim_Kd 0
+#define CONFIG_Foc_PID_VelCtrl_Kp 0.1f
+#define CONFIG_Foc_PID_VelCtrl_Ki 3.5f
+#define CONFIG_Foc_PID_VelCtrl_Kd 0
+#define CONFIG_Foc_PID_Autohold_Kp 0.01f
+#define CONFIG_Foc_PID_Autohold_Ki 0.2f
+#define CONFIG_Foc_PID_Autohold_Kd 0
+#define CONFIG_Foc_PID_IDCLim_Kp 5
+#define CONFIG_Foc_PID_IDCLim_Ki 15
+#define CONFIG_Foc_PID_IDCLim_Kd 0
+#define CONFIG_Settings_AutoHold  1
+#define CONFIG_Settings_BrkShutPower  1
+#define CONFIG_Settings_TcsEnable  0
+#define CONFIG_Gear0_MaxSpeed 1000
+#define CONFIG_Gear0_MaxTorque 100
+#define CONFIG_Gear0_MaxIdc 30
+#define CONFIG_Gear0_ZeroAccl 500
+#define CONFIG_Gear0_NormalAccl 100
+#define CONFIG_Gear0_Torque0 100
+#define CONFIG_Gear0_Torque1 100
+#define CONFIG_Gear0_Torque2 100
+#define CONFIG_Gear0_Torque3 100
+#define CONFIG_Gear0_Torque4 100
+#define CONFIG_Gear0_Torque5 100
+#define CONFIG_Gear0_Torque6 100
+#define CONFIG_Gear0_Torque7 100
+#define CONFIG_Gear0_Torque8 0
+#define CONFIG_Gear0_Torque9 0
+#define CONFIG_Gear1_MaxSpeed 1000
+#define CONFIG_Gear1_MaxTorque 100
+#define CONFIG_Gear1_MaxIdc 30
+#define CONFIG_Gear1_ZeroAccl 500
+#define CONFIG_Gear1_NormalAccl 100
+#define CONFIG_Gear1_Torque0 100
+#define CONFIG_Gear1_Torque1 100
+#define CONFIG_Gear1_Torque2 100
+#define CONFIG_Gear1_Torque3 100
+#define CONFIG_Gear1_Torque4 100
+#define CONFIG_Gear1_Torque5 100
+#define CONFIG_Gear1_Torque6 100
+#define CONFIG_Gear1_Torque7 100
+#define CONFIG_Gear1_Torque8 0
+#define CONFIG_Gear1_Torque9 0
+#define CONFIG_Gear2_MaxSpeed 1000
+#define CONFIG_Gear2_MaxTorque 100
+#define CONFIG_Gear2_MaxIdc 30
+#define CONFIG_Gear2_ZeroAccl 500
+#define CONFIG_Gear2_NormalAccl 100
+#define CONFIG_Gear2_Torque0 100
+#define CONFIG_Gear2_Torque1 100
+#define CONFIG_Gear2_Torque2 100
+#define CONFIG_Gear2_Torque3 100
+#define CONFIG_Gear2_Torque4 100
+#define CONFIG_Gear2_Torque5 100
+#define CONFIG_Gear2_Torque6 100
+#define CONFIG_Gear2_Torque7 100
+#define CONFIG_Gear2_Torque8 0
+#define CONFIG_Gear2_Torque9 0
+#define CONFIG_Gear3_MaxSpeed 1000
+#define CONFIG_Gear3_MaxTorque 100
+#define CONFIG_Gear3_MaxIdc 30
+#define CONFIG_Gear3_ZeroAccl 500
+#define CONFIG_Gear3_NormalAccl 100
+#define CONFIG_Gear3_Torque0 100
+#define CONFIG_Gear3_Torque1 100
+#define CONFIG_Gear3_Torque2 100
+#define CONFIG_Gear3_Torque3 100
+#define CONFIG_Gear3_Torque4 100
+#define CONFIG_Gear3_Torque5 100
+#define CONFIG_Gear3_Torque6 100
+#define CONFIG_Gear3_Torque7 100
+#define CONFIG_Gear3_Torque8 0
+#define CONFIG_Gear3_Torque9 0
+#define CONFIG_GearLow0_MaxSpeed 1000
+#define CONFIG_GearLow0_MaxTorque 100
+#define CONFIG_GearLow0_MaxIdc 30
+#define CONFIG_GearLow0_ZeroAccl 500
+#define CONFIG_GearLow0_NormalAccl 100
+#define CONFIG_GearLow0_Torque0 100
+#define CONFIG_GearLow0_Torque1 100
+#define CONFIG_GearLow0_Torque2 100
+#define CONFIG_GearLow0_Torque3 100
+#define CONFIG_GearLow0_Torque4 100
+#define CONFIG_GearLow0_Torque5 100
+#define CONFIG_GearLow0_Torque6 100
+#define CONFIG_GearLow0_Torque7 100
+#define CONFIG_GearLow0_Torque8 0
+#define CONFIG_GearLow0_Torque9 0
+#define CONFIG_GearLow1_MaxSpeed 1000
+#define CONFIG_GearLow1_MaxTorque 100
+#define CONFIG_GearLow1_MaxIdc 30
+#define CONFIG_GearLow1_ZeroAccl 500
+#define CONFIG_GearLow1_NormalAccl 100
+#define CONFIG_GearLow1_Torque0 100
+#define CONFIG_GearLow1_Torque1 100
+#define CONFIG_GearLow1_Torque2 100
+#define CONFIG_GearLow1_Torque3 100
+#define CONFIG_GearLow1_Torque4 100
+#define CONFIG_GearLow1_Torque5 100
+#define CONFIG_GearLow1_Torque6 100
+#define CONFIG_GearLow1_Torque7 100
+#define CONFIG_GearLow1_Torque8 0
+#define CONFIG_GearLow1_Torque9 0
+#define CONFIG_GearLow2_MaxSpeed 1000
+#define CONFIG_GearLow2_MaxTorque 100
+#define CONFIG_GearLow2_MaxIdc 30
+#define CONFIG_GearLow2_ZeroAccl 500
+#define CONFIG_GearLow2_NormalAccl 100
+#define CONFIG_GearLow2_Torque0 100
+#define CONFIG_GearLow2_Torque1 100
+#define CONFIG_GearLow2_Torque2 100
+#define CONFIG_GearLow2_Torque3 100
+#define CONFIG_GearLow2_Torque4 100
+#define CONFIG_GearLow2_Torque5 100
+#define CONFIG_GearLow2_Torque6 100
+#define CONFIG_GearLow2_Torque7 100
+#define CONFIG_GearLow2_Torque8 0
+#define CONFIG_GearLow2_Torque9 0
+#define CONFIG_GearLow3_MaxSpeed 1000
+#define CONFIG_GearLow3_MaxTorque 100
+#define CONFIG_GearLow3_MaxIdc 30
+#define CONFIG_GearLow3_ZeroAccl 500
+#define CONFIG_GearLow3_NormalAccl 100
+#define CONFIG_GearLow3_Torque0 100
+#define CONFIG_GearLow3_Torque1 100
+#define CONFIG_GearLow3_Torque2 100
+#define CONFIG_GearLow3_Torque3 100
+#define CONFIG_GearLow3_Torque4 100
+#define CONFIG_GearLow3_Torque5 100
+#define CONFIG_GearLow3_Torque6 100
+#define CONFIG_GearLow3_Torque7 100
+#define CONFIG_GearLow3_Torque8 0
+#define CONFIG_GearLow3_Torque9 0
+#define CONFIG_Protect_Motor_Level0_Entry 130
+#define CONFIG_Protect_Motor_Level0_Exit 120
+#define CONFIG_Protect_Motor_Level0_Value 0
+#define CONFIG_Protect_Motor_Level1_Entry 120
+#define CONFIG_Protect_Motor_Level1_Exit 110
+#define CONFIG_Protect_Motor_Level1_Value 34
+#define CONFIG_Protect_Motor_Level2_Entry 110
+#define CONFIG_Protect_Motor_Level2_Exit 100
+#define CONFIG_Protect_Motor_Level2_Value 66
+#define CONFIG_Protect_MosFet_Level0_Entry 100
+#define CONFIG_Protect_MosFet_Level0_Exit 95
+#define CONFIG_Protect_MosFet_Level0_Value 0
+#define CONFIG_Protect_MosFet_Level1_Entry 95
+#define CONFIG_Protect_MosFet_Level1_Exit 90
+#define CONFIG_Protect_MosFet_Level1_Value 34
+#define CONFIG_Protect_MosFet_Level2_Entry 90
+#define CONFIG_Protect_MosFet_Level2_Exit 80
+#define CONFIG_Protect_MosFet_Level2_Value 66
+#define CONFIG_Protect_Voltage_Level0_Entry 60
+#define CONFIG_Protect_Voltage_Level0_Exit 70
+#define CONFIG_Protect_Voltage_Level0_Value 0
+#define CONFIG_EnergyRecovery_Level0_Torque 0
+#define CONFIG_EnergyRecovery_Level0_Time 1000
+#define CONFIG_EnergyRecovery_Level1_Torque 10
+#define CONFIG_EnergyRecovery_Level1_Time 500
+#define CONFIG_EnergyRecovery_Level2_Torque 15
+#define CONFIG_EnergyRecovery_Level2_Time 400
+#define CONFIG_EnergyRecovery_Level3_Torque 20
+#define CONFIG_EnergyRecovery_Level3_Time 300
+#define CONFIG_EnergyRecovery_Level4_Torque 35
+#define CONFIG_EnergyRecovery_Level4_Time 200
+#define CONFIG_EnergyRecovery_Level5_Torque 40
+#define CONFIG_EnergyRecovery_Level5_Time 200
+#define CONFIG_EnergyRecovery_Level6_Torque 40
+#define CONFIG_EnergyRecovery_Level6_Time 200
+#define CONFIG_EnergyRecovery_Level7_Torque 40
+#define CONFIG_EnergyRecovery_Level7_Time 200
+#define CONFIG_EnergyRecovery_Level8_Torque 40
+#define CONFIG_EnergyRecovery_Level8_Time 200
+#define CONFIG_EnergyRecovery_Level9_Torque 40
+#define CONFIG_EnergyRecovery_Level9_Time 200
+#define CONFIG_CrossZero_Low  1
+#define CONFIG_CrossZero_High  7
+#define CONFIG_CrossZero_MinStep  0.03f
+#define CONFIG_CrossZero_NorStep  5
+#endif /* _AUTOGEN_CONFIG_H__ */ 

+ 239 - 0
configs/mc_servo.yml

@@ -0,0 +1,239 @@
+##### 配置文件自动生成,不要手动修改!! 2023/10/12 14:29:02
+Version: 1
+CheckCrc: 0
+Motor:
+  Poles: 4
+  Ld: 3.2E-05
+  Lq: 7.3E-05
+  Rs: 0.009
+  Flux: 0.019
+  PLLBand: 200
+  EpmPLL: 400
+  PosPLL: 500
+  VehicleW: 190
+  WheelC: 145
+  GearRatio: 6.25
+  MaxFwDCurr: 100
+  MaxTorque: 300
+  EncOffset: -103
+Foc:
+  MaxDCVol: 110
+  MinDCVol: 60
+  MaxPhaseCurr: 300
+  MaxRPM: 9000
+  MaxEPMRPM: 300
+  MaxEPMTorque: 100
+  MaxEPMRPMBk: 170
+  MaxEPMTorqueBk: 80
+  MaxTorque: 300
+  MaxEbrkTorque: 40
+  MaxIDC: 100
+  MaxAutoHoldTorque: 100
+  ThroStartVol: 0.85
+  ThroEndVol: 4.15
+  ThroMinVol: 0.4
+  ThroMaxVol: 4.6
+  CurrCtrlBandWith: 800
+  ThroDecTime: 10
+  PID:
+    VelLim:
+      Kp: 0.5
+      Ki: 2.5
+      Kd: 0
+    VelCtrl:
+      Kp: 0.1
+      Ki: 3.5
+      Kd: 0
+    Autohold:
+      Kp: 0.01
+      Ki: 0.2
+      Kd: 0
+    IDCLim:
+      Kp: 5
+      Ki: 15
+      Kd: 0
+Settings:
+  AutoHold: 1
+  BrkShutPower: 1
+  TcsEnable: 0
+Gear:
+- MaxSpeed: 1000
+  MaxTorque: 100
+  MaxIdc: 30
+  ZeroAccl: 500
+  NormalAccl: 100
+  Torque:
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 0
+  - 0
+- MaxSpeed: 1000
+  MaxTorque: 100
+  MaxIdc: 30
+  ZeroAccl: 500
+  NormalAccl: 100
+  Torque:
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 0
+  - 0
+- MaxSpeed: 1000
+  MaxTorque: 100
+  MaxIdc: 30
+  ZeroAccl: 500
+  NormalAccl: 100
+  Torque:
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 0
+  - 0
+- MaxSpeed: 1000
+  MaxTorque: 100
+  MaxIdc: 30
+  ZeroAccl: 500
+  NormalAccl: 100
+  Torque:
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 0
+  - 0
+GearLow:
+- MaxSpeed: 1000
+  MaxTorque: 100
+  MaxIdc: 30
+  ZeroAccl: 500
+  NormalAccl: 100
+  Torque:
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 0
+  - 0
+- MaxSpeed: 1000
+  MaxTorque: 100
+  MaxIdc: 30
+  ZeroAccl: 500
+  NormalAccl: 100
+  Torque:
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 0
+  - 0
+- MaxSpeed: 1000
+  MaxTorque: 100
+  MaxIdc: 30
+  ZeroAccl: 500
+  NormalAccl: 100
+  Torque:
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 0
+  - 0
+- MaxSpeed: 1000
+  MaxTorque: 100
+  MaxIdc: 30
+  ZeroAccl: 500
+  NormalAccl: 100
+  Torque:
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 100
+  - 0
+  - 0
+Protect:
+  Motor:
+  - Entry: 130
+    Exit: 120
+    Value: 0
+  - Entry: 120
+    Exit: 110
+    Value: 34
+  - Entry: 110
+    Exit: 100
+    Value: 66
+  MosFet:
+  - Entry: 100
+    Exit: 95
+    Value: 0
+  - Entry: 95
+    Exit: 90
+    Value: 34
+  - Entry: 90
+    Exit: 80
+    Value: 66
+  Voltage:
+  - Entry: 60
+    Exit: 70
+    Value: 0
+EnergyRecovery:
+- Torque: 0
+  Time: 1000
+- Torque: 10
+  Time: 500
+- Torque: 15
+  Time: 400
+- Torque: 20
+  Time: 300
+- Torque: 35
+  Time: 200
+- Torque: 40
+  Time: 200
+- Torque: 40
+  Time: 200
+- Torque: 40
+  Time: 200
+- Torque: 40
+  Time: 200
+- Torque: 40
+  Time: 200
+CrossZero:
+  Low: 1
+  High: 7
+  MinStep: 5
+  NorStep: 5

+ 0 - 0
mc_config.yml → configs/mc_zd100.yml