hardsploit_gui 2.0 → 2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. checksums.yaml +4 -4
  2. data/lib/Firmware/FPGA/I2C/I2C_INTERACT/HARDSPLOIT_FIRMWARE_FPGA_I2C_INTERACT.rpd +0 -0
  3. data/lib/HardsploitAPI/HardsploitAPI.rb +5 -6
  4. data/lib/HardsploitAPI/HardsploitAPI_CONSTANT.rb +1 -1
  5. data/lib/HardsploitAPI/HardsploitAPI_ERROR.rb +38 -0
  6. data/lib/HardsploitAPI/HardsploitAPI_FIRMWARE.rb +3 -3
  7. data/lib/HardsploitAPI/HardsploitAPI_I2C.rb +145 -3
  8. data/lib/HardsploitAPI/HardsploitAPI_PROGRESS.rb +28 -0
  9. data/lib/HardsploitAPI/HardsploitAPI_SPI.rb +195 -5
  10. data/lib/HardsploitAPI/HardsploitAPI_USB_COMMUNICATION.rb +0 -1
  11. data/lib/HardsploitAPI/SWD/HardsploitAPI_SWD.rb +1 -1
  12. data/lib/class/Generic_commands.rb +31 -36
  13. data/lib/class/HardsploitGUI.rb +5 -4
  14. data/lib/class/I2C/I2c_export.rb +6 -9
  15. data/lib/class/I2C/I2c_import.rb +15 -28
  16. data/lib/class/I2C/I2c_settings.rb +20 -8
  17. data/lib/class/Progress_bar.rb +31 -0
  18. data/lib/class/SPI/Spi_export.rb +6 -9
  19. data/lib/class/SPI/Spi_import.rb +33 -32
  20. data/lib/class/SPI/Spi_settings.rb +50 -4
  21. data/lib/db/hs.db +0 -0
  22. data/lib/gui/gui_chip_editor.rb +120 -127
  23. data/lib/gui/gui_i2c_settings.rb +34 -5
  24. data/lib/gui/gui_progress_bar.rb +84 -0
  25. data/lib/gui/gui_spi_settings.rb +175 -49
  26. data/lib/gui_designer/gui_chip_editor.ui +134 -141
  27. data/lib/gui_designer/gui_i2c_settings.ui +35 -4
  28. data/lib/gui_designer/gui_progress_bar.ui +83 -0
  29. data/lib/gui_designer/gui_spi_settings.ui +159 -34
  30. data/lib/hardsploit.rb +12 -3
  31. data/lib/logs/error.log +1 -0
  32. data/lib/startHardsploit.rb +10 -0
  33. metadata +8 -3
  34. data/lib/gui_designer/gui_processing.ui +0 -81
@@ -0,0 +1,84 @@
1
+ =begin
2
+ ** Form generated from reading ui file 'gui_progress_bar.ui'
3
+ **
4
+ ** Created: mar. févr. 9 17:07:34 2016
5
+ ** by: Qt User Interface Compiler version 4.8.6
6
+ **
7
+ ** WARNING! All changes made in this file will be lost when recompiling ui file!
8
+ =end
9
+
10
+ class Ui_Progress_bar
11
+ attr_reader :gridLayout
12
+ attr_reader :lbl_status
13
+ attr_reader :pgb
14
+ attr_reader :horizontalLayout
15
+ attr_reader :lbl_time
16
+ attr_reader :horizontalSpacer
17
+ attr_reader :lbl_close
18
+
19
+ def setupUi(progress_bar)
20
+ if progress_bar.objectName.nil?
21
+ progress_bar.objectName = "progress_bar"
22
+ end
23
+ progress_bar.resize(358, 90)
24
+ @gridLayout = Qt::GridLayout.new(progress_bar)
25
+ @gridLayout.objectName = "gridLayout"
26
+ @lbl_status = Qt::Label.new(progress_bar)
27
+ @lbl_status.objectName = "lbl_status"
28
+
29
+ @gridLayout.addWidget(@lbl_status, 0, 0, 1, 1)
30
+
31
+ @pgb = Qt::ProgressBar.new(progress_bar)
32
+ @pgb.objectName = "pgb"
33
+ @pgb.value = 0
34
+
35
+ @gridLayout.addWidget(@pgb, 1, 0, 1, 1)
36
+
37
+ @horizontalLayout = Qt::HBoxLayout.new()
38
+ @horizontalLayout.objectName = "horizontalLayout"
39
+ @lbl_time = Qt::Label.new(progress_bar)
40
+ @lbl_time.objectName = "lbl_time"
41
+
42
+ @horizontalLayout.addWidget(@lbl_time)
43
+
44
+ @horizontalSpacer = Qt::SpacerItem.new(40, 20, Qt::SizePolicy::Expanding, Qt::SizePolicy::Minimum)
45
+
46
+ @horizontalLayout.addItem(@horizontalSpacer)
47
+
48
+ @lbl_close = Qt::PushButton.new(progress_bar)
49
+ @lbl_close.objectName = "lbl_close"
50
+
51
+ @horizontalLayout.addWidget(@lbl_close)
52
+
53
+
54
+ @gridLayout.addLayout(@horizontalLayout, 3, 0, 1, 1)
55
+
56
+
57
+ retranslateUi(progress_bar)
58
+ Qt::Object.connect(@lbl_close, SIGNAL('clicked()'), progress_bar, SLOT('close()'))
59
+
60
+ Qt::MetaObject.connectSlotsByName(progress_bar)
61
+ end # setupUi
62
+
63
+ def setup_ui(progress_bar)
64
+ setupUi(progress_bar)
65
+ end
66
+
67
+ def retranslateUi(progress_bar)
68
+ progress_bar.windowTitle = Qt::Application.translate("Progress_bar", "Processing...", nil, Qt::Application::UnicodeUTF8)
69
+ @lbl_status.text = Qt::Application.translate("Progress_bar", "[STATUS]", nil, Qt::Application::UnicodeUTF8)
70
+ @lbl_time.text = Qt::Application.translate("Progress_bar", "[TIME]", nil, Qt::Application::UnicodeUTF8)
71
+ @lbl_close.text = Qt::Application.translate("Progress_bar", "Close", nil, Qt::Application::UnicodeUTF8)
72
+ end # retranslateUi
73
+
74
+ def retranslate_ui(progress_bar)
75
+ retranslateUi(progress_bar)
76
+ end
77
+
78
+ end
79
+
80
+ module Ui
81
+ class Progress_bar < Ui_Progress_bar
82
+ end
83
+ end # module Ui
84
+
@@ -1,7 +1,7 @@
1
1
  =begin
