Skip to content

Commit

Permalink
MPR121QR2 is not the same controller as MPR121
Browse files Browse the repository at this point in the history
  • Loading branch information
rwaldron committed May 5, 2015
1 parent 4dd3998 commit b0f6810
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 11 deletions.
8 changes: 4 additions & 4 deletions eg/keypad-MPR121.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@ var five = require("../");
var board = new five.Board();

board.on("ready", function() {
// MPR121 3x3 Capacitive Touch Pad
// MPR121QR2 3x3 Capacitive Touch Pad
var keypad;

if (argv.show === 1) {
keypad = new five.Keypad({
controller: "MPR121",
controller: "MPR121QR2",
address: 0x5A
});
}

if (argv.show === 2) {
keypad = new five.Keypad({
controller: "MPR121",
controller: "MPR121QR2",
address: 0x5A,
keys: [
["!", "@", "#"],
Expand All @@ -28,7 +28,7 @@ board.on("ready", function() {

if (argv.show === 3) {
keypad = new five.Keypad({
controller: "MPR121",
controller: "MPR121QR2",
address: 0x5A,
keys: ["!", "@", "#", "$", "%", "^", "&", "-", "+"]
});
Expand Down
7 changes: 0 additions & 7 deletions lib/keypad.js
Original file line number Diff line number Diff line change
Expand Up @@ -316,13 +316,6 @@ var Controllers = {
}
};





// Otherwise known as...
Controllers["MPR121"] = Controllers.MPR121QR2;

function touches(length) {
return Array.from({ length: length }, function() {
return 0;
Expand Down

0 comments on commit b0f6810

Please sign in to comment.