def setUp(self): ParserUnitTestCase.setUp(self) self.config = { DataSetDriverConfigKeys.PARTICLE_MODULE: 'mi.dataset.parser.dosta_ln_wfp_sio_mule', DataSetDriverConfigKeys.PARTICLE_CLASS: 'DostaLnWfpSioMuleParserDataParticle' } # First 'WE' SIO header in noe58p1.dat, first record. self.timestamp_1a = self.timestamp_to_ntp('Q\xf2W.') # The record timestamp should be 2986504401 log.debug("Converted timestamp 1a: %s",self.timestamp_1a) self.particle_1a = DostaLnWfpSioMuleParserDataParticle(b'Q\xf2W.\x00\x00\x00\x00A9Y' \ '\xb4\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x009\x00e\x02:', internal_timestamp = self.timestamp_1a) # First 'WE' SIO header in noe58p1.dat, second record. self.timestamp_1b = self.timestamp_to_ntp('Q\xf2Xq') log.debug("Converted timestamp 1b: %s",self.timestamp_1b) self.particle_1b = DostaLnWfpSioMuleParserDataParticle(b'Q\xf2XqB\x8f\x83DA5\x1e\xb8D' \ '\xfd\x85qB\x82\x83\x12?\xf9\xba^\x009\x00d\x028', internal_timestamp = self.timestamp_1b) # First 'WE' SIO header in noe58p1.dat, third record. self.timestamp_1c = self.timestamp_to_ntp('Q\xf2Z\xd3') log.debug("Converted timestamp 1c: %s",self.timestamp_1c) self.particle_1c = DostaLnWfpSioMuleParserDataParticle(b'Q\xf2Z\xd3B\x84\x06GA2\x9a\xd4E' \ '\t\xd3\xd7B\x9b\xdc)?\xec\xac\x08\x00:\x00d\x027', internal_timestamp = self.timestamp_1c) # Second 'WE' SIO header in noe58p1.dat, first record. self.timestamp_2a = self.timestamp_to_ntp('Q\xf2\x8fn') log.debug("Converted timestamp 2a: %s",self.timestamp_2a) self.particle_2a = DostaLnWfpSioMuleParserDataParticle(b'Q\xf2\x8fn\x00\x00\x00\x00A7\xd5f' \ '\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x008\x00a\x02=', internal_timestamp = self.timestamp_2a) # Last 'WE' SIO header in node58p1.dat, last record (when reading 12). self.timestamp_1l = self.timestamp_to_ntp('Q\xf2\x99q') log.debug("Converted timestamp 1l: %s",self.timestamp_1l) self.particle_1l = DostaLnWfpSioMuleParserDataParticle(b'Q\xf2\x99qC"\t\xceA/\x9alEM\x07\\C' \ '\x07\xd7\n?\xc3\x95\x81\x007\x00_\x02;', internal_timestamp = self.timestamp_1l) # Last 'WE' SIO header in node58p1.dat[0:300000], second to last record. self.timestamp_1k = self.timestamp_to_ntp('Q\xf2\x981') log.debug("Converted timestamp 1k: %s",self.timestamp_1k) self.particle_1k = DostaLnWfpSioMuleParserDataParticle(b'Q\xf2\x981C\x10\xe5kA/\xe4&EG\x8c\x00C' \ '\x04\xc2\x8f?\xc4\xfd\xf4\x006\x00_\x02;', internal_timestamp = self.timestamp_1k) # Last record of second 'WE' SIO header, the last record when pulling 5000 bytes. self.timestamp_m = self.timestamp_to_ntp('Q\xf2\xa5\xc9') log.debug("Converted timestamp m2: %s",self.timestamp_m) self.state_callback_value = None self.publish_callback_value = None self.exception_callback_value = None
def stream_config(cls): # Fill in below with particle stream return [DostaLnWfpSioMuleParserDataParticle.type()]
def stream_config(cls): return [DostaLnWfpSioMuleParserDataParticle.type(), DostaLnWfpInstrumentParserDataParticle.type()]
def stream_config(cls): return [ DostaLnWfpSioMuleParserDataParticle.type(), DostaLnWfpInstrumentParserDataParticle.type() ]