using multiple prISM

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

cross mob
KeYp_290406
Level 4
Level 4
        I'm using 9 prISM components to control small DC motors. What is the best way to have them all out of phase when they are sharing the clock? I can start them one at a time while the clock is running making sure they don't start on the same clock cycle. Or would it be better to change some of the number generating parameters so that no two are the same?   
0 Likes
10 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Since PrISM ises pseudo-random numbers (as the first two letters indicate) there must be a "seed" for the generator. Try to dig that up in the sources and modify it for each of the motors.

   

 

   

Bob

0 Likes
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

Not sure what you are trying to accomplish. Being a psuedo random

   

generator, PrISM, all 9 can be on or off at the same time, same is true

   

of x out of 9, seed value is irrelevant from this point of view. "Phase" is

   

almost irrelevant in the normal sense.

   

 

   

This is true of either density output or psuedo generator output.

   

 

   

If goal is each have a unique state in time of the psuedo sequence of generated values,

   

then seed value would accomplish this.

   

 

   

Regards, Dana.

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

The seed value is one of the parameters in the PrISM component configuration dialog. But in case you need it, it can also be set via the API.

0 Likes
KeYp_290406
Level 4
Level 4
        I would like each component to run the number sequence out of sync with the other components. I found by accident that when I start them up in sequence so that they are not in sync I get fewer noise issues in the system. When they are all in sync by starting them together and I turn on all motors, the noise will reset the psoc3. When not in sync this doesn't happen.   
0 Likes
KeYp_290406
Level 4
Level 4
        So by starting each component with a different seed, will they run the same pseudo sequence starting at a different point in the number sequence? I guess I don't completely understand how the random generator is working here.   
0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

With different seed values you will get a different series of pseudo-random numbers. PrISM just decides whether the actual number is larger (LED on) or not (LED off). So in fact it might turn out that all your LEDs are on at the same time. Better would be to stabilize the supply.

   

 

   

Bob

0 Likes
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given
0 Likes
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

@Dana

   

Stunned?

   

 

   

Bob

0 Likes
KeYp_290406
Level 4
Level 4
        I think all on is less of an issue than all switching on at the same time. I am working on the supply as well but this certainly makes a big difference with the seeds all set to a different value. I wonder is there are optimal values that insure that only a few can switch on at one time.   
0 Likes
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

Bobs point about a "stiffer" supply prescient I think. Especially in light you
have random processes that can result in worst case maximum load transients.

   


Some considerations -

   


1) I assume you are using some form of motor driver. If a simple MOSFET beware
of transient coupling due to Ldi/dt back thru Cgd and injecting spikes into PSOC.
A 2 stage isolated driver offers some isolation. or diode/zener clamps at PSOC inputs.

   

2) Use a scope, trigger on something below ground, like -1 volt, and look at driver pins.
Same for > Vdd, to see if you can establish where problems lie.

   


3) Use scope on infinite persistance and look at Vdd rail noise, might be an eye opener.

   

4) Polymer tantalums have a ESR vs F curve ~ 1 order of magnitude better than traditional
tants. Also use MLC caps for the faster higher freq problems.

   

Regards, Dana.
 

0 Likes