Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to call Mentor AMPLE from perl?

Status
Not open for further replies.

bageduke

Advanced Member level 4
Joined
Oct 19, 2005
Messages
119
Helped
11
Reputation
22
Reaction score
2
Trophy points
1,298
Activity points
2,090
Does anyone have any idea of this? I am trying to script a userware which can do file manipulation with perl and layout task in Mentor IC station.
 

I DONT KNOW ABT MENTOR AMPLE.
BUT U CAN DO FILE MANIPULATION AS SHOWN IN THE PERL PROGRAM BELOW.
THIS IS ACTUALLY FOR WRITING INTO A FILE. TRY IF IT WORKS

#!/usr/bin/perl -w
#purpose
#writes to a file
use Getopt::Long
#Set up the command line to accept a filename
my $ret = GetOptions (" i | input:s ", " o | output:s ");
my $input = $opt_i || die "Usage: $O -i Input filename -o Output filename\n";
my $output = $opt_o || die "Usage: $O -i Input filename -o Output filename\n";
#opent the input file
open (INPUT,"$input") || die "Could not open file $input: $!\n";
#open the output file
open (OUTPUT,">$output") || die "Could not open file $output: $!\n";
#start reading from the input file
while (<INPUT>)
{
chop;
#write to the output filename
print OUTPUT "Line $. = <$_>\n";
}
#close the files
close (INPUT);
close (OUTPUT);
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top