예제 #1
0
 internal static byte GetRelativeThermistorByte(Sensor.BaseSensorDevice sensor, IThermistor thermistor)
 {
     if (thermistor == null)
         return 0;
     if (!(thermistor is Thermistor))
         return 7;
     Thermistor thermistorCast = (Thermistor)thermistor;
     return (byte)((sensor.device == thermistorCast.device) ? thermistorCast.id : 7);
 }
예제 #2
0
        public void SetTemperatureSensor(IThermistor thermistor)
        {
            DisabledCheck();

            int  idx     = CoreUtil.GetRelativeThermistorByte(this, thermistor);
            byte ledData = GetLEDData();

            ledData &= 0xF8; //11111000
            ledData |= (byte)idx;
            SetLEDData(ledData);
        }
예제 #3
0
        public void SetTemperatureSensor(IThermistor thermistor)
        {
            DisabledCheck();

            int  idx     = CoreUtil.GetRelativeThermistorByte(this, thermistor);
            byte fanData = GetFanData();

            fanData &= 0x8F; //10001111
            fanData |= (byte)(idx << 4);
            SetFanData(fanData);
        }
 public void SetThermistor(IThermistor thermistor)
 {
     this.thermistor = thermistor;
 }
 public TemperatureDependantControllerBase(IThermistor thermistor)
 {
     SetThermistor(thermistor);
 }
 public void SetThermistor(IThermistor thermistor)
 {
     this.thermistor = thermistor;
 }
 public TemperatureDependantControllerBase(IThermistor thermistor)
 {
     SetThermistor(thermistor);
 }
예제 #8
0
 internal static bool DoesThermistorNeedManualPush(Sensor.BaseSensorDevice sensor, IThermistor thermistor)
 {
     return GetRelativeThermistorByte(sensor, thermistor) == 7;
 }
예제 #9
0
        public void SetTemperatureSensor(IThermistor thermistor)
        {
            DisabledCheck();

            int idx = CoreUtil.GetRelativeThermistorByte(this, thermistor);
            byte ledData = GetLEDData();
            ledData &= 0xF8; //11111000
            ledData |= (byte)idx;
            SetLEDData(ledData);
        }
예제 #10
0
 internal static bool DoesThermistorNeedManualPush(Sensor.BaseSensorDevice sensor, IThermistor thermistor)
 {
     return(GetRelativeThermistorByte(sensor, thermistor) == 7);
 }
예제 #11
0
        internal static byte GetRelativeThermistorByte(Sensor.BaseSensorDevice sensor, IThermistor thermistor)
        {
            if (thermistor == null)
            {
                return(0);
            }
            if (!(thermistor is Thermistor))
            {
                return(7);
            }
            Thermistor thermistorCast = (Thermistor)thermistor;

            return((byte)((sensor.device == thermistorCast.device) ? thermistorCast.id : 7));
        }
예제 #12
0
        public void SetTemperatureSensor(IThermistor thermistor)
        {
            DisabledCheck();

            int idx = CoreUtil.GetRelativeThermistorByte(this, thermistor);
            byte fanData = GetFanData();
            fanData &= 0x8F; //10001111
            fanData |= (byte)(idx << 4);
            SetFanData(fanData);
        }