def decode(self, data): """ Take the data bytearray. Decode the data to populate the velocities. :param data: Bytearray for the dataset. """ packet_pointer = Ensemble.GetBaseDataSize(self.name_len) for beam in range(self.element_multiplier): for bin_num in range(self.num_elements): self.Velocities[bin_num][beam] = Ensemble.GetFloat(packet_pointer, Ensemble().BytesInFloat, data) packet_pointer += Ensemble().BytesInFloat logger.debug(self.Velocities)
def decode(self, data): """ Take the data bytearray. Decode the data to populate the velocities. :param data: Bytearray for the dataset. """ packet_pointer = Ensemble.GetBaseDataSize(self.name_len) self.FirstPingTime = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 0, Ensemble().BytesInFloat, data) self.LastPingTime = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 1, Ensemble().BytesInFloat, data) self.Heading = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 2, Ensemble().BytesInFloat, data) self.Pitch = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 3, Ensemble().BytesInFloat, data) self.Roll = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 4, Ensemble().BytesInFloat, data) self.WaterTemp = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 5, Ensemble().BytesInFloat, data) self.SystemTemp = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 6, Ensemble().BytesInFloat, data) self.Salinity = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 7, Ensemble().BytesInFloat, data) self.Pressure = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 8, Ensemble().BytesInFloat, data) self.TransducerDepth = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 9, Ensemble().BytesInFloat, data) self.SpeedOfSound = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 10, Ensemble().BytesInFloat, data) self.Status = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 11, Ensemble().BytesInFloat, data) self.NumBeams = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 12, Ensemble().BytesInFloat, data) self.ActualPingCount = Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 13, Ensemble().BytesInFloat, data) index = 14 numBeam = int(self.NumBeams) for beams in range(numBeam): self.Range.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.SNR.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.Amplitude.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.Correlation.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.BeamVelocity.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.BeamGood.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.InstrumentVelocity.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.InstrumentGood.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.EarthVelocity.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.EarthGood.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 if self.num_elements > 54: for beams in range(numBeam): self.SNR_PulseCoherent.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.Amp_PulseCoherent.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.Vel_PulseCoherent.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.Noise_PulseCoherent.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 for beams in range(numBeam): self.Corr_PulseCoherent.append(Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * index, Ensemble().BytesInFloat, data)) index += 1 else: # Fill in with 0.0 for beams in range(numBeam): self.SNR_PulseCoherent.append(0.0) for beams in range(numBeam): self.Amp_PulseCoherent.append(0.0) for beams in range(numBeam): self.Vel_PulseCoherent.append(0.0) for beams in range(numBeam): self.Noise_PulseCoherent.append(0.0) for beams in range(numBeam): self.Corr_PulseCoherent.append(0.0) logger.debug(self.FirstPingTime) logger.debug(self.LastPingTime) logger.debug(self.Heading) logger.debug(self.Pitch) logger.debug(self.Roll) logger.debug(self.Salinity) logger.debug(self.SpeedOfSound) logger.debug(self.EarthVelocity)
def decode(self, data): """ Take the data bytearray. Decode the data to populate the values. :param data: Bytearray for the dataset. """ packet_pointer = Ensemble.GetBaseDataSize(self.name_len) self.BtSamplesPerSecond = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 0, Ensemble().BytesInFloat, data) self.BtSystemFreqHz = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 1, Ensemble().BytesInFloat, data) self.BtCPCE = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 2, Ensemble().BytesInFloat, data) self.BtNCE = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 3, Ensemble().BytesInFloat, data) self.BtRepeatN = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 4, Ensemble().BytesInFloat, data) self.WpSamplesPerSecond = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 5, Ensemble().BytesInFloat, data) self.WpSystemFreqHz = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 6, Ensemble().BytesInFloat, data) self.WpCPCE = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 7, Ensemble().BytesInFloat, data) self.WpNCE = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 8, Ensemble().BytesInFloat, data) self.WpRepeatN = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 9, Ensemble().BytesInFloat, data) self.WpLagSamples = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 10, Ensemble().BytesInFloat, data) self.Voltage = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 11, Ensemble().BytesInFloat, data) if self.num_elements > 12: self.XmtVoltage = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 12, Ensemble().BytesInFloat, data) self.BtBroadband = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 13, Ensemble().BytesInFloat, data) self.BtLagLength = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 14, Ensemble().BytesInFloat, data) self.BtNarrowband = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 15, Ensemble().BytesInFloat, data) self.BtBeamMux = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 16, Ensemble().BytesInFloat, data) self.WpBroadband = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 17, Ensemble().BytesInFloat, data) self.WpLagLength = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 18, Ensemble().BytesInFloat, data) self.WpTransmitBandwidth = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 19, Ensemble().BytesInFloat, data) self.WpReceiveBandwidth = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 20, Ensemble().BytesInFloat, data) logger.debug(self.BtSamplesPerSecond) logger.debug(self.BtSystemFreqHz) logger.debug(self.BtCPCE) logger.debug(self.BtNCE) logger.debug(self.BtRepeatN) logger.debug(self.WpSamplesPerSecond) logger.debug(self.WpSystemFreqHz) logger.debug(self.WpCPCE) logger.debug(self.WpNCE) logger.debug(self.WpRepeatN) logger.debug(self.WpLagSamples) logger.debug(self.Voltage) logger.debug(self.XmtVoltage) logger.debug(self.BtBroadband) logger.debug(self.BtLagLength) logger.debug(self.BtNarrowband) logger.debug(self.BtBeamMux) logger.debug(self.WpBroadband) logger.debug(self.WpLagLength) logger.debug(self.WpTransmitBandwidth) logger.debug(self.WpReceiveBandwidth)
def decode(self, data): """ Take the data bytearray. Decode the data to populate the values. :param data: Bytearray for the dataset. """ packet_pointer = Ensemble.GetBaseDataSize(self.name_len) self.FirstBinRange = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 0, Ensemble().BytesInFloat, data) self.BinSize = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 1, Ensemble().BytesInFloat, data) self.FirstPingTime = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 2, Ensemble().BytesInFloat, data) self.LastPingTime = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 3, Ensemble().BytesInFloat, data) self.Heading = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 4, Ensemble().BytesInFloat, data) self.Pitch = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 5, Ensemble().BytesInFloat, data) self.Roll = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 6, Ensemble().BytesInFloat, data) self.WaterTemp = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 7, Ensemble().BytesInFloat, data) self.SystemTemp = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 8, Ensemble().BytesInFloat, data) self.Salinity = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 9, Ensemble().BytesInFloat, data) self.Pressure = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 10, Ensemble().BytesInFloat, data) self.TransducerDepth = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 11, Ensemble().BytesInFloat, data) self.SpeedOfSound = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 12, Ensemble().BytesInFloat, data) if self.num_elements > 13: self.RawMagFieldStrength = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 13, Ensemble().BytesInFloat, data) self.PitchGravityVector = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 14, Ensemble().BytesInFloat, data) self.RollGravityVector = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 15, Ensemble().BytesInFloat, data) self.VerticalGravityVector = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 16, Ensemble().BytesInFloat, data) logger.debug(self.FirstBinRange) logger.debug(self.BinSize) logger.debug(self.Heading) logger.debug(self.Pitch) logger.debug(self.Roll) logger.debug(self.Salinity) logger.debug(self.SpeedOfSound)
def decode(self, data): """ Take the data bytearray. Decode the data to populate the values. :param data: Bytearray for the dataset. """ packet_pointer = Ensemble.GetBaseDataSize(self.name_len) self.NumBeams = Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 0, Ensemble().BytesInFloat, data) if self.NumBeams == 4.0: self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 1, Ensemble().BytesInFloat, data)) self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 2, Ensemble().BytesInFloat, data)) self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 3, Ensemble().BytesInFloat, data)) self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 4, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 5, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 6, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 7, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 8, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 9, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 10, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 11, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 12, Ensemble().BytesInFloat, data)) if len(data) > 80: self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 13, Ensemble().BytesInFloat, data)) self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 14, Ensemble().BytesInFloat, data)) self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 15, Ensemble().BytesInFloat, data)) self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 16, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 17, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 18, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 19, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 20, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 21, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 22, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 23, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 24, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 25, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 26, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 27, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 28, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 29, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 30, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 31, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 32, Ensemble().BytesInFloat, data)) elif self.NumBeams == 3.0: self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 1, Ensemble().BytesInFloat, data)) self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 2, Ensemble().BytesInFloat, data)) self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 3, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 4, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 5, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 6, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 7, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 8, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 9, Ensemble().BytesInFloat, data)) if len(data) > 68: self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 10, Ensemble().BytesInFloat, data)) self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 11, Ensemble().BytesInFloat, data)) self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 12, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 13, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 14, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 15, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 16, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 17, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 18, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 19, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 20, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 21, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 22, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 23, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 24, Ensemble().BytesInFloat, data)) elif self.NumBeams == 2.0: self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 1, Ensemble().BytesInFloat, data)) self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 2, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 3, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 4, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 5, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 6, Ensemble().BytesInFloat, data)) if len(data) > 56: self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 7, Ensemble().BytesInFloat, data)) self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 8, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 9, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 10, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 11, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 12, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 13, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 14, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 15, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 16, Ensemble().BytesInFloat, data)) elif self.NumBeams == 1.0: self.SNR.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 1, Ensemble().BytesInFloat, data)) self.Range.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 2, Ensemble().BytesInFloat, data)) self.Pings.append( Ensemble.GetFloat(packet_pointer + Ensemble().BytesInFloat * 3, Ensemble().BytesInFloat, data)) if len(data) > 44: self.Amplitude.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 4, Ensemble().BytesInFloat, data)) self.Correlation.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 5, Ensemble().BytesInFloat, data)) self.BeamVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 6, Ensemble().BytesInFloat, data)) self.InstrumentVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 7, Ensemble().BytesInFloat, data)) self.EarthVelocity.append( Ensemble.GetFloat( packet_pointer + Ensemble().BytesInFloat * 8, Ensemble().BytesInFloat, data)) logger.debug(self.NumBeams) logger.debug(self.SNR) logger.debug(self.Range) logger.debug(self.Pings) logger.debug(self.Amplitude) logger.debug(self.Correlation) logger.debug(self.BeamVelocity) logger.debug(self.InstrumentVelocity) logger.debug(self.EarthVelocity)