SKILL: How to read a file

A

anil Kumar

Guest
Hi,

I have list of cells in a file "cell_list" and I want to update
schematic of each cells. I am wondering how do I read this file in
skill and do the operation on each schematic. Here is the content of
the file "cell_list" looks like
---------------------
an2
an3
an4
an5
an6
na2
_________

I have tried following without success
myfile=infile("cell_list") ; didnot work
foreach(cell myfile
.... ...
)
----
Please help .
-Anil
 
SKILL Language User Guide, Chapter 7, I/O and File Handling
and
SKILL Language Reference

; reads file
p_inPort = infile( "cell_list" )

;; variable initialisation
l_lineList = list()

when( p_inPort
while( gets( t_line p_inPort )
....
) ;; close while
) ;; close when

close( p_inPort )

Bernd


anil Kumar wrote:
Hi,

I have list of cells in a file "cell_list" and I want to update
schematic of each cells. I am wondering how do I read this file in
skill and do the operation on each schematic. Here is the content of
the file "cell_list" looks like
---------------------
an2
an3
an4
an5
an6
na2
_________

I have tried following without success
myfile=infile("cell_list") ; didnot work
foreach(cell myfile
.... ...
)
----
Please help .
-Anil
 
foreach only works on lists and hash tables... not on ports.

anil Kumar wrote:
Hi,

I have list of cells in a file "cell_list" and I want to update
schematic of each cells. I am wondering how do I read this file in
skill and do the operation on each schematic. Here is the content of
the file "cell_list" looks like
---------------------
an2
an3
an4
an5
an6
na2
_________

I have tried following without success
myfile=infile("cell_list") ; didnot work
foreach(cell myfile
.... ...
)
----
Please help .
-Anil
 

Welcome to EDABoard.com

Sponsor

Back
Top