We are comparing the transfer bits themselves

This commit is contained in:
Lewis Moten
2024-05-09 14:42:03 -04:00
parent 06e917a0a6
commit 513aa67875

View File

@@ -1874,8 +1874,8 @@ function drawChannelData() {
const receivedBit = segmentBits[channelIndex]; const receivedBit = segmentBits[channelIndex];
// identify expected bit // identify expected bit
const bitIndex = channelIndex + (segmentIndex * channelCount); const bitIndex = channelIndex + (segmentIndex * channelCount);
if(bitIndex >= SENT_ENCODED_BITS.length) break; if(bitIndex >= SENT_TRANSFER_BITS.length) break;
const expectedBit = SENT_ENCODED_BITS[bitIndex]; const expectedBit = SENT_TRANSFER_BITS[bitIndex];
drawChannelSegmentBackground( drawChannelSegmentBackground(
ctx, ctx,
@@ -2215,7 +2215,7 @@ function handleReceivedChannelGraphClick(e) {
} }
}); });
const expectedBit = SENT_ENCODED_BITS[bitIndex]; const expectedBit = SENT_TRANSFER_BITS[bitIndex];
const receivedBit = packetReceivedBits[bitIndex]; const receivedBit = packetReceivedBits[bitIndex];
addLowHigh('Expected Bit', expectedBit === 1 ? '' : '0', expectedBit === 1 ? '1' : '') addLowHigh('Expected Bit', expectedBit === 1 ? '' : '0', expectedBit === 1 ? '1' : '')
addLowHigh('Received Bit', receivedBit === 1 ? '' : '0', receivedBit === 1 ? '1' : '') addLowHigh('Received Bit', receivedBit === 1 ? '' : '0', receivedBit === 1 ? '1' : '')