Skip to content

Commit 638b76a

Browse files
committed
fix(EquipmentStateMessage): add support for v3.x i5P personality byte [3,1]
#1223
1 parent 5d92d7d commit 638b76a

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

controller/comms/messages/status/EquipmentStateMessage.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,19 +102,20 @@ export class EquipmentStateMessage {
102102
// [1,5] = i10+3d
103103
// IntelliCenter v3.x reports model1=3 with model2 carrying the panel/expansion variant
104104
// (same convention IntelliTouch used for the `[1, N]` family above). Observed so far:
105+
// [3, 1] = v3.x i5P personality (Discussion #1223 / ISSUE-001)
105106
// [3, 2] = v3.004+ i8PS / i10PS personality card only
106107
// [3, 3] = v3.008 i10D personality card + i10X expansion panels (Discussion #1171 / ISSUE-081)
107108
// EasyTouch ET24P ALSO reports model1=3 (with model2 in {13,14}; see
108109
// EasyTouchBoard.expansionBoards), and IntelliTouch reuses model2 in {0..5}, so
109110
// model1=3 alone is NOT a safe IntelliCenter-v3 marker. Disambiguate by requiring
110-
// BOTH that model2 is a known v3 personality byte ({2,3} above) AND header[1]===1
111+
// BOTH that model2 is a known v3 personality byte ({1,2,3} above) AND header[1]===1
111112
// (IntelliCenter uses header[1]=1; Touch systems use other values, e.g. 18).
112113
// This rejects EasyTouch ([3,13]/[3,14]) while preserving the #1171 / ISSUE-081
113114
// fix for v3.008 i10D + i10X ([3,3]). If a future v3 personality appears, add its
114115
// model2 byte to the set below (and to the variant table at lines 105-106).
115116
if ((model2 === 0 && (model1 === 23 || model1 >= 40)) ||
116117
(model2 === 2 && model1 == 0 && msg.header[1] === 1) ||
117-
(model1 === 3 && (model2 === 2 || model2 === 3) && msg.header[1] === 1)) {
118+
(model1 === 3 && (model2 === 1 || model2 === 2 || model2 === 3) && msg.header[1] === 1)) {
118119
state.equipment.controllerType = 'intellicenter';
119120
sys.board.modulesAcquired = false;
120121
sys.controllerType = ControllerType.IntelliCenter;

0 commit comments

Comments
 (0)