mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
✨ feat: add vibration feedback support for UI events
- Add genericVibration class with 5-second cooldown and 1-second pulse - Integrate vibration triggers for new messages and contact discoveries - Add conditional compilation support with PIN_VIBRATION guard - Implement abstract interface for vibration in UITask system
This commit is contained in:
parent
d86851b881
commit
2da50882c0
6 changed files with 112 additions and 0 deletions
|
|
@ -244,6 +244,11 @@ void MyMesh::onDiscoveredContact(ContactInfo &contact, bool is_new, uint8_t path
|
|||
} else {
|
||||
#ifdef DISPLAY_CLASS
|
||||
if (_ui) _ui->soundBuzzer(UIEventType::newContactMessage);
|
||||
if (_ui) {
|
||||
#ifdef PIN_VIBRATION
|
||||
if (is_new) _ui->triggerVibration();
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue