Beispiel #1
0
 public ISharpGP2D12 produceSharpGP2D12(slg.RobotAbstraction.Ids.AnalogPinId pin, int updateFrequency, double distanceChangedThreshold)
 {
     return(new SharpGP2D12(this)
     {
         Pin = pin,
         UpdateFrequency = updateFrequency,              // milliseconds
         DistanceChangedThreshold = distanceChangedThreshold
     });
 }
Beispiel #2
0
        public IAnalogSensor produceAnalogSensor(slg.RobotAbstraction.Ids.AnalogPinId pin, int updateFrequency, double valueChangedThreshold)
        {
            int iValueChangedThreshold = (int)valueChangedThreshold;

            return(new AnalogSensor(this)
            {
                Pin = pin,
                UpdateFrequency = updateFrequency,              // milliseconds
                ValueChangedThreshold = iValueChangedThreshold < 1 ? 1 : iValueChangedThreshold
            });
        }