首页 > 其他分享 >CH9120网口配置协商及说明

CH9120网口配置协商及说明

时间:2024-04-13 11:11:41浏览次数:30  
标签:00 01 UCHAR 协商 43 网口 模块 串口 CH9120

 

目录

(1)结构体定义

(2)通信流程详解

  1.通信方式

  2.通信结构体

  3.通信过程

    ①搜索

    ②获取配置

    ③配置模块

    ④恢复出厂设置

(3)说明文档连接

 

CH9120上位机搜索配置协议

(1)结构体定义

 1 #define MAX_DEVICE_CNT                    2000                //最大搜索设备数
 2 #define NET_MODULE_DATA_LENGTH            255                  //与模块通信时数据区的最大长度
 3 #define MODULE_DEFAULT_CONFIG_PORT        50000              //默认的配置端口
 4 #define LOCAL_PORT                        60000              //默认本地配置端口
 5 
 6 //通信命令码
 7 #define NET_MODULE_CMD_SET            0X01                  //配置网络中的模块
 8 #define NET_MODULE_CMD_GET            0X02                  //获取某个模块的配置
 9 #define NET_MODULE_CMD_RESET        0x03                  //复位模块
10 #define NET_MODULE_CMD_SEARCH        0X04                  //搜索网络中的模块
11 
12 //应答命令码
13 #define NET_MODULE_ACK_SET            0X81                  //回应配置命令码
14 #define NET_MODULE_ACK_GET            0X82                  //回应获取命令码
15 #define NET_MODULE_ACK_RESEST        0X83                  //回应复位命令码
16 #define NET_MODULE_ACK_SEARCH        0X84                  //回应所搜命令码
17 
18 #define CH9120_CFG_FLAG                "CH9120_CFG_FLAG"      //用来标识通信_new
19 typedef struct _DEVICEHW_CONFIG
20 {
21     UCHAR  bDevType;                    /* 设备类型*/
22     UCHAR  bAuxDevType;                    /* 设备子类型 */
23     UCHAR  bIndex;                        /* 设备序号 */
24     UCHAR  bDevHardwareVer;                /* 设备硬件版本号 */    
25     UCHAR  bDevSoftwareVer;                /* 设备软件版本号 */    
26     UCHAR  szModulename[21];            /* 模块名*/
27     UCHAR  bDevMAC[ 6 ];                /* 模块网络MAC地址 */    
28     UCHAR  bDevIP[ 4 ];                    /* 模块IP地址*/
29     UCHAR  bDevGWIP[ 4 ];                /* 模块网关IP */
30     UCHAR  bDevIPMask[ 4 ];                /* 模块子网掩码 */
31     UCHAR  bDhcpEnable;                    /* DHCP 使能,是否启用DHCP,1:启用,0:不启用*/
32     USHORT wWebPort;                    /* WEB网页地址 */                  
33     UCHAR  szUsername[8];                /* 用户名同模块名*/                 
34     UCHAR  bPassWordEn;                    /*密码使能 1:使能 0: 禁用*/          
35     UCHAR  szPassWord[8];                /* 密码*/                      
36     UCHAR  bUpdateFlag;                    /* 固件升级标志,1:升级 0:不升级*/       
37     UCHAR  bComcfgEn;                    /*串口协商进入配置模式使能,1:使能 0:不使能 */
38     UCHAR  breserved[8];                /* 保留*/
39 }DeviceHWConfigS,*pDeviceHWConfigS;
40 
41 typedef struct _DEVICEPORT_CONFIG
42 {
43     UCHAR  bIndex;                     /* 端口序号 */
44     UCHAR  bPortEn;                    /* 端口启用标志 1:启用后 ;0:不启用 */
45     UCHAR  bNetMode;                /* 网络工作模式: 0: TCP SERVER;1: TCP CLENT; 2: UDP SERVER 3:UDP CLIENT; */
46     UCHAR  bRandSportFlag;            /* TCP 客户端模式下随即本地端口号,1:随机 0: 不随机*/
47     USHORT wNetPort;                /* 网络通讯端口号 */    
48     UCHAR  bDesIP[ 4 ];                /* 目的IP地址 */
49     USHORT wDesPort;                /* 工作于TCP Server模式时,允许外部连接的端口号 */
50     ULONG  dBaudRate;                /* 串口波特率: 300---921600bps */
51     UCHAR  bDataSize;                /* 串口数据位: 5---8位 */    
52     UCHAR  bStopBits;                /* 串口停止位: 1表示1个停止位; 2表示2个停止位 */    
53     UCHAR  bParity;                    /* 串口校验位: 0表示奇校验; 1表示偶校验; 2表示标志位(MARK,置1); 3表示空白位(SPACE,清0);4为无校验  */        
54     UCHAR  bPHYChangeHandle;        /* PHY断开,Socket动作,1:关闭Socket 2、不动作*/
55     ULONG  dRxPktlength;            /* 串口RX数据打包长度,最大1024 */
56     ULONG  dRxPktTimeout;            /* 串口RX数据打包转发的最大等待时间,单位为: 10ms,0则表示关闭超时功能 */
57     UCHAR  bReConnectCnt;            /* 工作于TCP CLIENT时,连接TCP SERVER的最大重试次数*/    
58     UCHAR  bResetCtrl;                /* 串口复位操作: 0表示不清空串口数据缓冲区; 1表示连接时清空串口数据缓冲区 */    
59     UCHAR  bDNSFlag;                /* 域名功能启用标志,1:启用 2:不启用*/
60     UCHAR  szDomainname[20];        /* 域名*/
61     UCHAR  bDNSHostIP[4];            /* DNS 主机*/
62     USHORT wDNSHostPort;            /* DNS 端口*/
63     UCHAR  breserved[8];            /* 保留*/
64 }DevicePortConfigS,*pDevicePortConfigS;

