- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello All,
I recently got a -050A kit with the new PSoC 5 LP silicon. I have been trying to test the full 1 MSPS sample rate on the SAR ADCs.
The problem that occurs is that Creator tells me that I have a clocking error. At 1 MSPS, the configuration dialog tells me that I need a 18 MHz clock. What I did was to change the PLL speed to 36 MHz (2X required frequency). In the clock tree, this generates a divide by 2 clock into the ADC. Theoretically, this should work, but Creator still throws a clocking error warning.
Is there an example project that shows 1 MSPS sampling, or is this some kind of bug?
Thanks!
Solved! Go to Solution.
- Labels:
-
PSoC 5LP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Actually the problem we are discussing here is that even for the 5LP, one cannot use the full sample speed. If you feed a SAR ADC component with a 18MHz clock, PSoC Creator gives an error about the clock frequency.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Just to help things along, here is the actual error message I get:
ADD: sdb.M0059: error: Error in component: ADC. Internal clock frequency value must be between 1 MHz + 1% (1.01 MHz) and 18 MHz - 1% (17.82 MHz).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You might want to increase the BUS clock of PSoC5 LP Devices.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This looks like a bug to me. The calculation of the allowed frequencies seems to get the boundaries wrong - it should be "1MHz-1% up to 18MHz+1%". The way the error is displayed means one cannot get the full sample rate, since the component would not accept a 18MHz clock.
I also tested it with an external clock - same problem. Lowering the frequency makes the error go away.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@hli:
What clock frequency did you use to get it to work?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Anything less than 18MHz did work (I tested with 12 and 16MHz), but then you don't get the full sample rate. (But beware - I tested only the compile, I don't own a PSoC5LP board yet).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The original PSoC 5 products could not run at the full 1M SAR ADC sample rate.
The new PSoC 5LP parts are full pin-for-pin replacements and are capable of running at the full 1M sample rate.
Creator knows via part#, which family of PSoC 5 you have, and will limit your sample rate.
The -050A kit contains the old silicon. The latest kit is a -050B and it contains the production ready 5LP silicon.
The upgrade site is below:
http://www.cypress.com/?app=kitupgrade
Try putting this part# into creator: CY8C5868AXI-LP035
Hope this helps...
-JHNW
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Actually the problem we are discussing here is that even for the 5LP, one cannot use the full sample speed. If you feed a SAR ADC component with a 18MHz clock, PSoC Creator gives an error about the clock frequency.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello All,
I am now running PSoC Creator 2.2 SP 1. I am still having this issue. Is there any knowledge base article or resolved method to get the full 1 MSPS without a build error?
Thank you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This the cause of the problem(PW of clk) -
Clock Frequency
This text box is a read-only (always grayed out) area that displays the required clock rate for the
selected operating conditions: resolution and conversion rate. It is updated when either or both of
these conditions change. Clock frequency can be anywhere between 1 MHz and 14 MHz
(18 MHz in PSoC 5LP). The duty cycle should be 50 percent. The minimum pulse width should
be greater than 33 ns (25.5 ns in PSoC 5LP). PSoC Creator will generate an error during the
build process if the clock does not fall within these limits. In that case, change the Master Clock
in the Design-Wide Resources Clock Editor.
18 Mhz = 55.5 ns, so perfectly square clock will not work. If square in 5LP then clk = 51 nS =
19.6 Mhz. But error takes into account tolerance, looks like limit is 17.82 Mhz max.
Error in component: ADC_SAR_1. Internal clock frequency value must be between 1 MHz + 1% (1.01 MHz) and 18 MHz - 1% (17.82 MHz).
Reagards, Dana.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I tired config with a xtal and got close to 18 Mhz, error for that was -
Error in component: ADC_SAR_1. Internal clock frequency value must be between 1 MHz + 0.001% (1.00001 MHz) and 18 MHz - 0.001% (17.99982 MHz).
I used 0% error for xtal config, but looks like tool defaults to .001 % as minimum tolerance,
in case of xtal. Maybe try external digital 0% error clock and see if that allows 18.000000 Mhz.
A bit of an exercise.
Regards, Dana.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No, this won't work either. Error message is the same. To me the SAR ADC is broken in that regard (and the sequencing SAR ADC too), one cannot use it with maximum sample rate.
Though one could import the component and change the validation (the check is in cyadcsarcontrol.cs)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
While you are at it, you can file a bug against the static timing analyzer as well for not figuring out the real clock to the ADC 🙂
But well done, this is a clever idea!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Case filed, I will update this when results are in.
Regards, Dana.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here is answer from Creator Team -
This is proved a defect of current version Creator. Creator should not introduce a 10PPM
accuracy penalty to XTAL clocks if customer has put in the error info in Clock Editor UI.
This problem will be fixed in Creator 3.0(I don't know when this version Creator will be
released), before that please use the solution(good solution) you created(using XOR gate
to pass the timing analyzer) to bypass the defect.
Regards, Dana.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This issue is not fixed in PSoC Creator 3.0 at least when using an external clock. The maximum external clock I can use is about 13MHz. I would prefer to run at the higher rate.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I recomend you post a case at -
“Support”
“Technical Support”
“Create a MyCase”
Regards, Dana.