I'm working on a wireless (2.4Ghz WiFi 11n) project where multiple nodes (ESP32) send very small data to the AP, something like 40 bytes every minute or so. I need to maintain an accurate coordinated clock between them, absolute accuracy doesn't matter, but they must match with each other to at least 1ms (or better).
As GPS signal is not guaranteed at the location, I prefer not to include it in the design and I was thinking using the server (laptop wired to AP) to send a UDP Multicast timestamp every, let say, 2 seconds. The nodes are in constant movement (with vibration) so they may drift faster, anyway, I have doubts if this alternative would be able to work as I expected and I would like to know any other alternative or improvement of this system
At the moment, I have these unknowns that I would like to get an answer to:
Expected delay if AP is already busy sending / listening in the very exact moment it must emit the timestamp
Is there any physical reason (Multipath, bad signal, whatever) that one or more nodes doesn't receive the UDP at the exact moment? With exact moment I mean between a millisecond
Is there any chance of ESP32 slowdown or hang by another task and receiving the UDP packet pretty later?