Skip to content

Commit 1789377

Browse files
committed
rework #411, add temporary workaround for unesired bai conditional load
1 parent b84b24d commit 1789377

File tree

5 files changed

+1023
-2
lines changed

5 files changed

+1023
-2
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"csvall": "./csvall.sh",
1313
"compile-en": "npx tsp compile --emit @ebusd/ebus-typespec src/main.tsp --output-dir outcsv",
1414
"compile-de": "npx tsp compile --emit @ebusd/ebus-typespec --option @ebusd/ebus-typespec.translations=src/de.yaml src/main.tsp --output-dir outcsv.de",
15-
"compile": "npm run compile-en && npm run compile-de"
15+
"compile": "npm run compile-en && npm run compile-de && sed -i -e 's#.*id_15_id.*##' outcsv*/@ebusd/ebus-typespec/vaillant/08.bai.csv"
1616
},
1717
"repository": {
1818
"type": "git",
@@ -38,7 +38,7 @@
3838
"typescript": "^5.9.2"
3939
},
4040
"dependencies": {
41-
"@ebusd/ebus-typespec": ">=0.23.0",
41+
"@ebusd/ebus-typespec": ">=0.24.0",
4242
"@typespec/compiler": "~1.4.0",
4343
"tsx": "^4.20.6"
4444
}

src/vaillant/08.bai.tsp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import "./bai.0020066007_inc.tsp";
1818
import "./bai.308523_inc.tsp";
1919
import "./bai.0010021901_inc.tsp";
2020
import "./bai.0010021961_inc.tsp";
21+
import "./bai.0010043897_inc.tsp";
2122
import "./bai.0010008045_inc.tsp";
2223
import "./errors_inc.tsp";
2324
import "./hcmode_inc.tsp";
@@ -347,6 +348,9 @@ namespace Bai {
347348
@condition(Scan.Id.product, "='0010008045'", "'0010008863'", "'0010023648'")
348349
Scan_Id_product_0010008045: Bai._0010008045_inc,
349350

351+
@condition(Scan.Id.product, "='0010043897'")
352+
Scan_Id_product_0010043897: Bai._0010043897_inc,
353+
350354
@condition(Id.Id.hw, "=6701")
351355
hw_6701: Bai._0010003886_inc,
352356

@@ -380,6 +384,9 @@ namespace Bai {
380384
@condition(Id.Id.hw, "=4702")
381385
hw_4702: Bai._0010008045_inc,
382386

387+
@condition(Id.Id.hw, "=7603")
388+
hw_7603: Bai._0010043897_inc,
389+
383390
// final load alternative
384391
default: Bai._308523_inc,
385392

src/vaillant/_templates.tsp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -314,6 +314,10 @@ scalar energyr extends UIR;
314314
@unit("kWh")
315315
scalar energy4 extends ULG;
316316

317+
@unit("kWh")
318+
@divisor(1000)
319+
scalar energye extends EXP;
320+
317321
/** start count */
318322
scalar cntstarts extends ULG;
319323

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import "@ebusd/ebus-typespec";
2+
import "./_templates.tsp";
3+
import "./bai.emm_inc.tsp";
4+
import "./bai.308523_inc.tsp";
5+
using Ebus;
6+
using Ebus.Num;
7+
using Ebus.Dtm;
8+
using Ebus.Str;
9+
namespace Vaillant;
10+
11+
namespace Bai._0010043897_inc {
12+
// ,BAI00,ecoTEC plus 0010043897 VC 15CS/1-5 (HW 7603) combined with sensoDIRECT 0020274790 VRC710 ("EMM00")
13+
14+
/** included parts */
15+
union _includes {
16+
Bai._308523_inc,
17+
18+
@conditionExt(Id.Id.id, 0x15, "='EMM00'")
19+
emm: Bai.Emm_inc,
20+
}
21+
}

0 commit comments

Comments
 (0)