2
2
  ** Form generated from reading ui file 'gui_spi_settings.ui'
3
3
  **
4
- ** Created: jeu. déc. 3 15:41:20 2015
4
+ ** Created: ven. févr. 12 16:51:57 2016
5
5
  ** by: Qt User Interface Compiler version 4.8.6
6
6
  **
7
7
  ** WARNING! All changes made in this file will be lost when recompiling ui file!
@@ -9,32 +9,68 @@
9
9
 
10
10
  class Ui_Spi_settings
11
11
  attr_reader :gridLayout
12
+ attr_reader :hl
13
+ attr_reader :lbl_chip
14
+ attr_reader :lbl_param
15
+ attr_reader :hs
12
16
  attr_reader :hl2
13
17
  attr_reader :fl
14
18
  attr_reader :lbl_frequency
15
19
  attr_reader :cbx_frequency
16
20
  attr_reader :lbl_cmd_read
17
21
  attr_reader :lie_cmd_read
18
- attr_reader :lbl_page_size
19
- attr_reader :lie_page_size
22
+ attr_reader :lbl_cmd_erase
23
+ attr_reader :lie_cmd_erase
24
+ attr_reader :lbl_cmd_write
25
+ attr_reader :lie_cmd_write_enable
26
+ attr_reader :lbl_mode
27
+ attr_reader :cbx_mode
28
+ attr_reader :label
29
+ attr_reader :lie_cmd_write
20
30
  attr_reader :fl2
21
31
  attr_reader :lbl_total_size
22
32
  attr_reader :lie_total_size
23
- attr_reader :lbl_mode
24
- attr_reader :cbx_mode
33
+ attr_reader :lbl_page_size
34
+ attr_reader :lie_page_size
35
+ attr_reader :label_2
36
+ attr_reader :lie_write_page_latency
37
+ attr_reader :label_3
38
+ attr_reader :lie_erase_time
39
+ attr_reader :label_4
40
+ attr_reader :rbn_yes
41
+ attr_reader :label_5
42
+ attr_reader :rbn_no
43
+ attr_reader :horizontalLayout
44
+ attr_reader :horizontalSpacer
45
+ attr_reader :btn_cancel
25
46
  attr_reader :btn_save
26
- attr_reader :hl
27
- attr_reader :lbl_chip
28
- attr_reader :lbl_param
29
- attr_reader :hs
30
47
 
31
48
  def setupUi(spi_settings)
32
49
  if spi_settings.objectName.nil?
33
50
  spi_settings.objectName = "spi_settings"
34
51
  end
35
- spi_settings.resize(531, 125)
52
+ spi_settings.resize(528, 237)
36
53
  @gridLayout = Qt::GridLayout.new(spi_settings)
37
54
  @gridLayout.objectName = "gridLayout"
