prova con thread.sleep(millisecondi)