Skip to content

Commit

Permalink
(simatec) X1-Hybrid-G4 added
Browse files Browse the repository at this point in the history
  • Loading branch information
simatec committed Oct 23, 2023
1 parent 324cb89 commit 3ee5b57
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 4 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,9 @@ When the adapter crashes or an other Code error happens, this error message that

## Changelog
<!-- ### __WORK IN PROGRESS__ -->
### __WORK IN PROGRESS__
* (simatec) X1-Hybrid-G4 added

### 0.7.7 (2023-09-06)
* (simatec) Dependencies updated
* (simatec) small Bugfix
Expand Down
31 changes: 30 additions & 1 deletion lib/inverterData.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 7 additions & 3 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -484,17 +484,20 @@ async function requestLocalAPI(root_dataPoints, information_dataPoints, data_dat
type = 5;
break;
case 14:
case 15:
//case 15:
type = 4;
break;
case 15:
type = 6;
break;
default:
type = 1;
break;
}

for (const key in apiData) {
const dataPoint = root_dataPoints[key.toLowerCase()];

if (!dataPoint) continue;
let data = apiData[key]
if (key == 'type' && _inverterType[data]) {
Expand Down Expand Up @@ -582,7 +585,8 @@ async function resetValues(data_dataPoints) {
2: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 39, 48, 50, 52],
3: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 74, 76, 78, 80],
4: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 34, 39, 40, 41, 47, 90, 92, 103, 105],
5: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 72, 74, 76, 78,]
5: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 72, 74, 76, 78,],
6: [0, 1, 2, 4, 5, 6, 7, 8, 9, 10, 14, 15, 16, 17, 18, 32, 34, 36],
};

for (const value of valuesOfReset[type]) {
Expand Down

0 comments on commit 3ee5b57

Please sign in to comment.