Sun module Time display #4

Closed
opened 2026-10-05 01:15:15 +02:00 by adam · 8 comments
Owner

If you write a SUN to the autoresponder, the output

SunRise: Mon 22 05:45
Set: Mon 22 09:10

is displayed
Is it possible to display sunrise and sunset times in 24 hours? Or at least that an AM and PM is employed.

If you write a `SUN` to the autoresponder, the output ``` SunRise: Mon 22 05:45 Set: Mon 22 09:10 ``` is displayed Is it possible to display sunrise and sunset times in 24 hours? Or at least that an AM and PM is employed. <!-- github-sync-id:2421278123 -->
adam closed this issue 2026-10-05 01:15:15 +02:00
Author
Owner

Yea I will get a 24:00 in soon

Yea I will get a 24:00 in soon <!-- github-comment-id:2241712974 -->
Author
Owner

should be resolved @Hailo1999

should be resolved @Hailo1999 <!-- github-comment-id:2248897273 -->
Author
Owner

will try when u fix the Fetch error

will try when u fix the Fetch error <!-- github-comment-id:2252067141 -->
Author
Owner

I tryed Sun... ;) Over IP Node autorespoder

2024-07-26 09:09:48 Received DM: Sun on Device:0 Channel: 0 From: 1128192892
ERROR:root:Unexpected error in deferred execution <class 'TypeError'>
Traceback (most recent call last):
  File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/meshtastic/util.py", line 283, in _run
    o()
  File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/meshtastic/mesh_interface.py", line 1190, in <lambda>
    lambda: pub.sendMessage(topic, packet=asDict, interface=self)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/pubsub/core/publisher.py", line 216, in sendMessage
    topicObj.publish(**msgData)
  File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/pubsub/core/topicobj.py", line 452, in publish
    self.__sendMessage(msgData, topicObj, msgDataSubset)
  File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/pubsub/core/topicobj.py", line 482, in __sendMessage
    listener(data, self, allData)
  File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/pubsub/core/listener.py", line 237, in __call__
    cb(**kwargs)
  File "/home/hailo/meshing-around/mesh_bot.py", line 238, in onReceive
    send_message(auto_response(message_string, snr, rssi, hop, message_from_id, channel_number, rxNode), channel_number, message_from_id, rxNode)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/hailo/meshing-around/mesh_bot.py", line 61, in auto_response
    bot_response = get_sun(str(location[0]),str(location[1]))
                               ~~~~~~~~^^^
TypeError: 'NoneType' object is not subscriptable
I tryed Sun... ;) **Over IP Node autorespoder** ``` 2024-07-26 09:09:48 Received DM: Sun on Device:0 Channel: 0 From: 1128192892 ERROR:root:Unexpected error in deferred execution <class 'TypeError'> Traceback (most recent call last): File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/meshtastic/util.py", line 283, in _run o() File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/meshtastic/mesh_interface.py", line 1190, in <lambda> lambda: pub.sendMessage(topic, packet=asDict, interface=self) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/pubsub/core/publisher.py", line 216, in sendMessage topicObj.publish(**msgData) File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/pubsub/core/topicobj.py", line 452, in publish self.__sendMessage(msgData, topicObj, msgDataSubset) File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/pubsub/core/topicobj.py", line 482, in __sendMessage listener(data, self, allData) File "/home/hailo/meshing-around/venv/lib/python3.12/site-packages/pubsub/core/listener.py", line 237, in __call__ cb(**kwargs) File "/home/hailo/meshing-around/mesh_bot.py", line 238, in onReceive send_message(auto_response(message_string, snr, rssi, hop, message_from_id, channel_number, rxNode), channel_number, message_from_id, rxNode) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/hailo/meshing-around/mesh_bot.py", line 61, in auto_response bot_response = get_sun(str(location[0]),str(location[1])) ~~~~~~~~^^^ TypeError: 'NoneType' object is not subscriptable ``` <!-- github-comment-id:2252117793 -->
Author
Owner

Tryed Sun over Serial connected Node Autoresponder:

2024-07-26 09:29:02 Received DM: sun on Device:1 Channel: 0 From: T-Deck (868)
2024-07-26 09:29:02 System: Error processing packet: 'latitude' Device:1
{'from': 860383800, 'to': 1128192892, 'decoded': {'portnum': 'TEXT_MESSAGE_APP', 'payload': b'sun', 'text': 'sun'}, 'id': 3682336776, 'rxTime': 1721978943, 'rxSnr': 5.75, 'hopLimit': 3, 'wantAck': True, 'rxRssi': -12, 'hopStart': 3, 'raw': from: 860383800
to: 1128192892
decoded {
  portnum: TEXT_MESSAGE_APP
  payload: "sun"
}
id: 3682336776
rx_time: 1721978943
rx_snr: 5.75
hop_limit: 3
want_ack: true
rx_rssi: -12
hop_start: 3
, 'fromId': '!33486a38', 'toId': '!433edb7c'}
END of packet 
Tryed Sun over Serial connected Node Autoresponder: ``` 2024-07-26 09:29:02 Received DM: sun on Device:1 Channel: 0 From: T-Deck (868) 2024-07-26 09:29:02 System: Error processing packet: 'latitude' Device:1 {'from': 860383800, 'to': 1128192892, 'decoded': {'portnum': 'TEXT_MESSAGE_APP', 'payload': b'sun', 'text': 'sun'}, 'id': 3682336776, 'rxTime': 1721978943, 'rxSnr': 5.75, 'hopLimit': 3, 'wantAck': True, 'rxRssi': -12, 'hopStart': 3, 'raw': from: 860383800 to: 1128192892 decoded { portnum: TEXT_MESSAGE_APP payload: "sun" } id: 3682336776 rx_time: 1721978943 rx_snr: 5.75 hop_limit: 3 want_ack: true rx_rssi: -12 hop_start: 3 , 'fromId': '!33486a38', 'toId': '!433edb7c'} END of packet ``` <!-- github-comment-id:2252148571 -->
Author
Owner

fixed this, thanks for this one as well!

fixed this, thanks for this one as well! <!-- github-comment-id:2252197280 -->
Author
Owner

over serial connected autoresponder it runs well but not on IP based autoresponder

over serial connected autoresponder it runs well but not on IP based autoresponder <!-- github-comment-id:2254186132 -->
Author
Owner

In going to close the sun issue as resolved. Can you open a new issue for the tcp issue? I will try and test using a heltec v3 in the meanwhile. but also check this out for likely all similar boards

https://github.com/meshtastic/firmware/issues/3618

In going to close the sun issue as resolved. Can you open a new issue for the tcp issue? I will try and test using a heltec v3 in the meanwhile. but also check this out for likely all similar boards https://github.com/meshtastic/firmware/issues/3618 <!-- github-comment-id:2254220870 -->
Sign in to join this conversation.
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: adam/meshing-around#4