KiCad PCB EDA Suite
Loading...
Searching...
No Matches
time_domain_parameters.h
Go to the documentation of this file.
1/*
2 * This program source code file is part of KiCad, a free EDA CAD application.
3 *
4 * Copyright (C) 2020 CERN
5 * Copyright The KiCad Developers, see AUTHORS.txt for contributors.
6 * @author Jon Evans <[email protected]>
7 *
8 * This program is free software: you can redistribute it and/or modify it
9 * under the terms of the GNU General Public License as published by the
10 * Free Software Foundation, either version 3 of the License, or (at your
11 * option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful, but
14 * WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License along
19 * with this program. If not, see <http://www.gnu.org/licenses/>.
20 */
21
22#ifndef KICAD_TIME_DOMAIN_PARAMETERS_H
23#define KICAD_TIME_DOMAIN_PARAMETERS_H
24
26#include <layer_ids.h>
27
32{
38
40 {
43
44 if( m_SignalLayerTo != other.m_SignalLayerTo )
46
47 if( m_ViaLayerFrom != other.m_ViaLayerFrom )
49
50 if( m_ViaLayerTo != other.m_ViaLayerTo )
52
53 return m_Delay < other.m_Delay;
54 }
55};
56
57
62{
63 wxString m_ProfileName;
65 std::map<PCB_LAYER_ID, int> m_LayerPropagationDelays;
66 std::vector<DELAY_PROFILE_VIA_OVERRIDE_ENTRY> m_ViaOverrides;
67};
68
69
74{
75public:
76 TIME_DOMAIN_PARAMETERS( JSON_SETTINGS* aParent, const std::string& aPath );
77
79
80 bool operator==( const TIME_DOMAIN_PARAMETERS& aOther ) const;
81
82 bool operator!=( const TIME_DOMAIN_PARAMETERS& aOther ) const { return !operator==( aOther ); }
83
84 void ClearDelayProfiles() { m_delayProfiles.clear(); }
85
86 void AddDelayProfile( DELAY_PROFILE&& aTraceEntry ) { m_delayProfiles.emplace_back( std::move( aTraceEntry ) ); }
87
88 const std::vector<DELAY_PROFILE>& GetDelayProfiles() const { return m_delayProfiles; }
89
90private:
91 std::vector<DELAY_PROFILE> m_delayProfiles;
92};
93
94#endif // KICAD_NET_SETTINGS_H
bool operator==(const wxAuiPaneInfo &aLhs, const wxAuiPaneInfo &aRhs)
NESTED_SETTINGS is a JSON_SETTINGS that lives inside a JSON_SETTINGS.
TIME_DOMAIN_PARAMETERS stores the configuration for time-domain tuning.
void AddDelayProfile(DELAY_PROFILE &&aTraceEntry)
const std::vector< DELAY_PROFILE > & GetDelayProfiles() const
bool operator!=(const TIME_DOMAIN_PARAMETERS &aOther) const
std::vector< DELAY_PROFILE > m_delayProfiles
#define KICOMMON_API
Definition: kicommon.h:28
bool IsCopperLayerLowerThan(PCB_LAYER_ID aLayerA, PCB_LAYER_ID aLayerB)
Return true if copper aLayerA is placed lower than aLayerB, false otherwise.
Definition: layer_ids.h:809
PCB_LAYER_ID
A quick note on layer IDs:
Definition: layer_ids.h:60
Represents a single line in the time domain configuration via overrides configuration grid.
PCB_LAYER_ID m_SignalLayerFrom
bool operator<(const DELAY_PROFILE_VIA_OVERRIDE_ENTRY &other) const
PCB_LAYER_ID m_ViaLayerFrom
int m_Delay
PCB_LAYER_ID m_SignalLayerTo
PCB_LAYER_ID m_ViaLayerTo
Represents a single line in the time domain configuration net class configuration grid.
std::vector< DELAY_PROFILE_VIA_OVERRIDE_ENTRY > m_ViaOverrides
std::map< PCB_LAYER_ID, int > m_LayerPropagationDelays