Fixed queue_packet_ready error and added skew compensation.
Minor code cleanup and skew compensation changes.

TODO next: use client-side skew compensation based on host vs
clock time differences.