add better exception message and changed delay to 40ms (24 fps)