예제 #1
0
 private void NotifyNewRig(IRig rig)
 {
     if (onRigFound != null)
     {
         onRigFound(rig);
     }
 }
예제 #2
0
        public IRig GetRigByAddress(string address)
        {
            IRig ret = null;

            addressRigLookup.TryGetValue(address, out ret);

            return(ret);
        }
예제 #3
0
 private void OnRigConnectionStateChanged(IRig rig)
 {
     lock (this) {
         if (isTesting)
         {
             CancelTest("Rig disconnected resulting in the test be scrubbed");
         }
     }
 }
예제 #4
0
 public void SetDeviceFilter(EDeviceModel deviceModel)
 {
     deviceFilter = deviceModel;
     deviceAdapter.SetConnections(service.GetConnectionsOfModel(deviceModel));
     if (rig != null && deviceModel.AsRigType() != rig.rigType)
     {
         rig.Disconnect();
         rig = null;
     }
 }
예제 #5
0
 private void Clear()
 {
     if (service != null)
     {
         if (rig != null)
         {
             rig.Disconnect();
             rig = null;
         }
         deviceAdapter.Clear();
         UpdateRigDisplay();
     }
 }
예제 #6
0
        public override void OnRigFound(IRig newRig)
        {
            base.OnRigFound(newRig);

            if (rig == null)
            {
                if (newRig.rigType == deviceFilter.AsRigType())
                {
                    rig = newRig;
                }                 // Else the rig doen't match and we should ignore it
            }
            else
            {
                // Check if the old rig doesn't match the device filter.
                if (rig.rigType != deviceFilter.AsRigType())
                {
                    rig = null;
                    if (newRig.rigType == deviceFilter.AsRigType())
                    {
                        rig = newRig;
                    }
                }                 // Else we already have a rig of the proper type.
            }
        }
예제 #7
0
 public virtual void OnRigFound(IRig rig)
 {
 }
예제 #8
0
 private void OnRigConnectionStateChanged(IRig rig)
 {
     handler.Post(UpdateRigDisplay);
 }