public static I2CEvint EvintI2C(this ArduinoSession session) { return(session.GetEvint(() => new I2CEvint(session))); }
///// <inheritdoc cref="IStringProtocol.ReadLine"/> //public static string ReadLine(this ArduinoSession session) //{ // return session.messageHeader.GetStringFromQueue(StringRequest.CreateReadLineRequest()); //} ///// <inheritdoc cref="IStringProtocol.ReadLineAsync"/> //public static async Task<string> ReadLineAsync(this ArduinoSession session) //{ // return await Task.Run(() => session.messageHeader.GetStringFromQueue(StringRequest.CreateReadLineRequest())); //} ///// <inheritdoc cref="IStringProtocol.Read"/> //public static string Read(this ArduinoSession session, int length = 1) //{ // if (length < 0) // throw new ArgumentOutOfRangeException(nameof(length), Messages.ArgumentEx_PositiveValue); // return session.messageHeader.GetStringFromQueue(StringRequest.CreateReadRequest(length)); //} ///// <inheritdoc cref="IStringProtocol.ReadAsync"/> //public static async Task<string> ReadAsync(this ArduinoSession session, int length = 1) //{ // if (length < 0) // throw new ArgumentOutOfRangeException(nameof(length), Messages.ArgumentEx_PositiveValue); // return await Task.Run(() => session.messageHeader.GetStringFromQueue(StringRequest.CreateReadRequest(length))); //} ///// <inheritdoc cref="IStringProtocol.ReadTo"/> //public static string ReadTo(this ArduinoSession session, char terminator = char.MinValue) //{ // return session.messageHeader.GetStringFromQueue(StringRequest.CreateReadRequest(terminator)); //} ///// <inheritdoc cref="IStringProtocol.ReadToAsync"/> //public static async Task<string> ReadToAsync(this ArduinoSession session, char terminator = char.MinValue) //{ // return await Task.Run(() => session.messageHeader.GetStringFromQueue(StringRequest.CreateReadRequest(terminator))); //} public static StringEvint EvintString(this ArduinoSession session) { return(session.GetEvint(() => new StringEvint(session))); }
public static FirmataEvint EvintFirmata(this ArduinoSession session) { return(session.GetEvint(() => new FirmataEvint(session))); }
public static AccelStepperEvint EvintAccelStepper(this ArduinoSession session) { return(session.GetEvint(() => new AccelStepperEvint(session))); }
public static SerialEvint EvintSerial(this ArduinoSession session) { return(session.GetEvint(() => new SerialEvint(session))); }