in python/awsgs.py [0:0]
def checkForStreamId(data):
streamIdIncluded = False
# We only want the first 4 bits, set other bits to zero, shift 4 places to the right, then trim to 4 in length
binString = convertMaskAndTrimBytesToBitString(data, 0b11110000, 4, 4)
if binString!=None:
streamIdIncluded = binString == '0011' or binString == '0001' or binString == '0100' or binString == '0101'
return [streamIdIncluded, binString]