properly convert ms ot timeval, add some examples