• F-I-L
  • Wiki
  • Source
  • Contact
  • MatchTemplateBin

    Modified by 2015.06.01

    Design

    MatchTemplateBin

    Version
    1.0


    Modified
    2015-05-25


    Source

    MatchTemplateBin


    IP-GUI

    MatchTemplateBin IP-GUI


    Function

    Match a binary from template for binary images.
    It will give the first output after 1 cycle while in_enable enable.


    Files

    Name Function
    MatchTemplateBin.v Main module
    MatchTemplateBin_TB.sv Test bench


    Parameters

    Name Type Range Default Description
    work_mode unsigned 0 for Pipeline, 1 for Req-ack 0 This module's working mode.
    window_width unsigned 2 - 15 3 The width(and height) of window.


    Ports

    Name Port Type Range Default Description
    clk input unsigned None None Clock.
    rst_n input unsigned None None Reset, active low.
    template input unsigned window_width * window_width - 1 : 0 None Reset, active low.
    in_enable input unsigned None None Input data enable, in pipeline mode, it works as another rst_n, in req-ack mode, only it is high will in_data can be really changes.
    in_data input unsigned window_width * window_width - 1 : 0 None Input data, it must be synchronous with in_enable.
    out_ready output unsigned None None Output data ready, in both two mode, it will be high while the out_data can be read.
    out_data output unsigned None None Output data, it will be synchronous with out_ready.


    Simulations

    Simulations for this module just support Gray-scale images !

    Waves

    Pipeline mode

    Pipeline mode

    ReqAck mode

    ReqAck mode

    Original

    Original

    Results

    Results
    HDL functional simulation for pipeline mode is on the left, for req-ack mode is on the middle, and which on the right is the soft simulation

    Results
    Left is 000010000, right is 11111111

    PSNR

    1-000010000 1-111111111 2-000010000 2-111111111 Total
    1000000.00 1000000.00 1000000.00 1000000.00 1000000.00


    Utilization

    Slice LUTs* Slice Registers
    5 2


    Timing

    The max Data Path Delay is 2.199ns, so:

    FMax = 454.75MHz


    Thanks

    The sources of images for simulations:
    LM7-アイカツ
    ぜろきち-Blue star