Convert a 3 byte KNX data object to a date

def knx_to_date(knxdata):
    """Convert a 3 byte KNX data object to a date"""

    if len(knxdata) != 3:
        raise KNXException("Can only convert a 3 Byte object to date")

    year = knxdata[2]
    if year >= 90:
        year += 1900
    else:
        year += 2000

    return date(year, knxdata[1], knxdata[0])