4 * This software is distributed under a zlib-style license.
\r
5 * See license.txt for more information.
\r
9 using System.Collections.Generic;
\r
12 namespace Yubeshi.Ubx
\r
14 public class NavSvInfo : Packet
\r
16 #region type definitions
\r
17 public struct SvInfo
\r
23 #region constructors
\r
25 public NavSvInfo(byte[] sentence, int length)
\r
26 : base(sentence, length)
\r
28 ID = MessageID.NavSvInfo;
\r
35 public decimal TimeOfWeek
\r
39 return BitConverter.ToUInt32(Raw, 6 + 0) * 1e-3m;
\r
45 #region public methods
\r
47 public static bool TryParse(byte[] sentence, out UnknownPacket packet)
\r
50 if (sentence.Length < 8)
\r
54 int length = 8 + 12 * sentence[6 + 4];
\r
55 return TryParse(sentence, out packet,
\r
56 MessageID.NavSvInfo, length, Build);
\r
61 #region private methods
\r
63 private static Packet Build(byte[] sentence, int length)
\r
65 return new NavSvInfo(sentence, length);
\r