Added dummy for loop instead of usleep