timing constraint for output mux and how to set output delay.
Hi,
I’m looking for some help to constraint my design. I didn’t write constraint before and i look some documents on internet. Still can’t find any example similar to my design.
My design has two interface protocol, the two interface will use the same ports to output to external device. Each interface has it’s own clock and data. So i use mux to decide which signal will be sent.
The code looks like :
//ifsel=1 : interface1. ifsel=0 : interface2.
assign portA = (ifsel)?(interface1_data1):(interface2_clock) ;
assign portB = (ifsel)?(interface1_data2):(interface2_data1) ;
assign portC = (ifsel)?(interface1_data3):(interface2_data2) ;
assign portD = (ifsel)?(interface1_clock):(interface2_data3) ;
The external device needs setup and hold time as following.
interface 1 : setup time : 1.7ns, hold time : 1.6ns (reference to interface1_clock rising edge, interface1_clock needs 180 MHz)
interface 2 : setup time : 1.5ns, hold time : 1.4ns (reference to interface2_clock rising edge, interface2_clock needs 160 MHz)
In this situation, how to set output constraint?
Thanks.
Andy.