Aliases for ports and via points
-- Work in progress --
Support adding an alias (name) for ports and via points.
Currently the ports and vias all have names, but users cannot edit them. Ports and vias only show up in GUIs when modifying connections.
In huge interconnected connection profile the user would sometimes like to rename a port or via. This alias will often be used as a reference inside the test step to refer to important items.
Implementation: Inside DUT or Instrument settings, show ports under a Ports group. Each port is listed with their name
Ports [Edit ...] // this shows a data grid window with name column
The C# code for defining an matrix instrument could look like this:
public class RevolverSwitchInstrument : Instrument
{
[Display("Positions", "Positions defined for this switch", "Via Points")]
public IReadOnlyList<ViaPoint> Positions { get; set; } = new ViaPointCollection(12);
}
We need to modify ViaPoint so that the name can be set by the user and reset to the original value.
The same will apply to ports, whose names can also be configured.
Later this will unlock the following possibility (issue #569):
public class MatrixInstrument : Instrument
{
[Display("Rows", "Via point rows defined for this matrix.", "Via Points")]
public IReadOnlyList<ViaPoint> Rows { get; set; } = new ViaPointCollection(4);
[Display("Columns", "Via point columns for this matrix.", "Via Points")]
public IReadOnlyList<ViaPoint> Columns { get; set; } = new ViaPointCollection(4);
}
Discarded ideas:
| + Port |
| + Port 1|
Alias [Port 1]
Mode Input \/
| + Port 2|
Alias [Port 2]
Mode Output \/
| + Port Name |
[Port 1 ] // dont show the name
Port 2 [Port 2]
Port 3 [Port 3]
Port 4 [Port 4]
...