Clock Distribution Error

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

cross mob
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

I have a clock, 1 Mhz, going into count input of UDB 16 bit cntr. In its properties I have

checked off syced to BUS_CLK.

But timing analysis errors clock is unsynced -

pastedImage_2.png

pastedImage_5.png

pastedImage_6.png

I would have thought the properties box on clk would have taken care of this.

But when I use an external sync component on clk, syncing to BUS_CLK, error goes away ?

An aside, cannot copy to clipboard in Notice window an error ?

Regards, Dana.

0 Likes
1 Solution
Len_CONSULTRON
Level 9
Level 9
Beta tester 500 solutions authored 1000 replies posted

Dana,

By design, the PSoC build process tries to force input signals to UDB blocks to be synchronized to BUS_CLK because the internal latches of the UDB are sourced by the BUS_CLK.  Synchronizing inputs to BUS_CLK virtually guarantees prevention of a condition called a meta-stable logic condition on the output of the latch taking those inputs.  See Metastability (electronics) - Wikipedia

"Sync with BUS_CLK" is set by default.  Deselecting the "Sync with BUS_CLK" allows for the error to not be flagged.  This means that if meta-stability occurs, you are responsible for the results and your application can tolerate it.

Len

Len
"Engineering is an Art. The Art of Compromise."

View solution in original post

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

Dana,

I believe that for reasons unknown the UDB Counter requires Clock_3 ("count") and "capture" inputs be Sync'ed to the "clock" (BUS_CLK in this case). Sometimes Sync'ing only the "count" is enough. I made a custom version of the Counter v3.0 (PSoC5), which ignores this requirement, which I can post if you need such.

/odissey1

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

Dana,

Attached a demo project with standard Counter and customized Counter_ex component, which does not require to sync the "count" input when connected to a clock. The Counter_ex library can be found here:

Phase offset and Quadrature signal generator for lock-in

/odissey1

Counter_01.png

0 Likes
Len_CONSULTRON
Level 9
Level 9
Beta tester 500 solutions authored 1000 replies posted

Dana,

By design, the PSoC build process tries to force input signals to UDB blocks to be synchronized to BUS_CLK because the internal latches of the UDB are sourced by the BUS_CLK.  Synchronizing inputs to BUS_CLK virtually guarantees prevention of a condition called a meta-stable logic condition on the output of the latch taking those inputs.  See Metastability (electronics) - Wikipedia

"Sync with BUS_CLK" is set by default.  Deselecting the "Sync with BUS_CLK" allows for the error to not be flagged.  This means that if meta-stability occurs, you are responsible for the results and your application can tolerate it.

Len

Len
"Engineering is an Art. The Art of Compromise."
0 Likes

So that checkoff does not force router to do the synch, it just

controls, if path not synched, the error to be reported ?

Seems odd use of a flag. Flag implies it will fix problem, HW, at least it

does to me.

Thanks for the reply, very helpful.

Regards, Dana.

0 Likes

Dana,

This checkoff is basically a design rule check.  It is a courtesy for the user.  The default is the preferred method to sync to the BUS_CLK especially for UDBs that need it to keep from potential output glitching.  This is a lesson Cypress learned from their PSoC1 series parts where this design rule is not enforced.

Depending on your design it might be critical for performance to disable this synchronization but the user should be aware of the caveats of using this mode.

Len

Len
"Engineering is an Art. The Art of Compromise."
0 Likes