10 Replies Latest reply on Oct 23, 2013 7:58 PM by user_14586677

    using multiple prISM

    user_6153427
              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?   
        • 1. Re: using multiple prISM
          user_1377889

          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

          • 2. Re: using multiple prISM
            user_14586677

            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.

            • 3. Re: using multiple prISM
              user_78878863

              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.

              • 4. Re: using multiple prISM
                user_6153427
                        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.   
                • 5. Re: using multiple prISM
                  user_6153427
                          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.   
                  • 6. Re: using multiple prISM
                    user_1377889

                    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

                    • 8. Re: using multiple prISM
                      user_1377889

                      @Dana

                         

                      Stunned?

                         

                       

                         

                      Bob

                      • 9. Re: using multiple prISM
                        user_6153427
                                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.   
                        • 10. Re: using multiple prISM
                          user_14586677

                          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.