Exemplo n.º 1
0
    public bool setIntegrationTimeMilliseconds(int ms)
    {
        bool result = false;

        if (!initialized)
        {
            return(result);
        }

        mut.WaitOne();

        try
        {
            int error = 0;
            SeaBreezeWrapper.seabreeze_set_integration_time_microsec(specIndex, ref error, (long)ms * 1000);
            result = checkSeaBreezeError("set_integration_time_microsec", error);
        }
        catch (Exception e)
        {
            logger.log("Error setting integration time: {0}", e);
        }
        finally
        {
            mut.ReleaseMutex();
        }

        return(result);
    }