public void SetDetectionSimulationMode(SimulatingDeviceDetectionMode mode) { using ScopedLock <SdkRecursiveMutex> lk = ScopedLock.Lock(ref _mutex); _isDetectionSimulationEnabled = mode != SimulatingDeviceDetectionMode.NoSimulation; _detectionSimulationMode = mode; }
public Result SimulateDeviceDetectionEvent(SdmmcPort port, SimulatingDeviceDetectionMode mode, bool signalEvent) { Result rc = GetProgramInfo(out ProgramInfo programInfo); if (rc.IsFailure()) { return(rc); } if (!programInfo.AccessControl.CanCall(OperationType.SimulateDevice)) { return(ResultFs.PermissionDenied.Log()); } throw new NotImplementedException(); }