Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   VHDL (http://www.velocityreviews.com/forums/f18-vhdl.html)
-   -   Data flow, change with the time (http://www.velocityreviews.com/forums/t755006-data-flow-change-with-the-time.html)

piolin86 10-19-2011 10:10 AM

Data flow, change with the time
 
Hello, I thinks that my problem is easy but I dont know the answer, I only want a program with 3 output send different vector in different time. If I try to cpy the port in a signal quartus say me impossible two values. So I try to make wiht different architecture but only copy the last, could you help me?

ENTITY prueba IS
port
(
a,b,c :out std_logic_vector (0 TO 6) );
END prueba;
ARCHITECTURE test_nand OF prueba IS
SIGNAL a_test, b_test, c_test : std_logic_vector (0 TO 6);
BEGIN
a <= "0000000" after 0 ns;
b<="0000000" after 0 ns;
c<= "0000000" after 0 ns;
END test_nand;

ARCHITECTURE test_nand2 OF prueba IS
BEGIN
a <="1010111" after 20 ns;
b<="0000001" after 0 ns;
c<= "0000100" after 0 ns;
END test_nand2;

ARCHITECTURE test_nand3 OF prueba IS
BEGIN
a <="0000000" after 30 ns;
b<="0000000" after 10 ns;
c<= "0000000" after 15 ns;
END test_nand3;

Thanks

piolin86 10-19-2011 03:26 PM

is it easy?

jeppe 10-21-2011 08:13 AM

Yes it is - like this.

a <= "00001111" after 0 ns, "11101010" after 20 ns, "10101010" after 50 ns;

Search the net for the free interactive book: EVITA VHDL
Chapter 7.4.2 got an example

Your welcome

piolin86 11-03-2011 09:49 AM

Thanks so much

piolin86 11-03-2011 10:06 AM

Only one question more, I dont know how it sould be the entity and the architeture, something like this:

entity BancoPruebas is port(
data1, data2, data3: out std_logic_vector (0 TO 3);
clk, reset: IN std_logic);
end BancoPruebas;

architecture a of BancoPruebas is
begin
TEMPO: process (clk, reset)
Begin
If reset = '1' THEN
data1<= "0000" ;
Elsif (clk'event AND clk ='1') THEN
data1<= "0101" After 50ns;
data1<= "0000" After 100ns;

end if ;
END PROCESS tempo;

end a;

jeppe 11-04-2011 11:05 AM

Your not allowed to mix:

Process( Clk) ... Clk'event

and

Data1 <= .... after ... ns;

piolin86 11-05-2011 02:29 PM

sorry?? i dont understan you :(

piolin86 11-06-2011 12:26 PM

like this
entity BancoPruebas is port(
data1, data2, data3: out std_logic_vector (0 TO 3);
clk, reset: IN std_logic);
end BancoPruebas;

architecture a of BancoPruebas is
signal AM: std_logic_vector (0 TO 3);
begin
TEMPO: process (clk, reset)
Begin

Am <= "0010" after 100 ns,
"1100" after 240 ns,
"1010" after 350 ns;
data1 <=Am;


END PROCESS tempo;

jeppe 11-12-2011 01:46 PM

Code:

entity BancoPruebas is port(
data1, data2, data3: out std_logic_vector (0 TO 3);
clk, reset: IN std_logic);
end BancoPruebas;

architecture a of BancoPruebas is
signal AM: std_logic_vector (0 TO 3);
begin

-- This code will ONLY be useful for simulation
TEMPO: process
Begin
    wait for 100 ns;
    Am <= "0010" ;  -- after 100 ns,
    data1 <=Am;
    wait for 140 ns;
    Am <= "1100";  -- after 240 ns,
    data1 <=Am;
    wait for 110 ns;
    Am  <= "1010";  -- after 350 ns;
    data1 <=Am;
    wait;  -- for ever
END PROCESS tempo;



All times are GMT. The time now is 09:00 AM.

Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57