changed to use network write thread sending data every 20ms