예제 #1
0
        private StdLogicVector ParseSignalOutput(string output)
        {
            string val = TrimExcessData(output);

            if (val.Contains('(') || val.Contains(')'))
            {
                throw new NotImplementedException("Arrays, and record types are not supported. To get the value index the object manually.");
            }

            // Is it a slv output?
            StdLogicVector slv = StdLogicVector.Parse(val);

            if (slv != null)
            {
                return(slv);
            }

            // Is it a boolean output?
            bool boolean = false;

            if (bool.TryParse(val, out boolean))
            {
                return(new StdLogicVector(new bool[] { boolean }));
            }

            // No idea
            return(null);
        }