Circular buffer fifo

15 0 0
Circular buffer   fifo

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

Circular Buffer & FIFO Digital Circuits Design with HDL Course CE Undergraduate – 1st, 2010 2011 Circular Buffer & FIFO Pham Quoc Cuong http //www cse hcmut edu vn Digital Circuits Design with HDL Cou[.]

Digital Circuits Design with HDL Course CE Undergraduate – 1st, 2010-2011 Circular Buffer & FIFO Pham Quoc Cuong http://www.cse.hcmut.edu.vn Digital Circuits Design with HDL Course CE Undergraduate – 1st, 2010-2011 Circular Buffer oldest sample x[k] newest sample N-samples Moving window of N samples Two options: (1) Shift the register contents concurrently at every clock (2) Shift the address pointer k Sample n-N+1 Sample n-N Sample n-1 Sample n-2 Sample n-3 Sample n Circular Buffer & FIFO 9/12/2010 N-cells Pham Quoc Cuong CE Undergraduate – 1st, 2010-2011 Digital Circuits Design with HDL Course Data Movement Data samples: 0110, 1010, 1111, Method #1: Shift Register 0110 1010 0110 1111 1010 0110 Method #2: Address Managed 0110 Circular Buffer & FIFO 0110 1010 9/12/2010 0110 1010 1111 Pham Quoc Cuong Digital Circuits Design with HDL Course CE Undergraduate – 1st, 2010-2011 Circular Buffer#1: Shift Operation module Circular_Buffer_1 (cell_3, cell_2, cell_1, cell_0, Data_in, clock, reset); parameter buff_size = 4; parameter word_size = 8; output [word_size -1: 0] cell_3, cell_2, cell_1, cell_0; input [word_size -1: 0] Data_in; input clock, reset; reg [word_size -1: 0] Buff_Array [buff_size -1: 0]; assign cell_3 = Buff_Array[3], cell_2 = Buff_Array[2]; assign cell_1 = Buff_Array[1], cell_0 = Buff_Array[0]; integer k; always @ (posedge clock) begin if (reset == 1) for (k = 0; k

Ngày đăng: 06/04/2023, 14:08

Tài liệu cùng người dùng

  • Đang cập nhật ...

Tài liệu liên quan