Formal parameter to initialize D1 with UDB Editor

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

I added a formal parameter, of type int8.  I set it's type to "hardware".

   

The parameter was added to the verilog:

   

 parameter HiCmp = 127;

   

I tried to paste my symbol into the UDB Editor's "Configure Datapath Registers" dialog and got:

   

Unexpected value: "HiCmp". Expected standard decimal or verilog-style integer literal, e.g. 8'b11001010​

   

I'm new at this, so I might be missing something obvious.

   

Is there a way to use the parameter to set the initial value?

   

Thanks

0 Likes
7 Replies
odissey1
Level 9
Level 9
First comment on KBA 1000 replies posted 750 replies posted

Did you try to set it to "int"?

0 Likes
Anonymous
Not applicable

I just tried it.  I got the same error message.

0 Likes
bharadhwajas_91
Employee
Employee
First like received First like given

Can you quickly change the value of parameter to  parameter HiCmp = 8'd127 in the verilog file and try  ?

   

Can you attach your project?

0 Likes
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

I can't edit the verilog because it's generated by the UDB Editor.

   

I attached a test project that shows the problem.

   
        
  • Open the workspace
  •     
  • Edit component01.cyudb
  •     
  • Double-click on the Registers to get the "Configure Datapath Registers" dialog.
  •     
  • Put HiCmp as the initial value of D1.
  •     
  • Click "OK"
  •     
  • Get "Unexpected value: "HiCmp". Expected standard decimal or verilog-style integer literal, e.g. 8'b11001010"
  •    
   

​Thanks,

   

Michael

0 Likes
Anonymous
Not applicable

I have the nearly the same problem. [1] says to use `=$HiCmp`.
But then it says "Unexpected Identifier '=$HiCmp'".

   

Did you find a solution?

   

[1] http://www.cypress.com/file/41531/download, p.25 

0 Likes

Did you found any solution to this problem? I'm also stuck in that point 😕

   

Did a quick search here on the forum and can't found anything related.

   

*********************************

   

EDIT: I did close PSoC Creator, open the project again and this make me able to use `=$Counter_Period` and `=$Compare_Value`.
 

0 Likes
Anonymous
Not applicable

I gave up on the UDB Editor and switched to Verilog.

0 Likes