Page 158 - Embedded Microprocessor Systems Real World Design
P. 158

ITEMS IN HOPPER. AWAITING FEED
                                                     OMRALL SPACING CONTROLLED TO MEET
                                                     MINIMUM  THROUGHPUT REQUIREMENT

                                                           GAP BETWEEN ITEMS HAD TO BE WIDE ENOUGH
                                                           FOR DOWNSTREAM SORTING MECHANISMS


                                                                              I
                                                       7
                                                   ITEMS ON TRACK
                     FEED MECHANISM
                                       DIRECTION OF MOTION -0

                Figure 4.4
                Conveyor Belt System.


                important to know when  the processes should not be independent. A real-world
                example will illustrate this: I worked on a motion control subsystem, developed by
                a contractor, that feeds items into a moving transport system (see Figure 4.4). The
                system has two requirements that are relevant here.
                   The first requirement is to meet a particular throughput in items per minute.
                The second requirement is to maintain a minimum spacing between any two suc-
                cessive items. Two independent processes run these two functions. The first process
                controls a terminal motor speed to maintain throughput, and the second process
                performs instantaneous adjustments to  the  motor  speed to maintain  minimum
                spacing between individual items. These corrections are small or large, depending
                on  the  predicted  spacing  error.  The  corrections reduce  throughput  but  are
                expected to occur infrequently. After a correction, the motor ramped back up to
                the terminal speed.
                   The prototypes of the system worked well, but production units could not meet
                the throughput requirement. It turned out that the spacing process was perform-
                ing a few corrections to fix spacing and this reduced throughput. The throughput
                process, not knowing about corrections, saw that throughput was too low and raised
                the terminal speed. This required even more corrections, which lowered through-
                put even more. The result was that the throughput process walked the speed up to
                the maximum value, while  the spacing process corrected more and more items,
                until it was finally correcting (or overcorrecting) nearly every item. The reason this
                showed up only in production was  that the mechanical adjustments in the proto-
                type allowed the system to “balance” and run without problems.
                  The solution for this problem was  fairly simple: If  too many corrections were
                performed, terminal speed was  lowered instead of  raised. The amount of  speed
                reduction  was  weighted  by  the  degree  and  number  of  corrections that  had


                Software Design                                                      139
   153   154   155   156   157   158   159   160   161   162   163