소스 검색

update example buff size

Ryan-CW 3 년 전
부모
커밋
40ff9247fd
2개의 변경된 파일5개의 추가작업 그리고 5개의 파일을 삭제
  1. 2 2
      W5500Client/RyanW5500Store.c
  2. 3 3
      example/RyanW5500Test.c

+ 2 - 2
W5500Client/RyanW5500Store.c

@@ -1,10 +1,10 @@
 #include "RyanW5500Store.h"
 
- wiz_NetInfo gWIZNETINFO = {.mac = {0x00, 0x08, 0xdc, 0x00, 0xab, 0xcd},
+wiz_NetInfo gWIZNETINFO = {.mac = {0x00, 0x08, 0xdc, 0x00, 0xab, 0xcd},
                            .ip = {192, 168, 3, 20},
                            .sn = {255, 255, 252, 0},
                            .gw = {192, 168, 1, 1},
                            .dns = {114, 114, 114, 114},
                            .dhcp = NETINFO_DHCP};
 
- RyanW5500Entry_t RyanW5500Entry = {0};
+RyanW5500Entry_t RyanW5500Entry = {0};

+ 3 - 3
example/RyanW5500Test.c

@@ -107,7 +107,7 @@ void *deal_client_fun(void *arg)
 {
 
     int fd = *(int *)arg; // 通过arg获得已连接套接字
-    char buf[256] = {0};
+    char buf[512] = {0};
 
     // struct timeval tv = {
     //     .tv_sec = 2,
@@ -202,7 +202,7 @@ void udpEchoServiceTask(void *argument)
     // 定义一个IPv4地址结构  存放发送者的数据
     struct sockaddr_in from_addr;
     socklen_t fromLen = sizeof(from_addr);
-    char buf[256] = {0};
+    char buf[512] = {0};
 
     while (1)
     {
@@ -258,7 +258,7 @@ void multicastEchoServiceTask(void *argument)
 
     struct sockaddr_in from_addr = {0};
     socklen_t fromLen = sizeof(from_addr);
-    char buf[256] = {0};
+    char buf[512] = {0};
 
     while (1)
     {