示例#1
0
文件: M3Client.cs 项目: Abitech/m3o
 public static void GetGpsInfoDelegate(ref GpsParse.GPS_PARSE_INFO info)
 {
     try
     {
         dUTCTime = info.dUTCTime;
     }
     catch (Exception e)
     {
         Console.WriteLine(e.Message);
     }
 }
示例#2
0
文件: M3Client.cs 项目: Abitech/m3o
        public static void InitGps()
        {
            gps = new GpsParse();
            var gpsMessageWindow = new GpsMessageWindow(OnReceivingGpsData);

            if (gps.Open(gpsMessageWindow.Hwnd, "COM2:", 9600, GetGpsInfoDelegate))
            {
                DebugMessageBox.Show("Соединение с GPS удалось");
            }
            else
            {
                gps.Close();
            }
        }