With some routers, if activity is not detected on a device after a set period of time, the device will be removed from the routing table. When the printer enters standby, it also enables discontinuous reception to save power. This might cause the printer to be disconnected from the router when you attempt to print again.
To disable this feature:
If the device is still disconnected after a long period of inactivity, I recommend contacting your router manufacturer for some additional options or settings you can change within the router itself.