(2)通信流程详解

1.通讯方式
CH9120 通过 UDP 广播方式进行网络配置功能。

CH9120以60000端口向50000端口下发广播数据,模块以50000端口向60000端口回传数据

2.通讯结构体

 1 //网络通信结构体
 2 typedef struct NET_COMM {
 3     unsigned char flag[16];                                  //通信标识,因为都是用广播方式进行通信的,所以这里加一个固定值
 4     unsigned char cmd;                                      //命令头
 5     unsigned char id[6];                                    //目标模块mac地址
 6     unsigned char cfg_mac[6];                                //配置软件端的MAC
 7     unsigned char len;                                      //数据区长度
 8     unsigned char data[NET_MODULE_DATA_LENGTH];              //数据区缓冲区
 9 }net_comm,*pnet_comm;
10 
11 //模块的配置结构
12 #pragma pack(1)
13 //模块MAC\IP结构体
14 typedef struct _Mod_MacIP{
15     unsigned char mod_ip[4];
16     unsigned char mod_mac[6];
17     unsigned char mod_name[21];
18     unsigned char mod_ver;
19 }Mod_MacIP,pMod_MacIP; 
20 
21 typedef struct _NET_DEVICE_CONFIG
22 {   
23     DeviceHWConfigS     HWCfg;                 /*从硬件处获取的配置信息*/
24     DevicePortConfigS   PortCfg[2];          /*网络设备所包含的子设备的配置信息*/
25 }NetDeviceConfigS,*pNetDeviceConfigS;

3.通讯过程

  CH9120上位机配置功能主要包括:①搜索,②获取配置,③配置网络参数,④恢复出厂设置。

  下面结合通讯过程中的数据包解析设置流程。(wireshark抓包可以抓取到数据包)

①搜索

-->PC下发的搜索包:

43 48 39 31 32 30 5f 43 46 47 5f 46 4c 41 47 00   //固定16字节通信标识
04                        //通信命令码,04为 搜索网络中的模块
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00

<--9121回复的应答包:

43 48 39 31 32 30 5f 43 46 47 5f 46 4c 41 47 00
84                         //回应所搜命令码
38 3b 26 60 00 1f                     //模块mac地址
00 00 00 00 00 00
0b                         //数据长度(IP+设备名总长)
c0 a8 03 c8                     //模块IP
43 48 39 31 32 30 00                //模块设备名(最大21字节)
0f                          //模块固件版本号
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00

