Merge pull request #103 from renzenicolai/master

Bugfixes and strobe
sammachin-gprs
Marek Ventur 2018-09-02 19:27:49 +01:00 committed by GitHub
commit 6168dee15a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 0 deletions

BIN
holland/brenno.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 136 KiB

View File

@ -111,6 +111,8 @@ def cbButton1(button_id):
ugfx.display_image(0, 0, "holland/eu.png")
def cbButton2(button_id):
sim800.speakervolume(100)
sim800.stopplayback()
show_screen(0x000000, 0xFFFFFF, "PLAY")
a = sim800.startplayback(1,0,100)
if not a:
@ -148,6 +150,11 @@ def cbButton8(button_id):
def cbButton9(button_id):
global strobe
strobe = False
def cbButtonHash(button_id):
global vip
vip = False
ugfx.display_image(0, 0, "holland/brenno.png")
Buttons.enable_interrupt(
Buttons.BTN_Call,
@ -221,6 +228,12 @@ Buttons.enable_interrupt(
on_press=True,
on_release=False);
Buttons.enable_interrupt(
Buttons.BTN_Hash,
cbButtonHash,
on_press=True,
on_release=False);
vip = True
aaa = False
@ -238,5 +251,7 @@ while True:
else:
n.display([0x000000, 0x000000])
aaa = True
if not vip:
time.sleep(0.1)
else:
time.sleep(0.1)