Skip to content

Commit

Permalink
mods for HB-GD-Sw1-TH-TS (add GDS control, renamed vom THP to TH)
Browse files Browse the repository at this point in the history
  • Loading branch information
jp112sdl committed Aug 29, 2021
1 parent 3fd6802 commit 0c284fe
Show file tree
Hide file tree
Showing 14 changed files with 290 additions and 98 deletions.
11 changes: 11 additions & 0 deletions patchsource/www/rega/esp/datapointconfigurator.fn
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ function ::dcCreate()
var CN_SERVO = "SERVO.";
var CN_AIRFLAP = "AIRFLAP.";
var CN_JPWINDOW = "JPWND.";
var CN_GDS = "GDS.";
var CN_FAN = "FAN.";
var CN_PFS = "PFS.";
var CN_LDRSC = "LDRSC.";
Expand Down Expand Up @@ -434,6 +435,16 @@ function ::dcCreate()
Call("/esp/controls/jpwindow.fn::CreateJPWindowControls()");
}

!# GDS
bIsControl = ( sControlName.Find(CN_GDS) > -1 );
if( bIsControl && (sLastControlName!=CN_GDS) )
{
WriteLine( "<script>conInfo('Control CN_GDS found.');</script>" );
isKnownControl = true;
sLastControlName = CN_GDS;
Call("/esp/controls/gds.fn::CreateGDSSensor()");
}

