def convertFreq(freq, unit):
    """convert frequency to current units"""
    if unit.upper() == 'KHZ':
        freq = freq / 1000.0
    elif unit.upper() == 'MHZ':
        freq = freq / 1000000.0
    elif unit.upper() == 'GHZ':
        freq = freq / 1000000000.0
    return freq