②获取配置

-->PC下发的获取配置请求包

43 48 39 31 32 30 5f 43 46 47 5f 46 4c 41 47 00
02                          //获取某个模块的配置
38 3b 26 60 00 1f                    //模块mac地址
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00

<--9121的应答包:

43 48 39 31 32 30 5f 43 46 47 5f 46 4c 41 47 00
82                                //回应获取命令码
38 3b 26 60 00 1f                          //模块mac
00 00 00 00 00 00
cc                                //数据总长(从下一个数据为开始,不包括最后51固定字节)
21                          /* 设备类型 */
21                          /* 设备子类型 */
01                          /* 设备序号 */
02                          /* 设备硬件版本号 */
03                          /* 设备软件版本号 */
43 48 39 31 32 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00      /* 模块名,21字节*/
38 3b 26 60 00 1f                    /* 模块网络MAC地址 */
c0 a8 01 c8                      /* 模块IP地址*/
c0 a8 01 01                      /* 模块网关IP */
ff ff ff 00                       /* 模块子网掩码 */
00                          /* DHCP 使能,是否启用DHCP,1:启用,0:不启用*/
50 00                          /* WEB网页地址 */
61 64 6d 69 6e 00 00 00                 /* 用户名同模块名*/  (恢复出厂设置后默认为该数据,正常设置时为00即可)
00                          /*密码使能 1:使能 0: 禁用*/
08 08 08 08 08 08 08 08                 /* 密码*/        (恢复出厂设置后默认为该数据,正常设置时为00即可)
ff                            /* 固件升级标志,1:升级 0:不升级*/
00                          /*串口协商进入配置模式使能,1:使能 0:不使能 */
00 00 00 00 00 00 00 00                 /* 保留*/
/*************************************************端口0设置*************************************************/
00                          /* 端口序号 */
00                          /* 端口启用标志 1:启用 ;0:不启用 */
02                          /* 网络工作模式: 0: TCP SERVER;1: TCP CLENT; 2: UDP SERVER 3:UDP CLIENT; */
01                          /* TCP 客户端模式下随即本地端口号,1:随机 0: 不随机*/
b8 0b                          /* 网络通讯端口号 */ 固定
c0 a8 01 64                      /* 目的IP地址 */
d0 07                           /* 目的端口 */···························固定
80 25 00 00                         /* 串口波特率: 300---921600bps */
08                           /* 串口数据位 */
01                                /* 串口停止位 */
04                           /* 串口校验位 */
01                           /* PHY断开,Socket动作,1:关闭Socket 2、不动作*/
00 02 00 00                         /* 串口RX数据打包长度,最大1024 */
00 00 00 00                         /* 串口RX数据打包转发的最大等待时间,单位为: 10ms,0则表示关闭超时功能 */
00                           /* 工作于TCP CLIENT时,连接TCP SERVER的最大重试次数*/
00                           /* 串口复位操作: 0表示不清空串口数据缓冲区; 1表示连接时清空串口数据缓冲区 */
00                           /* 域名功能启用标志,1:启用 2:不启用*/
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00       /* 域名*/
00 00 00 00                      /* DNS 主机*/
00 00                        /* DNS 端口*/
00 00 00 00 00 00 00 00                  /* 保留*/
/*************************************************端口1设置************************************************/(CH9120只有一个端口,默认用端口1)
01                          /* 端口序号 */
01                          /* 端口启用标志 1:启用 ;0:不启用 */
01                          /* 网络工作模式: 0: TCP SERVER;1: TCP CLENT; 2: UDP SERVER 3:UDP CLIENT; */
01                          /* TCP 客户端模式下随即本地端口号,1:随机 0: 不随机*/
d0 07                             /* 源端口号 */
c0 a8 01 64                      /* 目的IP地址 */
e8 03                             /* 目的端口 */
80 25 00 00                      /* 串口波特率: 300---921600bps */
08                          /* 串口数据位 */
01                          /* 串口停止位 */
04                          /* 串口校验位 */
01                          /* PHY断开,Socket动作,1:关闭Socket 2、不动作*/
00 02 00 00                      /* 串口RX数据打包长度,最大1024 */
00 00 00 00                      /* 串口RX数据打包转发的最大等待时间,单位为: 10ms,0则表示关闭超时功能 */
00                                /* 工作于TCP CLIENT时,连接TCP SERVER的最大重试次数*/
00                          /* 串口复位操作: 0表示不清空串口数据缓冲区; 1表示连接时清空串口数据缓冲区 */
00                          /* 域名功能启用标志,1:启用 2:不启用*/
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00      /* 域名*/
00 00 00 00                     /* DNS 主机*/
00 00                          /* DNS 端口*/
00 00 00 00 00 00 00 00                 /* 保留*/

