-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Thermostat Sensor example #35
Comments
initial but not complete answer: As for how to make an actual thermostat? Hope this helped, |
Thanks for pointing to vTaskDelay I'm thinking about use it About json calls, if I think correctly this is must be live call? As it heating device it must work autonomously much as possible |
json structure IS local inside the ESP8266
see AiLight example
```
on=cJSON_GetObjectItem(acc_items[mylight.on].json,"value")->type;
if (on) {
bri=cJSON_GetObjectItem(acc_items[mylight.bri].json,"value")->valueint;
hue=cJSON_GetObjectItem(acc_items[mylight.hue].json,"value")->valueint;
sat=cJSON_GetObjectItem(acc_items[mylight.sat].json,"value")->valueint;
```
each of these is a reference to the stored local value.
besides reset of the the device, that is always accessible
|
CLONED from API repository to demo repository, please stick to the format?
@faronov commented
Hi
I'm very interesting about this project, it looks very promise.
I'm not a developer guru, but can read and modify some code :)
I'm looking how to write thermostat code, I understand how to read temperature sensor
But can't understand how to store HEATING_THRESHOLD_TEMPERATURE_C
and where it can be stored
Also in your demo, I see how to get state from a sensor when it requested,
but how to get state continuously?
Like get the temperature from a sensor, compare with stored HEATING_THRESHOLD_TEMPERATURE_C and turn on or off relay when it needed, without interacting with homekit?
👍 1
@ageorgios
@ageorgios commented
I cannot answer your question, but on which hardware you are trying to implement the thermostat? Sonoff?
@faronov
@faronov commented
It can be Sonoff
but I have some devices with esp12 or esp7 modules
I made ESPurna-H board
http://tinkerman.cat/the-espurna-board-a-smart-wall-switch-with-power-monitoring/
P.S.
I also interesting to add power usage monitoring but it seems to look like power usage not supported homekit directly.
Only in custom profile with Elgato EVE application.
But this is another story :)
The text was updated successfully, but these errors were encountered: