public void DisConnect()
 {
     if (!CDLL.Com_disconnect(com))
     {
         throw new Exception("Disconnect fail!");
     }
 }
 public void DisConnect()
 {
     if (!CDLL.Com_disconnect(com))
     {
         throw new Exception("Disconnect fail!");
     }
     if (!CDLL.OmniDrive_destroy(omniDrive))
     {
         throw new Exception("Disconnect fail!");
     }
     for (int i = 0; i < 9; i++)
     {
         if (!CDLL.DistanceSensor_destroy(distanceSensor[i]))
         {
             throw new Exception("Disconnect fail!");
         }
     }
 }