diff --git a/pong-bot.py b/pong-bot.py index 49bf7ec..c760d80 100644 --- a/pong-bot.py +++ b/pong-bot.py @@ -15,7 +15,7 @@ interface = meshtastic.serial_interface.SerialInterface() #serial interface #interface=meshtastic.tcp_interface.TCPInterface(hostname="192.168.0.1") # IP of your device #interface=meshtastic.ble_interface.BLEInterface("AA:BB:CC:DD:EE:FF") # BLE interface -trap_list = ("ping","ack","testing") #A list of strings to trap and respond to +trap_list = ("ping","ack","testing","pong") #A list of strings to trap and respond to help_message = "PongBot, here for you like a friend who is not. Try: ping@foo" RESPOND_BY_DM_ONLY = True # Set to True to respond messages via DM only (keeps the channel clean) @@ -38,6 +38,8 @@ def auto_response(message,snr,rssi): bot_response = "ACK-ACK!" + f" SNR: {snr} RSSI: {rssi}" elif "testing" in message.lower(): bot_response = "Testing 1,2,3" + elif "pong" in message.lower(): + bot_response = "PING!!" else: bot_response = "I'm sorry, I'm afraid I can't do that."