55
+ @hl = Qt::HBoxLayout.new()
56
+ @hl.objectName = "hl"
57
+ @lbl_chip = Qt::Label.new(spi_settings)
58
+ @lbl_chip.objectName = "lbl_chip"
59
+
60
+ @hl.addWidget(@lbl_chip)
61
+
62
+ @lbl_param = Qt::Label.new(spi_settings)
63
+ @lbl_param.objectName = "lbl_param"
64
+
65
+ @hl.addWidget(@lbl_param)
66
+
67
+ @hs = Qt::SpacerItem.new(40, 20, Qt::SizePolicy::Expanding, Qt::SizePolicy::Minimum)
68
+
69
+ @hl.addItem(@hs)
70
+
71
+
72
+ @gridLayout.addLayout(@hl, 1, 0, 1, 1)
73
+
38
74
  @hl2 = Qt::HBoxLayout.new()
39
75
  @hl2.objectName = "hl2"
40
76
  @fl = Qt::FormLayout.new()
@@ -42,36 +78,68 @@ class Ui_Spi_settings
42
78
  @lbl_frequency = Qt::Label.new(spi_settings)
43
79
  @lbl_frequency.objectName = "lbl_frequency"
44
80
 
45
- @fl.setWidget(1, Qt::FormLayout::LabelRole, @lbl_frequency)
81
+ @fl.setWidget(2, Qt::FormLayout::LabelRole, @lbl_frequency)
46
82
 
47
83
  @cbx_frequency = Qt::ComboBox.new(spi_settings)
48
84
  @cbx_frequency.objectName = "cbx_frequency"
49
85
  @cbx_frequency.maximumSize = Qt::Size.new(100, 16777215)
50
86
 
51
- @fl.setWidget(1, Qt::FormLayout::FieldRole, @cbx_frequency)
87
+ @fl.setWidget(2, Qt::FormLayout::FieldRole, @cbx_frequency)
52
88
 
53
89
  @lbl_cmd_read = Qt::Label.new(spi_settings)
54
90
  @lbl_cmd_read.objectName = "lbl_cmd_read"
55
91
 
56
- @fl.setWidget(2, Qt::FormLayout::LabelRole, @lbl_cmd_read)
92
+ @fl.setWidget(3, Qt::FormLayout::LabelRole, @lbl_cmd_read)
57
93
 
58
94
  @lie_cmd_read = Qt::LineEdit.new(spi_settings)
59
95
  @lie_cmd_read.objectName = "lie_cmd_read"
60
96
  @lie_cmd_read.maximumSize = Qt::Size.new(100, 16777215)
61
97
  @lie_cmd_read.maxLength = 5
62
98
 
63
- @fl.setWidget(2, Qt::FormLayout::FieldRole, @lie_cmd_read)
99
+ @fl.setWidget(3, Qt::FormLayout::FieldRole, @lie_cmd_read)
64
100
 
65
- @lbl_page_size = Qt::Label.new(spi_settings)
66
- @lbl_page_size.objectName = "lbl_page_size"
101
+ @lbl_cmd_erase = Qt::Label.new(spi_settings)
102
+ @lbl_cmd_erase.objectName = "lbl_cmd_erase"
67
103
 
68
- @fl.setWidget(0, Qt::FormLayout::LabelRole, @lbl_page_size)
104
+ @fl.setWidget(5, Qt::FormLayout::LabelRole, @lbl_cmd_erase)
69
105
 
70
- @lie_page_size = Qt::LineEdit.new(spi_settings)
71
- @lie_page_size.objectName = "lie_page_size"
72
- @lie_page_size.maximumSize = Qt::Size.new(100, 16777215)
106
+ @lie_cmd_erase = Qt::LineEdit.new(spi_settings)
107
+ @lie_cmd_erase.objectName = "lie_cmd_erase"
108
+ @lie_cmd_erase.maxLength = 5
109
+
110
+ @fl.setWidget(5, Qt::FormLayout::FieldRole, @lie_cmd_erase)
111
+
112
+ @lbl_cmd_write = Qt::Label.new(spi_settings)
113
+ @lbl_cmd_write.objectName = "lbl_cmd_write"
114
+
115
+ @fl.setWidget(6, Qt::FormLayout::LabelRole, @lbl_cmd_write)
116
+
117
+ @lie_cmd_write_enable = Qt::LineEdit.new(spi_settings)
118
+ @lie_cmd_write_enable.objectName = "lie_cmd_write_enable"
119
+ @lie_cmd_write_enable.maxLength = 5
120
+
121
+ @fl.setWidget(6, Qt::FormLayout::FieldRole, @lie_cmd_write_enable)
122
+
123
+ @lbl_mode = Qt::Label.new(spi_settings)
124
+ @lbl_mode.objectName = "lbl_mode"
125
+
126
+ @fl.setWidget(1, Qt::FormLayout::LabelRole, @lbl_mode)
127
+
128
+ @cbx_mode = Qt::ComboBox.new(spi_settings)
129
+ @cbx_mode.objectName = "cbx_mode"
130
+ @cbx_mode.maximumSize = Qt::Size.new(100, 16777215)
131
+
132
+ @fl.setWidget(1, Qt::FormLayout::FieldRole, @cbx_mode)
133
+
134
+ @label = Qt::Label.new(spi_settings)
135
+ @label.objectName = "label"
73
136
 
