コード例 #1
0
def test_GPSSV_messages():
    '''
  GPS SV messages test
  '''
    sv = GPSSatellite(1)
    assert sv.l1caMessage == sv.getL1CAMessage()
    assert sv.l2cMessage == sv.getL2CMessage()
    lnav = LNavMessage(1)
    cnav = CNavMessage(1)
    sv.setL1CAMessage(lnav)
    sv.setL2CMessage(cnav)
    assert sv.l1caMessage == sv.getL1CAMessage() == lnav
    assert sv.l2cMessage == sv.getL2CMessage() == cnav
コード例 #2
0
def test_GPSSV_messages():
  '''
  GPS SV messages test
  '''
  sv = GPSSatellite(1)
  assert sv.l1caMessage == sv.getL1CAMessage()
  assert sv.l2cMessage == sv.getL2CMessage()
  lnav = LNavMessage(1)
  cnav = CNavMessage(1)
  sv.setL1CAMessage(lnav)
  sv.setL2CMessage(cnav)
  assert sv.l1caMessage == sv.getL1CAMessage() == lnav
  assert sv.l2cMessage == sv.getL2CMessage() == cnav
コード例 #3
0
 def __MapTo_GPSSatellite(self, data):
   prn = data['prn']
   doppler = dopplerOF.fromMapForm(data['doppler'])
   amplitude = amplitudeOF.fromMapForm(data['amplitude'])
   l1caEnabled = data['l1caEnabled']
   l2cEnabled = data['l2cEnabled']
   l1caMessage = messageOF.fromMapForm(data['l1caMessage'])
   l2cMessage = messageOF.fromMapForm(data['l2cMessage'])
   clCodeType = data['l2clCodeType']
   codeDopplerIgnored = data['codeDopplerIgnored']
   satellite = GPSSatellite(prn)
   satellite.setAmplitude(amplitude)
   satellite.setDoppler(doppler)
   satellite.setL1CAEnabled(l1caEnabled)
   satellite.setL2CEnabled(l2cEnabled)
   satellite.setL1CAMessage(l1caMessage)
   satellite.setL2CMessage(l2cMessage)
   satellite.setL2CLCodeType(clCodeType)
   satellite.setCodeDopplerIgnored(codeDopplerIgnored)
   return satellite
コード例 #4
0
 def __MapTo_GPSSatellite(self, data):
     prn = data['prn']
     doppler = dopplerOF.fromMapForm(data['doppler'])
     amplitude = amplitudeOF.fromMapForm(data['amplitude'])
     l1caEnabled = data['l1caEnabled']
     l2cEnabled = data['l2cEnabled']
     l1caMessage = messageOF.fromMapForm(data['l1caMessage'])
     l2cMessage = messageOF.fromMapForm(data['l2cMessage'])
     clCodeType = data['l2clCodeType']
     codeDopplerIgnored = data['codeDopplerIgnored']
     satellite = GPSSatellite(prn)
     satellite.setAmplitude(amplitude)
     satellite.setDoppler(doppler)
     satellite.setL1CAEnabled(l1caEnabled)
     satellite.setL2CEnabled(l2cEnabled)
     satellite.setL1CAMessage(l1caMessage)
     satellite.setL2CMessage(l2cMessage)
     satellite.setL2CLCodeType(clCodeType)
     satellite.setCodeDopplerIgnored(codeDopplerIgnored)
     return satellite