[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: gschem sym files



Kai-Martin Knaak:
> Karl Hammar wrote:
> >> 4, add explicit documentation on the rules in the wiki
> > I'm not the wiki man. I could read the code (I assume you mean drc2)
> > and try to describe it in text, but someone else has to enter it 
> > into the wiki.
> Ok, if you describe the rules here on the list, I'd volunteer to infuse 
> it at an appropriate place in the wiki. 
...

  The drc2 code resides in gnet-drc2.scm.

  It is probably installed in /usr/share/gEDA/scheme/gnet-drc2.scm or
  a similar place. In the git repository it in the file
  ./gnetlist/scheme/gnet-drc2.scm (relative where you put it when you
  did "git clone").

  Line 61 to 159 of that file contains the "usage" documentation for
  drc2, so my writings below is just my comments upon that.

*** Parameter ***

  You can supply a "parameter" to drc2: ignore-warnings-in-return-value.
  But I must be calling it in the wrong way becauce I cannot make it
  make any differnce:

$ gnetlist -g drc2 -O ignore-warnings-in-return-value -o lg1 styrkort.sch > lo1 2>&1
$ echo $?
0
$ gnetlist -g drc2 -o lg2 styrkort.sch > lo2 2>&1
$ echo $?
0
$ diff lg1 lg2
$ diff lo1 lo2
$

  Its supposed use is remove the error return ("echo $?" would return 
  something != 0) when there is only warnings and no errors. So maybe
  gnetlist have evolved removing any error return altogether.

*** Output ***

  As usual with the -o <log file> option to gnetlist, see gnetlist
  documentation. The statement that you can use "-" for <log file> is
  correct, the output do come to stdout, but so does a bonus
  backtrace:

$ gnetlist -g drc2 -o - styrkort.sch           
gEDA/gnetlist version 1.4.0.20080127
...
Found 3 warnings.
Found 15 errors.
Backtrace:
In current input:
   1: 0* [drc2 "-"]
In /usr/share/gEDA/scheme/gnet-drc2.scm:
 902: 1  (let* ((port #)) (begin (if # #) (if # #) (if # #) ...))
   ...
1016: 2  (begin (display "DRC errors found. See output file.") (newline))
1016: 3* [display "DRC errors found. See output file."]

/usr/share/gEDA/scheme/gnet-drc2.scm:1016:21: In procedure display in expression (display "DRC errors found. See output file."):
/usr/share/gEDA/scheme/gnet-drc2.scm:1016:21: Wrong type argument in position 2: #<closed: file 0>
$

*** Configuration ***

  ** How to disable some tests.

  You can disable a few of the checks that drc2 does. I think the text
  in gnet-drc2.scm (line 79-111) is to be consulted about that.

  Use gnetlist's -l or -c option, see first example in
  http://www.seul.org/pipermail/geda-user/2010-September/049378.html

  ** Check for not driven nets.

  You can provide your own version of "pintype-can-drive" (via
  gnetlist's -l or -c option). Currently it warns if you dont have any
  one of: out, io, oc, oe, pas, tp, tri, or pwr in a net.

  I.e. if you have a net of only "in"s and a "clk", and don't want drc2
  to complain about it do:

$ gnetlist -g drc2 -o <log file> -c '(define pintype-can-drive (list 0 0 1 1 1 1 1 1 1 1 1 0 ))' <gschem file>

  ** The drc-matrix

  See last example of
  http://www.seul.org/pipermail/geda-user/2010-September/049378.html

***

Regards,
/Karl Hammar

---------
Aspö Data
Lilla Aspö 148
S-742 94 Östhammar
Sweden
+46 173 140 57




_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user