append a frame containing a uint8

def uint8(self, val):
        """append a frame containing a uint8"""
        try:
            self.msg += [pack("B", val)]
        except struct.error:
            raise ValueError("Expected uint32")
        return self