mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
* MomentaryButton: added support for analog button (with threshold)
* RAK: support for PIN_USER_BTN_ANA
This commit is contained in:
parent
b8223e9d07
commit
74722c24b8
5 changed files with 39 additions and 3 deletions
|
|
@ -11,6 +11,10 @@ RAK4631Board board;
|
|||
#ifdef DISPLAY_CLASS
|
||||
DISPLAY_CLASS display;
|
||||
MomentaryButton user_btn(PIN_USER_BTN, 1000, true);
|
||||
|
||||
#if defined(PIN_USER_BTN_ANA)
|
||||
MomentaryButton analog_btn(PIN_USER_BTN_ANA, 1000, 20);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
RADIO_CLASS radio = new Module(P_LORA_NSS, P_LORA_DIO_1, P_LORA_RESET, P_LORA_BUSY, SPI);
|
||||
|
|
|
|||
|
|
@ -13,6 +13,9 @@
|
|||
extern DISPLAY_CLASS display;
|
||||
#include <helpers/ui/MomentaryButton.h>
|
||||
extern MomentaryButton user_btn;
|
||||
#if defined(PIN_USER_BTN_ANA)
|
||||
extern MomentaryButton analog_btn;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
extern RAK4631Board board;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue