diff --git a/mesh-bot.py b/mesh-bot.py index ab394f9..59c7830 100644 --- a/mesh-bot.py +++ b/mesh-bot.py @@ -65,12 +65,16 @@ def auto_response(message,snr,rssi,hop,message_from_id): elif "help" in message.lower(): bot_response = help_message elif "sun" in message.lower(): - suntime = get_sunrise_sunset(get_node_location(message_from_id)) + location = get_node_location(message_from_id) + lat = location[0] + lon = location[1] + print (f"Using Reported Location: {location}") + suntime = get_sunrise_sunset(lat,lon) bot_response = "Sunrise: " + suntime[0] + "\nSunset: " + suntime[1] elif "hfcond" in message.lower(): bot_response = hf_band_conditions() elif "solar" in message.lower(): - bot_response = drap_xray_conditions() + "\n" + solar_conditions(get_node_location) + bot_response = drap_xray_conditions() + "\n" + solar_conditions() elif "lheard" in message.lower(): bot_response = "Last 5 nodes heard: " + str(get_node_list()) else: