changed polling time to 1 ms