74
- @fl.setWidget(0, Qt::FormLayout::FieldRole, @lie_page_size)
137
+ @fl.setWidget(4, Qt::FormLayout::LabelRole, @label)
138
+
139
+ @lie_cmd_write = Qt::LineEdit.new(spi_settings)
140
+ @lie_cmd_write.objectName = "lie_cmd_write"
141
+
142
+ @fl.setWidget(4, Qt::FormLayout::FieldRole, @lie_cmd_write)
75
143
 
76
144
 
77
145
  @hl2.addLayout(@fl)
@@ -90,22 +158,60 @@ class Ui_Spi_settings
90
158
 
91
159
  @fl2.setWidget(0, Qt::FormLayout::FieldRole, @lie_total_size)
92
160
 
93
- @lbl_mode = Qt::Label.new(spi_settings)
94
- @lbl_mode.objectName = "lbl_mode"
161
+ @lbl_page_size = Qt::Label.new(spi_settings)
162
+ @lbl_page_size.objectName = "lbl_page_size"
95
163
 
96
- @fl2.setWidget(1, Qt::FormLayout::LabelRole, @lbl_mode)
164
+ @fl2.setWidget(1, Qt::FormLayout::LabelRole, @lbl_page_size)
97
165
 
98
- @cbx_mode = Qt::ComboBox.new(spi_settings)
99
- @cbx_mode.objectName = "cbx_mode"
100
- @cbx_mode.maximumSize = Qt::Size.new(100, 16777215)
166
+ @lie_page_size = Qt::LineEdit.new(spi_settings)
167
+ @lie_page_size.objectName = "lie_page_size"
168
+ @lie_page_size.maximumSize = Qt::Size.new(100, 16777215)
169
+ @lie_page_size.maxLength = 10
101
170
 
102
- @fl2.setWidget(1, Qt::FormLayout::FieldRole, @cbx_mode)
171
+ @fl2.setWidget(1, Qt::FormLayout::FieldRole, @lie_page_size)
103
172
 
104
- @btn_save = Qt::PushButton.new(spi_settings)
105
- @btn_save.objectName = "btn_save"
106
- @btn_save.maximumSize = Qt::Size.new(100, 16777215)
173
+ @label_2 = Qt::Label.new(spi_settings)
174
+ @label_2.objectName = "label_2"
175
+
176
+ @fl2.setWidget(2, Qt::FormLayout::LabelRole, @label_2)
177
+
178
+ @lie_write_page_latency = Qt::LineEdit.new(spi_settings)
179
+ @lie_write_page_latency.objectName = "lie_write_page_latency"
180
+ @lie_write_page_latency.maxLength = 10
181
+
182
+ @fl2.setWidget(2, Qt::FormLayout::FieldRole, @lie_write_page_latency)
183
+
184
+ @label_3 = Qt::Label.new(spi_settings)
185
+ @label_3.objectName = "label_3"
186
+
187
+ @fl2.setWidget(3, Qt::FormLayout::LabelRole, @label_3)
188
+
189
+ @lie_erase_time = Qt::LineEdit.new(spi_settings)
190
+ @lie_erase_time.objectName = "lie_erase_time"
191
+ @lie_erase_time.maxLength = 10
192
+
193
+ @fl2.setWidget(3, Qt::FormLayout::FieldRole, @lie_erase_time)
194
+
195
+ @label_4 = Qt::Label.new(spi_settings)
196
+ @label_4.objectName = "label_4"
107
197
 
108
- @fl2.setWidget(2, Qt::FormLayout::FieldRole, @btn_save)
198
+ @fl2.setWidget(4, Qt::FormLayout::LabelRole, @label_4)
199
+
200
+ @rbn_yes = Qt::RadioButton.new(spi_settings)
201
+ @rbn_yes.objectName = "rbn_yes"
202
+ @rbn_yes.checked = true
203
+
204
+ @fl2.setWidget(4, Qt::FormLayout::FieldRole, @rbn_yes)
205
+
206
+ @label_5 = Qt::Label.new(spi_settings)
207
+ @label_5.objectName = "label_5"
208
+
209
+ @fl2.setWidget(5, Qt::FormLayout::LabelRole, @label_5)
210
+
211
+ @rbn_no = Qt::RadioButton.new(spi_settings)
212
+ @rbn_no.objectName = "rbn_no"
213
+
214
+ @fl2.setWidget(5, Qt::FormLayout::FieldRole, @rbn_no)
109
215
 
110
216
 
111
217
  @hl2.addLayout(@fl2)
@@ -113,28 +219,30 @@ class Ui_Spi_settings
113
219
 
114
220
  @gridLayout.addLayout(@hl2, 2, 0, 1, 1)
115
221
 
