Skip to content
Snippets Groups Projects
main.tcl 1.76 KiB
Newer Older
################################################################################
# Main tcl for the module
################################################################################

# ==============================================================================
proc init {} {

    # Configuration
    # TODO Follow FWK
    # variable quad_name
    # set quad_name X0Y4
}

# ==============================================================================
proc setSources {} {
  variable Vhdl
BRONES Romain's avatar
BRONES Romain committed
  # Generate VHDL package with modversion
  genModVerFile VHDL ../hdl/pkg_combpm_version.vhd
BRONES Romain's avatar
BRONES Romain committed
  lappend Vhdl ../hdl/pkg_combpm_version.vhd
  lappend Vhdl ../hdl/combpm_protocol_electron.vhd
  lappend Vhdl ../hdl/top_combpm_electron.vhd
  lappend Vhdl ../hdl/pkg_bpmframe_stream.vhd
BRONES Romain's avatar
BRONES Romain committed
  lappend Vhdl ../hdl/combpm_packet_filter.vhd
BRONES Romain's avatar
BRONES Romain committed

}

# ==============================================================================
proc setAddressSpace {} {
    variable AddressSpace
BRONES Romain's avatar
BRONES Romain committed
    addAddressSpace AddressSpace "combpm" RDL {} ../rdl/combpm.rdl
}

# ==============================================================================
proc doOnCreate {} {

BRONES Romain's avatar
BRONES Romain committed
  # This module is only for vivado tool. End here for another tooltype.
  if {$::fwfwk::ToolType ne "vivado"} {
      puts "\n[ERROR] This module is only configured to work with Vivado"
      exit -1
  }
  # Create GT wizard IP
BRONES Romain's avatar
BRONES Romain committed
  set_property part ${::fwfwk::FpgaPart} [current_project]
  set_property target_language VHDL [current_project]
  source combpm_gtwizard.tcl

  source generate_combpm_packet_filter_ip.tcl

  variable Vhdl
  addSources Vhdl
}

# ==============================================================================
proc doOnBuild {} {
}

# ==============================================================================
proc setSim {} {
}