!# AIRFLAP
bIsControl = ( sControlName.Find(CN_AIRFLAP) > -1 );
if( bIsControl && (sLastControlName!=CN_AIRFLAP) )
Expand Down
12 changes: 6 additions & 6 deletions patchsource/www/webui/webui.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,12 +160,12 @@ DEV_DESCRIPTION['HB-UNI-Sen-WEA']='universeller Wetterdatensensor';
DEV_PATHS['HB-UNI-Sen-WEA'] = new Object();
DEV_PATHS['HB-UNI-Sen-WEA']['50'] = '/config/img/devices/50/hb-uni-sen-wea_thumb.png';
DEV_PATHS['HB-UNI-Sen-WEA']['250'] = '/config/img/devices/250/hb-uni-sen-wea.png';
DEV_HIGHLIGHT['HB-GD-Sw1-THP-TS'] = new Object();
DEV_LIST.push('HB-GD-Sw1-THP-TS');
DEV_DESCRIPTION['HB-GD-Sw1-THP-TS']='Garagentor-Aktor, Kontaktschnittstelle und T/H/P-Daten';
DEV_PATHS['HB-GD-Sw1-THP-TS'] = new Object();
DEV_PATHS['HB-GD-Sw1-THP-TS']['50'] = '/config/img/devices/50/hb-gd-sw1-thp-ts_thumb.png';
DEV_PATHS['HB-GD-Sw1-THP-TS']['250'] = '/config/img/devices/250/hb-gd-sw1-thp-ts.png';
DEV_HIGHLIGHT['HB-GD-Sw1-TH-TS'] = new Object();
DEV_LIST.push('HB-GD-Sw1-TH-TS');
DEV_DESCRIPTION['HB-GD-Sw1-TH-TS']='Garagentor-Aktor, Kontaktschnittstelle und Temperatur-/Luftfeuchtemessung';
DEV_PATHS['HB-GD-Sw1-TH-TS'] = new Object();
DEV_PATHS['HB-GD-Sw1-TH-TS']['50'] = '/config/img/devices/50/hb-gd-sw1-th-ts_thumb.png';
DEV_PATHS['HB-GD-Sw1-TH-TS']['250'] = '/config/img/devices/250/hb-gd-sw1-th-ts.png';
DEV_HIGHLIGHT['HB-UNI-Sen-VOLT'] = new Object();
DEV_LIST.push('HB-UNI-Sen-VOLT');
DEV_DESCRIPTION['HB-UNI-Sen-VOLT']='universeller Spannungsmesser';
Expand Down
2 changes: 1 addition & 1 deletion src/addon/devdb.csv
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ HB-DIS-EP-42BW-MAINS;hb-dis-ep-42bw-mains
HB-DIS-EP-75BW;hb-dis-ep-75bw
HB-DIS-EP-75BW-MAINS;hb-dis-ep-75bw-mains
HB-ES-PMSw1-USB;hb-es-pmsw1-usb
HB-GD-Sw1-THP-TS;hb-gd-sw1-thp-ts
HB-GD-Sw1-TH-TS;hb-gd-sw1-th-ts
HB-IBUT-8;hb-ibut-8
HB-IR-Rcv-RC;hb-ir-rcv-rc
HB-LC-Bl1-FM-BAT;7_hm-lc-bl1-fm
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<device version="2" cyclic_timeout="3600" supports_aes="false">
<device version="2" cyclic_timeout="3600" supports_aes="true">
<supported_types>
<type name="HB-GD-Sw1-THP-TS" id="HB-GD-Sw1-THP-TS" priority="2">
<type name="HB-GD-Sw1-TH-TS" id="HB-GD-Sw1-TH-TS" priority="2" updatable="true">
<parameter index="10.0" size="2.0" const_value="0xF35C" />
</type>
</supported_types>
Expand All @@ -10,6 +10,10 @@
<logical type="boolean" default="true"/>
<physical type="integer" interface="config" list="0" index="2.7" size="0.1"/>
</parameter>
<parameter id="TRANSMIT_DEV_TRY_MAX">
<logical type="integer" min="1.0" max="10.0" default="6.0"/>
<physical type="integer" interface="config" list="0" index="20" size="1"/>
</parameter>
</paramset>
<channels>
<channel index="0" type="MAINTENANCE" ui_flags="internal" class="maintenance" count="1">
Expand Down Expand Up @@ -45,25 +49,44 @@
</parameter>
</paramset>
</channel>
<channel index="1" type="SWITCH" count="1">
<channel autoregister="true" index="1" type="WEATHER" count="1">
<link_roles>
<target name="SWITCH"/>
<target name="WEATHER_CS"/>
<target name="WCS_TIPTRONIC_SENSOR"/>
<source name="WEATHER_TH" />
</link_roles>
<paramset type="MASTER" id="switch_ch_master">
<subset ref="switch_paramset"/>
</paramset>
<paramset type="VALUES" id="switch_ch_values">
<subset ref="switch_valueset"/>
<paramset type="MASTER" id="ash550_ch_master">
<parameter id="TEMPERATURE_OFFSET">
<logical type="float" min="-5.0" max="5.0" unit="K" default="0"/>
<physical type="integer" signed="true" interface="config" list="1" index="1" size="4"/>
<conversion type="float_integer_scale" factor="10"/>
</parameter>
<parameter id="HUMIDITY_OFFSET">
<logical type="integer" min="-10" max="10" default="0" unit="%"/>
<physical type="integer" interface="config" list="1" index="5" size="1"/>
<conversion type="sint4_sintx" physical_bytes="1"/>
</parameter>
</paramset>
<paramset type="LINK" id="switch_ch_link">
<subset ref="switch_linkset"/>
<paramset type="VALUES" id="ash550_ch_values">
<parameter id="TEMPERATURE" operations="read,event" control="GDS.TEMPERATURE">
<logical type="float" min="-40.0" max="80.0" unit="°C" />
<physical type="integer" interface="command" value_id="TEMPERATURE">
<event frame="WEATHER_EVENT" />
</physical>
<conversion type="float_integer_scale" factor="10.0" />
<description>
<field id="AutoconfRoles" value="WEATHER" />
</description>
</parameter>
<parameter id="HUMIDITY" operations="read,event" control="GDS.HUMIDITY">
<logical type="integer" min="0" max="99" unit="%" />
<physical type="integer" interface="command" value_id="HUMIDITY">
<event frame="WEATHER_EVENT" />
</physical>
<description>
<field id="AutoconfRoles" value="WEATHER" />
</description>
</parameter>
</paramset>
<enforce_link>
<value id="LCD_SYMBOL" value="2"/>
<value id="LCD_LEVEL_INTERP" value="1"/>
</enforce_link>
<paramset type="LINK" id="ash550_ch_link" />
</channel>
<channel autoregister="true" index="2" type="ROTARY_HANDLE_SENSOR" count="1" aes_default="false">
<link_roles>
Expand Down Expand Up @@ -114,13 +137,9 @@
<physical type="integer" interface="config" list="1" index="34" size="1" />
<conversion type="float_integer_scale" factor="200" />
</parameter>
<parameter id="TRANSMIT_TRY_MAX">
<logical type="integer" min="1.0" max="10.0" default="6.0" />
<physical type="integer" interface="config" list="1" index="48" size="1" />
</parameter>
</paramset>
<paramset type="VALUES" id="rhs_ch_values">
<parameter id="STATE" operations="read,event" control="RHS.STATE">
<parameter id="STATE" operations="read,event" control="GDS.STATE">
<logical type="option">
<option id="CLOSED" default="true" />
<option id="TILTED" />
Expand Down Expand Up @@ -178,58 +197,25 @@
<value id="SHORT_JT_RAMPON" value="4" />
</enforce_link>
</channel>
<channel autoregister="true" index="3" type="WEATHER" count="1">
<channel index="3" type="SWITCH" count="1">
<link_roles>
<source name="WEATHER_TH" />
<target name="SWITCH"/>
<target name="WEATHER_CS"/>
<target name="WCS_TIPTRONIC_SENSOR"/>
</link_roles>
<paramset type="MASTER" id="ash550_ch_master">
<parameter id="HBWEA_ALTITUDE">
<logical type="integer" min="0" max="10000" default="0" unit="m" />
<physical type="integer" interface="config" list="1" index="6" size="2" />
</parameter>
<parameter id="TEMPERATURE_OFFSET">
<logical type="float" min="-5.0" max="5.0" unit="K" default="0"/>
<physical type="integer" signed="true" interface="config" list="1" index="1" size="4"/>
<conversion type="float_integer_scale" factor="10"/>
</parameter>
<parameter id="HUMIDITY_OFFSET">
<logical type="integer" min="-10" max="10" default="0" unit="%"/>
<physical type="integer" interface="config" list="1" index="5" size="1"/>
<conversion type="sint4_sintx" physical_bytes="1"/>
</parameter>
<paramset type="MASTER" id="switch_ch_master">
<subset ref="switch_paramset"/>
</paramset>
<paramset type="VALUES" id="ash550_ch_values">
<parameter id="TEMPERATURE" operations="read,event">
<logical type="float" min="-40.0" max="80.0" unit="°C" />
<physical type="integer" interface="command" value_id="TEMPERATURE">
<event frame="WEATHER_EVENT" />
</physical>
<conversion type="float_integer_scale" factor="10.0" />
<description>
<field id="AutoconfRoles" value="WEATHER" />
</description>
</parameter>
<parameter id="HUMIDITY" operations="read,event">
<logical type="integer" min="0" max="99" unit="%" />
<physical type="integer" interface="command" value_id="HUMIDITY">
<event frame="WEATHER_EVENT" />
</physical>
<description>
<field id="AutoconfRoles" value="WEATHER" />
</description>
</parameter>
<parameter id="AIR_PRESSURE" operations="read,event">
<logical type="float" min="500.0" max="1100.0" unit="hPa" />
<physical type="integer" interface="command" value_id="AIR_PRESSURE">
<event frame="WEATHER_EVENT" />
</physical>
<conversion type="float_integer_scale" factor="10.0" />
<description>
<field id="AutoconfRoles" value="WEATHER" />
</description>
</parameter>
<paramset type="VALUES" id="switch_ch_values">
<subset ref="switch_valueset"/>
</paramset>
<paramset type="LINK" id="ash550_ch_link" />
<paramset type="LINK" id="switch_ch_link">
<subset ref="switch_linkset"/>
</paramset>
<enforce_link>
<value id="LCD_SYMBOL" value="2"/>
<value id="LCD_LEVEL_INTERP" value="1"/>
</enforce_link>
</channel>
</channels>
<frames>
Expand Down Expand Up @@ -266,10 +252,14 @@
<parameter type="integer" index="11.0" size="1.0" param="STATE"/>
<parameter type="integer" index="9.7" size="0.1" param="LOWBAT"/>
</frame>
<frame id="WEATHER_EVENT" direction="from_device" event="true" fixed_channel="1" type="0x70">
<parameter type="integer" signed="true" index="9.0" size="1.7" param="TEMPERATURE" />
<parameter type="integer" index="11.0" size="1.0" param="HUMIDITY" />
</frame>
</frames>
<paramset_defs>
<paramset id="switch_valueset">
<parameter id="STATE" operations="read,write,event" control="SWITCH.STATE">
<parameter id="STATE" operations="read,write,event" control="GDS.OPENER">
<logical type="boolean" default="false"/>
<physical type="integer" interface="command" value_id="STATE">
<set request="LEVEL_SET"/>
Expand Down Expand Up @@ -316,10 +306,6 @@
<logical type="boolean" default="false"/>
<physical type="boolean" interface="internal" value_id="AES"/>
</parameter>
<parameter id="TRANSMIT_TRY_MAX" operations="read,write">
<logical type="integer" min="0" max="10" default="6"/>
<physical type="integer" interface="config" list="1" index="48" size="1"/>
</parameter>
<parameter id="POWERUP_ACTION" operations="read,write">
<logical type="option">
<option id="POWERUP_OFF" default="true"/>
Expand Down
15 changes: 13 additions & 2 deletions src/addon/patch/common/datapointconfigurator.fn.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- ./patchsource/www/rega/esp/datapointconfigurator.fn.orig
+++ ./patchsource/www/rega/esp/datapointconfigurator.fn
@@ -148,6 +148,19 @@
@@ -148,6 +148,20 @@
var CN_WIN_SC_SENSOR = "WIN_SC_SENSOR.";
var CN_WINDOW = "WINDOW.";

