private void IssueCommand(IATCommand command) { string CommandString = command.GetCommandString(); CommandString = CommandString.ToUpper(); Port.WriteLine("AT" + CommandString); Port.BaseStream.Flush(); }
private void init() { _empty = CommandParameter.CreateEmpty(Constants.BasicSuccessfulResponse); _generalInfo = new SimpleATCommand(ATCommand.DefaultInfo.Command(), _empty); _rssi = new SimpleATCommand(ATCommand.ReceivedSignalStrengthInfo.Command(), _empty); _rscp = new SimpleATCommand(ATCommand.ReceivedSignalCodePowerInfo.Command(), _empty); _sysInfo = new SimpleATCommand(ATCommand.SystemInfo.Command(), _empty); }
private void init() { _empty = CommandParameter.CreateEmpty(Constants.BasicSuccessfulResponse); _storageQuery = new SimpleATCommand(ATCommand.MessageStorageInfo.Command(), _empty); var listParam = new CommandParameter(Constants.MessageStatus.Any.ToValueString(), Constants.BasicSuccessfulResponse); _listQuery = new ParamATCommand(ATCommand.MessageList.Command(), listParam); var mfParam = new CommandParameter(Constants.MessageFormat.Pdu.ToValueString(), Constants.BasicSuccessfulResponse); _mfCmd = new ParamATCommand(ATCommand.MessageFormat.Command(), mfParam); }
private void init() { var pinQueryParam = CommandParameter.CreateEmpty(@"\s*ready\s*.*\s*ok\s*$", true); _pinQuery = new SimpleATCommand(ATCommand.PinAuthenticateInfo.Command(), pinQueryParam); }
private void initCommands() { var mfParam = new CommandParameter(Constants.MessageFormat.Pdu.ToValueString(), Constants.BasicSuccessfulResponse); _mfCmd = new ParamATCommand(ATCommand.MessageFormat.Command(), mfParam); }
public ServiceCenter() { _emptyParam = CommandParameter.CreateEmpty(Constants.BasicSuccessfulResponse); _scaQuery = new SimpleATCommand(ATCommand.ServiceCenterAddressInfo.Command(), _emptyParam); }