Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MPR121 Touch IC Based Keypad Input Module #5103

Merged
merged 32 commits into from
Oct 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
3d1503e
For testing, switching to t3s3 platform
aussieklutz Oct 19, 2024
e6829a8
Merge branch 'meshtastic:master' into mpr121_v2
aussieklutz Oct 19, 2024
dbee1ff
Added flag to use MPR121 on default address, a the expense of MLX90614
aussieklutz Oct 19, 2024
4c7c59d
Added MPR121 keyboard I2C detection
aussieklutz Oct 19, 2024
d8bf9a5
Merge branch 'mpr121_v2' of https://github.com/aussieklutz/meshtastic…
aussieklutz Oct 19, 2024
080fcd6
Adding MPR121 to keyboard detection
aussieklutz Oct 19, 2024
f6a0706
Added MPR121 implementation v1
aussieklutz Oct 19, 2024
a9d69b0
Adding MPR121 instance to kbI2cBase
aussieklutz Oct 19, 2024
76e10d3
Completed MPR121 reset method
aussieklutz Oct 20, 2024
b234404
Switch back to old soft reset method
aussieklutz Oct 20, 2024
bce930d
Removing config loop.
aussieklutz Oct 20, 2024
8c87e5e
Cleanup reset.
aussieklutz Oct 20, 2024
ed29573
Fixed "Pressed" not changing state to "Held"
aussieklutz Oct 20, 2024
ff6a3c8
Merge branch 'meshtastic:master' into mpr121_v3
aussieklutz Oct 20, 2024
dd2e095
Reset testing config back to match original config
aussieklutz Oct 20, 2024
6212859
Merge branch 'mpr121_v3' of https://github.com/aussieklutz/meshtastic…
aussieklutz Oct 20, 2024
1b2c471
Fix warnings on t-echo re: member variable initialisation
aussieklutz Oct 20, 2024
7f1b675
Merge branch 'master' into mpr121_v3
thebentern Oct 20, 2024
ad5175f
Linted Codebase
aussieklutz Oct 20, 2024
5cf67fd
Made keymap and others unique
aussieklutz Oct 20, 2024
5e486a8
trunk fmt
aussieklutz Oct 20, 2024
d74cfc7
Alt detection mode test
aussieklutz Oct 20, 2024
444d3de
Update ScanI2CTwoWire.cpp
aussieklutz Oct 20, 2024
8e15b32
Switching to MLX90614 detection of 0x5a in bus address 0x0e
aussieklutz Oct 20, 2024
4326451
Fixed register read address to 0x0e
aussieklutz Oct 20, 2024
98dfdbf
Trunked...
aussieklutz Oct 20, 2024
ff25656
Remove logic to blink the fn symbol.
aussieklutz Oct 20, 2024
fa644a9
Merge pull request #1 from aussieklutz/mpr121_v3_alt_detection
aussieklutz Oct 20, 2024
8b3099e
Merge branch 'meshtastic:master' into mpr121_v3
aussieklutz Oct 20, 2024
0b90f05
Merge branch 'master' into mpr121_v3
thebentern Oct 21, 2024
992e282
Update MPR121Keyboard.cpp
aussieklutz Oct 21, 2024
24d889c
trunk fmt
fifieldt Oct 21, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define CARDKB_ADDR 0x5F
#define TDECK_KB_ADDR 0x55
#define BBQ10_KB_ADDR 0x1F
#define MPR121_KB_ADDR 0x5A

// -----------------------------------------------------------------------------
// SENSOR
Expand Down
4 changes: 2 additions & 2 deletions src/detect/ScanI2C.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ ScanI2C::FoundDevice ScanI2C::firstRTC() const

ScanI2C::FoundDevice ScanI2C::firstKeyboard() const
{
ScanI2C::DeviceType types[] = {CARDKB, TDECKKB, BBQ10KB, RAK14004};
return firstOfOrNONE(4, types);
ScanI2C::DeviceType types[] = {CARDKB, TDECKKB, BBQ10KB, RAK14004, MPR121KB};
return firstOfOrNONE(5, types);
}

ScanI2C::FoundDevice ScanI2C::firstAccelerometer() const
Expand Down
3 changes: 2 additions & 1 deletion src/detect/ScanI2C.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ class ScanI2C
STK8BAXX,
ICM20948,
MAX30102,
TPS65233
TPS65233,
MPR121KB
} DeviceType;

// typedef uint8_t DeviceAddress;
Expand Down
13 changes: 12 additions & 1 deletion src/detect/ScanI2CTwoWire.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ void ScanI2CTwoWire::scanPort(I2CPort port, uint8_t *address, uint8_t asize)

SCAN_SIMPLE_CASE(TDECK_KB_ADDR, TDECKKB, "T-Deck keyboard found");
SCAN_SIMPLE_CASE(BBQ10_KB_ADDR, BBQ10KB, "BB Q10 keyboard found");

SCAN_SIMPLE_CASE(ST7567_ADDRESS, SCREEN_ST7567, "st7567 display found");
#ifdef HAS_NCP5623
SCAN_SIMPLE_CASE(NCP5623_ADDR, NCP5623, "NCP5623 RGB LED found");
Expand Down Expand Up @@ -408,7 +409,17 @@ void ScanI2CTwoWire::scanPort(I2CPort port, uint8_t *address, uint8_t asize)
#ifdef HAS_TPS65233
SCAN_SIMPLE_CASE(TPS65233_ADDR, TPS65233, "TPS65233 BIAS-T found");
#endif
SCAN_SIMPLE_CASE(MLX90614_ADDR_DEF, MLX90614, "MLX90614 IR temp sensor found");

case MLX90614_ADDR_DEF:
registerValue = getRegisterValue(ScanI2CTwoWire::RegisterLocation(addr, 0x0e), 1);
if (registerValue == 0x5a) {
type = MLX90614;
LOG_INFO("MLX90614 IR temp sensor found");
} else {
type = MPR121KB;
LOG_INFO("MPR121KB keyboard found");
}
break;

case ICM20948_ADDR: // same as BMX160_ADDR
case ICM20948_ADDR_ALT: // same as MPU6050_ADDR
Expand Down
Loading
Loading