Discussion:
Eagle .dru file definitions, anyone?
(too old to reply)
Dave Curtis
2014-07-23 04:02:18 UTC
Permalink
Raw Message
Has anyone seen a description of the Eagle .dru (design rule) file?

I notice that a lot of fab houses publish Eagle .dru files for their
process, and it might be a quick/easy project to create a .dru to PCB
design rule translator for most of the common/meaningful rules.

It's a plain text file with a bunch of names and values, so it wouldn't
exactly be rocket science to reverse engineer, but I thought someone
might have run across a document on it. I haven't been able to snag
anything with Google.
gedau-1XeMD6fE9sqV9CSZFf/
2014-07-23 04:11:01 UTC
Permalink
Raw Message
Post by Dave Curtis
Has anyone seen a description of the Eagle .dru (design rule) file?
I notice that a lot of fab houses publish Eagle .dru files for their process,
and it might be a quick/easy project to create a .dru to PCB design rule
translator for most of the common/meaningful rules.
It's a plain text file with a bunch of names and values, so it wouldn't
exactly be rocket science to reverse engineer, but I thought someone might
have run across a document on it. I haven't been able to snag anything with
Google.
If it's that simple, we could write a script that creates/replaces the DRC
part of a pcb save. Could you attach some examples?
Dave Curtis
2014-07-23 14:50:07 UTC
Permalink
Raw Message
Post by gedau-1XeMD6fE9sqV9CSZFf/
Post by Dave Curtis
Has anyone seen a description of the Eagle .dru (design rule) file?
I notice that a lot of fab houses publish Eagle .dru files for their
process, and it might be a quick/easy project to create a .dru to PCB
design rule translator for most of the common/meaningful rules.
It's a plain text file with a bunch of names and values, so it
wouldn't exactly be rocket science to reverse engineer, but I thought
someone might have run across a document on it. I haven't been able
to snag anything with Google.
If it's that simple, we could write a script that creates/replaces the
DRC part of a pcb save. Could you attach some examples?
oshpark publishes their rules here:
https://oshpark.com/LaenPCBOrder.dru

if you google for 'dru' you get more hits of fab house dru files than
about anything else.

I don't really think it makes sense to modify the drc part of PCB's
save, as the two sets of design rule specs probably don't line up really
well. But maybe a "load rules from dru file" menu selection would be
good -- it could read a .dru file and pick out the pieces that make
sense, then just go forward with PCB in the normal way.
gedau-1XeMD6fE9sqV9CSZFf/
2014-07-23 17:04:22 UTC
Permalink
Raw Message
Post by Dave Curtis
Post by gedau-1XeMD6fE9sqV9CSZFf/
Post by Dave Curtis
Has anyone seen a description of the Eagle .dru (design rule) file?
I notice that a lot of fab houses publish Eagle .dru files for their
process, and it might be a quick/easy project to create a .dru to PCB
design rule translator for most of the common/meaningful rules.
It's a plain text file with a bunch of names and values, so it
wouldn't exactly be rocket science to reverse engineer, but I thought
someone might have run across a document on it. I haven't been able
to snag anything with Google.
If it's that simple, we could write a script that creates/replaces the
DRC part of a pcb save. Could you attach some examples?
https://oshpark.com/LaenPCBOrder.dru
if you google for 'dru' you get more hits of fab house dru files than about
anything else.
I don't really think it makes sense to modify the drc part of PCB's save, as
the two sets of design rule specs probably don't line up really well. But
maybe a "load rules from dru file" menu selection would be good -- it could
read a .dru file and pick out the pieces that make sense, then just go forward
with PCB in the normal way.
There are two different things here:

1. how much the pcb drc and the information in a dru can be matched up;
dru seems to be much more detailed. Extending PCB (feature-wise) to
support more of these details probably would be a large effort. Finding
out how to convert the information from the dru to PCB drc setup in a way
that a drc-accepted PCB design won't voilate the dru seems to be easier.
Of course because of the less detailed drc in PCB this also means a
drc-accepted design won't exploit all possible limits.

2. once we have such PCB drc settings derived from the dru, we need to
apply them to a design. Your suggestion is that it should happen within
PCB; my suggestion was to have a separate script. At the end the two
solutions would produce roughly the same effect, only the UI would differ:
the design you are working on in PCB is the same thing that the design
saved in the file. There is only one set of drc there. If you make pcb
directly manipulate the in-core representation of the drc settings, they
will be saved in the PCB file on the next save. Which is the same thing as
if you have a script that modifes the saved file and the next time you
load it in PCB it already has the new drc rules. At the end the
drc section of the design is changed to match the dru. Unless you meant a
second set of drc rules existing only while PCB is running and never
saved, or direct support for dru on top of drc... But these are both the
hard way mentioned in point 1.

