about esp

1163167506
Posts: 30
Joined: Mon Jun 11, 2018 5:52 am

about esp

Postby 1163167506 » Mon Jun 11, 2018 6:13 am

When I set the WiFi of esp32 to STA mode, I found a very serious problem.
I found that there was a very high delay in PC Ping esp32 in LAN.
But the distance is very close and the quality of the signal is very good.
Can anyone offer good advice

my code:

#include "WiFi.h"
const char* ssid ="UT-9061";
const char* ssid2 ="TP-LINK_BE5F";
const char*password = "yutaikeji123456@";
void setup()
{
Serial.begin(115200);
delay(10);

WiFi.mode(WIFI_STA);

WiFi.begin(ssid2, password);
while (WiFi.status()!= WL_CONNECTED)
{
delay(500);
Serial.println("Connectingto WiFi..");
}

Serial.println("Connectedto the WiFi network");
Serial.print("IP address:\t");
Serial.println(WiFi.localIP());
}

void loop()
{
delay(1000);
Serial.print("IP address:\t");
Serial.println(WiFi.localIP());

Serial.print("channel:");
Serial.print(WiFi.channel());

Serial.print("rssi:");
Serial.print(WiFi.RSSI());

}


ping:
正在 Ping 192.168.9.101 具有 32 字节的数据:
来自 192.168.9.101 的回复: 字节=32 时间=27ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=42ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=56ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=72ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=91ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=104ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=23ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=39ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=60ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=71ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=86ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=106ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=21ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=36ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=53ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=69ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=87ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=105ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=19ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=32ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=52ms TTL=255
来自 192.168.9.101 的回复: 字节=32 时间=67ms TTL=255

192.168.9.101 的 Ping 统计信息:
数据包: 已发送 = 22,已接收 = 22,丢失 = 0 (0% 丢失),
往返行程的估计时间(以毫秒为单位):
最短 = 19ms,最长 = 106ms,平均 = 59ms

Who is online

Users browsing this forum: No registered users and 49 guests