Guten Abend,
nach Kontakt mit Oekofen:
Den Fehler Connection refused kennt/kann die Heizung nicht, nur wait 2500ms between request. Also kann man alle 2,5 sec abfragen, braucht ja aber keiner.
Muss mein Netzwerk prüfen ob es daher kommt.
Guten Abend,
nach Kontakt mit Oekofen:
Den Fehler Connection refused kennt/kann die Heizung nicht, nur wait 2500ms between request. Also kann man alle 2,5 sec abfragen, braucht ja aber keiner.
Muss mein Netzwerk prüfen ob es daher kommt.
So, immerhin hab ich jetzt mal eine Antwort aus der Datenbank:
var end = new Date().getTime();
var ergebnis ='';
sendTo('influxdb.1', 'query', 'SELECT * FROM "oekofen" LIMIT 1', function (result) {
if (result.error) {
console.error(result.error);
} else {
// show result
console.log('Rows: ' + JSON.stringify(result.result[0]));
}
});
setTimeout(function(){ res = JSON.stringify(ergebnis); },5000);
return 0;
Ergebnis:
Leider sind nicht alle Werte befüllt und ich habe noch keinen Datenpunkt geschrieben.
Auf was habe ich mich da eingelassen.
Mail an Oekofen habe ich geschrieben, mal schauen was die zu den JSON-Abfragen sagen.
Guten Morgen oder Hallo,
vielen Dank für den Hinweis. Hatte ich auch schon gesehen, hieß aber immer JSON soll Modbus bei Oekofen ablösen.
Versuche das nachher mal, Link zur Registerversion 2.08., was neueres habe ich auf die Schnelle nicht gefunden.
Dokumentiere hier auch auf jeden Fall weiter, jeder andere der es eventuell sucht wird sich freuen.
EDIT: Stirling geht nicht mit Modbus Register 2.08, hat jemand was neueres?
@mickym
Müsste ich noch etwas neues lernen.
Funktioniert das dann auch, wenn die Heizung mal wieder eine JSON Abfrage verweigert?
Die Datenpunkte kann ich ja selbst in Influx “sichern / schreiben”.
Bin aber für jede Hilfe sehr dankbar, auch wenn ich Version 3 favorisieren würde.
Schönen Samstag
Guten Abend,
mit der Bitte um Hilfe wende ich mich an das Forum.
Situation:
Neue Heizung von Oekofen, benötige Daten aus dieser für die Steuerung Akku und Solarertrag im Haus.
Möglichkeit 1:
Abfrage per JSON direkt an die Heizung per http://IP:4321/password/all?
-> Antwort ist ein Array? mit {..{...}..}
Möglichkeit 2:
Diese JSON Abfrage gibt es als Adapter:
Oekofen JSON @ GitHub, schreibt dann alle Werte des Array als Datenpunkte in IoBroker.
Möglichkeit 3:
Ein Oekofen-Spy @ GitLab, fragt mittels Python3 ab und schreibt direkt in eine Influx-Datenbank. (Visualisierung per Grafana sehr schön, aber nebensächlich)
Möglichkeit 2 wäre für mich die smarteste, jedoch verweigert die Heizung regelmäßig die Verbindung mit ConnectionRefused, Terminate yourself. Dann geht die Instanz aus, Neustart per Script schon probiert, hilft nur sporadisch, es läuft nicht zuverlässig. (Ich vermute, alle APP-Anfrage und auch die Oekofen-Verbindung zum Werk laufen auch per JSON - und irgendwann ist es zuviel.)
Möglichkeit 3 habe ich jetzt paar Tage ausgetestet, geht recht zuverlässig, wenn mal 1-2h keine Daten abgerufen werden konnten, sehe ich es in Grafana, das Python-Script läuft aber per Crontab zuverlässig alle 4 Minuten weiter.
Problem / Fragestellung
Ich benötige viele der Daten im Iobroker, um die Steuerlogik zuverlässig laufen zu lassen und per JSON (http://IP:4321/password/pe1.mode=X) Teile der Heizung zu steuern.
Möglichkeit 2 ist nicht zuverlässig. Möglichkeit 1 scheitert an meinem Unvermögen das Result des JSON Script zuverlässig in die Datenpunkte schreiben zu lassen. Möglichkeit 3 scheitert an meinem Unvermögen die Daten aus der Datenbank in Datenpunkte im iobroker zu holen.
Aufbau der Datenbank bei Oekofen-spy
> show measurements
oekofen
> show series
key
---
oekofen,bereich=circ1
oekofen,bereich=forecast
oekofen,bereich=hk1
oekofen,bereich=hk2
oekofen,bereich=pe1
oekofen,bereich=power
oekofen,bereich=pu1
oekofen,bereich=sk1
oekofen,bereich=sk2
oekofen,bereich=stirling
oekofen,bereich=system
oekofen,bereich=weather
oekofen,bereich=ww1
> show tag keys
name: oekofen
tagKey
------
bereich
> show field keys
name: oekofen
fieldKey fieldType
-------- ---------
circ1_L_pummp float
circ1_L_release_temp float
circ1_L_ret_temp float
circ1_mode integer
circ1_name string
circ1_pump_release float
circ1_return_set float
circ1_time_prg integer
forecast_L_w_0 string
forecast_L_w_1 string
forecast_L_w_10 string
forecast_L_w_11 string
forecast_L_w_12 string
forecast_L_w_13 string
forecast_L_w_14 string
forecast_L_w_15 string
forecast_L_w_16 string
forecast_L_w_17 string
forecast_L_w_18 string
forecast_L_w_19 string
forecast_L_w_2 string
forecast_L_w_20 string
forecast_L_w_21 string
forecast_L_w_22 string
forecast_L_w_23 string
forecast_L_w_24 string
forecast_L_w_3 string
forecast_L_w_4 string
forecast_L_w_5 string
forecast_L_w_6 string
forecast_L_w_7 string
forecast_L_w_8 string
forecast_L_w_9 string
hk1_L_comfort float
hk1_L_flowtemp_act float
hk1_L_flowtemp_set float
hk1_L_pump float
hk1_L_roomtemp_act float
hk1_L_roomtemp_set float
hk1_L_state integer
hk1_L_statetext string
hk1_autocomfort float
hk1_autocomfort_sunrise float
hk1_autocomfort_sunset float
hk1_mode_auto integer
hk1_name string
hk1_oekomode integer
hk1_remote_override float
hk1_temp_heat float
hk1_temp_setback float
hk1_temp_vacation float
hk1_time_prg integer
hk2_L_comfort float
hk2_L_flowtemp_act float
hk2_L_flowtemp_set float
hk2_L_pump float
hk2_L_roomtemp_act float
hk2_L_roomtemp_set float
hk2_L_state integer
hk2_L_statetext string
hk2_autocomfort float
hk2_autocomfort_sunrise float
hk2_autocomfort_sunset float
hk2_mode_auto integer
hk2_name string
hk2_oekomode integer
hk2_remote_override float
hk2_temp_heat float
hk2_temp_setback float
hk2_temp_vacation float
hk2_time_prg integer
pe1_L_ak float
pe1_L_avg_runtime float
pe1_L_br float
pe1_L_currentairflow float
pe1_L_ext_temp float
pe1_L_fluegas float
pe1_L_frt_temp_act float
pe1_L_frt_temp_end float
pe1_L_frt_temp_set float
pe1_L_lowpressure float
pe1_L_lowpressure_set float
pe1_L_modulation float
pe1_L_not float
pe1_L_resttimeburner float
pe1_L_runtime float
pe1_L_runtimeburner float
pe1_L_starts float
pe1_L_state integer
pe1_L_statetext string
pe1_L_stb float
pe1_L_storage_fill float
pe1_L_storage_max float
pe1_L_storage_min float
pe1_L_storage_popper float
pe1_L_temp_act float
pe1_L_temp_set float
pe1_L_type float
pe1_L_uw float
pe1_L_uw_release float
pe1_L_uw_speed float
pe1_mode integer
pe1_storage_fill_today float
pe1_storage_fill_yesterday float
power_L_batt_chg float
power_L_batt_enabled float
power_L_batt_in float
power_L_batt_out float
power_L_from_grid float
power_L_offset float
power_L_output_mode integer
power_L_p1 float
power_L_p2 float
power_L_p3 float
power_L_power2car float
power_L_pv_1 float
power_L_pv_2 float
power_L_pv_total float
power_L_pwr_out float
power_L_pwr_out_per float
power_L_range float
power_L_state integer
power_L_to_grid float
power_L_today_batt_in float
power_L_today_batt_out float
power_L_today_in float
power_L_today_out float
power_L_today_total float
power_L_total float
power_L_total_car float
power_L_total_in float
power_L_total_out float
power_L_total_pv float
power_L_total_tyristor float
power_L_usage float
power_L_yesterday float
power_L_yesterday_batt_in float
power_L_yesterday_batt_out float
power_L_yesterday_car float
power_L_yesterday_in float
power_L_yesterday_out float
power_L_yesterday_pv float
power_L_yesterday_tyristor float
power_offtemp float
pu1_L_pump float
pu1_L_pump_release float
pu1_L_state integer
pu1_L_statetext string
pu1_L_tpm_act float
pu1_L_tpm_set float
pu1_L_tpo_act float
pu1_L_tpo_set float
pu1_ext_mintemp_off float
pu1_ext_mintemp_on float
pu1_mintemp_off float
pu1_mintemp_on float
sk1_L_koll_temp float
sk1_L_pump float
sk1_L_spu float
sk1_L_state integer
sk1_L_statetext string
sk1_cooling float
sk1_mode integer
sk1_name string
sk1_spu_max float
sk2_L_koll_temp float
sk2_L_pump float
sk2_L_spu float
sk2_L_state integer
sk2_L_statetext string
sk2_cooling float
sk2_mode integer
sk2_name string
sk2_spu_max float
stirling_L_current float
stirling_L_error float
stirling_L_flow float
stirling_L_frequency float
stirling_L_phase float
stirling_L_power float
stirling_L_power_today float
stirling_L_power_totals float
stirling_L_power_yesterday float
stirling_L_runtime float
stirling_L_safety_shutdown float
stirling_L_source float
stirling_L_st_req float
stirling_L_start float
stirling_L_state integer
stirling_L_temp_1 float
stirling_L_temp_2 float
stirling_L_temp_amb float
stirling_L_temp_diff float
stirling_L_temp_flow float
stirling_L_temp_ret float
stirling_L_voltage float
system_L_ambient float
system_L_errors float
system_L_existing_boiler float
system_L_usb_stick float
weather_L_clouds float
weather_L_endtime float
weather_L_forecast_clouds float
weather_L_forecast_temp float
weather_L_forecast_today float
weather_L_location string
weather_L_source string
weather_L_starttime float
weather_L_temp float
weather_cloud_limit float
weather_hysteresys float
weather_lead float
weather_oekomode integer
weather_offtemp float
weather_refresh float
ww1_L_offtemp_act float
ww1_L_ontemp_act float
ww1_L_pump float
ww1_L_state integer
ww1_L_statetext string
ww1_L_temp_set float
ww1_heat_once float
ww1_mode_auto integer
ww1_mode_dhw integer
ww1_name string
ww1_oekomode integer
ww1_sensor_off float
ww1_sensor_on float
ww1_smartstart float
ww1_temp_max_set float
ww1_temp_min_set float
ww1_time_prg integer
ww1_use_boiler_heat float
Die Custom queries beim ioBroker.influxdb habe ich gefunden, verstehe es aber nicht, async etc.
Bitte um Schubser, ich stehe gerade völlig auf dem Schlauch.
Vielen Dank
PS: Hier im Forum gelesen.