The file format seems to be simple. If someone collects the rules how to
convert these values to pcb drc values, I can easily write a script that
manipulates pcb saves. By rules I expect things like "PCB's drc
somesetting should be equal to min(dru.x, dru.y, dru.z)."

My fab house doesn't have dru, so it's not a feature I really need, so I
wouldn't invest my own time in figuring the matching nor would I try to
implement a more integrated solution, but can volunteer to write a
small script.

Regards,

Tibor
Dave Curtis
2014-07-23 17:40:33 UTC
Permalink
Raw Message
Post by gedau-1XeMD6fE9sqV9CSZFf/
Post by Dave Curtis
Post by gedau-1XeMD6fE9sqV9CSZFf/
Post by Dave Curtis
Has anyone seen a description of the Eagle .dru (design rule) file?
I notice that a lot of fab houses publish Eagle .dru files for their
process, and it might be a quick/easy project to create a .dru to PCB
design rule translator for most of the common/meaningful rules.
It's a plain text file with a bunch of names and values, so it
wouldn't exactly be rocket science to reverse engineer, but I thought
someone might have run across a document on it. I haven't been able
to snag anything with Google.
If it's that simple, we could write a script that creates/replaces the
DRC part of a pcb save. Could you attach some examples?
https://oshpark.com/LaenPCBOrder.dru
if you google for 'dru' you get more hits of fab house dru files than
about anything else.
I don't really think it makes sense to modify the drc part of PCB's
save, as the two sets of design rule specs probably don't line up
really well. But maybe a "load rules from dru file" menu selection
would be good -- it could read a .dru file and pick out the pieces
that make sense, then just go forward with PCB in the normal way.
1. how much the pcb drc and the information in a dru can be matched up;
dru seems to be much more detailed. Extending PCB (feature-wise) to
support more of these details probably would be a large effort. Finding
out how to convert the information from the dru to PCB drc setup in a
way that a drc-accepted PCB design won't voilate the dru seems to be
easier. Of course because of the less detailed drc in PCB this also
means a drc-accepted design won't exploit all possible limits.
Yes. Just guessing from the names, the .dru file I linked looks like
there are track-to-via, via-to-via, track-to-track, etc, minimum spacing
rules that could be all different. It seems to me that to convert to
PCB rules we would simply pick the max of all of those to be the minimum
clearance, for instance.
Post by gedau-1XeMD6fE9sqV9CSZFf/
2. once we have such PCB drc settings derived from the dru, we need to
apply them to a design. Your suggestion is that it should happen within
PCB; my suggestion was to have a separate script. At the end the two
solutions would produce roughly the same effect, only the UI would
differ: the design you are working on in PCB is the same thing that the
design saved in the file. There is only one set of drc there. If you
make pcb directly manipulate the in-core representation of the drc
settings, they will be saved in the PCB file on the next save. Which is
the same thing as if you have a script that modifes the saved file and
the next time you load it in PCB it already has the new drc rules. At
the end the drc section of the design is changed to match the dru.
Unless you meant a second set of drc rules existing only while PCB is
running and never saved, or direct support for dru on top of drc... But
these are both the hard way mentioned in point 1.
What I want is quite simple: translate the fab house rules into the
settings for the PCB rules dialog box. It can be automatic, it can be a
report. For my needs, I want the rules settings to be available in PCB
at design time. Either the dialog or updating the save works.
Post by gedau-1XeMD6fE9sqV9CSZFf/
The file format seems to be simple. If someone collects the rules how to
convert these values to pcb drc values, I can easily write a script that
manipulates pcb saves. By rules I expect things like "PCB's drc
somesetting should be equal to min(dru.x, dru.y, dru.z)."
Yes. I agree. The script is quite easy -- the work is in understanding
the .dru file, which is why I was wondering if anyone had seen a spec
:-/ ... otherwise it will mean downloading a copy of Eagle and poking
at it to see what changes in the .dru file.
Post by gedau-1XeMD6fE9sqV9CSZFf/
My fab house doesn't have dru, so it's not a feature I really need, so I
wouldn't invest my own time in figuring the matching nor would I try to
implement a more integrated solution, but can volunteer to write a small
script.
Regards,
Tibor
Loading...