/// <summary> /// Für HKR-Zeitschaltung eingestellte Spartemperatur. /// </summary> /// <exception cref="HttpRequestException">400, 403, 500</exception> /// <returns>Temperatur</returns> public async Task <TemperatureSetting> GetHKRSparAsync() { string url = $"{BaseURL}/webservices/homeautoswitch.lua?&switchcmd=gethkrabsenk&sid={SID}"; string result = await Helpers.GetAsync(url); int tempwert = Convert.ToInt16(result); TemperatureSetting temp = new TemperatureSetting(tempwert); return(temp); }
/// <summary> /// HKR Solltemperatur einstellen. /// </summary> /// <exception cref="HttpRequestException">400, 403, 500</exception> /// <returns>Temperatur</returns> public async Task SetHKRSollAsync(TemperatureSetting temp) { int tempwert = temp.Value; string url = $"{BaseURL}/webservices/homeautoswitch.lua?¶m={tempwert}&switchcmd=sethkrtsoll&sid={SID}"; string result = await Helpers.GetAsync(url); }