def toTwosComplement2Bytes(value):
    """ returns two bytes (ints) in high, low order
        whose bits form the input value when interpreted in
        two's complement
    """
    if value >= 0:
        eqBitVal = value
    else:
        eqBitVal = (1 << 16) + value
    return eqBitVal >> 8 & 255, eqBitVal & 255
