3
\$\begingroup\$

We need a pseudo-random clock with a length N, in such a way that out of every N clock pulses, M of them should randomly made zero (M<<N). What we want to do is to sample a signal in a random fashion. Meaning that, out of every N sample points (from Nyquist grid) we need to take M samples. Then through some processing and assumptions about signal structure, other un-sampled (N-M samples) points are recovered. Now I am using Linear Shift Registers, something like below:

schematic

simulate this circuit – Schematic created using CircuitLab

It works good, however, I do not want equal distribution for 1s and 0s, I mean I want something like 20% of clock cycles to be 1 and 80% to be zero. To achieve that, I made to AND output of two circuits like above to change probability from 50% for both 1s and zeros to 25% for 1s and 75% for zeros (in figure below, with different seeds).

schematic

simulate this circuit

It is good at the cost of doubling the power and chip area:( . I am seeking a way to make the system work with only 1 random clock generator circuit, not two.

  • Is possible through implanting some special initial seed change probability distribution of 1s and 0s in output sequence ?
  • Is there any power-area efficient method to accomplish this?

I was thinking to store a random binary sequence (with length of N) in a ROM and then And its output with the clock to make a random clock.

\$\endgroup\$
9
  • 1
    \$\begingroup\$ Depends how random it needs to be. If storing a sequence in a ROM is not an issue, then you could also use an LFSR to make a pseudo-random sequence. A bit more info on the application would help. \$\endgroup\$ Commented Aug 14, 2016 at 17:46
  • \$\begingroup\$ I second the lfsr. look for "irreducible polynomial" and pick which one gives the variations you want \$\endgroup\$
    – b degnan
    Commented Aug 14, 2016 at 17:56
  • \$\begingroup\$ The clock frequency is up to 1Mhz \$\endgroup\$
    – MimSaad
    Commented Aug 14, 2016 at 18:03
  • \$\begingroup\$ explain "M of them should randomly made zero " random edge, what min max time range and coherent with 1MHz? Random phase? \$\endgroup\$ Commented Aug 14, 2016 at 18:44
  • 1
    \$\begingroup\$ Wouldn't it be easier to simply take all of the samples at the full clock rate and then randomly discard some of them? \$\endgroup\$
    – Dave Tweed
    Commented Aug 14, 2016 at 23:11

1 Answer 1

5
\$\begingroup\$

Think of the contents of the N-bit LFSR as an N-bit integer. This number will have a uniform distribution of values from 1 to 2N - 1. You can generate a variable density of mask bits by comparing this number to a threshold that you also vary from 1 to 2N - 1. The output of this comparator is the clock mask you seek.

\$\endgroup\$
3
  • \$\begingroup\$ This method is flexible in changing distribution, so when I want like 17% of 1s, I'll set the threshold to 0.17*(2^N-1). I'll check to figure out if it is area and power efficient too. \$\endgroup\$
    – MimSaad
    Commented Aug 15, 2016 at 17:35
  • \$\begingroup\$ The answer is great and provides flexible distribution, however it stills requires an Comparator. I am researching to find out if I only use a few bits of N bit random generator and compare it to a threshold can acviehve good performance. \$\endgroup\$
    – MimSaad
    Commented Aug 17, 2016 at 14:24
  • 1
    \$\begingroup\$ Yes, of course. Any subset of M bits from the N-bit LFSR will contain a uniform distribution of values from 0 to 2^M - 1. So if you only need one part in 2^M resolution in your threshold settings, you can just use an M-bit comparator. \$\endgroup\$
    – Dave Tweed
    Commented Aug 17, 2016 at 20:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.