Intermittent TCP/IP messages

Ok, so you used millis() for better timing accuracy, however, you can use millis() to trigger an action WHEN it has reached a certain timeout, in the meantime allowing the loop run and do other things, rather than having the CPU tied up in a loop and being prevented from doing other things UNTIL timeout.

I am not sure why the Arduino is sending only 50% of responses, but have a suspicion it might be related to the processor is tied up in that loop. This video helped my to understand how millis() can be used without having CPU cycles being tied up:

^https://www.youtube.com/watch?v=dCku8BabPx4

The example demostrates this with LEDs, but you gives a good idea of the principle.