From 5ac1d0febb8de5e91ce2463baea68ddac3f66091 Mon Sep 17 00:00:00 2001
From: jinlicong <493886250@qq.com>
Date: Thu, 16 May 2024 20:00:17 +0800
Subject: [PATCH] 完善脉冲计费和485采集处理
---
Soft/system_general_para.h | 49 +++++++++++++++++++++++++++++++------------------
1 files changed, 31 insertions(+), 18 deletions(-)
diff --git a/Soft/system_general_para.h b/Soft/system_general_para.h
index 5a0042d..014e027 100644
--- a/Soft/system_general_para.h
+++ b/Soft/system_general_para.h
@@ -1,6 +1,7 @@
#ifndef _SYSTEM_GENERAL_PARA_H
#define _SYSTEM_GENERAL_PARA_H
#include "define_all.h"
+#include "extern_rtc.h"
/**************************************************
*��Ҫ����һЩͨ�õĺ���������
@@ -82,6 +83,17 @@
} PARITY_BIT; //������
+typedef enum
+{
+ RS485_START_REASON_NONE = 0U, //����������Ҫִ��
+ RS485_START_REASON_KEY , //����
+ RS485_START_REASON_TIMING, //��ʱ
+ RS485_START_REASON_REPORT, //ʵʱ�ϱ���Ҫ
+ RS485_START_REASON_RECORD, //�����¼��Ҫ���������ϱ���������
+
+} RS485_START_REASON; //485����ԭ��
+
+
/*****************ͨ�ýṹ�����******************************/
typedef struct
{
@@ -100,8 +112,20 @@
+typedef struct
+{
+ __IO FlagStatus start_flag; // ����������־
+ __IO FlagStatus running_flag; // ���������б�־
+} FUN_START_CTRL_T; // ��ʱʱ�����ͽṹ��
+typedef struct
+{
+ FUN_START_CTRL_T rs485_ctrl_flag;
+ FUN_START_CTRL_T wrc_ctrl_flag;
+ FUN_START_CTRL_T valve_ctrl_flag;
+
+} FUN_START_CTRL_PARA_T; // ��ʱʱ�����ͽṹ��
/*****************ͨ�ú�******************************/
@@ -154,16 +178,6 @@
-
-
-
-
-
-
-
-
-
-
//��־���в���
typedef struct log_sizhu_run_t
{
@@ -177,18 +191,13 @@
-
-
-
-
-
//extern uint8_t read_data_buf_A_l[200];
//extern uint8_t read_data_buf_B_l[200];
//extern uint8_t read_data_buf_C_l[200];
extern __IO FlagStatus sys_run_period; // ϵͳ��������
-extern SYS_DELAY_SEC_PARA_T sys_delay_sec_para_g;
-
+extern SYS_DELAY_SEC_PARA_T sys_delay_sec_para_g; //ϵͳ��ʱ����
+extern FUN_START_CTRL_PARA_T sys_fun_run_ctrl_g; //ϵͳ�������п���
@@ -198,7 +207,7 @@
-int mem_cmp_aray( const void * cs, const void * ct, u32 count );
+//int mem_cmp_aray( const void * cs, const void * ct, u32 count );
uint8_t TwoTimeCompara(uint8_t* TimeBCD1, uint8_t* TimeBCD2);//6�ֽ�BCDʱ���뵱ǰʱ��Ƚϣ���ǰʱ���0����ȷ���1����ǰʱ��С����2�� ���⣬������ʱ���ʽ��ЧҲ����0������������
@@ -206,5 +215,9 @@
//unsigned char HEX2BCD(unsigned char hex_data) ; //HEX??BCD???
void dou26Byte( double data, unsigned char *array );
+FlagStatus IntervalTriggerHandle(sClockBCD sys_clockBCD_in,uint16_t IntervalTime,uint8_t IntervalFirstTimeBCD[2]);
+
+FlagStatus IO_JitterEliminationCheck(GPIO_Type* GPIOx, uint32_t GPIO_Pin,uint16_t delay_time_ms,BitAction bit_status);
+
#endif
--
Gitblit v1.9.3