Add more unit selectors, temperature and material coefficient
to Calculator Tools/ Cable size
Fix some previous leftovers from 086ebe0f1d
Fixes: https://gitlab.com/kicad/code/kicad/-/issues/12129
This commit is contained in:
parent
d5e1990cf4
commit
ed47c47ec2
|
@ -84,6 +84,14 @@ PANEL_CABLE_SIZE::PANEL_CABLE_SIZE( wxWindow* parent, wxWindowID id, const wxPoi
|
|||
m_sizeChoice->Append( entry.m_Name );
|
||||
}
|
||||
|
||||
m_staticText16412->SetLabel( wxT( "Ω⋅m" ) );
|
||||
m_staticText181->SetLabel( wxT( "°C" ) );
|
||||
m_staticText161211->SetLabel( wxT( "Ω" ) );
|
||||
m_staticText1641->SetLabel( wxT( "mm²" ) );
|
||||
|
||||
// Needed on wxWidgets 3.0 to ensure sizers are correctly set
|
||||
GetSizer()->SetSizeHints( this );
|
||||
|
||||
// Set internal state flags:
|
||||
m_updatingUI = false;
|
||||
m_updatingDiameter = false;
|
||||
|
@ -93,7 +101,7 @@ PANEL_CABLE_SIZE::PANEL_CABLE_SIZE( wxWindow* parent, wxWindowID id, const wxPoi
|
|||
m_updatingAmpacity = false;
|
||||
m_updatingCurrent = false;
|
||||
m_updatingLength = false;
|
||||
m_updatingResistance = false;
|
||||
m_updatingResistanceDc = false;
|
||||
m_updatingRVdrop = false;
|
||||
m_updatingPower = false;
|
||||
|
||||
|
@ -103,9 +111,12 @@ PANEL_CABLE_SIZE::PANEL_CABLE_SIZE( wxWindow* parent, wxWindowID id, const wxPoi
|
|||
// Stored in normalized units
|
||||
|
||||
m_diameter = 0.001;
|
||||
m_conductorTemperature = 20;
|
||||
m_current = 1.0;
|
||||
m_length = 1.0;
|
||||
m_conductorMaterialResitivity = 1.72e-8; //Initialized for copper
|
||||
m_conductorMaterialResitivityRef = 1.72e-8; //Initialized for copper at 20 deg C
|
||||
m_conductorMaterialThermalCoef = 3.93e-3;
|
||||
|
||||
updateAll( m_diameter / 2 );
|
||||
}
|
||||
|
@ -128,7 +139,10 @@ void PANEL_CABLE_SIZE::SaveSettings( PCB_CALCULATOR_SETTINGS* aCfg )
|
|||
aCfg->m_cableSize.linResUnit = m_linResistanceUnit->GetSelection();
|
||||
aCfg->m_cableSize.frequencyUnit = m_frequencyUnit->GetSelection();
|
||||
aCfg->m_cableSize.lengthUnit = m_lengthUnit->GetSelection();
|
||||
aCfg->m_cableSize.conductorMaterialResitivity = m_textCtrlConductorResistivity->GetValue();
|
||||
aCfg->m_cableSize.conductorMaterialResitivity = wxString( "" )
|
||||
<< m_conductorMaterialResitivityRef;
|
||||
aCfg->m_cableSize.conductorTemperature = m_conductorTempCtrl->GetValue();
|
||||
aCfg->m_cableSize.conductorThermalCoef = m_textCtrlConductorThermCoef->GetValue();
|
||||
}
|
||||
|
||||
|
||||
|
@ -139,12 +153,24 @@ void PANEL_CABLE_SIZE::LoadSettings( PCB_CALCULATOR_SETTINGS* aCfg )
|
|||
m_frequencyUnit->SetSelection( aCfg->m_cableSize.frequencyUnit );
|
||||
m_lengthUnit->SetSelection( aCfg->m_cableSize.lengthUnit );
|
||||
m_textCtrlConductorResistivity->SetValue( aCfg->m_cableSize.conductorMaterialResitivity );
|
||||
m_conductorTempCtrl->SetValue( aCfg->m_cableSize.conductorTemperature );
|
||||
m_textCtrlConductorThermCoef->SetValue( aCfg->m_cableSize.conductorThermalCoef );
|
||||
|
||||
if( m_textCtrlConductorResistivity->IsEmpty() )
|
||||
wxString value = wxString( "" ) << m_conductorMaterialResitivity;
|
||||
|
||||
if( m_textCtrlConductorResistivity->IsEmpty() || value == "nan" )
|
||||
{
|
||||
//Initialize m_textCtrl to fill UI space
|
||||
//Working variable initialized earlier
|
||||
m_textCtrlConductorResistivity->SetValue( "1.72e-8" );
|
||||
m_conductorTempCtrl->SetValue( "20" );
|
||||
}
|
||||
|
||||
if( m_textCtrlConductorThermCoef->IsEmpty() )
|
||||
{
|
||||
//Initialize m_textCtrl to fill UI space
|
||||
//Working variable initialized earlier
|
||||
m_textCtrlConductorThermCoef->SetValue( "3.93e-3" );
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -167,26 +193,53 @@ void PANEL_CABLE_SIZE::OnConductorResistivityChange( wxCommandEvent& aEvent )
|
|||
{
|
||||
if( !m_updatingUI )
|
||||
{
|
||||
m_conductorMaterialResitivity =
|
||||
m_updatingConductorMaterialResitivity = true;
|
||||
|
||||
m_conductorMaterialResitivityRef =
|
||||
std::abs( DoubleFromString( m_textCtrlConductorResistivity->GetValue() ) );
|
||||
updateAll( m_diameter / 2 );
|
||||
m_updatingConductorMaterialResitivity = false;
|
||||
}
|
||||
}
|
||||
|
||||
void PANEL_CABLE_SIZE::OnConductorResistivity_Button( wxCommandEvent& event )
|
||||
{
|
||||
wxArrayString list = StandardResistivityList();
|
||||
wxArrayString list = StandardCableConductorList();
|
||||
|
||||
// Shows a list of current Specific resistance list (rho) and select a value
|
||||
wxString value =
|
||||
wxGetSingleChoice( wxEmptyString, _( "Electrical Resistivity in Ohm*m" ), list )
|
||||
wxString value = wxGetSingleChoice( wxEmptyString,
|
||||
_( "Electrical Resistivity in Ohm*m at 20 deg C" ), list )
|
||||
.BeforeFirst( ' ' );
|
||||
|
||||
if( !value.IsEmpty() )
|
||||
m_textCtrlConductorResistivity->ChangeValue( value );
|
||||
|
||||
OnConductorResistivityChange( event );
|
||||
}
|
||||
|
||||
void PANEL_CABLE_SIZE::OnConductorThermCoefChange( wxCommandEvent& aEvent )
|
||||
{
|
||||
if( !m_updatingUI )
|
||||
{
|
||||
m_conductorMaterialThermalCoef =
|
||||
std::abs( DoubleFromString( m_textCtrlConductorThermCoef->GetValue() ) );
|
||||
updateAll( m_diameter / 2 );
|
||||
}
|
||||
}
|
||||
|
||||
void PANEL_CABLE_SIZE::OnConductorThermCoefChange_Button( wxCommandEvent& event )
|
||||
{
|
||||
wxArrayString list = StandardCableTempCoefList();
|
||||
|
||||
// Shows a list of current Specific resistance list (rho) and select a value
|
||||
wxString value = wxGetSingleChoice( wxEmptyString, _( "Temperature coefficient" ), list )
|
||||
.BeforeFirst( ' ' );
|
||||
|
||||
if( !value.IsEmpty() )
|
||||
m_textCtrlConductorThermCoef->ChangeValue( value );
|
||||
OnConductorThermCoefChange( event );
|
||||
}
|
||||
|
||||
void PANEL_CABLE_SIZE::OnDiameterChange( wxCommandEvent& aEvent )
|
||||
{
|
||||
if( !m_updatingUI )
|
||||
|
@ -275,6 +328,20 @@ void PANEL_CABLE_SIZE::OnAmpacityChange( wxCommandEvent& aEvent )
|
|||
}
|
||||
}
|
||||
|
||||
void PANEL_CABLE_SIZE::OnConductorTempChange( wxCommandEvent& aEvent )
|
||||
{
|
||||
if( !m_updatingUI )
|
||||
{
|
||||
double value;
|
||||
|
||||
if( m_conductorTempCtrl->GetValue().ToDouble( &value ) )
|
||||
{
|
||||
m_conductorTemperature = value;
|
||||
updateAll( m_diameter / 2 );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void PANEL_CABLE_SIZE::OnCurrentChange( wxCommandEvent& aEvent )
|
||||
{
|
||||
|
@ -310,19 +377,19 @@ void PANEL_CABLE_SIZE::OnLengthChange( wxCommandEvent& aEvent )
|
|||
}
|
||||
|
||||
|
||||
void PANEL_CABLE_SIZE::OnResistanceChange( wxCommandEvent& aEvent )
|
||||
void PANEL_CABLE_SIZE::OnResistanceDcChange( wxCommandEvent& aEvent )
|
||||
{
|
||||
if( !m_updatingUI )
|
||||
{
|
||||
double value;
|
||||
m_updatingResistance = true;
|
||||
m_updatingResistanceDc = true;
|
||||
|
||||
if( m_resistanceCtrl->GetValue().ToDouble( &value ) )
|
||||
if( m_resistanceDcCtrl->GetValue().ToDouble( &value ) )
|
||||
{
|
||||
updateAll( sqrt( m_conductorMaterialResitivity / value * m_length / M_PI ) );
|
||||
m_sizeChoice->SetSelection( -1 );
|
||||
}
|
||||
m_updatingResistance = false;
|
||||
m_updatingResistanceDc = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -336,10 +403,8 @@ void PANEL_CABLE_SIZE::OnVDropChange( wxCommandEvent& aEvent )
|
|||
|
||||
if( m_vDropCtrl->GetValue().ToDouble( &value ) )
|
||||
{
|
||||
// in m_vDropCtrl, The value is in mV. We need it in Volt in calculations
|
||||
value /= 1000;
|
||||
updateAll(
|
||||
sqrt( m_conductorMaterialResitivity / value * m_length * m_current / M_PI ) );
|
||||
updateAll( sqrt( m_conductorMaterialResitivity / value * m_vDropUnit->GetUnitScale()
|
||||
* m_length * m_current / M_PI ) );
|
||||
m_sizeChoice->SetSelection( -1 );
|
||||
}
|
||||
m_updatingRVdrop = false;
|
||||
|
@ -356,10 +421,8 @@ void PANEL_CABLE_SIZE::OnPowerChange( wxCommandEvent& aEvent )
|
|||
|
||||
if( m_powerCtrl->GetValue().ToDouble( &value ) )
|
||||
{
|
||||
// m_powerCtrl shows the power in mW. we need Watts
|
||||
value /= 1000;
|
||||
updateAll( sqrt( m_conductorMaterialResitivity / value * m_length * m_current
|
||||
* m_current / M_PI ) );
|
||||
updateAll( sqrt( m_conductorMaterialResitivity / value * m_powerUnit->GetUnitScale()
|
||||
* m_length * m_current * m_current / M_PI ) );
|
||||
m_sizeChoice->SetSelection( -1 );
|
||||
}
|
||||
m_updatingPower = false;
|
||||
|
@ -372,6 +435,7 @@ void PANEL_CABLE_SIZE::printAll()
|
|||
m_updatingUI = true;
|
||||
|
||||
wxString value;
|
||||
wxString tooltipString;
|
||||
|
||||
if( !m_updatingDiameter )
|
||||
{
|
||||
|
@ -409,29 +473,40 @@ void PANEL_CABLE_SIZE::printAll()
|
|||
m_lengthCtrl->SetValue( value );
|
||||
}
|
||||
|
||||
if( !m_updatingConductorMaterialResitivity )
|
||||
{
|
||||
//This is not really to update m_textCtrlConductorResistivity since we do not override user's input
|
||||
//rather than update its tooltip
|
||||
//value = wxString( "" ) << m_conductorMaterialResitivity;
|
||||
value = wxString( "" ) << m_conductorMaterialResitivityRef;
|
||||
m_textCtrlConductorResistivity->SetValue( value );
|
||||
tooltipString = wxString( "Resistivity for " )
|
||||
<< m_conductorTemperature << wxString( " deg C is" )
|
||||
<< m_conductorMaterialResitivity << wxString( " Ohm*m" );
|
||||
m_textCtrlConductorResistivity->SetToolTip( tooltipString );
|
||||
}
|
||||
|
||||
if( !m_updatingCurrent )
|
||||
{
|
||||
value = wxString( "" ) << m_current;
|
||||
m_currentCtrl->SetValue( value );
|
||||
}
|
||||
|
||||
if( !m_updatingResistance )
|
||||
if( !m_updatingResistanceDc )
|
||||
{
|
||||
value = wxString( "" ) << m_resistance;
|
||||
m_resistanceCtrl->SetValue( value );
|
||||
value = wxString( "" ) << m_resistanceDc;
|
||||
m_resistanceDcCtrl->SetValue( value );
|
||||
}
|
||||
|
||||
if( !m_updatingRVdrop )
|
||||
{
|
||||
// The value is in mV
|
||||
value = wxString( "" ) << m_voltageDrop * 1000;
|
||||
value = wxString( "" ) << m_voltageDrop * m_vDropUnit->GetUnitScale();
|
||||
m_vDropCtrl->SetValue( value );
|
||||
}
|
||||
|
||||
if( !m_updatingPower )
|
||||
{
|
||||
// m_powerCtrl shows the power in mW. we have Watts
|
||||
value = wxString( "" ) << m_dissipatedPower * 1000;
|
||||
value = wxString( "" ) << m_dissipatedPower * m_powerUnit->GetUnitScale();
|
||||
m_powerCtrl->SetValue( value );
|
||||
}
|
||||
|
||||
|
@ -444,8 +519,10 @@ void PANEL_CABLE_SIZE::updateAll( double aRadius )
|
|||
// Update wire properties
|
||||
m_diameter = aRadius * 2;
|
||||
m_area = M_PI * aRadius * aRadius;
|
||||
m_conductorMaterialResitivity =
|
||||
m_conductorMaterialResitivityRef
|
||||
* ( 1 + m_conductorMaterialThermalCoef * ( m_conductorTemperature - 20 ) );
|
||||
m_linearResistance = m_conductorMaterialResitivity / m_area;
|
||||
|
||||
// max frequency is when skin depth = radius
|
||||
m_maxFrequency = m_conductorMaterialResitivity
|
||||
/ ( M_PI * aRadius * aRadius * VACCUM_PERMEABILITY * RELATIVE_PERMEABILITY );
|
||||
|
@ -455,8 +532,8 @@ void PANEL_CABLE_SIZE::updateAll( double aRadius )
|
|||
m_ampacity = ( m_area * 1973525241.77 ) / 700;
|
||||
|
||||
// Update application-specific values
|
||||
m_resistance = m_linearResistance * m_length;
|
||||
m_voltageDrop = m_resistance * m_current;
|
||||
m_resistanceDc = m_linearResistance * m_length;
|
||||
m_voltageDrop = m_resistanceDc * m_current;
|
||||
m_dissipatedPower = m_voltageDrop * m_current;
|
||||
|
||||
printAll();
|
||||
|
@ -464,8 +541,9 @@ void PANEL_CABLE_SIZE::updateAll( double aRadius )
|
|||
|
||||
void PANEL_CABLE_SIZE::updateApplication()
|
||||
{
|
||||
m_resistance = m_linearResistance * m_length;
|
||||
m_voltageDrop = m_resistance * m_current;
|
||||
m_resistanceDc = m_linearResistance * m_length;
|
||||
m_voltageDrop = m_resistanceDc * m_current;
|
||||
m_dissipatedPower = m_voltageDrop * m_current;
|
||||
|
||||
printAll();
|
||||
}
|
||||
|
|
|
@ -50,15 +50,18 @@ public:
|
|||
void OnCableSizeChange( wxCommandEvent& aEvent ) override;
|
||||
void OnConductorResistivityChange( wxCommandEvent& aEvent ) override;
|
||||
void OnConductorResistivity_Button( wxCommandEvent& aEvent ) override;
|
||||
void OnConductorThermCoefChange( wxCommandEvent& aEvent ) override;
|
||||
void OnConductorThermCoefChange_Button( wxCommandEvent& aEvent ) override;
|
||||
void OnUpdateUnit( wxCommandEvent& aEvent ) override;
|
||||
void OnDiameterChange( wxCommandEvent& aEvent ) override;
|
||||
void OnAreaChange( wxCommandEvent& aEvent ) override;
|
||||
void OnLinResistanceChange( wxCommandEvent& aEvent ) override;
|
||||
void OnFrequencyChange( wxCommandEvent& aEvent ) override;
|
||||
void OnAmpacityChange( wxCommandEvent& aEvent ) override;
|
||||
void OnConductorTempChange( wxCommandEvent& aEvent ) override;
|
||||
void OnCurrentChange( wxCommandEvent& aEvent ) override;
|
||||
void OnLengthChange( wxCommandEvent& aEvent ) override;
|
||||
void OnResistanceChange( wxCommandEvent& aEvent ) override;
|
||||
void OnResistanceDcChange( wxCommandEvent& aEvent ) override;
|
||||
void OnVDropChange( wxCommandEvent& aEvent ) override;
|
||||
void OnPowerChange( wxCommandEvent& aEvent ) override;
|
||||
|
||||
|
@ -73,27 +76,30 @@ private:
|
|||
bool m_updatingUI;
|
||||
bool m_updatingDiameter;
|
||||
bool m_updatingArea;
|
||||
bool m_updatingConductorMaterialResitivity;
|
||||
bool m_updatingLinResistance;
|
||||
bool m_updatingFrequency;
|
||||
bool m_updatingAmpacity;
|
||||
bool m_updatingCurrent;
|
||||
bool m_updatingLength;
|
||||
bool m_updatingResistance;
|
||||
bool m_updatingResistanceDc;
|
||||
bool m_updatingRVdrop;
|
||||
bool m_updatingPower;
|
||||
|
||||
bool m_imperial;
|
||||
|
||||
// Stored in normalized units
|
||||
double m_button_ResistivityConductor;
|
||||
double m_conductorMaterialResitivity;
|
||||
double m_conductorMaterialResitivityRef;
|
||||
double m_conductorMaterialThermalCoef;
|
||||
double m_diameter;
|
||||
double m_conductorTemperature;
|
||||
double m_current;
|
||||
double m_length;
|
||||
double m_area;
|
||||
double m_linearResistance;
|
||||
double m_maxFrequency;
|
||||
double m_resistance;
|
||||
double m_resistanceDc;
|
||||
double m_voltageDrop;
|
||||
double m_dissipatedPower;
|
||||
double m_ampacity;
|
||||
|
|
|
@ -68,13 +68,15 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
|
||||
m_staticText18 = new wxStaticText( sbSizer1->GetStaticBox(), wxID_ANY, _("Conductor resistivity:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText18->Wrap( -1 );
|
||||
m_staticText18->SetToolTip( _("Specific resistance in Ohm*m at 20 deg C") );
|
||||
|
||||
fgSizerLeft->Add( m_staticText18, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL, 5 );
|
||||
|
||||
wxBoxSizer* bSizerResistivity;
|
||||
bSizerResistivity = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_textCtrlConductorResistivity = new wxTextCtrl( sbSizer1->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
bSizerResistivity->Add( m_textCtrlConductorResistivity, 1, wxEXPAND|wxLEFT, 5 );
|
||||
bSizerResistivity->Add( m_textCtrlConductorResistivity, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxTOP, 5 );
|
||||
|
||||
m_button_ResistivityConductor = new wxButton( sbSizer1->GetStaticBox(), wxID_ANY, _("..."), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT );
|
||||
bSizerResistivity->Add( m_button_ResistivityConductor, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
|
||||
|
@ -82,6 +84,28 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
|
||||
fgSizerLeft->Add( bSizerResistivity, 1, wxEXPAND, 5 );
|
||||
|
||||
m_staticText16412 = new wxStaticText( sbSizer1->GetStaticBox(), wxID_ANY, _("ohm-meter"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText16412->Wrap( -1 );
|
||||
fgSizerLeft->Add( m_staticText16412, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_LEFT|wxALL, 5 );
|
||||
|
||||
m_staticText182 = new wxStaticText( sbSizer1->GetStaticBox(), wxID_ANY, _("Temperature Coefficient:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText182->Wrap( -1 );
|
||||
m_staticText182->SetToolTip( _("Thermal coefficient at 20 deg C") );
|
||||
|
||||
fgSizerLeft->Add( m_staticText182, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL, 5 );
|
||||
|
||||
wxBoxSizer* bSizerResistivity1;
|
||||
bSizerResistivity1 = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_textCtrlConductorThermCoef = new wxTextCtrl( sbSizer1->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
bSizerResistivity1->Add( m_textCtrlConductorThermCoef, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxTOP, 5 );
|
||||
|
||||
m_button_Temp_Coef_Conductor = new wxButton( sbSizer1->GetStaticBox(), wxID_ANY, _("..."), wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT );
|
||||
bSizerResistivity1->Add( m_button_Temp_Coef_Conductor, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
|
||||
|
||||
|
||||
fgSizerLeft->Add( bSizerResistivity1, 1, wxEXPAND, 5 );
|
||||
|
||||
|
||||
fgSizerLeft->Add( 0, 0, 1, wxEXPAND, 5 );
|
||||
|
||||
|
@ -121,7 +145,7 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
fgSizerLeft->Add( m_staticText16421, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
|
||||
|
||||
|
||||
sbSizer1->Add( fgSizerLeft, 1, wxEXPAND, 5 );
|
||||
sbSizer1->Add( fgSizerLeft, 0, wxEXPAND, 5 );
|
||||
|
||||
|
||||
bSizer4->Add( sbSizer1, 0, wxALL|wxEXPAND, 5 );
|
||||
|
@ -135,6 +159,19 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
fgSizerRight->SetFlexibleDirection( wxBOTH );
|
||||
fgSizerRight->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
||||
|
||||
m_staticText17 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("Cable temperature:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText17->Wrap( -1 );
|
||||
m_staticText17->SetToolTip( _("Off-Load max conductor temp. Reference: 20 deg C") );
|
||||
|
||||
fgSizerRight->Add( m_staticText17, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL, 5 );
|
||||
|
||||
m_conductorTempCtrl = new wxTextCtrl( sbSizer12->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fgSizerRight->Add( m_conductorTempCtrl, 0, wxALL, 5 );
|
||||
|
||||
m_staticText181 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("deg C"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText181->Wrap( -1 );
|
||||
fgSizerRight->Add( m_staticText181, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_LEFT|wxALL, 5 );
|
||||
|
||||
m_staticText163 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("Current:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText163->Wrap( -1 );
|
||||
fgSizerRight->Add( m_staticText163, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL, 5 );
|
||||
|
@ -148,6 +185,8 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
|
||||
m_staticText1612 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("Length:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText1612->Wrap( -1 );
|
||||
m_staticText1612->SetToolTip( _("Length includes the return path") );
|
||||
|
||||
fgSizerRight->Add( m_staticText1612, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL, 5 );
|
||||
|
||||
m_lengthCtrl = new wxTextCtrl( sbSizer12->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
|
@ -158,12 +197,14 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
m_lengthUnit->SetSelection( 0 );
|
||||
fgSizerRight->Add( m_lengthUnit, 0, wxALL, 5 );
|
||||
|
||||
m_staticText16121 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("Resistance:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText16121 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("Resistance DC:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText16121->Wrap( -1 );
|
||||
m_staticText16121->SetToolTip( _("DC Resistance of the conductor") );
|
||||
|
||||
fgSizerRight->Add( m_staticText16121, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL, 5 );
|
||||
|
||||
m_resistanceCtrl = new wxTextCtrl( sbSizer12->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fgSizerRight->Add( m_resistanceCtrl, 1, wxALL|wxEXPAND, 5 );
|
||||
m_resistanceDcCtrl = new wxTextCtrl( sbSizer12->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fgSizerRight->Add( m_resistanceDcCtrl, 1, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_staticText161211 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("ohm"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText161211->Wrap( -1 );
|
||||
|
@ -176,9 +217,10 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
m_vDropCtrl = new wxTextCtrl( sbSizer12->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fgSizerRight->Add( m_vDropCtrl, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_staticText1612121 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("mV"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText1612121->Wrap( -1 );
|
||||
fgSizerRight->Add( m_staticText1612121, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
|
||||
wxArrayString m_vDropUnitChoices;
|
||||
m_vDropUnit = new UNIT_SELECTOR_VOLTAGE( sbSizer12->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_vDropUnitChoices, 0 );
|
||||
m_vDropUnit->SetSelection( 0 );
|
||||
fgSizerRight->Add( m_vDropUnit, 0, wxALL, 5 );
|
||||
|
||||
m_staticText1612122 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("Dissipated power:"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText1612122->Wrap( -1 );
|
||||
|
@ -187,9 +229,10 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
m_powerCtrl = new wxTextCtrl( sbSizer12->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
||||
fgSizerRight->Add( m_powerCtrl, 0, wxALL|wxEXPAND, 5 );
|
||||
|
||||
m_staticText16121211 = new wxStaticText( sbSizer12->GetStaticBox(), wxID_ANY, _("mW"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_staticText16121211->Wrap( -1 );
|
||||
fgSizerRight->Add( m_staticText16121211, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 );
|
||||
wxArrayString m_powerUnitChoices;
|
||||
m_powerUnit = new UNIT_SELECTOR_POWER( sbSizer12->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_powerUnitChoices, 0 );
|
||||
m_powerUnit->SetSelection( 0 );
|
||||
fgSizerRight->Add( m_powerUnit, 0, wxALL, 5 );
|
||||
|
||||
|
||||
sbSizer12->Add( fgSizerRight, 1, wxEXPAND, 5 );
|
||||
|
@ -214,17 +257,22 @@ PANEL_CABLE_SIZE_BASE::PANEL_CABLE_SIZE_BASE( wxWindow* parent, wxWindowID id, c
|
|||
m_areaCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnAreaChange ), NULL, this );
|
||||
m_textCtrlConductorResistivity->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorResistivityChange ), NULL, this );
|
||||
m_button_ResistivityConductor->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorResistivity_Button ), NULL, this );
|
||||
m_textCtrlConductorThermCoef->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorThermCoefChange ), NULL, this );
|
||||
m_button_Temp_Coef_Conductor->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorThermCoefChange_Button ), NULL, this );
|
||||
m_linResistanceCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnLinResistanceChange ), NULL, this );
|
||||
m_linResistanceUnit->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
m_frequencyCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnFrequencyChange ), NULL, this );
|
||||
m_frequencyUnit->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
m_AmpacityCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnAmpacityChange ), NULL, this );
|
||||
m_conductorTempCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorTempChange ), NULL, this );
|
||||
m_currentCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnCurrentChange ), NULL, this );
|
||||
m_lengthCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnLengthChange ), NULL, this );
|
||||
m_lengthUnit->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
m_resistanceCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnResistanceChange ), NULL, this );
|
||||
m_resistanceDcCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnResistanceDcChange ), NULL, this );
|
||||
m_vDropCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnVDropChange ), NULL, this );
|
||||
m_vDropUnit->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
m_powerCtrl->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnPowerChange ), NULL, this );
|
||||
m_powerUnit->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
}
|
||||
|
||||
PANEL_CABLE_SIZE_BASE::~PANEL_CABLE_SIZE_BASE()
|
||||
|
@ -236,16 +284,21 @@ PANEL_CABLE_SIZE_BASE::~PANEL_CABLE_SIZE_BASE()
|
|||
m_areaCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnAreaChange ), NULL, this );
|
||||
m_textCtrlConductorResistivity->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorResistivityChange ), NULL, this );
|
||||
m_button_ResistivityConductor->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorResistivity_Button ), NULL, this );
|
||||
m_textCtrlConductorThermCoef->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorThermCoefChange ), NULL, this );
|
||||
m_button_Temp_Coef_Conductor->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorThermCoefChange_Button ), NULL, this );
|
||||
m_linResistanceCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnLinResistanceChange ), NULL, this );
|
||||
m_linResistanceUnit->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
m_frequencyCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnFrequencyChange ), NULL, this );
|
||||
m_frequencyUnit->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
m_AmpacityCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnAmpacityChange ), NULL, this );
|
||||
m_conductorTempCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnConductorTempChange ), NULL, this );
|
||||
m_currentCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnCurrentChange ), NULL, this );
|
||||
m_lengthCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnLengthChange ), NULL, this );
|
||||
m_lengthUnit->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
m_resistanceCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnResistanceChange ), NULL, this );
|
||||
m_resistanceDcCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnResistanceDcChange ), NULL, this );
|
||||
m_vDropCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnVDropChange ), NULL, this );
|
||||
m_vDropUnit->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
m_powerCtrl->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnPowerChange ), NULL, this );
|
||||
m_powerUnit->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( PANEL_CABLE_SIZE_BASE::OnUpdateUnit ), NULL, this );
|
||||
|
||||
}
|
||||
|
|
|
@ -90,7 +90,7 @@
|
|||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="proportion">1</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxFlexGridSizer" expanded="1">
|
||||
<property name="cols">3</property>
|
||||
<property name="flexible_direction">wxBOTH</property>
|
||||
|
@ -671,7 +671,7 @@
|
|||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="tooltip">Specific resistance in Ohm*m at 20 deg C</property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
|
@ -689,8 +689,8 @@
|
|||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<property name="flag">wxBOTTOM|wxEXPAND|wxLEFT|wxTOP</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
|
@ -828,6 +828,278 @@
|
|||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALIGN_LEFT|wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">ohm-meter</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_staticText16412</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Temperature Coefficient:</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_staticText182</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">Thermal coefficient at 20 deg C</property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxBoxSizer" expanded="1">
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">bSizerResistivity1</property>
|
||||
<property name="orient">wxHORIZONTAL</property>
|
||||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxBOTTOM|wxEXPAND|wxLEFT|wxTOP</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="maxlength">0</property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_textCtrlConductorThermCoef</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="value"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnText">OnConductorThermCoefChange</event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxRIGHT</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxButton" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="auth_needed">0</property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="bitmap"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="current"></property>
|
||||
<property name="default">0</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="disabled"></property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="focus"></property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">...</property>
|
||||
<property name="margins"></property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_button_Temp_Coef_Conductor</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="position"></property>
|
||||
<property name="pressed"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style">wxBU_EXACTFIT</property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnButtonClick">OnConductorThermCoefChange_Button</event>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND</property>
|
||||
|
@ -1439,6 +1711,193 @@
|
|||
<property name="permission">none</property>
|
||||
<property name="rows">0</property>
|
||||
<property name="vgap">0</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Cable temperature:</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_staticText17</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">Off-Load max conductor temp. Reference: 20 deg C</property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxTextCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="maxlength"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_conductorTempCtrl</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="value"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnText">OnConductorTempChange</event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALIGN_LEFT|wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">deg C</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_staticText181</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT|wxALL</property>
|
||||
|
@ -1680,7 +2139,7 @@
|
|||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="tooltip">Length includes the return path</property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
|
@ -1849,7 +2308,7 @@
|
|||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Resistance:</property>
|
||||
<property name="label">Resistance DC:</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
|
@ -1871,7 +2330,7 @@
|
|||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="tooltip">DC Resistance of the conductor</property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
|
@ -1918,7 +2377,7 @@
|
|||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_resistanceCtrl</property>
|
||||
<property name="name">m_resistanceDcCtrl</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
|
@ -1940,7 +2399,7 @@
|
|||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnText">OnResistanceChange</event>
|
||||
<event name="OnText">OnResistanceDcChange</event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
|
@ -2132,9 +2591,9 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALL</property>
|
||||
<property name="flag">wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<object class="wxChoice" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
|
@ -2148,6 +2607,7 @@
|
|||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="choices"></property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
|
@ -2162,8 +2622,6 @@
|
|||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">mV</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
|
@ -2171,7 +2629,7 @@
|
|||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_staticText1612121</property>
|
||||
<property name="name">m_vDropUnit</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
|
@ -2179,16 +2637,21 @@
|
|||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="selection">0</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="subclass">UNIT_SELECTOR_VOLTAGE; widgets/unit_selector.h; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
<event name="OnChoice">OnUpdateUnit</event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
|
@ -2319,9 +2782,9 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxALL</property>
|
||||
<property name="flag">wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticText" expanded="1">
|
||||
<object class="wxChoice" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
|
@ -2335,6 +2798,7 @@
|
|||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="choices"></property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
|
@ -2349,8 +2813,6 @@
|
|||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">mW</property>
|
||||
<property name="markup">0</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
|
@ -2358,7 +2820,7 @@
|
|||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_staticText16121211</property>
|
||||
<property name="name">m_powerUnit</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
|
@ -2366,16 +2828,21 @@
|
|||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="selection">0</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass">; ; forward_declare</property>
|
||||
<property name="subclass">UNIT_SELECTOR_POWER; widgets/unit_selector.h; forward_declare</property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<property name="wrap">-1</property>
|
||||
<event name="OnChoice">OnUpdateUnit</event>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
|
|
|
@ -14,6 +14,8 @@ class UNIT_SELECTOR_FREQUENCY;
|
|||
class UNIT_SELECTOR_LEN;
|
||||
class UNIT_SELECTOR_LEN_CABLE;
|
||||
class UNIT_SELECTOR_LINEAR_RESISTANCE;
|
||||
class UNIT_SELECTOR_POWER;
|
||||
class UNIT_SELECTOR_VOLTAGE;
|
||||
|
||||
#include "calculator_panels/calculator_panel.h"
|
||||
#include <wx/string.h>
|
||||
|
@ -54,6 +56,10 @@ class PANEL_CABLE_SIZE_BASE : public CALCULATOR_PANEL
|
|||
wxStaticText* m_staticText18;
|
||||
wxTextCtrl* m_textCtrlConductorResistivity;
|
||||
wxButton* m_button_ResistivityConductor;
|
||||
wxStaticText* m_staticText16412;
|
||||
wxStaticText* m_staticText182;
|
||||
wxTextCtrl* m_textCtrlConductorThermCoef;
|
||||
wxButton* m_button_Temp_Coef_Conductor;
|
||||
wxStaticText* m_staticText16411;
|
||||
wxTextCtrl* m_linResistanceCtrl;
|
||||
UNIT_SELECTOR_LINEAR_RESISTANCE* m_linResistanceUnit;
|
||||
|
@ -63,6 +69,9 @@ class PANEL_CABLE_SIZE_BASE : public CALCULATOR_PANEL
|
|||
wxStaticText* m_staticText1642;
|
||||
wxTextCtrl* m_AmpacityCtrl;
|
||||
wxStaticText* m_staticText16421;
|
||||
wxStaticText* m_staticText17;
|
||||
wxTextCtrl* m_conductorTempCtrl;
|
||||
wxStaticText* m_staticText181;
|
||||
wxStaticText* m_staticText163;
|
||||
wxTextCtrl* m_currentCtrl;
|
||||
wxStaticText* m_staticText;
|
||||
|
@ -70,14 +79,14 @@ class PANEL_CABLE_SIZE_BASE : public CALCULATOR_PANEL
|
|||
wxTextCtrl* m_lengthCtrl;
|
||||
UNIT_SELECTOR_LEN_CABLE* m_lengthUnit;
|
||||
wxStaticText* m_staticText16121;
|
||||
wxTextCtrl* m_resistanceCtrl;
|
||||
wxTextCtrl* m_resistanceDcCtrl;
|
||||
wxStaticText* m_staticText161211;
|
||||
wxStaticText* m_staticText161212;
|
||||
wxTextCtrl* m_vDropCtrl;
|
||||
wxStaticText* m_staticText1612121;
|
||||
UNIT_SELECTOR_VOLTAGE* m_vDropUnit;
|
||||
wxStaticText* m_staticText1612122;
|
||||
wxTextCtrl* m_powerCtrl;
|
||||
wxStaticText* m_staticText16121211;
|
||||
UNIT_SELECTOR_POWER* m_powerUnit;
|
||||
|
||||
// Virtual event handlers, override them in your derived class
|
||||
virtual void OnCableSizeChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
@ -86,12 +95,15 @@ class PANEL_CABLE_SIZE_BASE : public CALCULATOR_PANEL
|
|||
virtual void OnAreaChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnConductorResistivityChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnConductorResistivity_Button( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnConductorThermCoefChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnConductorThermCoefChange_Button( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnLinResistanceChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnFrequencyChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnAmpacityChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnConductorTempChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnCurrentChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnLengthChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnResistanceChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnResistanceDcChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnVDropChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
virtual void OnPowerChange( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* This program source code file is part of KICAD, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 1992-2021 Kicad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 1992-2022 Kicad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -89,8 +89,8 @@ void PANEL_VIA_SIZE::OnViaEpsilonR_Button( wxCommandEvent& event )
|
|||
//Shows a list of current relative dielectric constant(Er) and select a value.
|
||||
wxArrayString list = StandardRelativeDielectricConstantList();
|
||||
|
||||
wxString value = wxGetSingleChoice( wxEmptyString, _("Relative Dielectric Constants"),
|
||||
list).BeforeFirst( ' ' );
|
||||
wxString value = wxGetSingleChoice( wxEmptyString, _( "Relative Dielectric Constants" ), list )
|
||||
.BeforeFirst( ' ' );
|
||||
|
||||
if( !value.IsEmpty() )
|
||||
m_textCtrlPlatingPermittivity->SetValue( value );
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* This program source code file is part of KICAD, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 1992-2021 Kicad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 1992-2022 Kicad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
|
|
@ -100,3 +100,34 @@ wxArrayString StandardResistivityList()
|
|||
|
||||
return list;
|
||||
}
|
||||
|
||||
wxArrayString StandardCableConductorList()
|
||||
{
|
||||
wxArrayString list;
|
||||
|
||||
// Lined the same as StandardCableTempCoefList
|
||||
// Specific resistance list in ohms*meters (rho):
|
||||
list.Clear();
|
||||
list.Add( wxT( "1.72e-8 Cu, Copper" ) );
|
||||
list.Add( wxT( "2.62e-8 Al, Aluminum" ) );
|
||||
list.Add( wxT( "100e-8 NiCr, Nichrome" ) );
|
||||
list.Add( wxT( "9.71e-8 Fe, Iron" ) );
|
||||
list.Add( wxT( "5.6e-8 W, Tungsten" ) );
|
||||
|
||||
return list;
|
||||
}
|
||||
|
||||
wxArrayString StandardCableTempCoefList()
|
||||
{
|
||||
wxArrayString list;
|
||||
// Lined the same as StandardCableConductorList
|
||||
// Specific temperature coefficient (20C):
|
||||
list.Clear();
|
||||
list.Add( wxT( "3.93e-3 Cu, Copper" ) );
|
||||
list.Add( wxT( "4.29e-3 Al, Aluminum" ) );
|
||||
list.Add( wxT( "0.4e-3 NiCr, Nichrome" ) );
|
||||
list.Add( wxT( "5e-3 Fe, Iron" ) );
|
||||
list.Add( wxT( "4.5e-3 W, Tungsten" ) );
|
||||
|
||||
return list;
|
||||
}
|
||||
|
|
|
@ -47,4 +47,16 @@ wxArrayString StandardLossTangentList();
|
|||
*/
|
||||
wxArrayString StandardResistivityList();
|
||||
|
||||
/**
|
||||
* @return a list of resistivity constants (Er) of some conductors
|
||||
* used to make cable cores
|
||||
*/
|
||||
wxArrayString StandardCableConductorList();
|
||||
|
||||
/**
|
||||
* @return a list of temperature coefficient constants of some conductors
|
||||
* used to make cable cores
|
||||
*/
|
||||
wxArrayString StandardCableTempCoefList();
|
||||
|
||||
#endif // #ifndef COMMON_DATA_H
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2020 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2022 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -87,6 +87,12 @@ PCB_CALCULATOR_SETTINGS::PCB_CALCULATOR_SETTINGS() :
|
|||
m_params.emplace_back( new PARAM<wxString>( "cable_size.conductorMaterialResitivity",
|
||||
&m_cableSize.conductorMaterialResitivity, "" ) );
|
||||
|
||||
m_params.emplace_back( new PARAM<wxString>( "cable_size.conductorTemperature",
|
||||
&m_cableSize.conductorTemperature, "" ) );
|
||||
|
||||
m_params.emplace_back( new PARAM<wxString>( "cable_size.conductorThermalCoef",
|
||||
&m_cableSize.conductorThermalCoef, "" ) );
|
||||
|
||||
m_params.emplace_back( new PARAM<int>( "regulators.type", &m_Regulators.type, 0 ) );
|
||||
|
||||
m_params.emplace_back( new PARAM<int>( "regulators.last_param", &m_Regulators.last_param, 0 ) );
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2020-2021 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2020-2022 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -69,6 +69,8 @@ public:
|
|||
int frequencyUnit;
|
||||
int lengthUnit;
|
||||
wxString conductorMaterialResitivity;
|
||||
wxString conductorTemperature;
|
||||
wxString conductorThermalCoef;
|
||||
};
|
||||
|
||||
struct WAVELENGTH
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2011-2014 Jean-Pierre Charras
|
||||
* Copyright (C) 2004-2021 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2004-2022 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -51,7 +51,16 @@
|
|||
#define UNIT_OHM_PER_METER 1.0 // Ohm per meter to Ohm per meter
|
||||
#define UNIT_OHM_PER_KILOMETER 1e-3 // Ohm per kilometer to Ohm per meter
|
||||
#define UNIT_OHM_PER_FEET 3.28084 // Ohm per feet to Ohm per meter
|
||||
#define UNIT_OHM_PER_1000FEET 3.28084e-3 // Ohm per feet to Ohm per meter
|
||||
#define UNIT_OHM_PER_1000FEET 3.28084e-3 // Ohm per 1000feet to Ohm per meter
|
||||
|
||||
#define UNIT_KILOVOLT 1e-3 // Kilovolt to Volt
|
||||
#define UNIT_VOLT 1.0 // Volt to Volt
|
||||
#define UNIT_MILLIVOLT 1e+3 // Millivolt to Volt
|
||||
|
||||
#define UNIT_MEGAWATT 1e-6 // Kilowatt to Watt
|
||||
#define UNIT_KILOWATT 1e-3 // Kilowatt to Watt
|
||||
#define UNIT_WATT 1.0 // Watt to Watt
|
||||
#define UNIT_MILLIWATT 1e+3 // Milliwatt to Watt
|
||||
|
||||
#define UNIT_METER_PER_SECOND 1.0 // meter per second to meter per second
|
||||
#define UNIT_KILOMETER_PER_HOUR ( 1 / 3.6 ) // km/h to m/s
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2011-2014 Jean-Pierre Charras
|
||||
* Copyright (C) 2004-2021 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2004-2022 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -214,11 +214,10 @@ UNIT_SELECTOR_LEN_CABLE::UNIT_SELECTOR_LEN_CABLE( wxWindow *parent, wxWindowID i
|
|||
Append( _( "feet" ) );
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Function GetUnitScale
|
||||
* return the scaling factor to convert users units
|
||||
* to normalized units (meter)
|
||||
* to normalized units ( m )
|
||||
*/
|
||||
double UNIT_SELECTOR_LEN_CABLE::GetUnitScale()
|
||||
{
|
||||
|
@ -233,6 +232,54 @@ double UNIT_SELECTOR_LEN_CABLE::GetUnitScale()
|
|||
return 1.0;
|
||||
}
|
||||
|
||||
/*
|
||||
* Function GetUnitScale
|
||||
* return the scaling factor to convert users units
|
||||
* to normalized units ( V )
|
||||
*/
|
||||
double UNIT_SELECTOR_VOLTAGE::GetUnitScale()
|
||||
{
|
||||
switch( GetCurrentSelection() )
|
||||
{
|
||||
case 0: return UNIT_MILLIVOLT; break;
|
||||
case 1: return UNIT_VOLT; break;
|
||||
}
|
||||
return 1.0;
|
||||
}
|
||||
|
||||
UNIT_SELECTOR_VOLTAGE::UNIT_SELECTOR_VOLTAGE( wxWindow* parent, wxWindowID id, const wxPoint& pos,
|
||||
const wxSize& size, const wxArrayString& choices,
|
||||
long style ) :
|
||||
UNIT_SELECTOR( parent, id, pos, size, choices, style )
|
||||
{
|
||||
Append( _( "mV" ) );
|
||||
Append( _( "V" ) );
|
||||
}
|
||||
|
||||
/*
|
||||
* Function GetUnitScale
|
||||
* return the scaling factor to convert users units
|
||||
* to normalized units ( W )
|
||||
*/
|
||||
double UNIT_SELECTOR_POWER::GetUnitScale()
|
||||
{
|
||||
switch( GetCurrentSelection() )
|
||||
{
|
||||
case 0: return UNIT_MILLIWATT; break;
|
||||
case 1: return UNIT_WATT; break;
|
||||
}
|
||||
return 1.0;
|
||||
}
|
||||
|
||||
UNIT_SELECTOR_POWER::UNIT_SELECTOR_POWER( wxWindow* parent, wxWindowID id, const wxPoint& pos,
|
||||
const wxSize& size, const wxArrayString& choices,
|
||||
long style ) :
|
||||
UNIT_SELECTOR( parent, id, pos, size, choices, style )
|
||||
{
|
||||
Append( _( "mW" ) );
|
||||
Append( _( "W" ) );
|
||||
}
|
||||
|
||||
UNIT_SELECTOR_SPEED::UNIT_SELECTOR_SPEED( wxWindow* parent, wxWindowID id, const wxPoint& pos,
|
||||
const wxSize& size, const wxArrayString& choices,
|
||||
long style ) :
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2011-2014 Jean-Pierre Charras
|
||||
* Copyright (C) 2004-2016 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 2004-2022 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -154,7 +154,35 @@ public:
|
|||
/**
|
||||
* Function GetUnitScale
|
||||
* @return the scaling factor to convert users units
|
||||
* to normalized units ( ohm/m )
|
||||
* to normalized units ( m )
|
||||
*/
|
||||
double GetUnitScale() override;
|
||||
};
|
||||
|
||||
class UNIT_SELECTOR_VOLTAGE : public UNIT_SELECTOR
|
||||
{
|
||||
public:
|
||||
UNIT_SELECTOR_VOLTAGE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size,
|
||||
const wxArrayString& choices, long style = 0 );
|
||||
|
||||
/**
|
||||
* Function GetUnitScale
|
||||
* @return the scaling factor to convert users units
|
||||
* to normalized units ( V )
|
||||
*/
|
||||
double GetUnitScale() override;
|
||||
};
|
||||
|
||||
class UNIT_SELECTOR_POWER : public UNIT_SELECTOR
|
||||
{
|
||||
public:
|
||||
UNIT_SELECTOR_POWER( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size,
|
||||
const wxArrayString& choices, long style = 0 );
|
||||
|
||||
/**
|
||||
* Function GetUnitScale
|
||||
* @return the scaling factor to convert users units
|
||||
* to normalized units ( W )
|
||||
*/
|
||||
double GetUnitScale() override;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue