send to server every 20 loops