Hi Andres, On Tue, May 16, 2000 at 12:57:05AM -0700, Andres Farfan wrote: > Hi, > I have problems with the SXLIB library, I want to synthetize a decoder, its > behavioural description is in DECODER.VBE, each step is listed in the > Makefiles MakeSXLIB and MakeSCLIB, all needed files are in the attachment > "decoder.tar.gz". > > The first one uses the SXLIB library and SCLIB the second file, the commands > are identical, and there's not any compilation error, but during the > simulation the outputs from the first circuit are undefined. > > The commands to build the circuits and simulate them, are: > > >>make -f MakeSXLIB vst1.pat > > >>make -f MakeSCLIB vst2.pat > > The outputs files are: vst1.pat vst2.pat > > Where is the mistake? The last version of ASIMUT simulates description with delays. The cells of the sclib library have not any delay in their behavioral description. For example in the a2_y cell there is no delay information : -- ARCHITECTURE VBE OF a2_y IS BEGIN t <= (i0 and i1); END; -- But in the cell a2_x2 of sxlib library you have this information : -- ARCHITECTURE behaviour_data_flow OF a2_x2 IS BEGIN q <= (i0 and i1) after 1000 ps; -- ^^^^^^^^ END; -- In your pattern file decoder_genpat.pat (generated by GenPat) you have implicit delay : -- < 0 ps> pat_0 : 1 0 0 1 00 ?**** ; < 1 ps> pat_1 : 1 0 0 1 01 ?**** ; ... -- As you can see, 1 pico-second is not enough to propagate input values in your decoder (with the SXLIB version) ... But with the SCLIB version there is no problem because there is NO delay ... So you have to modify your genpat file decoder_genpat.c as follow : --- //************************************************************* // Ejemplo 1 // Generacion de Patrones de prueba para el decodificador 2 a 4 // Archivo : decoder.c // Autor : Andres Farfan P // Fecha : Marzo 28 de 1999 //************************************************************* #include <stdio.h> #include <genpat.h> char *int2str(int entero) { char *str; str = (char *) mbkalloc( 32 * sizeof(char)); sprintf( str, "%d", entero); return(str); } //********************************************************************** int main(void) { int i; //Nombre de archivo de salida DEF_GENPAT("decoder_genpat"); //Declaracion de entradas/salidas DECLAR("vdd", ":2", "B", IN, "",""); DECLAR("vss", ":2", "B", IN, "",""); DECLAR("vsse",":2", "B", IN, "",""); DECLAR("vdde",":2", "B", IN, "",""); DECLAR("A", ":2", "B", IN, "1 DOWNTO 0",""); DECLAR("Y", ":2", "B", OUT, "3 DOWNTO 0",""); //Generar los patrones de simulacion AFFECT(int2str(0), "vdd", "0b1"); AFFECT(int2str(0), "vss", "0b0"); AFFECT(int2str(0), "vdde","0b1"); AFFECT(int2str(0), "vsse","0b0"); for(i=0;i<4;i++) { LABEL("pat"); /* HERE IS THE MODIFICATIONS */ /* AFFECT (int2str(i), "A", int2str(i)); */ AFFECT (int2str(i * 2000), "A", int2str(i)); /* ^^^^ TO HAVE 2000 PS BETWEEN EACH PATTERN */ /* END OF MODIFICATIONS */ } //Guardar el archivo generado SAV_GENPAT(); //Retornar exit(0); } -- Best regards, Ludo. (_) ___ Ludovic JACOMME _ _ ( ) ( ) ( ) ( 6 ) Laboratoire LIP6, Equipe ASIM ( ) (_) ( _ ) Couloir 55-65, 2eme etage, ( )___ ( ) Universite P. et M. Curie (P6) (_____) (_) 4 place Jussieu, 75252 Paris Cedex 05 Tel: (33) 01.44.27.54.15 Fax: (33) 01.44.27.72.80 ICQ: 62526530 mailto: Ludovic.Jacomme@asim.lip6.fr http: //asim.lip6.fr/~ludo