Beispiel #1
0
    def __init__(self, *args, **kwargs):
	Parameters.__init__(self, *args, **kwargs)
	
	aux = self.aux
	
	aux_blocks = [None] * self.n_aux
	
	for blocknum in range(self.n):
	    for auxblocknum in aux[blocknum]:
		block = self.get_block(blocknum)
		if aux_blocks[auxblocknum] is None: 
		    aux_blocks[auxblocknum] = block
		else: aux_blocks[auxblocknum] = strxor(aux_blocks[auxblocknum], block)
	    
	self.aux_blocks = aux_blocks
Beispiel #2
0
    def add_data(self, data):
	# Skip the check since a CheckBlock always starts with data
	self.decoder.cbdb[self.id] = strxor(self.decoder.cbdb[self.id], data)
Beispiel #3
0
    def add_data(self, data):
	assert data is not None
	if self.temp is None: self.temp = data
	else: self.temp = strxor(self.temp, data)