I want to use a low EMI clock generator to reduce noise in my system. Does the AM335x series support this type of clock, the datasheet does not indicate that it does or does not, please advise. Thanks!
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
I want to use a low EMI clock generator to reduce noise in my system. Does the AM335x series support this type of clock, the datasheet does not indicate that it does or does not, please advise. Thanks!
I have a medical device customer that is asking about the AM335x SSC support. I’ve read through the TRM but do not have enough experience with SSC to understand what is being conveyed, or what the actual capabilities are just by looking at the register definitions. It looks like MPU, DDR, DISP (LCD?), CORE, and PER domains are supported.
Does the PRCM generate SSC clocks for each domain, based on the SSC registers for each domain?
Can the main clock be fed with an SSC source?
Am I missing anything in a typical EMI constrained use case?
Thank you!
The following section will be added to the TRM to describe SSC:
Spread Spectrum Clocking (SSC)
The module supports spread spectrum clocking (SSC) on its output clocks. SSC is used to spread the spectral peaking of the clock to reduce any electromagnetic interference (EMI) that may be caused due to the clock’s fundamental or any of its harmonics. When SSC is enabled the clock’s spectrum is spread by the amount of frequency spread, and the attenuation is given by the ratio of the frequency spread (Δf) and the modulation frequency (fm), i.e., [{10*log10(Df/fm)}-10] dB.
SSC is performed by changing the feedback divider (M) in a triangular pattern. Implying, the frequency of the output clock would vary in a triangular pattern. The frequency of this pattern would be modulation frequency (fm). The peak (ΔM) or the amplitude of the triangular pattern as a percent of M would be equal to the percent of the output frequency spread (Δf); that is, ΔM/M= Δf / fc.
Next mark with Finp the frequency of the clock signal at the input of the DPLL. Because it is divided to N+1 before entering the phase detector, so the internal reference frequency is Fref = Finp / (N + 1).
Assume the central frequency fc to be equal to the DPLL output frequency Fout, or fc= Fout = (Finp / (N + 1)) * (M / M2).
Since this is in band modulation for the DPLL, the modulation frequency is required to be within the DPLL's loop bandwidth (lowest BW of Fref / 70). A higher modulation frequency would result in lesser spreading in the output clock.
SSC can be enabled/disabled using bit CM_CLKMODE_DPLL_xxx.DPLL_SSC_EN (where xxx can be any one of the following DPLLs: MPU, DDR, DISP, CORE, PER). An acknowledge signal CM_CLKMODE_DPLL_xxx.DPLL SSC_ACK notifies the exact start and end of SSC. When SSC_EN is de-asserted, SSC is disabled only after completion of one full cycle of the triangular pattern given by the modulation frequency. This is done in order to maintain the average frequency.
Modulation frequency (fm) can be programmed as a ratio of Fref / 4; that is, the value that needs to be programmed ModFreqDivider = Fref / (4*fm). The ModFreqDivider is split into Mantissa and 2^Exponent (ModFreqDivider = ModFreqDividerMantissa * 2^ModFreqDividerExponent). The mantissa is controlled by 7-bit signal ModFreqDividerMantissa through CM_SSC_MODFREQDIV_DPLL_xxx.MODFREQDEV_MANTISSA bit field. The exponent is controlled by 3bit signal ModFreqDividerExponent through the CM_SSC_MODFREQDIV_DPLL_xxx.MODFREQDEV_EXPONENT bit field.
NOTE: Although the same value of ModFreqDivider can be obtained by different combinations of mantissa and exponent values, it is recommended to get the target ModFreqDivider by programming maximum mantissa and a minimum exponent.
To define the Frequency spread (Δf), ΔM must be controlled as explained previously. To define ΔM, the step size of M for each Fref during the triangular pattern must be programmed; that is,
ΔM = (2^ModFreqDividerExponent) * ModFreqDividerMantissa * DeltaMStep IF ModFreqDividerExponent <= 3ΔM = 8 * ModFreqDividerMantissa * DeltaMStep IF ModFreqDividerExponent > 3
DeltaMStep is split into integer part and fractional part. Integer part is controlled by 2-bit signal DeltaMStepInteger through the CM_SSC_DELTAMSTEP_DPLL_xxx.DELTAMSTEP_INTEGER bit field. Fractional part is controlled by 18-bit signal DeltaMStepFraction through the CM_SSC_DELTAMSTEP_DPLL_xxx.DELTAMSTEP_FRACTION bit field.
The frequency spread achieved has an overshoot of 20 percent or an inaccuracy of +20 percent.
If the CM_CLKMODE_DPLL.DPLL_SSC_DOWNSPREADis set to 1, the frequency spread on lower side is twice the programmed value. The frequency spread on higher side is 0 (except for the overshoot as described previously).
There is restriction of range of M values. The restriction is M-ΔM should be >= 20. Also, M+ΔM should be <= 2045. In case the downspread feature is enabled, M-2*ΔM should be >= 20 and M <= 2045.
Regards,
James
Please can you give me an example on how to activate the Spread Spectrum Clock in linux?
It is mentioned in AM335x_TRM that "SSC can be enabled/disabled using bit CM_CLKMODE_DPLL_xxx.DPLL_SSC_EN", but I have no clue how to do that on my linux board.
Thanks.
G.
See attached source code. Use it in the board file of the linux kernel.
regards
Wolfgang
Hi guys
I'm trying to do spread spectrum on AM335x and I got this source code and tried to compile it. I am running TI Arago Kernel 3.12 from SDK7 and tried to compile it against that, but no matter what method I use I keep getting so many errors.
I tried to compile it as an independent source (used Linaro Cross GCC and G++) couldn't get it to work, as it failed with errors regarding definitions of "HZ" and "RCU":
In file included from ../include/linux/smp.h:12:0,
You have to configure and build the kernel before you can build a module against the kernel.
Look at your make output: it seems that the kernel tries to build a x86 module.
I already have built the kernel:
make -C . -j4 ARCH=arm CROSS_COMPILE=$CC zImage
Should I make modules too first?
I have a perfectly good zImage sitting in arch/arm/boot.
I made some progress today...However I'm still getting this error:
make -C ./ ARCH=arm CROSS_COMPILE=${CC}
I made another change but still no success:
I moved the dither.c to arch/arm/mach-omap2/ and modified the Makefile there and added
obj-m += dither.o
and did make ARCH=.... modules but I keep getting the following errors:
I'm at a dead end...any help anyone?