116
- @hl = Qt::HBoxLayout.new()
117
- @hl.objectName = "hl"
118
- @lbl_chip = Qt::Label.new(spi_settings)
119
- @lbl_chip.objectName = "lbl_chip"
222
+ @horizontalLayout = Qt::HBoxLayout.new()
223
+ @horizontalLayout.objectName = "horizontalLayout"
224
+ @horizontalSpacer = Qt::SpacerItem.new(40, 20, Qt::SizePolicy::Expanding, Qt::SizePolicy::Minimum)
120
225
 
121
- @hl.addWidget(@lbl_chip)
226
+ @horizontalLayout.addItem(@horizontalSpacer)
122
227
 
123
- @lbl_param = Qt::Label.new(spi_settings)
124
- @lbl_param.objectName = "lbl_param"
228
+ @btn_cancel = Qt::PushButton.new(spi_settings)
229
+ @btn_cancel.objectName = "btn_cancel"
125
230
 
126
- @hl.addWidget(@lbl_param)
231
+ @horizontalLayout.addWidget(@btn_cancel)
127
232
 
128
- @hs = Qt::SpacerItem.new(40, 20, Qt::SizePolicy::Expanding, Qt::SizePolicy::Minimum)
233
+ @btn_save = Qt::PushButton.new(spi_settings)
234
+ @btn_save.objectName = "btn_save"
235
+ @btn_save.maximumSize = Qt::Size.new(16777215, 16777215)
129
236
 
130
- @hl.addItem(@hs)
237
+ @horizontalLayout.addWidget(@btn_save)
131
238
 
132
239
 
133
- @gridLayout.addLayout(@hl, 1, 0, 1, 1)
240
+ @gridLayout.addLayout(@horizontalLayout, 3, 0, 1, 1)
134
241
 
135
242
 
136
243
  retranslateUi(spi_settings)
137
244
  Qt::Object.connect(@btn_save, SIGNAL('clicked()'), spi_settings, SLOT('save_settings()'))
245
+ Qt::Object.connect(@btn_cancel, SIGNAL('clicked()'), spi_settings, SLOT('close()'))
138
246
 
139
247
  Qt::MetaObject.connectSlotsByName(spi_settings)
140
248
  end # setupUi
@@ -145,6 +253,8 @@ class Ui_Spi_settings
145
253
 
146
254
  def retranslateUi(spi_settings)
147
255
  spi_settings.windowTitle = Qt::Application.translate("Spi_settings", "Hardsploit - Bus settings", nil, Qt::Application::UnicodeUTF8)
256
+ @lbl_chip.text = Qt::Application.translate("Spi_settings", "[CHIP]", nil, Qt::Application::UnicodeUTF8)
257
+ @lbl_param.text = Qt::Application.translate("Spi_settings", "PARAMETERS", nil, Qt::Application::UnicodeUTF8)
148
258
  @lbl_frequency.text = Qt::Application.translate("Spi_settings", "Frequency (Mhz):", nil, Qt::Application::UnicodeUTF8)
149
259
  @cbx_frequency.insertItems(0, [Qt::Application.translate("Spi_settings", "25.00", nil, Qt::Application::UnicodeUTF8),
150
260
  Qt::Application.translate("Spi_settings", "18.75", nil, Qt::Application::UnicodeUTF8),
@@ -160,18 +270,34 @@ class Ui_Spi_settings
160
270
  Qt::Application.translate("Spi_settings", "1.00", nil, Qt::Application::UnicodeUTF8),
161
271
  Qt::Application.translate("Spi_settings", "0.50", nil, Qt::Application::UnicodeUTF8),
162
272
  Qt::Application.translate("Spi_settings", "0.29", nil, Qt::Application::UnicodeUTF8)])
163
- @lbl_cmd_read.text = Qt::Application.translate("Spi_settings", "SPI command read:", nil, Qt::Application::UnicodeUTF8)
164
- @lie_cmd_read.text = Qt::Application.translate("Spi_settings", "3", nil, Qt::Application::UnicodeUTF8)
165
- @lbl_page_size.text = Qt::Application.translate("Spi_settings", "Page size:", nil, Qt::Application::UnicodeUTF8)
166
- @lbl_total_size.text = Qt::Application.translate("Spi_settings", "Total size (8 bits word):", nil, Qt::Application::UnicodeUTF8)
273
+ @lbl_cmd_read.text = Qt::Application.translate("Spi_settings", "Read command:", nil, Qt::Application::UnicodeUTF8)
274
+ @lie_cmd_read.text = ''
275
+ @lie_cmd_read.placeholderText = Qt::Application.translate("Spi_settings", "in decimals", nil, Qt::Application::UnicodeUTF8)
276
+ @lbl_cmd_erase.text = Qt::Application.translate("Spi_settings", "Erase command:", nil, Qt::Application::UnicodeUTF8)
277
+ @lie_cmd_erase.placeholderText = Qt::Application.translate("Spi_settings", "in decimals", nil, Qt::Application::UnicodeUTF8)
278
+ @lbl_cmd_write.text = Qt::Application.translate("Spi_settings", "Enable write command:", nil, Qt::Application::UnicodeUTF8)
279
+ @lie_cmd_write_enable.placeholderText = Qt::Application.translate("Spi_settings", "in decimals", nil, Qt::Application::UnicodeUTF8)
167
280
  @lbl_mode.text = Qt::Application.translate("Spi_settings", "Mode:", nil, Qt::Application::UnicodeUTF8)
