25.01.2014 Aufrufe

Prüfung - Institut für Kommunikationsnetze und Rechnersysteme ...

Prüfung - Institut für Kommunikationsnetze und Rechnersysteme ...

Prüfung - Institut für Kommunikationsnetze und Rechnersysteme ...

MEHR ANZEIGEN
WENIGER ANZEIGEN

Erfolgreiche ePaper selbst erstellen

Machen Sie aus Ihren PDF Publikationen ein blätterbares Flipbook mit unserer einzigartigen Google optimierten e-Paper Software.

syncfifo_process: process(wclk, rclk) is<br />

constant N: natural := 5;<br />

subtype INDEX_RANGE is natural range 0 to N - 1;<br />

type fifo_t is array(INDEX_RANGE) of std_logic_vector(7 downto 0);<br />

variable fifo: fifo_t;<br />

variable rindex, windex: INDEX_RANGE;<br />

begin<br />

w_if: if wclk’event and wclk = ’1’ then<br />

if wena = ’1’ then<br />

fifo(windex) := wdata;<br />

windex := (windex + 1) mod N;<br />

end if;<br />

end if;<br />

r_if: if rclk’event and rclk = ’1’ then<br />

if rena = ’1’ then<br />

rdata

Hurra! Ihre Datei wurde hochgeladen und ist bereit für die Veröffentlichung.

Erfolgreich gespeichert!

Leider ist etwas schief gelaufen!