Copy Wire (Polygon Wire) to any layer"
"This ULP copies copper wire and/or polygon from layer (1 or 16) of selected signals into "
"the solderstop layers or any layer in order to keep it free from solder stop layer.
"
"Use:
"
"run copy-wire-to-solder-mask.ulp [signalname] [signalname]
"
"run copy-wire-to-solder-mask.ulp $nameoff$
"
"run copy-wire-to-solder-mask.ulp -p [signalname] [signalname]
"
"run copy-wire-to-solder-mask.ulp +p [signalname] [signalname]
"
"run copy-wire-to-solder-mask.ulp -p -f [signalname] [signalname]
"
"run copy-wire-to-solder-mask.ulp +p +f [signalname] [signalname]
"
"$nameoff$ switches off the checking of net names"
"Options are case sensitive.
"
"$nameoff$ copy all signals.
"
"-p copies also polygons.
"
"+p copies only polygons.
"
"-f copies only polygon contour as polygon.
"
"-f copies polygon contour and filling as wire.
"
"
"
"Author: support@cadsoft.de
"
// THIS PROGRAM IS PROVIDED AS IS AND WITHOUT WARRANTY OF ANY KIND, EXPRESSED OR IMPLIED.
string Version = "ULP-Version: 1.5"; // 2008-04-23 check is a polygon placed
// changed menu to copy to any layer
// 2009-01-28 check polygon filling on orphan alf@cadsoft.de
// 2009-04-23 check menu parameter
// 2009-06-30 correct polygon export
int NameOff = 0; // 0 = copy by signal name
// 1 = copy without signal name (all)
int PolygonOn = 0; // copy also polygon
int onlyPolygon = 0;
int fillPolygon = 0; // copy only polygon contour or copy polygon filling as wire 2006.01.20 alf
int Player[];
string poly[];
int cntp = 0;
string isRatsnest;
string isLayer = "Top/Bottom"; // default layer
int isLayerNb = 0;
string toLayer = "t/bStop"; // default do Stop-Layer
int Lused[]; // 2009-04-23
string signals[] = { "" };
string chsignals[] = { "" };
int chngsig = 0;
int lastSigCh = -1;
int decs;
int index[];
int x1[], y1[], x2[], y2[], layer[];
int Wwidth[];
int n = 1;
string cmd;
string c;
int nbIslayer;
int nbTolayer;
int test = 0; // 2009-06-30 for test menu
// *************************************
string check(void) { // 2009-04-23 alf@cadsoft.de
int isLfound = 0;
int toLfound = 0;
nbIslayer = strtol(isLayer);
nbTolayer = strtol(toLayer);
if (isLayer == "Top/Bottom") isLfound = -1;
else {
board(B) B.layers(L) {
if (nbIslayer == L.number || isLayer == L.name) {
isLfound = L.number;
nbIslayer = L.number;
break;
}
}
}
if (toLayer == "t/bStop") toLfound = -1;
else {
board(B) B.layers(L) {
if (nbTolayer == L.number || toLayer == L.name) {
toLfound = L.number;
nbTolayer = L.number;
break;
}
}
}
if (isLfound == -1);
else if (!isLfound) return "!Select a available layer number or name for