Skip to content

Commit bf7b0fb

Browse files
Tested and finalised version 3.0.0
1 parent ad4aa79 commit bf7b0fb

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

README.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -126,10 +126,10 @@ This simple script showcases the usage of this library using a single button.
126126
127127
128128
actions = {
129-
ButtonInput("DOUBLE_PRESS", callback=double_press),
130-
ButtonInput("SHORT_PRESS", callback=short_press),
131-
ButtonInput("LONG_PRESS", callback=long_press),
132-
ButtonInput("HOLD", callback=hold),
129+
ButtonInput(ButtonInput.DOUBLE_PRESS, callback=double_press),
130+
ButtonInput(ButtonInput.SHORT_PRESS, callback=short_press),
131+
ButtonInput(ButtonInput.LONG_PRESS, callback=long_press),
132+
ButtonInput(ButtonInput.HOLD, callback=hold),
133133
}
134134
135135
scanner = Keys([board.D9], value_when_pressed=False)

examples/button_handler_doublebutton.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def triple_press_0():
3434

3535
def triple_press_1():
3636
if button_0.is_pressed:
37-
triple_press_0_holding_1()
37+
triple_press_1_holding_0()
3838
return
3939
print("Button 1 has been triple pressed!")
4040

examples/button_handler_singlebutton.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
import board
99
from keypad import Keys
1010

11-
from button_handler import ButtonHandler, ButtonInitConfig, ButtonInput
11+
from button_handler import ButtonHandler, ButtonInput
1212

1313

1414
def double_press():

0 commit comments

Comments
 (0)