168
281
  @cbx_mode.insertItems(0, [Qt::Application.translate("Spi_settings", "0", nil, Qt::Application::UnicodeUTF8),
169
282
  Qt::Application.translate("Spi_settings", "1", nil, Qt::Application::UnicodeUTF8),
170
283
  Qt::Application.translate("Spi_settings", "2", nil, Qt::Application::UnicodeUTF8),
171
284
  Qt::Application.translate("Spi_settings", "3", nil, Qt::Application::UnicodeUTF8)])
285
+ @label.text = Qt::Application.translate("Spi_settings", "Write command:", nil, Qt::Application::UnicodeUTF8)
286
+ @lie_cmd_write.placeholderText = Qt::Application.translate("Spi_settings", "in decimals", nil, Qt::Application::UnicodeUTF8)
287
+ @lbl_total_size.text = Qt::Application.translate("Spi_settings", "Total size:", nil, Qt::Application::UnicodeUTF8)
288
+ @lie_total_size.placeholderText = Qt::Application.translate("Spi_settings", "8 bits word", nil, Qt::Application::UnicodeUTF8)
289
+ @lbl_page_size.text = Qt::Application.translate("Spi_settings", "Page size:", nil, Qt::Application::UnicodeUTF8)
290
+ @lie_page_size.placeholderText = Qt::Application.translate("Spi_settings", "in octet", nil, Qt::Application::UnicodeUTF8)
291
+ @label_2.text = Qt::Application.translate("Spi_settings", "Write page latency:", nil, Qt::Application::UnicodeUTF8)
292
+ @lie_write_page_latency.placeholderText = Qt::Application.translate("Spi_settings", "in miliseconds", nil, Qt::Application::UnicodeUTF8)
293
+ @label_3.text = Qt::Application.translate("Spi_settings", "Clear chip time:", nil, Qt::Application::UnicodeUTF8)
294
+ @lie_erase_time.placeholderText = Qt::Application.translate("Spi_settings", "in seconds", nil, Qt::Application::UnicodeUTF8)
295
+ @label_4.text = Qt::Application.translate("Spi_settings", "Flash memory:", nil, Qt::Application::UnicodeUTF8)
296
+ @rbn_yes.text = Qt::Application.translate("Spi_settings", "Yes", nil, Qt::Application::UnicodeUTF8)
297
+ @label_5.text = ''
298
+ @rbn_no.text = Qt::Application.translate("Spi_settings", "No", nil, Qt::Application::UnicodeUTF8)
299
+ @btn_cancel.text = Qt::Application.translate("Spi_settings", "Cancel", nil, Qt::Application::UnicodeUTF8)
172
300
  @btn_save.text = Qt::Application.translate("Spi_settings", "Save", nil, Qt::Application::UnicodeUTF8)
173
- @lbl_chip.text = Qt::Application.translate("Spi_settings", "[CHIP]", nil, Qt::Application::UnicodeUTF8)
174
- @lbl_param.text = Qt::Application.translate("Spi_settings", "PARAMETERS", nil, Qt::Application::UnicodeUTF8)
175
301
  end # retranslateUi
176
302
 
177
303
  def retranslate_ui(spi_settings)
@@ -103,55 +103,8 @@
103
103
  </property>
104
104
  </widget>
105
105
  </item>
106
- <item row="7" column="0">
107
- <widget class="QLabel" name="lbl_package">
108
- <property name="text">
109
- <string>Package:</string>
110
- </property>
111
- </widget>
112
- </item>
113
- <item row="7" column="1">
114
- <layout class="QHBoxLayout" name="hl1">
115
- <item>
116
- <widget class="QComboBox" name="cbx_package">
117
- <item>
118
- <property name="text">
119
- <string>Select...</string>
120
- </property>
121
- </item>
122
- </widget>
123
- </item>
124
- <item>
125
- <widget class="QPushButton" name="btn_pack_remove">
126
- <property name="maximumSize">
127
- <size>
128
- <width>30</width>
129
- <height>16777215</height>
130
- </size>
131
- </property>
132
- <property name="text">
133
- <string>X</string>
134
- </property>
135
- </widget>
136
- </item>
137
- </layout>
138
- </item>
139
- <item row="10" column="0">
140
- <widget class="QLabel" name="lbl_pack_new">
141
- <property name="text">
142
- <string>Not in the list ? Create a new one</string>
143
- </property>
144
- </widget>
145
- </item>
146
- <item row="11" column="0">
147
- <widget class="QLabel" name="lbl_name">
148
- <property name="text">
149
- <string>Package name:</string>
150
- </property>
151
- </widget>
152
- </item>
153
- <item row="11" column="1">
154
- <widget class="QLineEdit" name="lie_pack_name">
106
+ <item row="0" column="1">
107
+ <widget class="QLineEdit" name="lie_reference">
155
108
  <property name="maxLength">