Expand All @@ -10,6 +10,7 @@
+ var CN_SERVO = "SERVO.";
+ var CN_AIRFLAP = "AIRFLAP.";
+ var CN_JPWINDOW = "JPWND.";
+ var CN_GDS = "GDS.";
+ var CN_FAN = "FAN.";
+ var CN_PFS = "PFS.";
+ var CN_LDRSC = "LDRSC.";
Expand All @@ -20,7 +21,7 @@
var CN_EVENT_INTERFACE = "EVENT_INTERFACE.";
var CN_NOT_ACTIVE = "CHANNEL_NOT_ACTIVE";

@@ -369,7 +382,130 @@
@@ -369,7 +383,140 @@
sLastControlName = CN_BTN_SHORT_ONLY;
Call("/esp/controls/button.fn::CreateKeyShortOnly()");
}
Expand Down Expand Up @@ -77,6 +78,16 @@
+ Call("/esp/controls/jpwindow.fn::CreateJPWindowControls()");
+ }
+
+ !# GDS
+ bIsControl = ( sControlName.Find(CN_GDS) > -1 );
+ if( bIsControl && (sLastControlName!=CN_GDS) )
+ {
+ WriteLine( "<script>conInfo('Control CN_GDS found.');</script>" );
+ isKnownControl = true;
+ sLastControlName = CN_GDS;
+ Call("/esp/controls/gds.fn::CreateGDSSensor()");
+ }
+
+ !# AIRFLAP
+ bIsControl = ( sControlName.Find(CN_AIRFLAP) > -1 );
+ if( bIsControl && (sLastControlName!=CN_AIRFLAP) )
Expand Down
34 changes: 20 additions & 14 deletions src/addon/patch/common/webui.js.patch
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- ./patchsource/www/webui/webui.js.orig
+++ ./patchsource/www/webui/webui.js
@@ -88,6 +88,528 @@
@@ -88,6 +88,534 @@
DEV_PATHS["HM-RC-4-3"] = new Object();
DEV_PATHS["HM-RC-4-3"]["50"] = "/config/img/devices/50/84_hm-rc-4-x_thumb.png";
DEV_PATHS["HM-RC-4-3"]["250"] = "/config/img/devices/250/84_hm-rc-4-3.png";
Expand Down Expand Up @@ -76,12 +76,18 @@
+DEV_PATHS['HB-UNI-Sen-WEA'] = new Object();
+DEV_PATHS['HB-UNI-Sen-WEA']['50'] = '/config/img/devices/50/hb-uni-sen-wea_thumb.png';
+DEV_PATHS['HB-UNI-Sen-WEA']['250'] = '/config/img/devices/250/hb-uni-sen-wea.png';
+DEV_HIGHLIGHT['HB-GD-Sw1-THP-TS'] = new Object();
+DEV_LIST.push('HB-GD-Sw1-THP-TS');
+DEV_DESCRIPTION['HB-GD-Sw1-THP-TS']='Garagentor-Aktor, Kontaktschnittstelle und T/H/P-Daten';
+DEV_PATHS['HB-GD-Sw1-THP-TS'] = new Object();
+DEV_PATHS['HB-GD-Sw1-THP-TS']['50'] = '/config/img/devices/50/hb-gd-sw1-thp-ts_thumb.png';
+DEV_PATHS['HB-GD-Sw1-THP-TS']['250'] = '/config/img/devices/250/hb-gd-sw1-thp-ts.png';
+DEV_HIGHLIGHT['HB-GD-Sw1-TH-TS'] = new Object();
+DEV_LIST.push('HB-GD-Sw1-TH-TS');
+DEV_DESCRIPTION['HB-GD-Sw1-TH-TS']='Garagentor-Aktor, Kontaktschnittstelle und Temperatur-/Luftfeuchtemessung';
+DEV_PATHS['HB-GD-Sw1-TH-TS'] = new Object();
+DEV_PATHS['HB-GD-Sw1-TH-TS']['50'] = '/config/img/devices/50/hb-gd-sw1-th-ts_thumb.png';
+DEV_PATHS['HB-GD-Sw1-TH-TS']['250'] = '/config/img/devices/250/hb-gd-sw1-th-ts.png';
+DEV_HIGHLIGHT['HB-Sw1-TH-SC'] = new Object();
+DEV_LIST.push('HB-Sw1-TH-SC');
+DEV_DESCRIPTION['HB-Sw1-TH-SC']='Schalt-Aktor, Kontaktschnittstelle und Temperatur-/Luftfeuchtemessung';
+DEV_PATHS['HB-Sw1-TH-SC'] = new Object();
+DEV_PATHS['HB-Sw1-TH-SC']['50'] = '/config/img/devices/50/hb-sw1-th-sc_thumb.png';
+DEV_PATHS['HB-Sw1-TH-SC']['250'] = '/config/img/devices/250/hb-sw1-sc-ts.png';
+DEV_HIGHLIGHT['HB-UNI-Sen-VOLT'] = new Object();
+DEV_LIST.push('HB-UNI-Sen-VOLT');
+DEV_DESCRIPTION['HB-UNI-Sen-VOLT']='universeller Spannungsmesser';
Expand Down Expand Up @@ -529,7 +535,7 @@
DEV_HIGHLIGHT["HM-RC-4-3"] = new Object();
DEV_HIGHLIGHT["HM-RC-4-3"]["arrow_part1"] = [6, 0.312, 0.288, 0.416, 0.288, 0.012];
DEV_HIGHLIGHT["HM-RC-4-3"]["arrow_part2"] = [6, 0.312, 0.288, 0.352, 0.248, 0.012];
@@ -3843,6 +4365,224 @@
@@ -3843,6 +4371,224 @@
elvST['CAPACITIVE_FILLING_LEVEL_SENSOR|CASE_HIGH'] = '${stringTableCapacitiveFillingSensorCaseHeight}';
elvST['CAPACITIVE_FILLING_LEVEL_SENSOR|CASE_LENGTH'] = '${stringTableCapacitiveFillingSensorCaseLength}';
elvST['CAPACITIVE_FILLING_LEVEL_SENSOR|CASE_WIDTH'] = '${stringTableCapacitiveFillingSensorCaseWidth}';
Expand Down Expand Up @@ -754,7 +760,7 @@
elvST['CAPACITIVE_FILLING_LEVEL_SENSOR|CONTROLTEXT_CALC_FILLINGLEVEL'] = '${stringTableCapacitiveFillingSensorTextCalcFillingLevel}';
elvST['CAPACITIVE_FILLING_LEVEL_SENSOR|CONTROLTEXT_FILLINGLEVEL'] = '${stringTableCapacitiveFillingSensorTextFillingLevel}';
elvST['CAPACITIVE_FILLING_LEVEL_SENSOR|FILLING_LEVEL'] = '${stringTableCapacitiveFillingSensorFillingLevel}';
@@ -13664,7 +14404,7 @@
@@ -13664,7 +14410,7 @@
// Check each line if the free text mode is active.
// If yes switch on the appropriate text input field
// and set the variable freeTextActive to true
Expand All @@ -763,7 +769,7 @@
var jLine = jQuery("#textSelect_" + line),
jCellFreeText = jQuery("#cellFreeText_"+line);

