Changeset 11215 in ntrip for trunk/BNC/tests


Ignore:
Timestamp:
Nov 19, 2026, 11:04:10 PM (2 weeks ago)
Author:
stuerze
Message:

Upload Ephemeris: majority vote included

Location:
trunk/BNC/tests
Files:
13 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/tests/README.md

    r11214 r11215  
    128128  `upload_raw` (raw forwarding to RINEX nav). `upload_rtnet_rtcm` encodes the same input to RTCM-SSR
    129129  (message numbers 1057-1068, 1240-1270) and decodes it again.
     130  `upload_eph_vote` replays the ephemerides of 89 uploader input streams
     131  (`data/eph_vote_261118_20min.raw`, 18 Nov 2026 17:43-18:03, BCEP00BKG0
     132  removed) and compares the log with the majority vote replacements
     133  (e.g. R06/R19/R20 Bn = 1 from RIO200ARG0); the uploaded stream depends on
     134  the wall-clock timing and is not compared. `eph_out_of_range` replays 6 min of
     135  the same input with a G39 copy of the G24 ephemerides of 3 stations
     136  (`tools/mk_eph_g39.py`): the G39 data set is logged once as RINEX record, the
     137  RINEX navigation file and the uploaded stream (`bncraw.py ephsats`) have no G39.
    130138* SSR decoding (`ssr_*`): 3 min slices of real streams replayed through
    131139  `03_BrdcCorr.bnc`. They compare the `.ssr` files and the `BNC_DEBUG_SSR`
  • trunk/BNC/tests/tools/bncraw.py

    r11130 r11215  
    1010    slice <raw> <out> [options]      cut a time window / subset of stations
    1111    crs   <raw>                      decode RTCM 1300/1301/1302 (CRS messages)
     12    ephsats <raw>                    satellite IDs of the ephemeris messages
    1213"""
    1314
    … …  
    246247
    247248
     249EPH_SYS = {"1019": ("G", 6), "1020": ("R", 6), "1041": ("I", 6), "1042": ("C", 6),
     250           "1044": ("J", 4), "1045": ("E", 6), "1046": ("E", 6)}
     251
     252
     253def cmd_ephsats(args):
     254    """Satellite IDs of the ephemeris messages per stream and message type."""
     255    sats = collections.OrderedDict()
     256    framers = {}
     257    for t, sta, fmt, data in read_chunks(args.input):
     258        for p in framers.setdefault(sta, Rtcm3Framer()).feed(data):
     259            mt = msg_type(p)
     260            if mt in EPH_SYS:
     261                sy, nb = EPH_SYS[mt]
     262                b = BitReader(p)
     263                b.u(12)
     264                sats.setdefault((sta, mt), set()).add("%s%02d" % (sy, b.u(nb)))
     265    for (sta, mt), s in sorted(sats.items()):
     266        print("%s %s %s" % (sta, mt, " ".join(sorted(s))))
     267
     268
    248269def main():
    249270    ap = argparse.ArgumentParser(description=__doc__,
    … …  
    269290    p.set_defaults(func=cmd_crs)
    270291
     292    p = sub.add_parser("ephsats", help="satellite IDs of the ephemeris messages")
     293    p.add_argument("input")
     294    p.set_defaults(func=cmd_ephsats)
     295
    271296    args = ap.parse_args()
    272297    args.func(args)
Note: See TracChangeset for help on using the changeset viewer.