How to enable the external crystal oscillator in PSOC5.

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

cross mob
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Hello, All! I am new in PSoC world. Currently I am working on a project that require accurate frequency measurement. Since PSOC5 internal clock doesn’t accurate, using external crystal oscillator will provide  more accurate measurement.

   

I have an external crystal with part number ECS-240-20-33-CKM-TR, which is 24 Mhz crystal and 20 pF load capacitance. I already soldered this crystal on the PCB board next to PSOC chip at Pin 15[0] and Pin 15[1](I have attached schematic). I choose two 22 pF capacitors as load.

   

I followed procedure (AN54439_External crystal oscillators) and tried to enable this external crystal oscillator in PSOC creator, but it never work.  (See attached setup).

   

I don’t know why that it doesn’t work. Thank you for any help, I will really appreciate.  

0 Likes
11 Replies
odissey1
Level 9
Level 9
First comment on KBA 1000 replies posted 750 replies posted
        jacob,, Please take a look on XTAL settings here http://www.cypress.com/comment/406171#comment-406171 Note that IMO is hoocked to XTAL and XTAL setting are different. The 22pf caps might be an issue, notice 12pf value on the picture. I used 14pf caps (20pf didn't work). Lastly, all XTAL wiring must be as short as possible.   
0 Likes
Anonymous
Not applicable

Thanks for the reply!
I know what you mean about using the lower caps. However, since my crystal has load caps spec as 20 pf, that's why I used 22 pf as load caps. (It is based on cypress website 
http://www.cypress.com/knowledge-base-article/mhz-external-crystal-oscillator-eco-cy8ckit-050-and-cy...
I will try it by using lower caps to see if is work. 

Thanks again.

0 Likes
HeLi_263931
Level 8
Level 8
100 solutions authored 50 solutions authored 25 solutions authored

When selecting the capacitors, you need to take into account the capacitance on the PCB and the MCU inputs. 12pF sound about right.

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

Thank you for the reply!

   

There is a formula for calculating the load capacitance. I assume Cstray is around= 7pF, if I pick up 12pF, 7+((12*12)/(12+12))= 13pF, which is lower than my crystal load capacitance. I used 22 as my C load, based of this formula. But it's not work....

   

update: I changed cap to 15pF, and it is still not work. I am considering does my layout did wrong? The distance between crystal to chip is around 0.14inch. 

I have attached layout pictures.

0 Likes
rola_264706
Level 8
Level 8
50 likes received 25 likes received 10 likes received

Have you scoped the Crystal and what kind of signal do you have on P15(0) and P15(1)?  Also did you mount the crystal correctly?

0 Likes
rola_264706
Level 8
Level 8
50 likes received 25 likes received 10 likes received

Also did you check halt on error in the Crystal setup screen.

0 Likes
Anonymous
Not applicable

Thanks for the reply!
I did check halt on error in the clock setup, but I didn't check the pin since I have to consider the capacitance in the probe, and it will load the crystal.

0 Likes
HeLi_263931
Level 8
Level 8
100 solutions authored 50 solutions authored 25 solutions authored

Look at the data sheet - the pin-out is shown from the bottom. Taking this into consideration your PCB looks wrong.

0 Likes
Anonymous
Not applicable

Thanks for the reply. You are right, we missed up top view /bottom view of crystal. Thank you! 

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

hli is right, the PCB is no good. Only way to salvage the board is to glue XTAL upside down and hard-wire with 30AWG 😞

   

   

 

   

0 Likes
Anonymous
Not applicable

Thanks for the reply. Yes, you are right, the PCB is no good, it is upside down.  Thank you again.:)

0 Likes