Skip to content

Commit

Permalink
Changed to alternative Z bias for LS128.
Browse files Browse the repository at this point in the history
Made sensor prescale go to 200 instead of 100.
  • Loading branch information
gbevin committed Sep 18, 2019
1 parent a128c56 commit aea121c
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
16 changes: 15 additions & 1 deletion ls_sensor.ino
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,20 @@ const short Z_BIAS_128_SEPTEMBER2016[MAXROWS][MAXCOLS] = {
{500, 2240, 2080, 1940, 1800, 1720, 1640, 1580, 1540, 1540, 1560, 1600, 1660, 1760, 1880, 2000, 2140, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{500, 2320, 2120, 1980, 1900, 1820, 1740, 1680, 1650, 1660, 1700, 1760, 1820, 1880, 1960, 2060, 2200, 0, 0, 0, 0, 0, 0, 0, 0, 0}
};
// Make LS128 feel more like LS200, here is the LS200 bias array but with the center 9 columns removed:
// delete from here ^ to here ^
const short Z_BIAS_128_SEPTEMBER2019[MAXROWS][MAXCOLS] = {
{350, 1506, 1497, 1417, 1357, 1297, 1241, 1205, 1177, 1109, 1121, 1157, 1209, 1277, 1361, 1441, 1256, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{350, 1506, 1418, 1350, 1282, 1222, 1178, 1150, 1126, 1074, 1086, 1114, 1150, 1214, 1290, 1386, 1256, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{350, 1443, 1359, 1295, 1227, 1175, 1143, 1119, 1095, 1039, 1051, 1079, 1111, 1171, 1243, 1331, 1193, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{350, 1400, 1320, 1260, 1200, 1152, 1120, 1096, 1072, 1020, 1032, 1056, 1088, 1150, 1216, 1293, 1150, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{350, 1400, 1320, 1260, 1200, 1152, 1120, 1096, 1072, 1020, 1032, 1056, 1088, 1150, 1216, 1293, 1150, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{350, 1443, 1359, 1295, 1227, 1175, 1143, 1119, 1095, 1039, 1051, 1079, 1111, 1171, 1243, 1331, 1193, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{350, 1506, 1418, 1350, 1282, 1222, 1178, 1150, 1126, 1074, 1086, 1114, 1150, 1214, 1290, 1386, 1256, 0, 0, 0, 0, 0, 0, 0, 0, 0},
{350, 1506, 1497, 1417, 1357, 1297, 1241, 1205, 1177, 1109, 1121, 1157, 1209, 1277, 1361, 1441, 1256, 0, 0, 0, 0, 0, 0, 0, 0, 0}
};


const short Z_BIAS_MULTIPLIER = 1400;

// readX:
Expand All @@ -51,7 +65,7 @@ void initializeSensors() {
else if (LINNMODEL == 128) {
for (byte r = 0; r < MAXROWS; ++r) {
for (byte c = 0; c < MAXCOLS; ++c) {
Z_BIAS[r][c] = Z_BIAS_128_SEPTEMBER2016[r][c];
Z_BIAS[r][c] = Z_BIAS_128_SEPTEMBER2019[r][c];
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion ls_settings.ino
Original file line number Diff line number Diff line change
Expand Up @@ -2104,7 +2104,7 @@ void handleSensorSensitivityZNewTouch() {
updateDisplay();
}
else if (sensorRow == 0) {
handleNumericDataNewTouchCol(Device.sensorSensitivityZ, 50, 100, false);
handleNumericDataNewTouchCol(Device.sensorSensitivityZ, 50, 200, false);
}
}

Expand Down

0 comments on commit aea121c

Please sign in to comment.