Jump to content
    

Параметризация в Verilog

всю жизнь передавали

пример, типа описанного мной выше, в студию, пжлст

 

измените его кто-нить на правильный, плииииззз

Edited by stu

Share this post


Link to post
Share on other sites

пример, типа описанного мной выше, в студию, пжлст

 

измените его кто-нить на правильный, плииииззз

не могу понять что вам не понятно %)

module gige_decimator
#(
  parameter int pIDAT_W  = 22 ,
  parameter int pODAT_W  = 32
)
(
  iclk          ,
  ireset        ,
  iclkena       ,
  ival          ,
  idat_re       ,
  idat_im       ,
  oval          ,
  odat_re       ,
  odat_im
);

  //------------------------------------------------------------------------------------------------------
  //
  //------------------------------------------------------------------------------------------------------

  input  logic                        iclk              ;
  input  logic                        ireset            ;
  input  logic                        iclkena           ;
  input  logic                        ival              ;
  input  logic signed [pIDAT_W-1 : 0] idat_re    [0 : 7];
  input  logic signed [pIDAT_W-1 : 0] idat_im    [0 : 7];
  output logic                        oval              ;
  output logic signed [pODAT_W-1 : 0] odat_re    [0 : 1];
  output logic signed [pODAT_W-1 : 0] odat_im    [0 : 1];

...........

  logic                            decimator__ival           ;
  logic signed  [pIDAT_W-1 : 0]    decimator__idat_re  [0 : 7];
  logic signed  [pIDAT_W-1 : 0]    decimator__idat_im  [0 : 7];
  logic                            decimator__oval           ;
  logic signed [cCIC_ODAT_W-1 : 0] decimator__odat_re  [0 : 1];
  logic signed [cCIC_ODAT_W-1 : 0] decimator__odat_im  [0 : 1];
.....
  gige_decimator
  #(
    .pIDAT_W ( pIDAT_W     ) ,
    .pODAT_W ( cCIC_ODAT_W )
  )
  decimator
  (
    .iclk     ( iclk    ) ,
    .ireset   ( ireset  ) ,
    .iclkena  ( iclkena ) ,
    //
    .ival     ( decimator__ival    ) ,
    .idat_re  ( decimator__idat_re ) ,
    .idat_im  ( decimator__idat_im ) ,
    //
    .oval     ( decimator__oval    ) ,
    .odat_re  ( decimator__odat_re ) ,
    .odat_im  ( decimator__odat_im )
  );

Share this post


Link to post
Share on other sites

Mc_Indication - модуль "вложенный в описанный ниже"

мой код:

wire [Dout_Width-1:0] I_D [0:3];
Mc_Indication Ind_I (
        .sck (I_Sck),
        .log_brmax (Logcr),
        .oe (I_Oe),
        .pck (I_Pck),
        .dout (I_D)
        );
defparam....

 

выдает: SystemVerilog error at <location>: can't resolve aggregate expression in connection to port <number> on instance "<string>" because the instance has no module binding

ругается на I_D

 

Share this post


Link to post
Share on other sites

выдает: SystemVerilog error at <location>: can't resolve aggregate expression in connection to port <number> on instance "<string>" because the instance has no module binding

ругается на I_D

кхм ошибка because the instance has no module binding говорит о том, что ква не нашел исходники компонента %)

Share this post


Link to post
Share on other sites

но если убрать порт dout, все ок

Error (10703): SystemVerilog error at probe.v(842): can't resolve aggregate expression in connection to port 4 on instance "Ind_I" because the instance has no module binding

Edited by stu

Share this post


Link to post
Share on other sites

но если убрать порт dout, все ок

Error (10703): SystemVerilog error at probe.v(842): can't resolve aggregate expression in connection to port 4 on instance "Ind_I" because the instance has no module binding

по вашему ошибка это ок ? :) проект приложите с ошибкой, по фотографии лечить крайне сложно.

Share this post


Link to post
Share on other sites

)) я просто снова скопировал ту ошибку. без этой строчки компилится

пути я указал

Edited by stu

Share this post


Link to post
Share on other sites

)) я просто снова скопировал ту ошибку. без этой строчки компилится

пути я указал

проект приложите. у меня куча проектов сделано в указанном выше стиле и все работает.

Share this post


Link to post
Share on other sites

дк там туеву хучу библиотек надо переслать.

Subdesign Mc_Indication

(

Wck : input = gnd;

Wck_En : input = vcc;

Wa[Addr_Width-1..0] : input = gnd;

Wd[2..0][Data_Width-1..0] : input = gnd;

Write[Mem_Width-1..0] : input = gnd;

Wsync : input = gnd;

Rck : input = gnd;

Sck[1..0], Pck : output;

Dout[3..0][Dout_Width-1..0] : output;

Oe : output;

Log_brmax[15..0] : output;

)

Share this post


Link to post
Share on other sites

дк там туеву хучу библиотек надо переслать.

обрежте до минимума, что бы баг проявился. в противном случае мучайтесь самостоятельно. телепатов тут нет.

Share this post


Link to post
Share on other sites

спецом создал проект) ff используется как компонент в ff2. т.е. надо откомпилить проект ff2

quartus.rar

 

если переделать порт в линейный, то все норм)

Edited by stu

Share this post


Link to post
Share on other sites

спецом создал проект) ff используется как компонент в ff2. т.е. надо откомпилить проект ff2

файл ff.v с описанием компонента ff для которого instance has no module binding кто будет в проект ff2 включать ?

 

Share this post


Link to post
Share on other sites

не понял. почему тогда линейный порт норм обрабатывается?

почему так?

без объявления двумерный не работает, даже если в одной папке оба файла. а линейный норм

 

ЗЫ: С П А С И Б О.

 

на AHDL указывал, когда писал. а тут с линейными портами прокатывало и так, думал не надо))

а можно не полный путь писать?

Edited by stu

Share this post


Link to post
Share on other sites

не понял. почему тогда линейный порт норм обрабатывается?

почему так?

без объявления двумерный не работает, даже если в одной папке оба файла. а линейный норм

потому что у вас ДВА проекта.

 

В первом топ-модулем является модуль ff, описанный в файле ff.v. Этот модуль не содержит никаких инстансов сторонних компонентов.

 

Второй проект это проект с топ-модулем ff2, описанным в файле ff2.v. Этот модуль содержит инстанс компонента ff из файла ff.v, который вы не указали в проекте (о чем квартус вас честно предупреждал).

 

 

ЗЫ. учите английский и переводите ошибки/варнинги, пригодится.

 

Share this post


Link to post
Share on other sites

что ква написал, я понял. не обратил на это внимания т.к. линейный порт работал без объявления ff2

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...