55 aa 00 00 00 00 00 00 00 00 00 00 00 00 00 00     //51字节
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00   

 ③进行网络参数配置

-->PC机下发的恢复出厂请求包:

43 48 39 31 32 30 5f 43 46 47 5f 46 4c 41 47 00
01                                  //配置网络中的模块
38 3b 26 60 00 1f
00 e0 4c 36 3c ec
cc
21
21
01
02
03
43 48 39 31 32 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
38 3b 26 60 00 1f
c0 a8 01 c8
c0 a8 01 01
ff ff ff 00
00
50 00
00 00 00 00 00 00 00 00
00
00 00 00 00 00 00 00 00
ff
00
00 00 00 00 00 00 00 00
/***********************************************配置解析同上,不多赘述
00
00
02
01
b8 0b
c0 a8 01 64
d0 07
80 25 00 00
08
01
04
01
00 02 00 00
00 00 00 00
00
00
00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00
00 00
00 00 00 00 00 00 00 00

01
01
01
00
88 13
c0 a8 01 64
88 13
80 25 00 00
08
01
04
01
00 02 00 00
00 00 00 00
00
00
00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00
00 00
00 00 00 00 00 00 00 00

00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00

<--9121应答包

43 48 39 31 32 30 5f 43 46 47 5f 46 4c 41 47 00
81                            //回应配置命令码
38 3b 26 60 00 1f
00 e0 4c 36 3c ec
00                               
21
21
01
02
03
43 48 39 31 32 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
38 3b 26 60 00 1f
c0 a8 01 c8
c0 a8 01 01
ff ff ff 00
00
50 00
00 00 00 00 00 00 00 00
00
00 00 00 00 00 00 00 00
ff
00
00 00 00 00 00 00 00 00

00
00
02
01
b8 0b
c0 a8 01 64
d0 07
80 25 00 00
08
01
04
01
00 02 00 00
00 00 00 00
00
00
00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00
00 00
00 00 00 00 00 00 00 00

01
01
01
00
88 13
c0 a8 01 64
88 13
80 25 00 00
08
01
04
01
00 02 00 00
00 00 00 00
00
00
00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00
00 00
00 00 00 00 00 00 00 00

00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 

④恢复出厂设置

-->PC机下发的恢复出厂请求包:

43 48 39 31 32 30 5f 43 46 47 5f 46 4c 41 47 00
03                            //复位模块
38 3b 26 60 00 1f                      //模块mac地址
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00

<--9121应答包

43 48 39 31 32 30 5f 43 46 47 5f 46 4c 41 47 00
83                                  //回应复位命令码
38 3b 26 60 00 1f                  //模块mac地址
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00


协议文档:https://files.cnblogs.com/files/blogs/808422/NetModCfgDemo_CH9120.zip?t=1712976869&download=true

CH9121流程及数据包解析可参考随笔:CH9121网口配置协议及说明

标签:00,01,UCHAR,协商,43,网口,模块,串口,CH9120
From: https://www.cnblogs.com/wchwchlq/p/18124368

相关文章

  • 通过IKE协商方式建立IPSec隧道示例
    通过IKE协商方式建立IPSec隧道示例一、组网需求如图所示,HX为企业分支网关,GY为企业总部网关,分支与总部通过公网建立通信。分支子网为10.1.2.0/24,总部子网为10.1.1.0/24。GY和HX两个站点用户均可以正常访问互联网2.2.2.2。企业希望对分支子网与总部子网之间相互访问的流量进行安......
  • HTTP的强制缓存和协商缓存
    HTTP的强制缓存和协商缓存HTTP的缓存技术强制缓存ExpiresCache-Control协商缓存If-Modified-Since和Last-ModifiedIf-None-Match和ETag优先级可被缓存的请求方法总结HTTP的缓存技术  当我们进行HTTP请求时,需要将请求报文发送给对端,当服务端收到请求后会做出合适......
  • 【HTTP完全注解】内容协商
    内容协商在HTTP协议中,内容协商是一种用于为同一URI提供资源不同的表示形式(如语言、字符集、媒体类型等)的机制,该机制能够让用户获得最合适的资源表现内容。例如对于中文用户请求某一URI内容,服务器将返回该资源的中文形式;而英语用户请求同一资源时,则会返回该资源的英文形式......
  • CH9126网口配置协议及说明
    目录1.CH9126简介及应用特点2.通信相关结构体定义3.通信流程解析3.1搜索设备3.2恢复出厂设置3.3获取设备配置3.4配置设备本文通过wireshark抓包分析了官方配套CH9126搜索上位机软件的底层通信,简单分析了搜索,恢复出厂,配置,获取配置这四个操作。1.CH9126---......
  • CH9120 TFTP使用详解
    一、TFTP简介:TFTP是基于UDP应用层的简单的文件传输协议,端口号为69,TFTP协议主要应用于网络引导、配置文件传输等场景。二、报文介绍:TFTP有四种数据包格式,分别是读/写请求包、文件数据包、回应包和错误信息包。读/写请求包操作码,它的值为1表示读操作,2表示写操作;文件名,它是一......
  • 5G穿墙王!TP-LINK发布BE5100 Wi-Fi 7路由器:2.5G网口 279元
    1月14日消息,日前,TP-LINK发布BE5100Wi-Fi7路由器,到手价279元,支持MLO、4KQAM、MRU、前导打孔等Wi-Fi7新特性。据介绍,在MLO多链路技术加持下,2.4G+5G叠加快至7.3倍,4KQAM高阶调制,速率提升至120%。MRU技术允许将多个资源块分配给单个用户,提升传输效率,降低延迟。TP-LINKBE5100还是“......
  • 中断机制之中断协商案例深度解析 上
    说明具体来说,当一个线程调用interrupt()时:如果线程处于正常活动状态,那么会将该线程的中断标志设置为true,仅此而已。被设置中断标志的线程将继续正常运行,不受影响。所以,innerupt()并不能真正的中断线程,需要被调用的线程自己进行配合才行。如果线程处于被阻塞状态(例如处于sl......
  • 5G穿墙王!TP-LINK发布BE5100 Wi-Fi 7路由器:2.5G网口 279元
    1月14日消息,日前,TP-LINK发布BE5100Wi-Fi7路由器,到手价279元,支持MLO、4KQAM、MRU、前导打孔等Wi-Fi7新特性。据介绍,在MLO多链路技术加持下,2.4G+5G叠加快至7.3倍,4KQAM高阶调制,速率提升至120%。MRU技术允许将多个资源块分配给单个用户,提升传输效率,降低延迟。TP-LINKBE5100......
  • CH9121网口配置协议及说明
    (1)结构体定义(2)通信流程详解1.通讯方式2.通讯结构体3.通讯过程①搜索②获取配置③配置④恢复出厂设置(3)相关文档下载CH9121搜素配置协议(1)结构体定义1//定义了与网络CH9121通信的基本数据结构,和配置结构,参数等23#ifndef__MODULECONFIG_H__4#define__MO......
  • 深入了解 Linux 网卡和网口:揭秘网络接口的奥秘
    实际工作中,把服务器关机了,网线从一个网口移动到了其他网口,导致再开机后,服务器无法联网了。由于缺少王工的支持,这使我开始关注网络技术。先总结下常用的概念和操作吧。1.网卡和网口的对应关系在Linux系统中,网卡(NetworkInterfaceCard,NIC)与网络接口(网口)之间存在紧密的对应关系。......