Documentation for project sigasi-cli-docgen-demo

Table of Contents

Project files overview

Design Units

Project sigasi-cli-docgen-demo has 10 design units.

Module counter

This design unit is implemented in step​_1​_dut​_core.sv

Description

TODO "Validation: parameters" For the next steps in this tutorial, you need a Sigasi Studio license. If you don't have one already, request your trial license at https://www.sigasi.com/try-buy (you can Ctrl+Click here too)

Parameters and Ports

Parameters

NameTypeDefault ValueDescription
WIDTH16

Ports

NameDirectionTypeDescription
clkinputwire logic
rstinputwire logic
startinputwire logic
enableinputwire logic
endvalueinputwire logic [(WIDTH-1):0]
countoutputwire logic [(WIDTH-1):0]
near​_endoutputlogic
on​_edgeoutputlogic

Always Blocks

  • unnamed : always
    • And 1 more

Block Diagram

Module dut​_core

This design unit is implemented in step​_1​_dut​_core.sv

Description

TODO "Correct syntax error" Sigasi Studio puts error markers in the left hand side margin when a syntax error is found. Sigasi Studio marks errors while you are typing. The earlier errors are found, the easier they are to fix.

Parameters and Ports

Ports

NameDirectionTypeDescription
pixel​_outoutputlogic [7:0]
pixel​_ppinputwire logic [7:0]
pixel​_p0inputwire logic [7:0]
pixel​_pminputwire logic [7:0]
pixel​_0pinputwire logic [7:0]
pixel​_0minputwire logic [7:0]
pixel​_mpinputwire logic [7:0]
pixel​_m0inputwire logic [7:0]
pixel​_mminputwire logic [7:0]
on​_edgeinputwire logic
clockinputwire logic
resetinputwire logic

Always Blocks

  • unnamed : always
    • TODO "Autocompletion" On the blank line below, type the first letters of always and then Ctrl+Space. Select Insert an always block with posedge clk (double-click, or use arrow up/down and press enter). An always block is generated and clk is selected. Type cl (replacing clk) and press Ctrl+Space again to auto-select clock which is our clock signal.

  • unnamed : always_ff

Block Diagram

Module dut​_engine

This design unit is implemented in step​_5​_dut​_engine.sv

Parameters and Ports

Ports

NameDirectionTypeDescription
clkinputwire logic
rstinputwire logic
startinputwire logic
extra​_at​_startinputwire logic
start​_xoutputlogic
enable​_xoutputlogic
near​_end​_xinputwire logic
start​_youtputlogic
enable​_youtputlogic
near​_end​_yinputwire logic
pixel​_validoutputlogic
idleoutputlogic

Always Blocks

  • unnamed : always
    • State Machine

      SourceTargetConditionComment
      calculatefinish_row_1near_end_y == 1'b1 && near_end_x == 1'b1

      main calculation done

      finish_row_1finish_row_2extra_at_start == 1'b0
      near_end_x == 1'b1

      extra line at end

      finish_row_1waitingnear_end_x == 1'b1

      all done

      finish_row_2waitingnear_end_x == 1'b1

      edit the label

      startup_row_1calculatenear_end_x == 1'b1
      startup_row_1startup_row_2extra_at_start == 1'b1
      near_end_x == 1'b1

      extra line at start

      startup_row_2calculatenear_end_x == 1'b1
      waitingstartup_row_1start == 1'b1

      received start

Block Diagram

Module dut​_top

This design unit is implemented in step​_2​_dut​_top.sv

This file depends on: step_1_dut_core.sv, step_5_dut_engine.sv, step_3_pixelbuffer.sv

Parameters and Ports

Ports

NameDirectionTypeDescription
clkinputwire logic

core clock

rstinputwire logic

system reset

startinputwire logic

start DUT (pulse)

size​_xinputwire logic [11:0]

image width

size​_yinputwire logic [11:0]

image height

pixel​_ininputwire logic [7:0]

pixel in (streaming input)

pixel​_outoutputwire logic [7:0]

pixel out (streaming output)

pixel​_validoutputwire logic

indicates that the output pixel is valid

Instantiations

Block Diagram

Module image​_testbench

This design unit is implemented in step​_6​_image​_testbench.sv

This file depends on: drive_rst_start.vhd, step_2_dut_top.sv

Description

Standardized header of my.compa.ny

(c) 2020 MyCo Inc. All rites reversed.

Top-level testbench of the Imaginary Project

Author: Sigasi Team

Instantiations

Initial Blocks

  • unnamed : initial
    • Initialize the source image

Always Blocks

  • unnamed : always
    • Clock generator

  • unnamed : always
    • Feed data into the DUT

Block Diagram

Module pixel​_testbench

This design unit is implemented in step​_4​_pixel​_testbench.sv

This file depends on: step_2_dut_top.sv

Description

Module pixel_testbench implements a first testbench for the design under test.

Instantiations

Always Blocks

  • unnamed : always
    • Feed data into the DUT

      State Machine

      SourceTargetCondition
      IDLERUNNINGstart
      READYIDLE
      RUNNINGREADY
  • unnamed : always
    • Clock generator

Block Diagram

Module pixelbuffer

This design unit is implemented in step​_3​_pixelbuffer.sv

This file depends on: ram.sv

Description

Module pixelbuffer implements a buffer to contain 2 pixel rows + 3 pixels of the image. Pixels arrive into the buffer in a streaming mode. A 3x3 pixel window (without the central pixel) is offered at the output.

This is a behavioral implementation, not suitable for synthesis.

Parameters and Ports

Ports

NameDirectionTypeDescription
clkinputwire logic

core clock and synchronous reset

rstinputwire logic

core clock and synchronous reset

size​_xinputwire logic [11:0]

image width

pixel​_ininputwire logic [(24-1):0]

input pixel

pixel​_in​_validinputwire logic

incoming pixel is valid

pixel​_ppoutputlogic [(24-1):0]

3x3 pixel window: upper right

pixel​_p0outputlogic [(24-1):0]

3x3 pixel window: middle right

pixel​_pmoutputlogic [(24-1):0]

3x3 pixel window: bottom right

pixel​_0poutputlogic [(24-1):0]

3x3 pixel window: upper middle

pixel​_0moutputlogic [(24-1):0]

3x3 pixel window: lower middle

pixel​_mpoutputlogic [(24-1):0]

3x3 pixel window: upper left

pixel​_m0outputlogic [(24-1):0]

3x3 pixel window: middle left

pixel​_mmoutputlogic [(24-1):0]

3x3 pixel window: bottom left

Instantiations

Always Blocks

  • unnamed : always
    • And 1 more

Block Diagram

Module ram

This design unit is implemented in ram.sv

Description

A naive RAM module without an impementation

Parameters and Ports

Parameters

NameTypeDefault ValueDescription
addrwidth8
datawidth8

Ports

NameDirectionTypeDescription
clkinputwire logic

clock

rstinputwire logic

reset

addressinputwire logic [addrwidth-1:0]

address

reninputwire logic

read enable

weninputwire logic

write enable

data​_ininputwire logic [datawidth-1:0]

data in

data​_outoutputlogic [(datawidth-1):0]

data out

Block Diagram

Entity work.drive​_rst​_start

This design unit is implemented in drive​_rst​_start.vhd

Architectures

Generics and Ports

Ports

NameDirectionTypeDescription
rstoutstd​_logic
startoutstd​_logic

Architecture work.drive​_rst​_start(RTL)

This design unit is implemented in drive​_rst​_start.vhd

This architecture implements entity work.drive​_rst​_start

Processes

  • proc​_stim

Block Diagram