BrickPi.Brick.GetBrickVersion C# (CSharp) Method

GetBrickVersion() public method

Don't use in normal code, this will errase the sensor type use only for debug purpose
public GetBrickVersion ( ) : int
return int
        public int GetBrickVersion()
        {
            //stop the brick, start a thread and read the version, start again the brick
            Stop();
            Task.Delay(100).Wait();
            for (int i = 0; i < 4; i++)
                brickPi.Sensor[i].Type = (BrickSensorType)70;
            SetupSensors().Wait();
            UpdateValues();
            return brickPi.Sensor[0].Value;           
        }