yincheng.zhong
2023-05-05 737a981dc473a1e6018bd7e0db35fee69e5b3b01
源码/核心板/Src/main.c
@@ -100,7 +100,8 @@
      {dist_threshold = 15000;}
}
u16 JDQ_time;
int16_t g_commap_antdelay;
int16_t g_commap_antdelay,alarm_angle;
extern uint16_t samegroup_ancid,anc_mount_dist;
void Program_Init(void)
{   float temp;
   u16 temp2;
@@ -141,11 +142,13 @@
//      g_com_map[FILTER_COEFFICIENT]=40;
//        g_com_map[ANT_LENGTH]=0;
//        g_com_map[NOMOVESLEEP_TIME]=728;
    samegroup_ancid = g_com_map[MODBUS_ID2]; //鍚岀粍鍩虹珯ID
    anc_mount_dist = g_com_map[MODBUS_ID3];  //鍩虹珯瀹夎璺濈
    alarm_angle = g_com_map[MODBUS_ID4];    //鍩虹珯鎶ヨ瑙掑害
        
   OUT485_ENABLE;
      
   g_com_map[VERSION] = (1<<8)|(70);
   g_com_map[VERSION] = (1<<8)|(71);
   FLASH_Read(FLASH_HARDWARE_FLAG, (uint8_t*)&g_com_map[HARDWAREFLAG_INDEX], 16);
   dist_threshold = (g_com_map[SPEEDFILTER_THRES]*10)/(1000/g_com_map[COM_INTERVAL]);
   g_commap_antdelay = g_com_map[ANT_LENGTH];