@@ -13680,7 +14420,7 @@
@@ -13680,7 +14426,7 @@
// If at least one line has an active free text mode
// we have to activate the placeholder for the other lines and the header (color and icon are moving up)
if (freeTextActive) {
Expand All @@ -772,7 +778,7 @@
var jLine = jQuery("#textSelect_" + line),
jPlaceHolder = jQuery("#placeHolder_"+line);

@@ -13692,7 +14432,7 @@
@@ -13692,7 +14438,7 @@
}
} else {
jHeadFreeText.hide().css("display", "none");
Expand All @@ -781,7 +787,7 @@
jQuery("#placeHolder_"+line).hide().css("display", "none");
}
}
@@ -23560,6 +24300,24 @@
@@ -23560,6 +24306,24 @@
this.setWidth(400);
this.setFile( "/pages/msg/setOUCFMMode.htm" );
break;
Expand All @@ -806,7 +812,7 @@
case ID_SET_STATUS_DISPLAY:
this.setTitle( translateKey("dialogEnterValue") /*"Wert eingeben" */);
this.addToPostBody( 'string type = "'+this.type+'";' );
@@ -24363,6 +25121,9 @@
@@ -24363,6 +25127,9 @@
ID_AUTO_LOGIN_CONFIG = 1018;
ID_PROGRAM_CHOOSER = 1019;
ID_EDIT_SYSVAR = 1021;
Expand All @@ -816,7 +822,7 @@
ID_CHOOSE_LED = 1022;
ID_SET_OUCFM_MODE = 1023;
ID_SET_STATUS_DISPLAY = 1024;
@@ -36863,7 +37624,15 @@
@@ -36863,7 +37630,15 @@
SetParameters ($F('global_iface'), channel_address, 'CHANNEL_'+i);
actions++;
}
Expand Down
Loading

0 comments on commit 0c284fe

Please sign in to comment.