示例#1
0
        public Radar(Socket h, string name, int x, int y)
        {
            Location        = new Point(x, y);
            Name            = name;
            Offset          = 0.0;
            Scans           = new List <MRM_SCAN_INFO>();
            CurrentScan     = new MRM_SCAN_INFO();
            UnfilteredScans = new MRM_SCAN_INFO[FilterCoeffs.Length];
            _handler        = h;
            MRM_GET_STATUSINFO_REQUEST t = new MRM_GET_STATUSINFO_REQUEST();

            t.MessageID = 0;
            if (_handler != null)
            {
                RadarRequest.SendMRM_GET_STATUSINFO_REQUEST(this, t);
            }
        }
示例#2
0
 public static bool SendMRM_GET_STATUSINFO_REQUEST(Radar p, MRM_GET_STATUSINFO_REQUEST t)
 {
     try
     {
         byte[] b = new byte[8];
         b[0] = b[1] = 0xA5;
         b[2] = 0x00; b[3] = 0x04;
         b[4] = 0xF0; b[5] = 0x01;
         b[6] = (byte)(t.MessageID >> 8);
         b[7] = (byte)(t.MessageID);
         p.Send(b);
         CommandOut = true;
         return(true);
     }
     catch
     {
         return(false);
     }
 }