Current code:
if (len(frame.data) > 0):
destAlias |= (frame.data[0] & 0x0F) << 8 # rm f bits
# TODO: Is this ok when len(frame.data) <= 1? Still << 8?
if (len(frame.data) > 1):
destAlias |= (frame.data[1] & 0xFF)
Should we have a warning below that?
else:
logger.warning("Missing last 2 nibbles of address in received data")
or discard the CanFrame?