-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Matija Nalis
committed
Sep 7, 2015
1 parent
d4f15e4
commit 7c64fb2
Showing
1 changed file
with
13 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/usr/bin/perl -w | ||
# extract only MID8 data from SLCLog.gp2.human.txt (produced via "sirfbin_gp2_to_human.pl SLCLog.gp2) | ||
# and fake it in raw4t format, so we can test raw4t_gp2_to_human.pl parser | ||
|
||
use strict; | ||
# lines looks like this: | ||
# 16:21:38.147 GPSD knows MID 0x08 -- subframe data MID 8 (extract leap-second from this) -- hex 00 1D 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 00 00 00 0A 89 DD 83 81 46 78 F1 C6 A7 7D 3A 02 8A C0 06 10 | ||
|
||
while (<>) { | ||
next unless /^(.*) GPSD knows MID 0x08\h*--\h*subframe data MID 8.*-- hex\h*(..)\h+(..)\h+(.*)$/; | ||
my $time=$1; my $cnt=$2; my $SVID=$3; my $hex=$4; | ||
print "00/00/0009 $time (0) 85 $cnt 01 $SVID FF FF FF FF FF FF FF $hex\n"; | ||
} |