Пример #1
0
        public CommandResponse ExecuteCommand(ATCommand command)
        {
            var builder = new StringBuilder();

            _port.WriteLine(command);

            Thread.Sleep(ExecutionGracePeriod);

            var character = default(int);

            while ((character = _port.ReadChar()) != ResponseTermination)
            {
                builder.Append((char)character);
            }

            var content = builder.ToString();

            return(new CommandResponse(content, command.Evaluator));
        }