14PANEL_VIA_SIZE_BASE::PANEL_VIA_SIZE_BASE( wxWindow* parent, wxWindowID
id,
const wxPoint& pos,
const wxSize& size,
long style,
const wxString&
name ) :
CALCULATOR_PANEL( parent, id, pos, size, style,
name )
16 wxBoxSizer* bSizerViaSize;
17 bSizerViaSize =
new wxBoxSizer( wxHORIZONTAL );
19 wxBoxSizer* bSizerViaLeftColumn;
20 bSizerViaLeftColumn =
new wxBoxSizer( wxVERTICAL );
22 wxStaticBoxSizer* sbSizerVS_Inputs;
23 sbSizerVS_Inputs =
new wxStaticBoxSizer(
new wxStaticBox(
this, wxID_ANY,
_(
"Parameters") ), wxVERTICAL );
25 wxFlexGridSizer* fgSizerVS_Inputs;
26 fgSizerVS_Inputs =
new wxFlexGridSizer( 0, 3, 4, 0 );
27 fgSizerVS_Inputs->AddGrowableCol( 1 );
28 fgSizerVS_Inputs->SetFlexibleDirection( wxBOTH );
29 fgSizerVS_Inputs->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
31 m_staticTextHoleDia =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Finished hole diameter (D):"), wxDefaultPosition, wxDefaultSize, 0 );
33 m_staticTextHoleDia->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL,
false, wxEmptyString ) );
37 m_textCtrlHoleDia =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
40 wxArrayString m_choiceHoleDiaChoices;
45 m_staticTextPlatingThickness =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Plating thickness (T):"), wxDefaultPosition, wxDefaultSize, 0 );
49 m_textCtrlPlatingThickness =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
52 wxArrayString m_choicePlatingThicknessChoices;
57 m_staticTextViaLength =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Via length:"), wxDefaultPosition, wxDefaultSize, 0 );
63 m_textCtrlViaLength =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
66 wxArrayString m_choiceViaLengthChoices;
69 fgSizerVS_Inputs->Add(
m_choiceViaLength, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
71 m_staticTextViaPadDia =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Via pad diameter:"), wxDefaultPosition, wxDefaultSize, 0 );
77 m_textCtrlViaPadDia =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
80 wxArrayString m_choiceViaPadDiaChoices;
83 fgSizerVS_Inputs->Add(
m_choiceViaPadDia, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
85 m_staticTextClearanceDia =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Clearance hole diameter:"), wxDefaultPosition, wxDefaultSize, 0 );
91 m_textCtrlClearanceDia =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
94 wxArrayString m_choiceClearanceDiaChoices;
99 m_staticTextImpedance =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Z0:"), wxDefaultPosition, wxDefaultSize, 0 );
105 m_textCtrlImpedance =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
108 wxArrayString m_choiceImpedanceChoices;
111 fgSizerVS_Inputs->Add(
m_choiceImpedance, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND, 5 );
113 m_staticAppliedCurrent =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Applied current:"), wxDefaultPosition, wxDefaultSize, 0 );
117 m_textCtrlAppliedCurrent =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
124 m_staticTextResistivity =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Plating resistivity:"), wxDefaultPosition, wxDefaultSize, 0 );
130 wxBoxSizer* bSizerResistivity;
131 bSizerResistivity =
new wxBoxSizer( wxHORIZONTAL );
133 m_textCtrlPlatingResistivity =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
136 m_button_ResistivityVia =
new wxButton( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"..."), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT );
140 fgSizerVS_Inputs->Add( bSizerResistivity, 1, wxEXPAND, 5 );
142 m_viaResistivityUnits =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"ohm-meter"), wxDefaultPosition, wxDefaultSize, 0 );
146 m_staticTextPermittivity =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Substrate relative permittivity:"), wxDefaultPosition, wxDefaultSize, 0 );
152 wxBoxSizer* bSizerPermittivity;
153 bSizerPermittivity =
new wxBoxSizer( wxHORIZONTAL );
155 m_textCtrlPlatingPermittivity =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
158 m_button_Permittivity =
new wxButton( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"..."), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT );
162 fgSizerVS_Inputs->Add( bSizerPermittivity, 1, wxEXPAND, 5 );
165 fgSizerVS_Inputs->Add( 0, 0, 1, wxEXPAND, 5 );
167 m_staticTextTemperatureDiff =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Temperature rise:"), wxDefaultPosition, wxDefaultSize, 0 );
173 m_textCtrlTemperatureDiff =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
176 m_viaTempUnits =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"deg C"), wxDefaultPosition, wxDefaultSize, 0 );
178 fgSizerVS_Inputs->Add(
m_viaTempUnits, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
180 m_staticTextRiseTime =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"Pulse rise time:"), wxDefaultPosition, wxDefaultSize, 0 );
186 m_textCtrlRiseTime =
new wxTextCtrl( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
187 fgSizerVS_Inputs->Add(
m_textCtrlRiseTime, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT, 5 );
189 m_staticTextRiseTimeUnits =
new wxStaticText( sbSizerVS_Inputs->GetStaticBox(), wxID_ANY,
_(
"ns"), wxDefaultPosition, wxDefaultSize, 0 );
196 sbSizerVS_Inputs->Add( fgSizerVS_Inputs, 0, wxALL|wxEXPAND, 5 );
199 bSizerViaLeftColumn->Add( sbSizerVS_Inputs, 0, wxEXPAND|wxLEFT|wxRIGHT|wxTOP, 5 );
201 m_staticTextWarning =
new wxStaticText(
this, wxID_ANY,
_(
"Warning:\nVia pad diameter >= Clearance hole diameter.\nSome parameters cannot be calculated for a via inside a copper zone."), wxDefaultPosition, wxDefaultSize, 0 );
203 m_staticTextWarning->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_BOLD,
false, wxEmptyString ) );
208 bSizerViaSize->Add( bSizerViaLeftColumn, 0, wxEXPAND, 5 );
210 wxBoxSizer* bSizerRight;
211 bSizerRight =
new wxBoxSizer( wxVERTICAL );
213 bSizerRight->SetMinSize( wxSize( -1,460 ) );
215 bSizer6 =
new wxBoxSizer( wxVERTICAL );
217 wxStaticBoxSizer* sbSizerVS_Result;
218 sbSizerVS_Result =
new wxStaticBoxSizer(
new wxStaticBox(
this, wxID_ANY,
_(
"Results") ), wxVERTICAL );
220 wxFlexGridSizer* fgSizerTW_Results11;
221 fgSizerTW_Results11 =
new wxFlexGridSizer( 0, 3, 5, 0 );
222 fgSizerTW_Results11->AddGrowableCol( 1 );
223 fgSizerTW_Results11->SetFlexibleDirection( wxBOTH );
224 fgSizerTW_Results11->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
226 m_staticTextArea11 =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Resistance:"), wxDefaultPosition, wxDefaultSize, 0 );
230 m_ViaResistance =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
232 fgSizerTW_Results11->Add(
m_ViaResistance, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxLEFT|wxRIGHT, 5 );
234 m_viaResUnits =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"ohm"), wxDefaultPosition, wxDefaultSize, 0 );
236 fgSizerTW_Results11->Add(
m_viaResUnits, 0, wxALIGN_CENTER_VERTICAL, 5 );
238 m_staticText65111 =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Voltage drop:"), wxDefaultPosition, wxDefaultSize, 0 );
242 m_ViaVoltageDrop =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
244 fgSizerTW_Results11->Add(
m_ViaVoltageDrop, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT, 5 );
246 m_staticText8411 =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"V"), wxDefaultPosition, wxDefaultSize, 0 );
248 fgSizerTW_Results11->Add(
m_staticText8411, 0, wxALIGN_CENTER_VERTICAL, 5 );
250 m_staticText66111 =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Power loss:"), wxDefaultPosition, wxDefaultSize, 0 );
254 m_ViaPowerLoss =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
256 fgSizerTW_Results11->Add(
m_ViaPowerLoss, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT, 5 );
258 m_staticText8311 =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"W"), wxDefaultPosition, wxDefaultSize, 0 );
260 fgSizerTW_Results11->Add(
m_staticText8311, 0, wxALIGN_CENTER_VERTICAL, 5 );
262 m_staticText79211 =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Thermal resistance:"), wxDefaultPosition, wxDefaultSize, 0 );
264 m_staticText79211->SetToolTip(
_(
"Using thermal conductivity value 401 Watts/(meter-Kelvin)") );
268 m_ViaThermalResistance =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
270 fgSizerTW_Results11->Add(
m_ViaThermalResistance, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT, 5 );
272 m_viaThermalResUnits =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"deg C/W"), wxDefaultPosition, wxDefaultSize, 0 );
276 m_staticTextAmpacity =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Estimated ampacity:"), wxDefaultPosition, wxDefaultSize, 0 );
282 m_ViaAmpacity =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
284 fgSizerTW_Results11->Add(
m_ViaAmpacity, 0, wxALIGN_CENTER_VERTICAL|wxEXPAND|wxRIGHT|wxLEFT, 5 );
286 m_staticTextAmpacityUnits =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"A"), wxDefaultPosition, wxDefaultSize, 0 );
290 m_staticTextCapacitance =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Capacitance:"), wxDefaultPosition, wxDefaultSize, 0 );
294 m_ViaCapacitance =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
304 m_staticTextRiseTimeOutput =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Rise time degradation:"), wxDefaultPosition, wxDefaultSize, 0 );
310 m_RiseTimeOutput =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
320 m_staticTextInductance =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Inductance:"), wxDefaultPosition, wxDefaultSize, 0 );
324 m_Inductance =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
326 fgSizerTW_Results11->Add(
m_Inductance, 0, wxRIGHT|wxLEFT, 5 );
328 m_staticTextInductanceUnits =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"nH"), wxDefaultPosition, wxDefaultSize, 0 );
334 m_staticTextReactance =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"Reactance:"), wxDefaultPosition, wxDefaultSize, 0 );
336 m_staticTextReactance->SetToolTip(
_(
"Inductive reactance for given rise time and calculated inductance") );
340 m_Reactance =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"dummy"), wxDefaultPosition, wxDefaultSize, 0 );
342 fgSizerTW_Results11->Add(
m_Reactance, 0, wxRIGHT|wxLEFT, 5 );
344 m_viaReactanceUnits =
new wxStaticText( sbSizerVS_Result->GetStaticBox(), wxID_ANY,
_(
"ohm"), wxDefaultPosition, wxDefaultSize, 0 );
349 sbSizerVS_Result->Add( fgSizerTW_Results11, 0, wxALL|wxEXPAND, 5 );
352 bSizer6->Add( sbSizerVS_Result, 0, wxALL, 5 );
354 m_viaBitmap =
new wxStaticBitmap(
this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, 0 );
357 bSizer6->Add(
m_viaBitmap, 0, wxALIGN_CENTER_HORIZONTAL|wxTOP|wxRIGHT|wxLEFT, 10 );
360 bSizerRight->Add( bSizer6, 0, 0, 5 );
363 bSizerRight->Add( 0, 0, 1, 0, 5 );
365 m_buttonViaReset =
new wxButton(
this, wxID_ANY,
_(
"Reset to Defaults"), wxDefaultPosition, wxDefaultSize, 0 );
369 bSizerViaSize->Add( bSizerRight, 1, wxEXPAND, 5 );
372 this->SetSizer( bSizerViaSize );
374 bSizerViaSize->Fit(
this );
wxTextCtrl * m_textCtrlPlatingResistivity
wxTextCtrl * m_textCtrlClearanceDia
PANEL_VIA_SIZE_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxTAB_TRAVERSAL, const wxString &name=wxEmptyString)
wxStaticText * m_RiseTimeOutput
wxStaticText * m_staticTextRiseTimeOutputUnits
wxTextCtrl * m_textCtrlPlatingThickness
wxButton * m_button_ResistivityVia
wxStaticText * m_staticTextWarning
UNIT_SELECTOR_LEN * m_choiceClearanceDia
wxStaticText * m_ViaThermalResistance
wxButton * m_button_Permittivity
wxStaticText * m_staticTextAppliedCurrentUnits
wxStaticText * m_staticTextViaLength
wxTextCtrl * m_textCtrlViaLength
wxTextCtrl * m_textCtrlAppliedCurrent
wxStaticText * m_staticTextRiseTimeUnits
virtual void OnViaRho_Button(wxCommandEvent &event)
wxStaticText * m_staticTextRiseTime
wxTextCtrl * m_textCtrlViaPadDia
wxTextCtrl * m_textCtrlRiseTime
wxStaticText * m_staticText66111
wxStaticText * m_staticTextPlatingThickness
virtual void OnViaEpsilonR_Button(wxCommandEvent &event)
wxStaticText * m_staticTextTemperatureDiff
wxStaticText * m_ViaAmpacity
wxStaticText * m_staticTextViaPadDia
wxStaticText * m_viaResUnits
wxStaticText * m_staticTextClearanceDia
wxTextCtrl * m_textCtrlHoleDia
wxStaticText * m_staticTextPermittivity
wxTextCtrl * m_textCtrlImpedance
wxStaticText * m_staticTextInductance
wxStaticText * m_staticTextReactance
wxStaticText * m_viaReactanceUnits
wxStaticText * m_staticTextRiseTimeOutput
wxStaticText * m_staticText8411
UNIT_SELECTOR_LEN * m_choiceViaPadDia
wxStaticText * m_ViaCapacitance
wxStaticText * m_staticAppliedCurrent
UNIT_SELECTOR_RESISTOR * m_choiceImpedance
wxStaticText * m_ViaResistance
wxStaticText * m_staticText79211
wxStaticText * m_staticTextAmpacityUnits
wxTextCtrl * m_textCtrlTemperatureDiff
virtual void OnViaCalculate(wxCommandEvent &event)
wxStaticText * m_Inductance
wxStaticText * m_staticTextCapacitance
wxStaticText * m_ViaVoltageDrop
wxStaticText * m_staticTextInductanceUnits
wxTextCtrl * m_textCtrlPlatingPermittivity
wxStaticText * m_staticTextHoleDia
wxStaticText * m_staticText65111
wxStaticBitmap * m_viaBitmap
wxStaticText * m_staticTextArea11
wxStaticText * m_viaResistivityUnits
wxStaticText * m_staticTextCapacitanceUnits
UNIT_SELECTOR_LEN * m_choiceViaLength
wxButton * m_buttonViaReset
UNIT_SELECTOR_LEN * m_choiceHoleDia
wxStaticText * m_viaTempUnits
wxStaticText * m_Reactance
wxStaticText * m_staticTextResistivity
wxStaticText * m_ViaPowerLoss
UNIT_SELECTOR_LEN * m_choicePlatingThickness
wxStaticText * m_staticTextImpedance
wxStaticText * m_staticTextAmpacity
virtual void OnViaResetButtonClick(wxCommandEvent &event)
wxStaticText * m_staticText8311
virtual void onUpdateViaCalcErrorText(wxUpdateUIEvent &event)
wxStaticText * m_viaThermalResUnits