namespace Tinkerforge
{
    public static class EThermocouple
    {
        public static (byte Averaging, byte ThermocoupleType, byte Filter) GetConfiguration(
            this BrickletThermocouple thermocouple)
        {
            thermocouple.GetConfiguration(out byte averaging, out byte thermocoupleType, out byte filter);
            return (averaging, thermocoupleType, filter);
        }

        public static (bool OverUnder, bool OpenCircuit) GetErrorState(this BrickletThermocouple thermocouple)
        {
            thermocouple.GetErrorState(out bool overUnder, out bool openCircuit);
            return (overUnder, openCircuit);
        }

        public static (char Option, int Min, int Max) GetTemperatureCallbackThreshold(
            this BrickletThermocouple thermocouple)
        {
            thermocouple.GetTemperatureCallbackThreshold(out char option, out int min, out int max);
            return (option, min, max);
        }
    }
}
