diff --git a/PRD_MP550.tscn b/PRD_MP550.tscn index 31c8c9c..9ca0a5c 100644 --- a/PRD_MP550.tscn +++ b/PRD_MP550.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=50 format=3 uid="uid://cvor2jm4xk3ha"] +[gd_scene load_steps=49 format=3 uid="uid://cvor2jm4xk3ha"] [ext_resource type="Script" path="res://scripts/PRD.gd" id="1_v273n"] [ext_resource type="Texture2D" uid="uid://cdxdluvyb5uei" path="res://table/on.png" id="2_dv7xx"] @@ -13,7 +13,6 @@ [ext_resource type="Script" path="res://scripts/ems_g.gd" id="9_g1wia"] [ext_resource type="Shader" path="res://load.gdshader" id="10_lf1xh"] [ext_resource type="PackedScene" uid="uid://bdb0bhfu7366l" path="res://kasseta-fs-kd.tscn" id="10_tdh2s"] -[ext_resource type="PackedScene" uid="uid://bnlkbbn7b4a3k" path="res://table/элемент-эмс.tscn" id="11_d60jk"] [ext_resource type="PackedScene" uid="uid://p2suppildvq0" path="res://table/элемент-в.tscn" id="11_fg7ul"] [ext_resource type="Script" path="res://scripts/modul_fs.gd" id="15_b4pr1"] @@ -267,7 +266,7 @@ text = "Прочитать ISA" offset_left = 216.0 offset_top = 39.0 offset_right = 2420.0 -offset_bottom = 917.0 +offset_bottom = 936.0 theme = SubResource("Theme_k5ur4") theme_override_colors/font_unselected_color = Color(0, 0, 0, 0.0392157) theme_override_colors/font_selected_color = Color(0, 0, 0, 0) @@ -279,10 +278,11 @@ theme_override_styles/tab_selected = SubResource("StyleBoxTexture_k08q3") theme_override_styles/tab_hovered = SubResource("StyleBoxTexture_dklg6") theme_override_styles/tab_unselected = SubResource("StyleBoxTexture_17le6") tab_alignment = 2 -current_tab = 0 +current_tab = 1 tab_focus_mode = 0 [node name="PRD" type="Panel" parent="TabContainer"] +visible = false layout_mode = 2 theme_override_styles/panel = SubResource("StyleBoxTexture_7u7p7") metadata/_tab_index = 0 @@ -424,7 +424,6 @@ script = ExtResource("2_vmbyo") node_gap = Vector2(100, 50) [node name="ControlPanel" type="Panel" parent="TabContainer"] -visible = false layout_mode = 2 theme_override_styles/panel = SubResource("StyleBoxTexture_tn8m6") script = ExtResource("9_akagi") @@ -433,10 +432,10 @@ metadata/_edit_lock_ = true [node name="lbl_control" type="Label" parent="TabContainer/ControlPanel"] layout_mode = 0 -offset_left = 4.0 -offset_top = 21.0 -offset_right = 624.0 -offset_bottom = 52.0 +offset_left = 45.0 +offset_top = -37.0 +offset_right = 665.0 +offset_bottom = -6.0 theme_override_font_sizes/font_size = 22 text = "Контроль исправности прибора ПРД-Н" horizontal_alignment = 1 @@ -445,16 +444,16 @@ vertical_alignment = 1 [node name="soc_y5" type="NinePatchRect" parent="TabContainer/ControlPanel"] layout_mode = 0 offset_left = 199.0 -offset_top = 103.0 +offset_top = 10.0 offset_right = 516.0 -offset_bottom = 293.0 +offset_bottom = 200.0 texture = ExtResource("9_0r2qk") patch_margin_left = 16 patch_margin_top = 16 patch_margin_right = 16 patch_margin_bottom = 16 -[node name="ref_A24" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] +[node name="IP5_25" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] offset_left = 9.0 offset_top = 34.0 offset_right = 59.0 @@ -474,7 +473,7 @@ fname = "ЯУ-07" rname = "A30" metadata/_edit_lock_ = true -[node name="ref_A26" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] +[node name="ems_g" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] offset_left = 109.0 offset_top = 34.0 offset_right = 159.0 @@ -484,7 +483,7 @@ fname = "ЭМС-Г" rname = "A26" metadata/_edit_lock_ = true -[node name="ref_A27" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] +[node name="ug" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] offset_left = 159.0 offset_top = 34.0 offset_right = 209.0 @@ -494,7 +493,7 @@ fname = "УГ" rname = "A27" metadata/_edit_lock_ = true -[node name="ref_A28" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] +[node name="ukp_1" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] offset_left = 209.0 offset_top = 34.0 offset_right = 259.0 @@ -505,7 +504,7 @@ fname = "УКП-1" rname = "A28" metadata/_edit_lock_ = true -[node name="ref_A29" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] +[node name="ukp_2" parent="TabContainer/ControlPanel/soc_y5" instance=ExtResource("11_fg7ul")] offset_left = 259.0 offset_top = 34.0 offset_right = 309.0 @@ -630,30 +629,20 @@ horizontal_alignment = 1 vertical_alignment = 1 [node name="MAA_1" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] -offset_left = -63.0 -offset_top = 36.0 -offset_right = -13.0 -offset_bottom = 210.0 -[node name="ref_A23" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] -offset_left = 40.0 -offset_top = -206.0 -offset_right = 90.0 -offset_bottom = -32.0 +offset_left = -64.0 +offset_top = 37.0 +offset_right = -14.0 +offset_bottom = 211.0 textures = Array[Texture]([]) self_size = Vector2i(50, 174) fname = "МАА2000" rname = "А22" [node name="MAA_2" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] -offset_left = 199.0 -offset_top = 37.0 -offset_right = 249.0 -offset_bottom = 211.0 -[node name="ref_A24" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] -offset_left = 40.0 -offset_top = -448.0 -offset_right = 90.0 -offset_bottom = -274.0 +offset_left = 203.0 +offset_top = 36.0 +offset_right = 253.0 +offset_bottom = 210.0 textures = Array[Texture]([]) self_size = Vector2i(50, 174) fname = "МАА2000" @@ -679,11 +668,6 @@ self_size = Vector2i(50, 174) fname = "ИП9-50" rname = "А20" -[node name="IP12_50" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] -offset_left = 16.0 -offset_top = 37.0 -offset_right = 66.0 -offset_bottom = 211.0 [node name="ref_A28" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] visible = false offset_left = 259.0 @@ -695,12 +679,34 @@ self_size = Vector2i(50, 174) fname = "ИП12-50" rname = "A21" +[node name="ref_A29" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] +visible = false +offset_left = 309.0 +offset_top = 34.0 +offset_right = 359.0 +offset_bottom = 208.0 +textures = Array[Texture]([]) +self_size = Vector2i(50, 174) +fname = "ИП9-50" +rname = "А22" +metadata/_edit_lock_ = true + +[node name="IP12_50" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] +offset_left = 16.0 +offset_top = 36.0 +offset_right = 66.0 +offset_bottom = 210.0 +textures = Array[Texture]([]) +self_size = Vector2i(50, 174) +fname = "ИП12-50" +rname = "А21" + [node name="soc_P2" type="NinePatchRect" parent="TabContainer/ControlPanel"] layout_mode = 0 -offset_left = 258.0 -offset_top = 649.0 -offset_right = 446.0 -offset_bottom = 865.0 +offset_left = 278.0 +offset_top = 645.0 +offset_right = 432.0 +offset_bottom = 861.0 texture = ExtResource("9_0r2qk") patch_margin_left = 16 patch_margin_top = 16 @@ -710,154 +716,33 @@ patch_margin_bottom = 16 [node name="Kasseta" type="Label" parent="TabContainer/ControlPanel/soc_P2"] self_modulate = Color(1, 1, 1, 0.62) layout_mode = 0 -offset_left = 7.0 +offset_left = 8.0 offset_top = 8.0 -offset_right = 181.0 +offset_right = 142.0 offset_bottom = 33.0 text = "Кассета П-2" horizontal_alignment = 1 vertical_alignment = 1 -[node name="IP9_50" parent="TabContainer/ControlPanel/soc_P2" instance=ExtResource("11_fg7ul")] -offset_left = 73.0 -offset_top = 36.0 -offset_right = 123.0 -offset_bottom = 210.0 -[node name="ref_A29" parent="TabContainer/ControlPanel/soc_P1" instance=ExtResource("11_fg7ul")] -visible = false -offset_left = 309.0 -offset_top = 34.0 -offset_right = 359.0 -offset_bottom = 208.0 -textures = Array[Texture]([]) -self_size = Vector2i(50, 174) -metadata/_edit_lock_ = true -fname = "ИП9-50" -rname = "А22" - [node name="IP12_50" parent="TabContainer/ControlPanel/soc_P2" instance=ExtResource("11_fg7ul")] -offset_left = 128.0 +offset_left = 81.0 offset_top = 36.0 -offset_right = 178.0 +offset_right = 131.0 offset_bottom = 210.0 textures = Array[Texture]([]) self_size = Vector2i(50, 174) fname = "ИП12-50" rname = "A25" -[node name="Signal_EMS_G" type="NinePatchRect" parent="TabContainer/ControlPanel"] -layout_mode = 0 -offset_left = 536.0 -offset_top = 550.0 -offset_right = 1055.0 -offset_bottom = 777.0 -texture = ExtResource("9_0r2qk") -patch_margin_left = 16 -patch_margin_top = 16 -patch_margin_right = 16 -patch_margin_bottom = 16 - -[node name="lbl_fname" type="Label" parent="TabContainer/ControlPanel/Signal_EMS_G"] -self_modulate = Color(1, 1, 1, 0.62) -layout_mode = 0 -offset_left = 7.0 -offset_top = 8.0 -offset_right = 508.0 -offset_bottom = 33.0 -text = "ЭМС-Г" -horizontal_alignment = 1 -vertical_alignment = 1 -metadata/_edit_lock_ = true - -[node name="ref_A22" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 9.0 -offset_top = 38.0 -offset_right = 59.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) +[node name="IP9_50" parent="TabContainer/ControlPanel/soc_P2" instance=ExtResource("11_fg7ul")] +offset_left = 24.0 +offset_top = 36.0 +offset_right = 74.0 +offset_bottom = 210.0 +textures = Array[Texture]([]) +self_size = Vector2i(50, 174) +fname = "ИП9-50" rname = "A22" -metadata/_edit_lock_ = true - -[node name="ref_A23" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 59.0 -offset_top = 38.0 -offset_right = 109.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "A23" -metadata/_edit_lock_ = true - -[node name="ref_A26" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 109.0 -offset_top = 38.0 -offset_right = 159.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "A26" -metadata/_edit_lock_ = true - -[node name="ref_A27" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 159.0 -offset_top = 38.0 -offset_right = 209.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "A27" -metadata/_edit_lock_ = true - -[node name="ref_A28" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 209.0 -offset_top = 38.0 -offset_right = 259.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "A28" -metadata/_edit_lock_ = true - -[node name="ref_A29" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 259.0 -offset_top = 38.0 -offset_right = 309.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "A29" -metadata/_edit_lock_ = true - -[node name="ref_A31" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 309.0 -offset_top = 38.0 -offset_right = 359.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "УМ2" -metadata/_edit_lock_ = true - -[node name="ref_A32" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 359.0 -offset_top = 38.0 -offset_right = 409.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "УМ3" -metadata/_edit_lock_ = true - -[node name="ref_A33" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 409.0 -offset_top = 38.0 -offset_right = 459.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "A33" -metadata/_edit_lock_ = true - -[node name="ref_A34" parent="TabContainer/ControlPanel/Signal_EMS_G" instance=ExtResource("11_d60jk")] -offset_left = 459.0 -offset_top = 38.0 -offset_right = 509.0 -offset_bottom = 216.0 -self_size = Vector2i(50, 178) -rname = "A33" -metadata/_edit_lock_ = true [node name="device" type="Label" parent="TabContainer/ControlPanel"] layout_mode = 0 diff --git a/scripts/PRD.gd b/scripts/PRD.gd index ce784db..a86b892 100644 --- a/scripts/PRD.gd +++ b/scripts/PRD.gd @@ -125,7 +125,7 @@ func _ready() -> void: for key in Constants.RAY_DICT: node_select_yau_07b.get_node2(1, 3).add_item(key) node_select_yau_07b_2.get_node2(1, 3).add_item(key) - + ## Заполненение списка аттенюатора for key in Constants.ATT_DICT: node_select_yau_07b.get_node2(1, 4).add_item(key) @@ -348,13 +348,13 @@ func _on_data_received(data_from_yau_07): var _DKM: int = data_from_yau_07.decode_u16(Constants.DataIndices.DKM) # ДКМ от УГ #node_select1.set_node_text(2, 0, '%d' % dry_contact) #node_select1.set_node_text(3, 0, '%d' % DKM) - - + + ## УКП for i in range(6): ## Мощность от УКП_1 var power_ukp_1 = data_from_yau_07.decode_u16(Constants.DataIndices.POWER_UKP_1 + 2 * i) node_select1.set_node_text(0, i+1, '%d' % power_ukp_1) - + for i in range(6): ## Температура от УКП_1 var temperature_ukp_1 = data_from_yau_07.decode_u16(Constants.DataIndices.TEMPERATURE_UKP_1 + 2 * i) var TMP = Constants.CONST_MIN_TEMP + (Constants.MAXIMUM_CODE_ADC - temperature_ukp_1) * Constants.TEMP @@ -364,7 +364,7 @@ func _on_data_received(data_from_yau_07): if len(data_from_yau_07) > Constants.DataIndices.POWER_UKP_2 + 2 * i_pow: var power_ukp_2 = data_from_yau_07.decode_u16(Constants.DataIndices.POWER_UKP_2 + 2 * i_pow) node_select2.set_node_text(0, i_pow+1, '%d' % power_ukp_2) - + for row in range(6): ## Температура от УКП_2 if len(data_from_yau_07) > Constants.DataIndices.TEMPERATURE_UKP_2 + 2 * row: var temperature_ukp_2 = data_from_yau_07.decode_u16(Constants.DataIndices.TEMPERATURE_UKP_2 + 2 * row) @@ -479,7 +479,7 @@ func _on_load_config(): func set_tab_and_buttons(tab_index: int, button_name: String) -> void: $TabContainer.current_tab = tab_index var side_panel = $Background/side_panel - + for button in side_panel.get_children(): if button is Button: button.button_pressed = (button.name == button_name) diff --git a/scripts/constants.gd b/scripts/constants.gd index 6d2c3fe..4eb493b 100644 --- a/scripts/constants.gd +++ b/scripts/constants.gd @@ -6,7 +6,7 @@ const DEFAULT_ADDRESS: String = '10.1.1.11' const DEFAULT_PORT: String = '50011' const CONST_MIN_TEMP: int = -25 const MAXIMUM_CODE_ADC: int = 3796 -const MINIMUM_CODE_AD: int = 2660 +const MINIMUM_CODE_AD: int = 2660 const TEMP: float = 115.0 / (MAXIMUM_CODE_ADC - MINIMUM_CODE_AD) const TableNode = preload("res://table/node.tscn") const TableList = preload("res://table/node_list.tscn") @@ -121,75 +121,6 @@ const ATT_DICT: Array = [ ' 10 dB', ' 10.5 dB', ] -const SIGNS_PRD: Array = [ - ## ПРК-К - [ - ' Запрет СИ7', - ' Запрет СИ1', - 'ЛИТЕРА 7! ПРД-К', - 'СЗИ6 от УФ', - 'СЗИ7 от УФ', - 'СИ6 от ФС', - 'СИ7 от ФС', - 'СИ6 в УФ', - 'СИ7 в УФ', - 'Мод. УМ 6', - 'Мод. УМ 7', - 'ФГОЗ 6', - 'Мод. УМ 1', - 'МАА №1', - 'МАА №2', - 'ИП9-50 №1', - 'ИП9-50 №2', - 'ИП9-50 №3', - 'ИП5-25', - ], - ## ПРК-В - [ - ' Запрет СИ4', - ' Запрет СИ5', - '', - 'ЛИТЕРА 5! ПРД-В', - 'СЗИ4 от УФ', - 'СЗИ5 от УФ', - 'СИ4 от ФС', - 'СИ5 от ФС', - 'СИ4 в УФ', - 'СИ5 в УФ', - 'Мод. УМ 4', - 'Мод. УМ 5', - 'ФГОЗ 4', - 'ФГОЗ 5', - 'МАА №1', - 'МАА №2', - 'ИП9-50 №1', - 'ИП9-50 №2', - '-', - '-', - 'ИП5-25', - ], - ## ПРД-Н - [ - ' Запрет СИ3', - '', - 'ЛИТЕРА 3! ПРД-Н', - 'СИ3 от ФС', - 'СИ2 в УФ', - 'СИ3 в УФ', - 'Мод. УМ 2', - 'Мод. УМ 3', - 'ФГОЗ 3', - '-', - 'МАА №1', - 'МАА №2', - 'ИП9-50 №1', - 'ИП9-50 №2', - '-', - '-', - 'ИП5-25', - '--', - ], -] enum BASE_PORTS { UG = 0x100, diff --git a/scripts/ems_g.gd b/scripts/ems_g.gd index 0821155..760296d 100644 --- a/scripts/ems_g.gd +++ b/scripts/ems_g.gd @@ -10,7 +10,7 @@ func _on_read_ems_g(): for i_input in 16: Network.write_port_isa(Constants.BASE_PORTS.EMS_G+2, 1+i_input) Network.read_port_isa([Constants.BASE_PORTS.EMS_G+0xA]) - + for i_output in range(46, 62): Network.write_port_isa(Constants.BASE_PORTS.EMS_G+2, 1+i_output) Network.read_port_isa([Constants.BASE_PORTS.EMS_G+4, Constants.BASE_PORTS.EMS_G+8]) @@ -27,7 +27,7 @@ func _on_sync(): port0x124 = Constants.EMS_G_PORT_DATA_HOLDER[index][1][key] for row in 16: if (port0x124 & (1 << row)) != 0: - var chk_btn = node_select1.get_node2(tmp_device_mode-45, row+3).get_child(1, false) + var chk_btn = node_select1.get_node2(tmp_device_mode-45, row+3).get_child(1, false) chk_btn.button_pressed =true if key == 0x128: port0x128 = Constants.EMS_G_PORT_DATA_HOLDER[index][1][key] @@ -52,24 +52,24 @@ func _ready() -> void: else: column.append(Constants.TableNode) EMS_G_TABLE.append(column) - + draw_tabl(node_select1, EMS_G_TABLE, EMS_G_TABLE.size()) - + node_select1.get_node2(1, 1).text = 'x3_ВЫХ:GND' node_select1.get_node2(0, 2).text = 'x3_ВХ :GND' for i in Constants.INPUT_EMS_G.size(): node_select1.get_node2(0, i+shift+1).text = Constants.INPUT_EMS_G[i] - + for i in Constants.OUT_EMS_G.size(): node_select1.get_node2(i+shift, 1).text = Constants.OUT_EMS_G[i][1] - + for i in EMS_G_TABLE[0].size()-shift: var list = node_select1.get_node2(i+shift, 0) list.set_meta('device', Constants.OUT_EMS_G[i][0]) list.connect('item_selected', Callable(self, 'on_mode_link').bind(list)) for k in Constants.OUT_x128.size(): - list.add_item(Constants.OUT_x128[k]) - + list.add_item(Constants.OUT_x128[k]) + var columns_min_size: Array for i in EMS_G_TABLE[0].size(): if i < 2: @@ -77,13 +77,13 @@ func _ready() -> void: else: columns_min_size.append(80) node_select1.set_columns_min_size(columns_min_size) - + var parrent_NODE2 = get_parent().get_parent() parrent_NODE2.connect('read_ems_g_start', Callable(self, '_on_read_ems_g')) parrent_NODE2.connect('read_ems_g_finish', Callable(self, '_on_sync')) Network.connect('yau_receive', Callable(self, '_on_data_received')) create_link_button(node_select1, shift+1, 16+shift+1, shift, 16+shift) - + func draw_tabl(tbl, row: Array, count_row: int): for i_row in count_row: @@ -96,23 +96,23 @@ func _on_data_received(data_from_yau_07): var out_blank: int = data_from_yau_07.decode_u16(Constants.DataIndices.OUT_BLANK_PRD) var out_imp: int = data_from_yau_07.decode_u16(Constants.DataIndices.OUT_IMPULS_PRD) var parent_node2 = get_parent().get_parent() - - process_sockets_vert(in_blank, in_imp, 16, 1, parent_node2) - process_sockets_horizon(out_blank, out_imp, 16, 2, parent_node2) - - + + #process_sockets_vert(in_blank, in_imp, 16, 1, parent_node2) + #process_sockets_horizon(out_blank, out_imp, 16, 2, parent_node2) + + func process_sockets_horizon(blank: int, imp: int, count: int, col: int, parent_node2: Node): for i in count: var socket_status = node_select1.get_node2(col+i, shift).get_child(1, false) var frame_type = Constants.Frame.WORK - + if (blank & (1 << i)) != 0: frame_type = Constants.Frame.CONSTANT elif (imp & (1 << i)) != 0: frame_type = Constants.Frame.VARIABLE - + set_frame(socket_status, frame_type) - + if i == 1: set_frame(get_specific_node(parent_node2, 5), frame_type) if i == 2: @@ -129,14 +129,14 @@ func process_sockets_vert(blank: int, imp: int, count: int, col: int, parent_nod for i in count: var socket_status = node_select1.get_node2(col, i + shift+1).get_child(1, false) var frame_type = Constants.Frame.WORK - + if (blank & (1 << i)) != 0: frame_type = Constants.Frame.CONSTANT elif (imp & (1 << i)) != 0: frame_type = Constants.Frame.VARIABLE - + set_frame(socket_status, frame_type) - + if i == 1: set_frame(get_specific_node(parent_node2, 1), frame_type) var CI_2_UF = parent_node2.get_child(3).get_child(0).get_child(0).get_child(0).get_child(2).get_node2(1, 6).get_child(1) @@ -170,7 +170,7 @@ func create_link_button(node, count_rows_sart: int, count_rows_end: int, coln_st for i_colum in 16: META_EMS_G.append([INPUT+i_row, OUTPUT+i_colum]) button_link_meta[OUTPUT+i_colum] = 0 - + var count_register = 0 for i_row in range(count_rows_sart, count_rows_end): for i_col in range (coln_start, coln_end): @@ -188,7 +188,7 @@ func on_mouse_entered(meta_area): var device = meta_area.get_meta('device') var y = device[0] + 1 var x = device[1] - 45 - + for i_y in 18: for i_x in 18: if i_y <= y and i_x <= x and i_y == y: @@ -207,9 +207,9 @@ func on_mode_link(mode, list): var meta = list.get_meta('device') var address_port_wr = Constants.BASE_PORTS.EMS_G+2 Network.write_port_isa(address_port_wr, meta) # Отправка команды - + ## Формирование команды для отправкы команды на устройство - address_port_wr = Constants.BASE_PORTS.EMS_G+8 + address_port_wr = Constants.BASE_PORTS.EMS_G+8 var set_mode = 0x0000 if mode == 0 else 0x2000 if mode == 1 else 0x4000 if mode == 2 else 0x8000 Network.write_port_isa(address_port_wr, set_mode)