Доработка. Добавлено время в 8 пакет для КАПС РПБ.

This commit is contained in:
MaD_CaT
2025-09-02 13:37:45 +03:00
parent 422accf4c7
commit 99e62036fd

View File

@@ -185,6 +185,7 @@ func _ready() -> void:
func on_nav_data_received(coords: Dictionary, unit_caps):
var ship_time = Time.get_datetime_dict_from_system()
var data_to_json = {
'ts': 8,
'ss': msg8_num,
@@ -193,7 +194,13 @@ func on_nav_data_received(coords: Dictionary, unit_caps):
'long': coords.get('longitude', 0),
'lat': coords.get('latitude', 0),
'course': coords.get('k', 0),
'speed': coords.get('speed', 0) }
'speed': coords.get('speed', 0),
'year': ship_time['year'],
'month': ship_time['month'],
'day': ship_time['day'],
'hour': ship_time['hour'],
'minute': ship_time['minute'],
'second': ship_time['second'],}
var json_data = JSON.stringify(data_to_json).to_utf8_buffer()
unit_caps.tx_stack.append(json_data)
msg8_num += 1