156
109
  <number>30</number>
157
110
  </property>
@@ -160,40 +113,27 @@
160
113
  </property>
161
114
  </widget>
162
115
  </item>
163
- <item row="12" column="0">
164
- <widget class="QLabel" name="lbl_pack_pin">
116
+ <item row="1" column="0">
117
+ <widget class="QLabel" name="lbl_description">
165
118
  <property name="text">
166
- <string>Package pin number:</string>
119
+ <string>Description:</string>
167
120
  </property>
168
121
  </widget>
169
122
  </item>
170
- <item row="12" column="1">
171
- <widget class="QLineEdit" name="lie_pack_pin">
172
- <property name="inputMask">
173
- <string/>
174
- </property>
123
+ <item row="1" column="1">
124
+ <widget class="QLineEdit" name="lie_description">
175
125
  <property name="maxLength">
176
- <number>3</number>
126
+ <number>200</number>
177
127
  </property>
178
128
  <property name="placeholderText">
179
- <string>4-144</string>
129
+ <string>200 chars max</string>
180
130
  </property>
181
131
  </widget>
182
132
  </item>
183
- <item row="13" column="0">
184
- <widget class="QLabel" name="lbl_pack_shape">
133
+ <item row="2" column="0">
134
+ <widget class="QLabel" name="lbl_voltage">
185
135
  <property name="text">
186
- <string>Package shape:</string>
187
- </property>
188
- </widget>
189
- </item>
190
- <item row="0" column="1">
191
- <widget class="QLineEdit" name="lie_reference">
192
- <property name="maxLength">
193
- <number>30</number>
194
- </property>
195
- <property name="placeholderText">
196
- <string>30 chars max</string>
136
+ <string>Voltage:</string>
197
137
  </property>
198
138
  </widget>
199
139
  </item>
@@ -243,69 +183,39 @@
243
183
  </item>
244
184
  </layout>
245
185
  </item>
246
- <item row="2" column="0">
247
- <widget class="QLabel" name="lbl_voltage">
186
+ <item row="3" column="0">
187
+ <widget class="QLabel" name="lbl_manu">
248
188
  <property name="text">
249
- <string>Voltage:</string>
189
+ <string>Manufacturer:</string>
250
190
  </property>
251
191
  </widget>
252
192
  </item>
253
- <item row="13" column="1">
254
- <layout class="QHBoxLayout" name="hl3">
193
+ <item row="3" column="1">
194
+ <layout class="QHBoxLayout" name="hl4">
255
195
  <item>
256
- <widget class="QGroupBox" name="groupBox_2">
257
- <property name="title">
258
- <string/>
259
- </property>
260
- <widget class="QRadioButton" name="rbn_square">
261
- <property name="geometry">
262
- <rect>
263
- <x>10</x>
264
- <y>0</y>
265
- <width>81</width>
266
- <height>20</height>
267
- </rect>
268
- </property>
269
- <property name="text">
270
- <string>Square</string>
271
- </property>
272
- <property name="checked">
273
- <bool>true</bool>
274
- </property>
275
- <property name="autoExclusive">
276
- <bool>true</bool>
277
- </property>
278
- </widget>
279
- <widget class="QRadioButton" name="rbn_rectangular">
280
- <property name="geometry">
281
- <rect>
282
- <x>110</x>
283
- <y>0</y>
284
- <width>109</width>
285
- <height>20</height>
286
- </rect>
287
- </property>
196
+ <widget class="QComboBox" name="cbx_manufacturer">
197
+ <item>
288
198
  <property name="text">
289
- <string>Rectangular</string>
290
- </property>
291
- <property name="checked">
292
- <bool>false</bool>
293
- </property>
294
- <property name="autoExclusive">
295
- <bool>true</bool>
199
+ <string>Select...</string>
296
200
  </property>
297
- </widget>
201
+ </item>
202
+ </widget>
203
+ </item>
204
+ <item>
205
+ <widget class="QPushButton" name="btn_manu_remove">
206
+ <property name="maximumSize">
207
+ <size>
208
+ <width>30</width>
209
+ <height>16777215</height>
210
+ </size>
211
+ </property>
212
+ <property name="text">
213
+ <string>X</string>
214
+ </property>
298
215
  </widget>
299
216
  </item>
300
217
  </layout>
301
218
  </item>
