Compare commits
5 Commits
17460b5b0d
...
b7fa8cca66
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b7fa8cca66 | ||
|
|
5dac4fae5e | ||
|
|
02f8a6a8c5 | ||
|
|
9e74a67e86 | ||
|
|
0497a5dadb |
|
Before Width: | Height: | Size: 3.3 KiB After Width: | Height: | Size: 3.7 KiB |
|
Before Width: | Height: | Size: 3.0 KiB After Width: | Height: | Size: 3.7 KiB |
|
Before Width: | Height: | Size: 4.1 KiB After Width: | Height: | Size: 4.9 KiB |
|
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 5.4 KiB |
|
Before Width: | Height: | Size: 3.8 KiB After Width: | Height: | Size: 4.6 KiB |
|
Before Width: | Height: | Size: 3.6 KiB After Width: | Height: | Size: 4.5 KiB |
|
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 3.8 KiB |
|
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 3.6 KiB |
|
Before Width: | Height: | Size: 4.1 KiB After Width: | Height: | Size: 4.9 KiB |
|
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 5.4 KiB |
|
Before Width: | Height: | Size: 3.9 KiB After Width: | Height: | Size: 4.6 KiB |
|
Before Width: | Height: | Size: 3.7 KiB After Width: | Height: | Size: 4.5 KiB |
|
Before Width: | Height: | Size: 3.0 KiB After Width: | Height: | Size: 3.9 KiB |
|
Before Width: | Height: | Size: 7.8 KiB After Width: | Height: | Size: 3.6 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 18 KiB |
BIN
data/Приём.png
|
Before Width: | Height: | Size: 3.7 KiB After Width: | Height: | Size: 3.8 KiB |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 2.2 KiB |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 2.2 KiB |
|
Before Width: | Height: | Size: 2.5 KiB After Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 2.7 KiB After Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 2.2 KiB |
|
Before Width: | Height: | Size: 4.3 KiB After Width: | Height: | Size: 6.1 KiB |
@@ -8,7 +8,7 @@ const TableHeader = preload('res://table/header.tscn') ## Ячейка за
|
||||
const TABLE_HEADER = [ TableHeader, TableHeader, TableHeader , TableHeader ] ## Описание ряда заголовка.
|
||||
const TABLE_ROW = [ CellLineEdit, CellLineEdit, CellLineEdit , CellLineEdit ] ## Описание ряда.
|
||||
const TABLE_HEADERS_TEXT = ['№', 'Название', 'Пеленг', 'Состояние' ] ## Заголовки таблицы.
|
||||
const TABLE_COLUMN_SIZE = [ 65, 100, 90, 170 ] ## Ширины колонок.
|
||||
const TABLE_COLUMN_SIZE = [ 65, 100, 95, 185 ] ## Ширины колонок.
|
||||
|
||||
## Состояние выполнения сеанса помехи
|
||||
const INTERFER_STATE = {
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
[ext_resource type="PackedScene" uid="uid://musb21x2u0xs" path="res://scenes/эмс2/эмс2.tscn" id="6_41d34"]
|
||||
[ext_resource type="PackedScene" uid="uid://bnptm4rlp60dq" path="res://scenes/настройки/настройки.tscn" id="6_i8iv3"]
|
||||
[ext_resource type="Script" uid="uid://b5ykwyk5vpi6" path="res://scenes/tabs-switch/lbl_ready.gd" id="8_tidwt"]
|
||||
[ext_resource type="Script" path="res://scenes/tabs-switch/тренаж_режим.gd" id="9_41d34"]
|
||||
[ext_resource type="Script" uid="uid://roajn6c6wvc1" path="res://scenes/tabs-switch/тренаж_режим.gd" id="9_41d34"]
|
||||
|
||||
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_tidwt"]
|
||||
|
||||
|
||||
@@ -373,7 +373,7 @@ func _process(delta) -> void:
|
||||
remove_child(req)
|
||||
req.queue_free()
|
||||
_req_count -= 1
|
||||
push_error('запрос \"%s\" не отправлен' % tile.url) #TODO: For Deugs
|
||||
push_error('запрос \"%s\" не отправлен' % tile.url) #TODO: For Debug
|
||||
if _queue.is_empty():
|
||||
emit_signal('load_completed')
|
||||
|
||||
@@ -717,7 +717,7 @@ func set_coordinates(lon: float, lat: float, course: float) -> void:
|
||||
add_mark_from_lon_lat(ship_id, lon, lat, ship_instance, 0.0)
|
||||
else:
|
||||
_marks[ship_id].position = lonlat_to_world(lon, lat)
|
||||
ship_instance.rotation_degrees = fmod(course, 360.0)
|
||||
ship_instance.rotation_degrees = fmod(270.0 + course, 360.0)
|
||||
queue_redraw()
|
||||
|
||||
|
||||
@@ -727,7 +727,7 @@ func blend_mask(val: bool) -> void:
|
||||
|
||||
|
||||
func update_coordinates_label(lon: float, lat: float) -> void:
|
||||
coordinates_label = 'Координаты: NS:%f, EW:%f' % [lat, lon]
|
||||
coordinates_label = 'Координаты: NS: %f, EW: %f' % [lat, lon]
|
||||
signaller.emit_signal('update_coordinates_map', coordinates_label)
|
||||
|
||||
|
||||
|
||||
@@ -45,6 +45,14 @@ func enter_press():
|
||||
Input.parse_input_event(enter_event)
|
||||
|
||||
|
||||
func _on_settings_changed():
|
||||
if not is_inside_tree(): return
|
||||
var white_color = ProjectSettings.get_setting('Схема прибора. Белый цвет', Color.LIGHT_GRAY)
|
||||
var black_color = ProjectSettings.get_setting('Схема прибора. Чёрный цвет', Color.BLACK)
|
||||
$pic_functional.material.set('shader_parameter/white', white_color)
|
||||
$pic_functional.material.set('shader_parameter/black', black_color)
|
||||
|
||||
|
||||
@export var state: int:
|
||||
set(v):
|
||||
v = 0 if v < 0 else v % state_colors.size()
|
||||
|
||||
@@ -160,7 +160,7 @@ func init_fs_failed():
|
||||
var sectors_count = $canvas.fs_default_colors.size()
|
||||
fs_failed.resize(sectors_count)
|
||||
for i in fs_failed.size():
|
||||
fs_failed[i] = AntBandState.ANT_BAND_READY
|
||||
fs_failed[i] = AntBandState.ANT_BAND_FAILED
|
||||
|
||||
|
||||
## Производит инициализацию.
|
||||
@@ -593,7 +593,7 @@ func on_interfer_prinuditelno(prenuditelno_sectors, btns):
|
||||
## Вызывается при получении информации о состоянии модулей ФС от КАПС РПБ.
|
||||
func on_fs_update_state(fs_dict: Dictionary):
|
||||
for key in fs_dict.keys():
|
||||
fs_failed[key] = fs_dict[key].isg
|
||||
fs_failed[key] = fs_dict[key].ready
|
||||
|
||||
|
||||
func on_btn_center_toggled(toggled_on: bool) -> void:
|
||||
|
||||
@@ -306,36 +306,36 @@ vertical_alignment = 1
|
||||
|
||||
[node name="coordinates_map" type="Label" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 660.0
|
||||
offset_top = -24.0
|
||||
offset_right = 772.0
|
||||
offset_bottom = -5.0
|
||||
offset_left = 654.0
|
||||
offset_top = -23.0
|
||||
offset_right = 766.0
|
||||
offset_bottom = -4.0
|
||||
text = "Координаты:"
|
||||
|
||||
[node name="scale_map" type="Label" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 1003.0
|
||||
offset_top = -24.0
|
||||
offset_right = 1113.0
|
||||
offset_bottom = -3.0
|
||||
offset_left = 1009.0
|
||||
offset_top = -23.0
|
||||
offset_right = 1119.0
|
||||
offset_bottom = -2.0
|
||||
text = "Масштаб:"
|
||||
|
||||
[node name="zoom_plus" type="Button" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 1056.0
|
||||
offset_top = 230.0
|
||||
offset_right = 1088.0
|
||||
offset_bottom = 262.0
|
||||
offset_left = 952.0
|
||||
offset_top = 43.0
|
||||
offset_right = 984.0
|
||||
offset_bottom = 75.0
|
||||
theme_override_fonts/font = SubResource("SystemFont_5ffal")
|
||||
theme_override_font_sizes/font_size = 20
|
||||
text = "+"
|
||||
|
||||
[node name="zoom_minus" type="Button" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 1056.0
|
||||
offset_top = 270.0
|
||||
offset_right = 1088.0
|
||||
offset_bottom = 302.0
|
||||
offset_left = 952.0
|
||||
offset_top = 84.0
|
||||
offset_right = 984.0
|
||||
offset_bottom = 116.0
|
||||
theme_override_font_sizes/font_size = 20
|
||||
text = "−"
|
||||
|
||||
@@ -383,8 +383,8 @@ texture_normal = ExtResource("14_ggrwd")
|
||||
[connection signal="toggled" from="btn_activate" to="." method="on_btn_activate_toggled"]
|
||||
[connection signal="toggled" from="btn_center" to="." method="on_btn_center_toggled"]
|
||||
[connection signal="button_down" from="zoom_plus" to="tilemap" method="_on_zoom_plus_button_down"]
|
||||
[connection signal="button_up" from="zoom_plus" to="tilemap" method="_on_zoom_plus_button_up"]
|
||||
[connection signal="button_up" from="zoom_plus" to="tilemap" method="_on_zoom_button_up"]
|
||||
[connection signal="button_up" from="zoom_plus" to="tilemap" method="_on_zoom_plus_button_up"]
|
||||
[connection signal="button_down" from="zoom_minus" to="tilemap" method="_on_zoom_minus_button_down"]
|
||||
[connection signal="button_up" from="zoom_minus" to="tilemap" method="_on_zoom_button_up"]
|
||||
[connection signal="pressed" from="btn_all_work" to="." method="_on_btn_all_work_pressed"]
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://hkcvl2waf63s" path="res://data/вид сверху.png" id="1_b7vcf"]
|
||||
[ext_resource type="Script" uid="uid://bvlqgv7aapebl" path="res://scenes/эмс2/эмс_тг.gd" id="1_l3ueu"]
|
||||
[ext_resource type="Texture2D" uid="uid://b1dw06ahtftq2" path="res://data/Окно частот0.png" id="3_2spgl"]
|
||||
[ext_resource type="Texture2D" uid="uid://0w6q4vfst0ry" path="res://data/OP-63.png" id="3_8gk36"]
|
||||
[ext_resource type="Texture2D" uid="uid://coxhivvc6uibs" path="res://data/Состояние РЭС 40.png" id="4_b3mus"]
|
||||
[ext_resource type="Texture2D" uid="uid://073el51yholj" path="res://data/454.png" id="4_nqi0i"]
|
||||
@@ -33,11 +34,7 @@
|
||||
[ext_resource type="Texture2D" uid="uid://carr8bw5rwiwj" path="res://data/Кнопка подтверждения01.png" id="32_p41nv"]
|
||||
[ext_resource type="Texture2D" uid="uid://3siondd3feev" path="res://data/Скруглённый прямоугольник белый.png" id="33_5ifkb"]
|
||||
|
||||
[sub_resource type="CompressedTexture2D" id="CompressedTexture2D_5u4bk"]
|
||||
load_path = "res://.godot/imported/Окно частот0.png-6b01791c971bddb01337caf9077bf060.ctex"
|
||||
|
||||
[sub_resource type="CompressedTexture2D" id="CompressedTexture2D_l3ueu"]
|
||||
load_path = "res://.godot/imported/Скруглённый квадрат серый.png-4655829309cca3b1dec2c9ae01376d54.ctex"
|
||||
|
||||
[node name="Panel" type="Panel"]
|
||||
script = ExtResource("1_l3ueu")
|
||||
@@ -56,7 +53,7 @@ offset_top = 240.0
|
||||
offset_right = 1649.0
|
||||
offset_bottom = 813.0
|
||||
scale = Vector2(0.95, 0.95)
|
||||
texture = SubResource("CompressedTexture2D_5u4bk")
|
||||
texture = ExtResource("3_2spgl")
|
||||
expand_mode = 1
|
||||
|
||||
[node name="Op-63" type="TextureRect" parent="."]
|
||||
@@ -69,13 +66,13 @@ scale = Vector2(0.312207, 0.312207)
|
||||
texture = ExtResource("3_8gk36")
|
||||
|
||||
[node name="СостояниеРэс44" type="Sprite2D" parent="Op-63"]
|
||||
position = Vector2(277.772, 259.444)
|
||||
scale = Vector2(1.77945, 1.77945)
|
||||
position = Vector2(285.067, 253.037)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("4_b3mus")
|
||||
|
||||
[node name="СостояниеРэс24" type="Sprite2D" parent="Op-63"]
|
||||
position = Vector2(277.772, 192.18)
|
||||
scale = Vector2(1.77945, 1.77945)
|
||||
position = Vector2(285.067, 150.541)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("5_yqn2y")
|
||||
|
||||
[node name="СостояниеРэс2" type="Sprite2D" parent="Op-63"]
|
||||
@@ -94,18 +91,18 @@ scale = Vector2(0.312, 0.312)
|
||||
texture = ExtResource("4_nqi0i")
|
||||
|
||||
[node name="СостояниеРэс45" type="Sprite2D" parent="454"]
|
||||
position = Vector2(277.956, 259.615)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.571, 253.205)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("4_b3mus")
|
||||
|
||||
[node name="СостояниеРэс25" type="Sprite2D" parent="454"]
|
||||
position = Vector2(277.956, 192.308)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.571, 153.847)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("5_yqn2y")
|
||||
|
||||
[node name="СостояниеРэс3" type="Sprite2D" parent="454"]
|
||||
position = Vector2(275.641, 38.4615)
|
||||
scale = Vector2(3.20513, 3.20513)
|
||||
position = Vector2(285.256, 41.6667)
|
||||
scale = Vector2(4, 4)
|
||||
texture = ExtResource("6_m57px")
|
||||
|
||||
[node name="lbl_trassa" type="Label" parent="454"]
|
||||
@@ -120,25 +117,25 @@ text = "Трасса"
|
||||
[node name="Го" type="TextureRect" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 488.0
|
||||
offset_top = 85.0
|
||||
offset_top = 84.0
|
||||
offset_right = 701.0
|
||||
offset_bottom = 377.0
|
||||
offset_bottom = 376.0
|
||||
scale = Vector2(0.312, 0.312)
|
||||
texture = ExtResource("5_e7tlv")
|
||||
|
||||
[node name="СостояниеРэс40" type="Sprite2D" parent="Го"]
|
||||
position = Vector2(278.045, 253.205)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.66, 253.205)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("4_b3mus")
|
||||
|
||||
[node name="СостояниеРэс20" type="Sprite2D" parent="Го"]
|
||||
position = Vector2(278.045, 185.897)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.66, 150.641)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("5_yqn2y")
|
||||
|
||||
[node name="СостояниеЭмсСлабыйСигнал" type="Sprite2D" parent="Го"]
|
||||
position = Vector2(278.045, 118.59)
|
||||
scale = Vector2(3.37683, 3.20513)
|
||||
position = Vector2(284.455, 38.4619)
|
||||
scale = Vector2(4, 3.796)
|
||||
texture = ExtResource("9_5u4bk")
|
||||
|
||||
[node name="Рлс1" type="TextureRect" parent="."]
|
||||
@@ -151,18 +148,18 @@ scale = Vector2(0.312, 0.312)
|
||||
texture = ExtResource("6_y58bl")
|
||||
|
||||
[node name="СостояниеРэс41" type="Sprite2D" parent="Рлс1"]
|
||||
position = Vector2(278.045, 259.615)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.661, 253.205)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("4_b3mus")
|
||||
|
||||
[node name="СостояниеРэс21" type="Sprite2D" parent="Рлс1"]
|
||||
position = Vector2(278.045, 192.308)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.661, 153.846)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("5_yqn2y")
|
||||
|
||||
[node name="СостояниеЭмсСлабыйСигнал2" type="Sprite2D" parent="Рлс1"]
|
||||
position = Vector2(278.045, 125)
|
||||
scale = Vector2(3.37683, 3.20513)
|
||||
position = Vector2(287.66, 38.4615)
|
||||
scale = Vector2(4, 3.796)
|
||||
texture = ExtResource("9_5u4bk")
|
||||
|
||||
[node name="Рлс2" type="TextureRect" parent="."]
|
||||
@@ -175,37 +172,37 @@ scale = Vector2(0.312, 0.312)
|
||||
texture = ExtResource("7_mxw8g")
|
||||
|
||||
[node name="СостояниеРэс42" type="Sprite2D" parent="Рлс2"]
|
||||
position = Vector2(278.045, 259.615)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.661, 253.205)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("4_b3mus")
|
||||
|
||||
[node name="СостояниеРэс22" type="Sprite2D" parent="Рлс2"]
|
||||
position = Vector2(278.045, 192.308)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.661, 153.846)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("5_yqn2y")
|
||||
|
||||
[node name="СостояниеЭмсСлабыйСигнал3" type="Sprite2D" parent="Рлс2"]
|
||||
position = Vector2(278.045, 125)
|
||||
scale = Vector2(3.37683, 3.20513)
|
||||
position = Vector2(287.66, 38.4615)
|
||||
scale = Vector2(4, 3.796)
|
||||
texture = ExtResource("9_5u4bk")
|
||||
|
||||
[node name="Ннвс" type="TextureRect" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 1240.0
|
||||
offset_top = 88.0
|
||||
offset_top = 84.0
|
||||
offset_right = 1453.0
|
||||
offset_bottom = 380.0
|
||||
offset_bottom = 376.0
|
||||
scale = Vector2(0.312, 0.312)
|
||||
texture = ExtResource("8_q16jd")
|
||||
|
||||
[node name="СостояниеРэс43" type="Sprite2D" parent="Ннвс"]
|
||||
position = Vector2(277.956, 253.205)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.571, 253.205)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("4_b3mus")
|
||||
|
||||
[node name="СостояниеРэс23" type="Sprite2D" parent="Ннвс"]
|
||||
position = Vector2(277.956, 185.897)
|
||||
scale = Vector2(1.78063, 1.78063)
|
||||
position = Vector2(287.571, 153.846)
|
||||
scale = Vector2(2.1, 2.1)
|
||||
texture = ExtResource("5_yqn2y")
|
||||
|
||||
[node name="УгловойКвадрат2" type="Sprite2D" parent="."]
|
||||
@@ -406,9 +403,9 @@ texture = SubResource("CompressedTexture2D_l3ueu")
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 800.0
|
||||
offset_left = 799.0
|
||||
offset_top = 246.0
|
||||
offset_right = 873.0
|
||||
offset_right = 872.0
|
||||
offset_bottom = 265.0
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
theme_override_font_sizes/font_size = 16
|
||||
@@ -416,7 +413,7 @@ text = "Излучение"
|
||||
|
||||
[node name="Label2" type="Label" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 813.0
|
||||
offset_left = 814.0
|
||||
offset_top = 503.0
|
||||
offset_right = 861.0
|
||||
offset_bottom = 522.0
|
||||
@@ -484,52 +481,52 @@ theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Изделие"
|
||||
|
||||
[node name="Label" type="Label" parent="СкруглённыйПрямоугСалатный"]
|
||||
offset_left = -33.0
|
||||
offset_left = -33.7501
|
||||
offset_top = -10.2857
|
||||
offset_right = 35.0
|
||||
offset_bottom = 8.71429
|
||||
offset_right = 34.2499
|
||||
offset_bottom = 8.7143
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Комплекс"
|
||||
|
||||
[node name="Label3" type="Label" parent="СкруглённыйПрямоугСалатный"]
|
||||
offset_left = 133.0
|
||||
offset_top = -10.0
|
||||
offset_right = 180.0
|
||||
offset_bottom = 9.0
|
||||
offset_left = 132.75
|
||||
offset_top = -11.1428
|
||||
offset_right = 179.75
|
||||
offset_bottom = 11.8572
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Режим"
|
||||
|
||||
[node name="Label4" type="Label" parent="СкруглённыйПрямоугСалатный"]
|
||||
offset_left = 209.25
|
||||
offset_left = 210.751
|
||||
offset_top = -10.2857
|
||||
offset_right = 258.25
|
||||
offset_right = 259.751
|
||||
offset_bottom = 8.7143
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Азимут"
|
||||
|
||||
[node name="Label5" type="Label" parent="СкруглённыйПрямоугСалатный"]
|
||||
offset_left = 627.0
|
||||
offset_top = -20.5713
|
||||
offset_right = 693.0
|
||||
offset_bottom = 20.4287
|
||||
offset_left = 620.252
|
||||
offset_top = -23.1428
|
||||
offset_right = 699.252
|
||||
offset_bottom = 25.8572
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Запрет
|
||||
передачи"
|
||||
horizontal_alignment = 1
|
||||
|
||||
[node name="Label6" type="Label" parent="СкруглённыйПрямоугСалатный"]
|
||||
offset_left = 516.75
|
||||
offset_top = -10.2857
|
||||
offset_right = 574.75
|
||||
offset_bottom = 8.7143
|
||||
offset_left = 518.251
|
||||
offset_top = -12.0
|
||||
offset_right = 576.251
|
||||
offset_bottom = 11.0
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Верхняя"
|
||||
|
||||
[node name="Label7" type="Label" parent="СкруглённыйПрямоугСалатный"]
|
||||
offset_left = 441.0
|
||||
offset_top = -10.2857
|
||||
offset_right = 495.0
|
||||
offset_bottom = 8.7143
|
||||
offset_left = 440.0
|
||||
offset_top = -11.0
|
||||
offset_right = 494.0
|
||||
offset_bottom = 12.0
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Нижняя"
|
||||
|
||||
@@ -542,12 +539,14 @@ theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Кластер"
|
||||
|
||||
[node name="Label9" type="Label" parent="СкруглённыйПрямоугСалатный"]
|
||||
offset_left = 275.25
|
||||
offset_top = -10.2857
|
||||
offset_right = 349.25
|
||||
offset_bottom = 8.7143
|
||||
offset_left = 276.001
|
||||
offset_top = -20.5714
|
||||
offset_right = 350.001
|
||||
offset_bottom = 20.4286
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Угол места"
|
||||
text = "Угол
|
||||
места"
|
||||
horizontal_alignment = 1
|
||||
|
||||
[node name="Label10" type="Label" parent="СкруглённыйПрямоугСалатный"]
|
||||
offset_left = 747.0
|
||||
|
||||
@@ -277,10 +277,10 @@ func on_th_aoa_update(threats: Dictionary, ecms: Dictionary, unit_instance) -> v
|
||||
var ecm_active = true
|
||||
if not gos_flag:
|
||||
if ecm.nmfs in gos_nmfs:
|
||||
interfer_off(ecm, unit_instance)
|
||||
signaller.emit_signal('interfer_off', ecm)
|
||||
ecm_active = false
|
||||
if ecm_active and (prd.fs_caps_id[ecm.nmfs] in fs_closed):
|
||||
interfer_off(ecm, unit_instance)
|
||||
signaller.emit_signal('interfer_off', ecm)
|
||||
|
||||
var th_id = thr.id
|
||||
for ecm_i in thrs.keys():
|
||||
@@ -290,9 +290,9 @@ func on_th_aoa_update(threats: Dictionary, ecms: Dictionary, unit_instance) -> v
|
||||
ecm.kni = fposmod(thr.aoa - course, 360)
|
||||
call_ecm_proc(ecm)
|
||||
if ecm.nmfs in gos_nmfs:
|
||||
interfer_off(ecm, unit_instance)
|
||||
signaller.emit_signal('interfer_off', ecm)
|
||||
elif prd.fs_caps_id[ecm.nmfs] in fs_closed:
|
||||
interfer_off(ecm, unit_instance)
|
||||
signaller.emit_signal('interfer_off', ecm)
|
||||
else:
|
||||
send_ecm(ecm, unit_instance)
|
||||
signaller.emit_signal('fs_update_color', ecms)
|
||||
@@ -382,7 +382,7 @@ func on_interfer_create(interfer_name, sel_threats, fs_arr, power, u, ecms) -> v
|
||||
for ecm in ecms.values():
|
||||
if ecm.nmfs == item.nmfs:
|
||||
if item.priority > ecm.priority:
|
||||
interfer_off(ecm, u)
|
||||
signaller.emit_signal('interfer_off', ecm)
|
||||
elif item.priority < ecm.priority:
|
||||
need_continue = true
|
||||
break
|
||||
@@ -504,17 +504,17 @@ func send_ecm(ecm, unit0) -> void:
|
||||
unit0.tx_stack.append(json_data)
|
||||
|
||||
|
||||
func on_interfer_off_all(unit0, ecms: Dictionary) -> void:
|
||||
func on_interfer_off_all(_unit0, ecms: Dictionary) -> void:
|
||||
for ecm in ecms.values():
|
||||
interfer_off(ecm, unit0)
|
||||
signaller.emit_signal('interfer_off', ecm)
|
||||
|
||||
|
||||
func on_threats_lost(th, ecms, unit0) -> void:
|
||||
func on_threats_lost(th, ecms, _unit0) -> void:
|
||||
for key in interfer.thrs:
|
||||
if interfer.thrs[key] == th.id:
|
||||
var ecm_id = key
|
||||
var ecm = ecms[ecm_id]
|
||||
interfer_off(ecm, unit0)
|
||||
signaller.emit_signal('interfer_off', ecm)
|
||||
|
||||
|
||||
func pop_id() -> int:
|
||||
@@ -647,13 +647,19 @@ func get_krp(threat: threats.Threat):
|
||||
return krp
|
||||
|
||||
|
||||
func on_interfer_off(ecm: Interfer, _ecms, unit_caps):
|
||||
func on_interfer_off(ecm: Interfer, ecms, unit_caps):
|
||||
ecm.krp = INTERFER_OFF
|
||||
send_ecm(ecm, unit_caps)
|
||||
|
||||
|
||||
func interfer_off(ecm, _unit_caps):
|
||||
signaller.emit_signal('interfer_off', ecm)
|
||||
if not unit_caps.online:
|
||||
var sz = ecms.size()
|
||||
signaller.emit_signal('on_prog_ecm_off', ecm)
|
||||
ecms.erase(ecm.ispp)
|
||||
thrs.erase(ecm.ispp)
|
||||
cu.erase(ecm.ispp)
|
||||
fs.erase(ecm.ispp)
|
||||
push_id(ecm.ispp)
|
||||
if sz != ecms.size():
|
||||
interfer.call_deferred('emit_signal', 'interfer_resized', ecms)
|
||||
|
||||
|
||||
func on_interfer_new(ecm, unit_caps):
|
||||
|
||||
@@ -119,6 +119,9 @@ class Fs:
|
||||
var freq_caps_rx: float = 0.0 ## Частота принятая от КАПС РПБ
|
||||
var width_caps_rx: float = 0.0 ## Ширина полосы принятая от КАПС РПБ
|
||||
var msvk: Array
|
||||
var ready: bool = false ## Готовность сектора к излучению
|
||||
var caps_online: bool = false ## Состояние связи с КАПС РПБ
|
||||
var yau_07_online: bool = false ## Состояние связи ЯУ-07
|
||||
|
||||
signal update_modulation(index)
|
||||
|
||||
@@ -148,7 +151,10 @@ class Fs:
|
||||
val = tools.set_bits(u.isa_ports[um_port], um_code_tx, 0x0007)
|
||||
data_arr.append(um_port)
|
||||
data_arr.append(val)
|
||||
|
||||
|
||||
# Установка готовности модуля ФС к излучению
|
||||
func set_ready():
|
||||
ready = isg and caps_online and yau_07_online
|
||||
|
||||
class PRD:
|
||||
enum STATE_DEVICE {
|
||||
@@ -208,7 +214,6 @@ class PRD:
|
||||
if port == fs.um_port:
|
||||
fs.um_code_rx = u.isa_ports[port] & 0x7
|
||||
|
||||
|
||||
func on_line_changed(unit_ems):
|
||||
if not unit_ems.online:
|
||||
yemsg_board.ems_load = yemsg_board.LoadState.NOT_DEFINED
|
||||
@@ -303,7 +308,6 @@ class PRD:
|
||||
break
|
||||
return STATE_DEVICE.NONE if all_online else STATE_DEVICE.ERROR
|
||||
|
||||
|
||||
func execute_cmd():
|
||||
if not len(cmd_array): return
|
||||
if unit_yau07.cmd_state != unit_yau07.CmdState.DONE: return
|
||||
@@ -338,21 +342,24 @@ class PRD:
|
||||
yemsg_board.set_wait()
|
||||
log.error('Не удалось прочитать файл настроек ячейки ЭМС-Г %s' %abs_dir)
|
||||
|
||||
|
||||
func on_update_modulation(index):
|
||||
yemsg_board.add_cmd(index/4, fs_dic[index].modulation)
|
||||
|
||||
func set_um(data_arr):
|
||||
cmd_array.append([unit_yau07.CmdCode.WRITE_ISA, data_arr])
|
||||
|
||||
|
||||
|
||||
func set_fs_caps_online(caps_online: bool):
|
||||
for fs in fs_dic.values():
|
||||
fs.caps_online = caps_online
|
||||
fs.set_ready()
|
||||
|
||||
func _ready() -> void:
|
||||
check_dir()
|
||||
for prd_name in PRD_NAMES:
|
||||
var unit_prd = network.get_unit_instance(prd_name)
|
||||
var new_prd = PRD.new(prd_name, unit_prd)
|
||||
prd_dict[prd_name] = new_prd
|
||||
new_prd.unit_yau07.connect('line_changed', on_yau07_line_changed.bind(new_prd))
|
||||
var unit_control = TestPRD.new({'unit_prd': unit_prd}, new_prd.cmd_array)
|
||||
add_child(unit_control)
|
||||
new_prd.unit_control = unit_control
|
||||
@@ -367,6 +374,7 @@ func _ready() -> void:
|
||||
fs_caps_id[FS_PRD[key][1]] = key
|
||||
var unit_caps = network.get_unit_instance('уарэп-капсрпб')
|
||||
unit_caps.connect('data_received', Callable(self, 'on_data_capsrpb_received'))
|
||||
unit_caps.connect('line_changed', Callable(self, 'on_caps_line_changed'))
|
||||
signaller.connect('режим_контроль', Callable(self, 'on_mode_changed').bind(PrdState.CONTROL))
|
||||
signaller.connect('режим_работа', Callable(self, 'on_mode_changed').bind(PrdState.WORK))
|
||||
var unit_nav = network.get_unit_instance('навигация')
|
||||
@@ -433,7 +441,6 @@ func update_fs_state(ecms, trenaz_mode: bool):
|
||||
prd_module.set_um(um_data_array)
|
||||
|
||||
|
||||
|
||||
## Проверяет ниличие директории, если их нет, создаёт
|
||||
func check_dir():
|
||||
var dir = DirAccess.open(yemsconsts.emsg_files_folder)
|
||||
@@ -461,6 +468,7 @@ func on_data_capsrpb_received(unit0: capsrpb.CapsRpb):
|
||||
var fs_module = fs_dict[ii]
|
||||
if fs.has('isg'):
|
||||
fs_module.isg = int(fs['isg'])
|
||||
fs_module.set_ready()
|
||||
if fs.has('pow'):
|
||||
fs_module.pow_caps_rx = int(fs['pow'])
|
||||
if fs.has('freq'):
|
||||
@@ -479,3 +487,16 @@ func on_mode_changed(changed_mode: int) -> void:
|
||||
|
||||
func on_navi_data_received(data: Dictionary):
|
||||
course = data.get('k', 0.0)
|
||||
|
||||
|
||||
func on_caps_line_changed(unit_caps):
|
||||
for pribor_prd in prd_dict.values():
|
||||
pribor_prd.set_fs_caps_online(unit_caps.online)
|
||||
signaller.emit_signal('fs_update_state', fs_dict)
|
||||
|
||||
|
||||
func on_yau07_line_changed(unit_yau07, prd_pribor):
|
||||
for fs in prd_pribor.fs_dic.values():
|
||||
fs.yau_07_online = unit_yau07.online
|
||||
fs.set_ready()
|
||||
signaller.emit_signal('fs_update_state', fs_dict)
|
||||
|
||||