GSF.PhasorProtocols.IEEE1344.PhasorDefinition.ParseConversionFactor C# (CSharp) Method

ParseConversionFactor() private method

Parses conversion factor image from the specified buffer.
private ParseConversionFactor ( byte buffer, int startIndex ) : int
buffer byte Binary image to parse.
startIndex int Start index into to begin parsing.
return int
        internal int ParseConversionFactor(byte[] buffer, int startIndex)
        {
            // Get phasor type from first byte
            PhasorType = (buffer[startIndex] == 0) ? PhasorType.Voltage : PhasorType.Current;

            // Last three bytes represent scaling factor
            ScalingValue = BigEndian.ToUInt24(buffer, startIndex + 1);

            return ConversionFactorLength;
        }