Skip to content

Commit

Permalink
now layout pages support button 9 and 10
Browse files Browse the repository at this point in the history
  • Loading branch information
toyoshim committed Dec 19, 2023
1 parent e01a80f commit 66eba97
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 70 deletions.
4 changes: 4 additions & 0 deletions docs/layout.js
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,8 @@ function applyData(data) {
check('p' + p + buttonMap[i] + '_p' + targetP + '6', d2 & 0x10);
check('p' + p + buttonMap[i] + '_p' + targetP + '7', d2 & 0x08);
check('p' + p + buttonMap[i] + '_p' + targetP + '8', d2 & 0x04);
check('p' + p + buttonMap[i] + '_p' + targetP + '9', d2 & 0x02);
check('p' + p + buttonMap[i] + '_p' + targetP + 'a', d2 & 0x01);
}
}
}
Expand Down Expand Up @@ -331,6 +333,8 @@ function storeTo(data) {
d2 |= isChecked('p' + p + buttonMap[i] + '_p' + targetP + '6') ? 0x10 : 0;
d2 |= isChecked('p' + p + buttonMap[i] + '_p' + targetP + '7') ? 0x08 : 0;
d2 |= isChecked('p' + p + buttonMap[i] + '_p' + targetP + '8') ? 0x04 : 0;
d2 |= isChecked('p' + p + buttonMap[i] + '_p' + targetP + '9') ? 0x02 : 0;
d2 |= isChecked('p' + p + buttonMap[i] + '_p' + targetP + 'a') ? 0x01 : 0;
data[offset++] = d1;
data[offset++] = d2;
}
Expand Down
Loading

0 comments on commit 66eba97

Please sign in to comment.