コード例 #1
0
ファイル: GlonassNavFileWriter.cs プロジェクト: yxw027/GNSSer
        /// <summary>
        /// Glonass星历数据构建
        /// </summary>
        /// <param name="record"></param>
        /// <returns></returns>
        public static string BuildRinexRecordV4(GlonassNavRecord record)
        {
            StringBuilder sb = new StringBuilder();

            sb.Append(record.Prn.ToString());
            sb.Append(" ");
            sb.Append(TimeIoUtil.ToRinexV3String(record.Time));
            sb.Append(DoubleUtil.ScientificFomate(record.ClockBias, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.RelativeFrequencyBias, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.MessageTime, "E19.12", false));
            sb.AppendLine();

            sb.Append("    ");
            sb.Append(DoubleUtil.ScientificFomate(record.XYZ.X / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.XyzVelocity.X / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.XyzAcceleration.X / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.Health, "E19.12", false));
            sb.AppendLine();

            sb.Append("    ");
            sb.Append(DoubleUtil.ScientificFomate(record.XYZ.Y / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.XyzVelocity.Y / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.XyzAcceleration.Y / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.FrequencyNumber / 1000, "E19.12", false));
            sb.AppendLine();

            sb.Append("    ");
            sb.Append(DoubleUtil.ScientificFomate(record.XYZ.Z / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.XyzVelocity.Z / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.XyzAcceleration.Z / 1000, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.AgeOfOper, "E19.12", false));
            sb.AppendLine();

            return(sb.ToString());
        }
コード例 #2
0
ファイル: ParamNavFileWriter.cs プロジェクト: yxw027/GNSSer
        /// <summary>
        /// 构建第一行
        /// </summary>
        /// <param name="record"></param>
        /// <returns></returns>
        public static string BuildFirstLineV3(SatClockBias record)
        {
            StringBuilder sb = new StringBuilder();

            sb.Append(record.Prn.ToString());
            sb.Append(" ");
            sb.Append(TimeIoUtil.ToRinexV3String(record.Time));
            sb.Append(DoubleUtil.ScientificFomate(record.ClockBias, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.ClockDrift, "E19.12", false));
            sb.Append(DoubleUtil.ScientificFomate(record.DriftRate, "E19.12", false));
            return(sb.ToString());
        }