def rostime_to_msecs(rostime):
    """Convert rostime to milliseconds

    Args:
        rostime (rospy.Time): Rospy Time object to convert

    Returns:
        int: time in milliseconds
    """
    return rostime.to_nsec() // 1e6