V1.007.SJ
1.修复下行网口的MAC获取
2.增加232回显
This commit is contained in:
2026-09-21 11:22:47 +08:00
parent ac9199b926
commit 50de2b5e41
7 changed files with 1669 additions and 1635 deletions
+1593 -1590
View File
File diff suppressed because it is too large Load Diff
+59 -41
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -135,7 +135,7 @@
<SetRegEntry>
<Number>0</Number>
<Key>JL2CM3</Key>
<Name>-U602713110 -O78 -S2 -ZTIFSpeedSel5000 -A0 -C0 -JU1 -JI127.0.0.1 -JP0 -RST0 -N00("ARM CoreSight SW-DP") -D00(1BA01477) -L00(0) -TO18 -TC10000000 -TP21 -TDS8007 -TDT0 -TDC1F -TIEFFFFFFFF -TIP8 -TB1 -TFE0 -FO15 -FD20000000 -FC1000 -FN1 -FF0STM32F10x_128.FLM -FS08000000 -FL020000 -FP0($$Device:STM32F103CB$Flash\STM32F10x_128.FLM)</Name>
<Name>-U602713110 -O78 -S2 -ZTIFSpeedSel5000 -A0 -C0 -JU1 -JI127.0.0.1 -JP0 -RST0 -N00("ARM CoreSight SW-DP") -D00(2BA01477) -L00(0) -TO18 -TC10000000 -TP21 -TDS8007 -TDT0 -TDC1F -TIEFFFFFFFF -TIP8 -TB1 -TFE0 -FO15 -FD20000000 -FC1000 -FN1 -FF0STM32F10x_128.FLM -FS08000000 -FL020000 -FP0($$Device:STM32F103CB$Flash\STM32F10x_128.FLM)</Name>
</SetRegEntry>
<SetRegEntry>
<Number>0</Number>
Binary file not shown.
+1 -1
View File
@@ -18,7 +18,7 @@
#include "proto_modbus_tcp_master.h"
const char *HwVersion = "V2.2";
char SwVersion[24] = "SECS2 V2.2-V1.006.SJ";
char SwVersion[24] = "SECS2 V2.2-V1.007.SJ";
void TASK_Idle(void);
void Task_10ms(void);
void Task_50ms(void);
+2 -2
View File
@@ -502,8 +502,8 @@ static void W5500_Init(void)
//使用单片机UID
uid[0] = *(u32*)(STM32F1_UID_BASE);
uid[1] = *(u32*)(STM32F1_UID_BASE + 4 +1);
uid[2] = *(u32*)(STM32F1_UID_BASE + 8 +1);
uid[1] = (*(u32*)(STM32F1_UID_BASE + 4) +1);
uid[2] = (*(u32*)(STM32F1_UID_BASE + 8) +1);
pW5500_1->Phy_Addr[0] = uid[1] >> 8;
+13
View File
@@ -24,6 +24,7 @@ static void proto_Modbus_Init(void);
static void proto_Modbus_Task(void);
static ModbusErrorCode_e ModbusCommunicationDataWrite(u16 Addr, u16 Value);
static u16 ModbusCommunicationDataRead(u16 Addr);
static void echo_uart_rx(u8 *pData, u16 Len, void *other_data);
proto_Modbus_t Para_Modbus=
{
@@ -54,11 +55,23 @@ static void proto_Modbus_Init(void)
{
COM_Uart1.Rx_DataAnalysis = ModbusCommunicationDataReceive;
COM_Uart2.Rx_DataAnalysis = ModbusCommunicationDataReceive;
COM_Uart3.Rx_DataAnalysis = echo_uart_rx;
}
static void proto_Modbus_Task(void)
{
}
/*232串口的回显*/
static void echo_uart_rx(u8 *pData, u16 Len, void *other_data)
{
bsp_Uart_t *pUart = (bsp_Uart_t*)other_data;
if (!pUart || !pData || Len == 0) return;
// 非 Modbus 数据,原样回显
pUart->Send(pUart, pData, Len);
}
static void ModbusCommunicationDataReceive(u8 *pData, u16 len,void *other_data)
{
ModbusErrorCode_e ErrorCode;