Skip to content

Commit 4885084

Browse files
author
brentru
committed
add RI pin to sms_response example
1 parent 808019e commit 4885084

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

adafruit_fona/adafruit_fona.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,6 @@ def receive_sms(self):
449449
if self._ri is not None: # poll the RI pin
450450
if self._ri.value:
451451
return False, False
452-
453452
if not self._uart.in_waiting: # otherwise, poll the UART
454453
return False, False
455454

examples/fona_sms_response.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,14 @@
1111
# Create a serial connection for the FONA connection
1212
uart = busio.UART(board.TX, board.RX)
1313
rst = digitalio.DigitalInOut(board.D4)
14+
# Ring Indicator (RI) interrupt pin
15+
ri = digitalio.DigitalInOut(board.D5)
1416

1517
# Use this for FONA800 and FONA808
16-
fona = FONA(uart, rst)
18+
fona = FONA(uart, rst, ri)
1719

1820
# Use this for FONA3G
19-
# fona = FONA3G(uart, rst)
21+
# fona = FONA3G(uart, rst, ri)
2022

2123
# Initialize Network
2224
while fona.network_status != 1:

0 commit comments

Comments
 (0)