Calibre Duplicate Derived Layers in Rules for Ignoring Encrypted Parts

2023-07-14T08:18:57.000-0400
IC Verification & Signoff

Summary

When working with derived layers, which cannot be viewed directly in layout viewing tools, it can be useful for debugging purposes to create a DRC rule that shares the same name as the derived layer. This DRC rule should contain a copy of the derived layer. By doing so, the derived layer can be viewed as a DRC result item, which can help verify whether the design expectations are met. This can be a valuable tool for designers when working with derived layers in their layouts.


Details

To automate this process, the provided Perl code generates a DRC rule for each derived layer found in a rules file.

In a previous article (MG33770), we discussed a script that was designed to read and process data from a rule file. However, the script was unable to handle encrypted parts in the file:

https://support.sw.siemens.com/knowledge-base/MG33770

In this article, we introduce a modified script that addresses this limitation and allows for more efficient data processing and will handle encrypted parts in the rule file.

Here is the result of running the code below on an example rule file:

% layer-copy.pl  -f rules-test | grep -v / | grep {
gate { Copy  gate }
ncont { Copy  ncont }
pcont { Copy  pcont }
bulk { Copy  bulk }
diff { Copy  diff }
psub { Copy  psub }

Here is the updated Perl code which produced the above results:

# USAGE :  perl  <path>/layer-copy.pl  -f  rules_file
#
use Getopt::Std;
getopt('fl');

$flag = 1;

open(THATFILE, "$opt_f") || die "\n[USAGE: perl <path>/layer-copy.pl  -f <rulesfile>  \n\n";
while (<THATFILE>) {
                if ($_ =~ /#DECRYPT/){
                                $flag = 0;
                                next;
                }
                if ($_ =~ /#ENDCRYPT/){
                                $flag = 1;
                                next;
                }
                if ($flag and $_ =~ /(^\S*)\s*=\s*(.*)\s*/) {
                                $layers{$1} = $2;
                }
               
                                               
}
foreach $key (keys %layers) {
    print("// $key =  $layers{$key}\n");
    print("$key { Copy  $key }\n");
    print("\n");
}
 

KB Article ID# KB000111918_EN_US

Contents

SummaryDetails

Associated Components

Calibre nmDRC