problems with UDP Mode 2

RecursiveError
Posts: 1
Joined: Sun Dec 15, 2024 10:47 pm

problems with UDP Mode 2

Postby RecursiveError » Sun Dec 15, 2024 11:12 pm

I'm trying to set up a UDP listener where I'll receive packets on port 1234 and reply to whoever sent it


the problem is that it seems that mode 2 has no effect, the IP and the remote port does not change, the only way to modify them is to send AT+CIPSEND


Here are the commands I used: (ESP-AT 3.4.0.0)

Code: Select all

AT+CIPSTART=3,"UDP","255.255.255.255",1234,1234,2
3,CONNECT

OK
AT+CIPSTATE?
+CIPSTATE:3,"UDP","255.255.255.255",1234,1234,0

OK

+IPD,3,7
AT+CIPSTATE?
+CIPSTATE:3,"UDP","255.255.255.255",1234,1234,0

OK
AT+CIPRECVDATA=3,7
+CIPRECVDATA:7,"192.168.15.61",49587,TESTE

OK
AT+CIPSTATE?
+CIPSTATE:3,"UDP","255.255.255.255",1234,1234,0

OK
AT+CIPSEND=3,3,"192.168.15.61",49587

OK

>
Recv 3 bytes

SEND OK
AT+CIPSTATE?
+CIPSTATE:3,"UDP","192.168.15.61",49587,1234,0

OK
the documentation says:
2: Each time UDP data is received, the <"remote host"> and <remote port> will be changed to the IP address and port of the device that sends the data."
Am I doing something wrong?

Who is online

Users browsing this forum: No registered users and 9 guests