Small bug fix relating to interrupts afecting file transfer
parent
916a3b054c
commit
e2c33faf79
|
@ -676,6 +676,7 @@ def btsppwrite(connection, data):
|
||||||
# Receive data from a Bluetooth serial connection
|
# Receive data from a Bluetooth serial connection
|
||||||
def btsppread(connection):
|
def btsppread(connection):
|
||||||
command()
|
command()
|
||||||
|
global holdoffirq
|
||||||
# Don't let the interupt process the buffer mid command
|
# Don't let the interupt process the buffer mid command
|
||||||
holdoffirq = True
|
holdoffirq = True
|
||||||
request = "AT+BTSPPGET=3," + str(connection) + "\n"
|
request = "AT+BTSPPGET=3," + str(connection) + "\n"
|
||||||
|
@ -778,6 +779,7 @@ def fscreate(filename):
|
||||||
|
|
||||||
# Read a chunk of data from a file on the flash storage
|
# Read a chunk of data from a file on the flash storage
|
||||||
def fsreadpart(filename, size=256, start=0):
|
def fsreadpart(filename, size=256, start=0):
|
||||||
|
global holdoffirq
|
||||||
mode=int(start>0)
|
mode=int(start>0)
|
||||||
command()
|
command()
|
||||||
# Don't let the interupt process the buffer mid command
|
# Don't let the interupt process the buffer mid command
|
||||||
|
@ -846,8 +848,8 @@ def callbuttonpressed_internal(nullparam=None):
|
||||||
def endbuttonpressed_internal(nullparam=None):
|
def endbuttonpressed_internal(nullparam=None):
|
||||||
hangup()
|
hangup()
|
||||||
|
|
||||||
# Startup...
|
|
||||||
|
|
||||||
|
# Startup...
|
||||||
|
|
||||||
# Start turning on the SIM800 asynchronously
|
# Start turning on the SIM800 asynchronously
|
||||||
onatstart = poweron(True)
|
onatstart = poweron(True)
|
||||||
|
|
Loading…
Reference in New Issue