113 Commits

Author SHA1 Message Date
Seth Hillbrand
b207ec8817 Remove negative index access from CPoint
Callers should be responsible for index count and/or use iterators
2025-08-08 10:46:45 -07:00
Jeff Young
044ac6e8e5 Prefer board's errorMax to a constant. 2025-06-27 22:59:12 -06:00
JamesJCode
eb17ebee4e Implement time-domain length tuning
- Adds time and delay units
- Adds time domain tuning parameters entry and storage
- Adds pad-to-die delay property
- Adds time domain parameter interface for length / delay calculations
- Adds unit tracking for numerical constants through LIBEVAL
   - Will need future work to truly propagate through binary expressions
- Adds time domain tuning to meander placers
- Adds time delay display to net inspector panel
- Modifies DRC to handle time domain constraints
2025-04-17 21:46:56 +01:00
JamesJCode
906c24bc6d Unify length calculation between router, board / frame, and DRC 2025-03-30 09:18:41 +01:00
Jeff Young
f951497a4f Code brevity. 2025-03-01 21:58:31 +00:00
Tomasz Wlostowski
849e3d2f18 qa: fix setting of router mode (single/diff) in pns_log_viewer 2025-02-03 13:24:27 +01:00
jean-pierre charras
e487f19260 QA api test: ensure the "C" locale is used in tests.
Fix also a compatibility with current code in drc_proto.cpp
2025-01-26 11:47:18 +01:00
John Beard
c19a1718de PNS log viewer: fix loading via relative paths
This means you can run like this:

  ./qa/tools/pns/pns_debug_tool replay ../qa/data/pcbnew/pns_regressions/simple_shove1/pns.log
2025-01-08 22:14:36 +08:00
Seth Hillbrand
0b2d4d4879 Revise Copyright statement to align with TLF
Recommendation is to avoid using the year nomenclature as this
information is already encoded in the git repo.  Avoids needing to
repeatly update.

Also updates AUTHORS.txt from current repo with contributor names
2025-01-01 14:12:04 -08:00
Seth Hillbrand
e9bc8cfe9d Give Clipper1 a Viking funeral
Clears out the last spot where we were only using Clipper1 (how'd I
miss that?) and remove all calls to the Clipper1 structures
2024-12-23 17:12:09 -08:00
Marek Roszko
22d13546fb Some DisplayError -> DisplayErrorMessage 2024-12-20 19:28:30 -05:00
jean-pierre charras
4c632990ff QA: fix build issue when KICAD_DRC_PROTO is ON (OFF by default) 2024-11-30 18:26:28 +01:00
Seth Hillbrand
9dfcb6a362 Cleanup ViewGetLayers()
Old style c-array replaced with vector returns
2024-11-21 13:18:36 -08:00
Jon Evans
83020447b0 Fix build of PNS log viewer 2024-11-05 08:02:07 -05:00
Jon Evans
7bd8cd9721 Disable qa_pns_regressions for now 2024-11-03 12:00:40 -05:00
Jon Evans
2d0e8c73d0 Fix crashes in qa_pns_regressions 2024-11-03 11:22:15 -05:00
Alex Shvartzkop
bc7d5c821c Fix some warnings. 2024-11-03 00:01:26 +03:00
Tomasz Wlostowski
6ef68d99d5 qa: followup changes in the router in the pns_debug_tool (multidrag + some UI rework) 2024-11-02 19:59:09 +01:00
Alex Shvartzkop
5ef9a8235d Fix link errors in QA. 2024-10-22 19:54:10 +03:00
Fabien Corona
34ac0fc6f7 add drc_test_provider_clearance_base.cpp to qa cmake 2024-10-22 18:49:04 +02:00
jean-pierre charras
3671342933 Fix missing change in commit 6cfff715 in QA PNS tool 2024-09-29 12:05:27 +02:00
Seth Hillbrand
a8dc101010 Fix layer translation in setting start item
Need to be very careful when translating between PNS layers and board
layers.  PNS layers are linear while board layers are not, so reaching
into the view will return a board layer (maybe we should proxy this
through the iface?)

Fixes https://gitlab.com/kicad/code/kicad/-/issues/18708
2024-09-27 11:08:19 -07:00
John Beard
0d2371c9c3 IBIS: Constness and skipping copies
Lot of things can be const which makes the interface
a bit more legible and safe to use - lots of things are
accessing pointers that if they changed, would have wierd
and unpredicatable effects.

Probably of minor concern in practice, but a lot of strings
and vectors are being copied when they don't have to be.
Very crude profiling indicates this could save 30-50% of the time in
KIBIS::KIBIS after ParseFile, but this is incidental to
clarifying the API of the classes.

