FPGA Intellectual Property
PCI Express*, Networking and Connectivity, Memory Interfaces, DSP IP, and Video IP
Announcements
Intel Support hours are Monday-Fridays, 8am-5pm PST, except Holidays. Thanks to our community members who provide support during our down time or before we get to your questions. We appreciate you!

Need Forum Guidance? Click here
Search our FPGA Knowledge Articles here.

tcl commands

Altera_Forum
Honored Contributor II
1,135 Views

For master_write_32 $master_path [expr $base_reconfig + 0x40*4], can anybody tell me what *4 means exactly? Thanks

0 Kudos
3 Replies
Altera_Forum
Honored Contributor II
97 Views

 

--- Quote Start ---  

For master_write_32 $master_path [expr $base_reconfig + 0x40*4], can anybody tell me what *4 means exactly? Thanks 

--- Quote End ---  

 

Avalon-MM master addresses are 32-bits wide. The address map for the reconfiguration controller probably has the register offsets in words, i.e., the register located at 32-bit word offset 0x40 is located at byte offset 4*0x40. 

 

If the address map for the reconfiguration controller is already in byte offsets, and the register you want to access is at byte-offset 0x40, then the 4* would be unnecessary. 

 

Cheers, 

Dave
Altera_Forum
Honored Contributor II
97 Views

Thanks, Dave. 

 

* here doesn't mean multiply. So 4*0x40 = 0x00000040. Is that correct?
Altera_Forum
Honored Contributor II
97 Views

 

--- Quote Start ---  

here doesn't mean multiply. So 4*0x40 = 0x00000040 

--- Quote End ---  

 

 

The Tcl command expr means "do some math", so 4*0x40 = 0x100 :)
Reply