Fix get_delay calculation on Pi