302
- <item row="3" column="0">
303
- <widget class="QLabel" name="lbl_manu">
304
- <property name="text">
305
- <string>Manufacturer:</string>
306
- </property>
307
- </widget>
308
- </item>
309
219
  <item row="4" column="1">
310
220
  <widget class="QLineEdit" name="lie_manu_name">
311
221
  <property name="maxLength">
@@ -362,27 +272,17 @@
362
272
  </property>
363
273
  </widget>
364
274
  </item>
365
- <item row="1" column="0">
366
- <widget class="QLabel" name="lbl_description">
275
+ <item row="7" column="0">
276
+ <widget class="QLabel" name="lbl_package">
367
277
  <property name="text">
368
- <string>Description:</string>
369
- </property>
370
- </widget>
371
- </item>
372
- <item row="1" column="1">
373
- <widget class="QLineEdit" name="lie_description">
374
- <property name="maxLength">
375
- <number>200</number>
376
- </property>
377
- <property name="placeholderText">
378
- <string>200 chars max</string>
278
+ <string>Package:</string>
379
279
  </property>
380
280
  </widget>
381
281
  </item>
382
- <item row="3" column="1">
383
- <layout class="QHBoxLayout" name="hl4">
282
+ <item row="7" column="1">
283
+ <layout class="QHBoxLayout" name="hl1">
384
284
  <item>
385
- <widget class="QComboBox" name="cbx_manufacturer">
285
+ <widget class="QComboBox" name="cbx_package">
386
286
  <item>
387
287
  <property name="text">
388
288
  <string>Select...</string>
@@ -391,7 +291,7 @@
391
291
  </widget>
392
292
  </item>
393
293
  <item>
394
- <widget class="QPushButton" name="btn_manu_remove">
294
+ <widget class="QPushButton" name="btn_pack_remove">
395
295
  <property name="maximumSize">
396
296
  <size>
397
297
  <width>30</width>
@@ -405,6 +305,99 @@
405
305
  </item>
406
306
  </layout>
407
307
  </item>
308
+ <item row="8" column="0">
309
+ <widget class="QLabel" name="lbl_name">
310
+ <property name="text">
311
+ <string>Package name:</string>
312
+ </property>
313
+ </widget>
314
+ </item>
315
+ <item row="8" column="1">
316
+ <widget class="QLineEdit" name="lie_pack_name">
317
+ <property name="maxLength">
318
+ <number>30</number>
319
+ </property>
320
+ <property name="placeholderText">
321
+ <string>30 chars max</string>
322
+ </property>
323
+ </widget>
324
+ </item>
325
+ <item row="9" column="0">
326
+ <widget class="QLabel" name="lbl_pack_pin">
327
+ <property name="text">
328
+ <string>Package pin number:</string>
329
+ </property>
330
+ </widget>
331
+ </item>
332
+ <item row="9" column="1">
333
+ <widget class="QLineEdit" name="lie_pack_pin">
334
+ <property name="inputMask">
335
+ <string/>
336
+ </property>
337
+ <property name="maxLength">
338
+ <number>3</number>
339
+ </property>
340
+ <property name="placeholderText">
341
+ <string>4-144</string>
342
+ </property>
343
+ </widget>
344
+ </item>
345
+ <item row="10" column="0">
346
+ <widget class="QLabel" name="lbl_pack_shape">
347
+ <property name="text">
348
+ <string>Package shape:</string>
349
+ </property>
350
+ </widget>
351
+ </item>
352
+ <item row="10" column="1">
353
+ <layout class="QHBoxLayout" name="hl3">
354
+ <item>
355
+ <widget class="QGroupBox" name="groupBox_2">
356
+ <property name="title">
357
+ <string/>
358
+ </property>
359
+ <widget class="QRadioButton" name="rbn_square">
360
+ <property name="geometry">
361
+ <rect>
362
+ <x>10</x>
363
+ <y>0</y>
364
+ <width>81</width>
365
+ <height>20</height>
366
+ </rect>
367
+ </property>
368
+ <property name="text">
369
+ <string>Square</string>
370
+ </property>
371
+ <property name="checked">
372
+ <bool>true</bool>
373
+ </property>
374
+ <property name="autoExclusive">
375
+ <bool>true</bool>
376
+ </property>
377
+ </widget>
378
+ <widget class="QRadioButton" name="rbn_rectangular">
379
+ <property name="geometry">
380
+ <rect>
381
+ <x>110</x>
382
+ <y>0</y>
383
+ <width>109</width>
384
+ <height>20</height>
385
+ </rect>
386
+ </property>
387
+ <property name="text">
388
+ <string>Rectangular</string>
389
+ </property>
390
+ <property name="checked">
391
+ <bool>false</bool>
392
+ </property>
393
+ <property name="autoExclusive">
394
+ <bool>true</bool>
395
+ </property>
396
+ </widget>
397
+ </widget>
398
+ </item>
399
+ </layout>
400
+ </item>
408
401
  </layout>
409
402
  </item>
410
403
  </layout>