示例#1
0
def test_pvt_repair():
    ret, soln, dops = calc_PVT_(nms[0:9], False)
    assert ret == 1, "Return code should be 1 (pvt repair)"
    assert soln.n_used == 8
    assert np.allclose(
        soln.pos_llh,
        [0.6590899959250786, -2.1360890086733595, 28.617422790579482])
    assert soln.valid
示例#2
0
def test_pvt_failed_repair():
  n_used = 5
  ret, soln, dops = calc_PVT_(nms[0:8], False)
  assert ret == 1
  assert np.allclose(soln.pos_llh, [0.6590905981580969, -2.136087375092587, 37.806255077127076])
  assert soln.valid
  assert soln.n_used == 7
  assert soln.time['tow'] - 0.07107547315305934 <= TOL
  assert soln.time['wn'] == 0
  assert soln.clock_offset - 0.008803100339752288 <= TOL
  assert soln.clock_bias - 0 <= TOL
  assert dops.pdop - 2.04639475526 <= TOL
  assert dops.gdop - 2.36782174999 <= TOL
  assert dops.tdop - 1.19115420721 <= TOL
  assert dops.hdop - 1.32894965567 <= TOL
  assert dops.vdop - 1.5561569031 <= TOL
示例#3
0
def test_pvt_failed_repair():
  n_used = 5
  ret, soln, dops = calc_PVT_(nms[0:8], False)
  assert ret == 1
  assert np.allclose(soln.pos_llh, [0.6590905981580969, -2.136087375092587, 37.806255077127076])
  assert soln.valid
  assert soln.n_used == 7
  assert soln.time['tow'] - 0.07107547315305934 <= TOL
  assert soln.time['wn'] == 0
  assert soln.clock_offset - 0.008803100339752288 <= TOL
  assert soln.clock_bias - 0 <= TOL
  assert dops.pdop - 2.04639475526 <= TOL
  assert dops.gdop - 2.36782174999 <= TOL
  assert dops.tdop - 1.19115420721 <= TOL
  assert dops.hdop - 1.32894965567 <= TOL
  assert dops.vdop - 1.5561569031 <= TOL
示例#4
0
def test_pvt_disable_pvt_raim():
  ret, soln, dops = calc_PVT_(nms[0:9], True)
  assert soln.n_used == 9
  assert ret == 2, "Return code should be 2 (raim not used)"
  assert soln.valid == 1, "Solution should be valid!"
示例#5
0
def test_pvt_repair():
  ret, soln, dops = calc_PVT_(nms[0:9], False)
  assert ret == 1, "Return code should be 1 (pvt repair)"
  assert soln.n_used == 8
  assert np.allclose(soln.pos_llh, [0.6590899959250786, -2.1360890086733595, 28.617422790579482])
  assert soln.valid
示例#6
0
def test_pvt_disable_pvt_raim():
  ret, soln, dops = calc_PVT_(nms[0:9], True)
  assert soln.n_used == 9
  assert ret == 2, "Return code should be 2 (raim not used)"
  assert soln.valid == 1, "Solution should be valid!"