Embedded Systems December 2000 Vol13_13

Issue link:

Contents of this Issue


Page 166 of 197

Don Morgan A Translation Point Initially, the introduction of the digital signal processor (DSP) into motion control was meant to solve problems relating to fl exibility, size, precision, cost, and ease of mainte- nance in the moti on control and dri ve. The DSP made it possible to replace a great deal of expensive and to uchy analog circuitry with more sta- ble and much more malleable digital circuitry. This meant tha t a math engin e became th e brain of the con- troller and the engineer was able- thro ugh software-to accomplish any transfe r fun ction that an analog con- trolle r was capable of doing, and much mo re. Once manufacture rs realized an inte rest in DSP fo r moti on control exis ted , th ey in creased o n-chip capabiliti es and speeds. It is no t uncommo n now to find DSPs with o ne o r mo re a nalog-to-digita l con- ve rte rs on board, as well as en code r counte rs and hardwa re PWM ge ne r- a ti o n. It's possibl e to create a ve ry o phi ti cated mo tio n controll e r using j ust a DSP, some memory, and logic e leme nts. This kind of density is possible because the DSP now performs so many of ule activities that llsed to requi re sepal-ate equipment, boards, processors, or l es. In ulis column, we will examine some of ule oUler duties Ulat the DSP can pel-form while con- trolling ule motor. We will start by re- introducing concepts from trigonome- u]' and show how they allow the DSP to replace such ancillary circui ts as the resolve r-to-digital (RTD) conversio n and to perform sinusoidal encoder interpolation. Trigonometry Figure 1 is an illustration of a pair of right triangles supel-imposed on a cir- cle WiUl ule angle a originating at the center. Trigonomeu-ic fun ction are ratios based on angles. Fo r example, the sine of the angle a is ule ratio of the opposite side (y) to th e hypotenuse on the smaller triangle, while the cosine of the angle a is the DSPs can replace a great deal of analog circuitry, while offering better stability and configurability. Basic trigonometry might give you some ideas. ratio of the adjacent side (x) to the hypotenuse. Another useful ide ntity is th e tan- gent. In the figure, the tangent touch- es the circle at only one point, where the radius meets the unit circl e. The tangent is pel-pendicular to the radius and stretches between this point and where it would meet the hypotenuse if th e hypotenuse were exte nded beyond the unit circle. The tangent of a is the ratio of y to x. It is also possible to write the tan- gent fun ction as: tan a = sin a cosa What we derive from th e forwa rd u-igonometric fun ctions of angles are magnitudes. The inverse fun ctio ns- a rcsin e, a rccosin e, and a rcta ngent-o n th e with Y = sin a and x = cos a. What we recover from ulis fun ction is an angle. These relationships are remarkably useful. Because uley provide such a simple u-anslation point between a lin- ear and rotal], viewpoint, you will find Ulem useful in un to ld engin eering applications; we will see some in this column. A common signal processing application In sign al processing fo r instance, the trigonome tri c functio ns are a sta n- da rd part o f ma ny bilinear tra nsform algori th ms. Digi tal filte rs are based upon finite arithme ti c with a finite sample ra te; th e co rn er freque ncie (3dB po in t frequencies) of digital fil- te rs bear a highly non-linear rela- tionship to continuous tim e corn e r frequencies. We can warp a n a nalog Embedded Systems Programming DECEMBER 2000 165 oth er hand, a re angles. Yo u read ta n-I z (or arctan z), for instance, as "tan-1 z is a n angle whose tange nt is z." In th e fi gure, if we know th e le ngth of the side marked as ta n, we can find a by performing th e a rct- a ngent fun cti on. We may write thi s as:

Articles in this issue

Archives of this issue

view archives of EETimes - Embedded Systems December 2000 Vol13_13