Commit 188210a3d290e2a6dde7882af9d2fddc758edea6

Con Kolivas 2013-08-18T10:28:28

Add a ms_to_timespec helper function, and create a cgsleep_ms function that uses absolute timers with clock_nanosleep to avoid overruns.