Report is const as it doesn't change the logical state of the
IBIS_ANY object (if m_reporter were a ref, it'd be mutable).

If a T* isn't null-checked inside a function, pass as ref
to show that the function expects and requires non-nullity.
2024-09-19 06:35:43 +01:00
Seth Hillbrand
1a6b309ad6 Some extra cleanup for layer interface
PNS<->Board layer interface needs clear boundaries about where we are
using board layers (with the alternating numbers) and PNS layers which
are sequential and all copper
2024-09-13 15:50:12 -07:00
Seth Hillbrand
5e0abadb23 Reorganize layer numbering
F_Cu = 0
B_Cu = 2
Remaining internal copper layers are even and incrementing

Non-copper layers are odd and incrementing.

This means that we can no longer do things like:
for( PCB_LAYER_ID layer = F_Cu; layer <= B_Cu; ++layer)
Instead, we have the class LAYER_RANGE:
for( PCB_LAYER_ID layer : LAYER_RANGE( F_Cu, B_Cu) )

Similarly, gt/lt tests should not refer to the integer value of the
layer.  We have functions such as IsCopperLayer to test whether a layer
is copper or not.

When using the connectivity RTree, the third dimension is layer, so we
provide B_Cu with the special INT_MAX value, ensuring that elements
between F_Cu and B_Cu will be identified.  There is a new, special
function GetBoardLayer() for interfacing with CN_ITEMS

Similarly, PNS layers remain unchanged and sequential.  A set of
interface functions is provided to map PNS layers to Board layers and
back.  This allows the PNS_LAYER_RANGE to function as expected
2024-09-06 23:07:58 +00:00
Jon Evans
0a816ce079 Fix PNS log viewer after c39551b032 2024-08-15 22:02:01 -04:00
Wayne Stambaugh
795a9eea60 Coding policy fixes.
This is primarily to change all instances of wxLogDebug with wxLogTrace
so developers do not have to sift through debugging output that is always
dumped.  The only exception is for code blocks built in debug builds and
called on demand for dumping object states.
2024-05-23 07:59:45 -04:00
Wayne Stambaugh
a508f2e716 Fix false annular ring width DRC test failure.
The DRC annular ring width test failed to take into account that a pad
could be contained inside another pad having the same number (thermal
vias for example) which changes the effective annular width of the pad
contained within another pad.  A test was added to calculate the effective
annular ring width in this case.

Added some PNS log viewer helper and test code to the PNS playground QA
utility for testing the effective pad annular width code.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/17485
2024-05-07 08:04:17 -04:00
Roberto Fernandez Bautista
6078bc52eb PNS: Fix a few memory leaks 2024-03-31 18:21:02 +02:00
Roberto Fernandez Bautista
8afeea4ce9 Fix "pns_debug_tool replay" hidden controls 2024-03-29 23:15:44 +01:00
Tomasz Wlostowski
9e0cd7e6ee qa/tools: add PCB_TEST_SELECTION_TOOL to CmakeLists 2024-03-03 17:42:21 +01:00
Tomasz Wlostowski
2280c696d0 wip on resizeable view & adding tabs to pns_debug_tool 2024-03-03 17:42:21 +01:00
Roberto Fernandez Bautista
ca148fb4d1 pns_debug_tool: Fix "save as" to save log file with new router state 2024-02-12 21:22:57 +01:00
Roberto Fernandez Bautista
8e0489bc24 pns_debug_tool: goto line windows + add visual studio (half working)
Visual studio (full) doesn't seem to like  going to the line, but at
least it opens the file in the same instance...
2024-02-10 16:28:01 +01:00
Roberto Fernandez Bautista
86368abba2 pns_debug_tool: Add Emacs as IDE option for Wayne, maybe? 2024-02-03 10:34:47 +01:00
Roberto Fernandez Bautista
366d8ecb73 pns_debug_tool: Add combobox to select IDE (CLion / VS Code) 2024-02-03 00:36:34 +01:00
Roberto Fernandez Bautista
3a95bd1bd1 pns_debug_tool: Add option to go to definition in vs code
Todo: add a way to add other IDEs and select them via GUI or
advanced config
2024-02-02 23:47:00 +01:00
Roberto Fernandez Bautista
70f14277d1 PNS Debug/regresions: Fix some memory leaks 2024-01-31 19:17:46 +03:00
Jeff Young
a523c58530 Add a m_forceMarkObstaclesMode warning when violating DRC.
Also adds a modifier combination to commit anyway.
2024-01-02 17:02:50 +00:00
Ian McInerney
f2702b223c Introduce base IO_MGR class and unify RELEASER objects
The IO_RELEASER is a thin-wrapper around a std::unique_ptr, but done
this way to allow easier addition of a custom deleter in the future if
something needs to call back into the IO_MGR.
2023-12-29 00:37:38 +00:00
Ian McInerney
e6632bb983 Rename PCB IO classes/files 2023-12-24 01:22:21 +00:00
Ian McInerney
d8b47d18d3 Initial rename of file plugin infrastructure components to IO 2023-12-24 01:22:21 +00:00
Jeff Young
e0a34efcb7 Use a more self-documenting API for router preview item flags.
Also fixes a bug where rule areas were drawn with solid fills.
2023-12-08 16:02:15 +00:00
Seth Hillbrand
75c6b0ab28 Added IPC2581 support
IPC2581 is a modern production file exchange system.  It provides
single-file data output for an entire board including BOM and netlist
information.

Fixes https://gitlab.com/kicad/code/kicad/-/issues/1954
2023-11-26 15:30:58 -08:00
Marek Roszko
7505fd0f37 Profile can live in core 2023-09-07 07:47:01 -04:00
Marek Roszko
5c62b98e7c observable can live in core 2023-09-06 21:25:24 -04:00
Jeff Young
0002eca70b Fix missing string-to-int conversion. 2023-08-31 15:15:57 +01:00
Jeff Young
f08370b3dc Remove no-longer-used guard. 2023-08-31 15:15:57 +01:00
Jeff Young
81117d2217 Fix memory leak from double-allocation. 2023-08-31 15:15:57 +01:00
Jeff Young
05135eed66 Extra debugging info for pns regression tests. 2023-08-31 15:15:57 +01:00