Feature

Managing motion

Motion-control circuits, development kits, and real-time software give you the tools to make your next embedded product literally move.

By Warren Webb, Technical Editor -- EDN, 7/11/2002

AT A GLANCE
  • To provide a more realistic interaction with the user, embedded designers are adding controlled mechanical motion to their products.
  • Designers must choose from hundreds of variations of ac, dc, and stepper motors to find the unique characteristics for each application.
  • As processing power grows, the real-time software algorithms from separate motion-control silicon will be integrated into the main CPU.
  • Off-the-shelf development kits offer an easy way to begin the integration of the motor's mechanical properties with an embedded application.
Sidebars:
Combat robots: motion to the max

With the growing call for fully interactive products, your next embedded design may have to shake, rattle, roll, twist, bend, rotate, quiver, vibrate, or even walk. Managing these mechanical gyrations falls under the general heading of motion control, one of the fastest growing embedded specialties. Motion control has become the foundation of contemporary manufacturing and is most often implemented by computer control of electric motors or actuators. Numerical-control machinery, robotics, and factory automation are all familiar examples of motion control used in manufacturing. Designers have used electromagnetic control circuits since the early days of electronics to energize motors, relays, solenoids, and speakers, but motion-control techniques are now much more complex, as system requirements call for precision motion that is coordinated among multiple motors or actuators.

Whether your application is aerospace, manufacturing, medical instrumentation, test equipment, or the hundreds of other motion-control applications, the basic problem is the same: the efficient, reliable, economical, and precise control of one or more electromechanical devices. The most commonly used devices, and the focus of most motion-control vendors, are ac-induction motors, stepper motors, and dc motors. You can apply each motor type in open-loop situations or with feedback from the motor itself or other portions of your application to guarantee accuracy. Each of the motor types has myriad variations with corresponding advantages, drawbacks, and best-suited applications. Before embarking on your first or next motion-control project, you should review the characteristics of each motor type and matching controller to ensure that you have the best candidate for your project.

The most widely used industrial motor is the ac-induction motor because of its low cost, simple design, and reliability. An ac-induction motor is comparable with a transformer with a rotating secondary. The stator or primary windings are arranged in multiple poles and driven by an ac power source to produce a rotating magnetic field. A torque is produced by the magnetic reaction to the currents induced in the windings of the rotating secondary or rotor. Unlike a brushed-dc motor, the currents in the rotor of an ac-induction motor do not have to be supplied by a commutator. You can calculate the velocity of the rotating magnetic field of the stator as V=120f/p, where p is the number of poles, and f is the frequency.

The rotor responds to the stator's magnetic field but travels at a lower speed. Because the difference between V and the rotor's speed increases proportionally with the load, open-loop ac-induction-motor systems are poor candidates for precision velocity or position systems. Speed control requires an expensive and complex ac inverter drive to vary the motor's input frequency to compensate for load changes. Designers usually opt for dc or stepper motors when precision motion control is required.

Simple stepper

Stepper motors are one of the most popular embedded motion-control devices because they move in discrete steps, provide accurate angular position information, and are relatively easy to control. The rotor of a stepper motor is made of permanent magnets arranged in a series of poles that determine the step size. The stator includes multiple windings to create a magnetic field that interacts with the rotor's permanent magnets. As the stator windings are turned on and off by a sequence of pulses from a control circuit, the motor rotates forward or in reverse. Reversing the stator pulse sequence changes the direction of rotation, and the frequency of the pulses controls speed. To make a stepper motor rotate, you must constantly turn on and off the windings. Conversely, if you constantly energize one winding, the motor stops rotating and maintains an angular position with its specified holding torque. Stepper motors are either bipolar, requiring a dual-polarity power source, or unipolar, requiring only one power source. These characteristics of stepper motors allow the open-loop position control that you often see in precision products, such as printers and disk drives.

Open-loop stepper-motor controllers simply switch on and off the current in each winding to control speed and direction. If you are designing your own controller, you can drive stepper windings directly from open-collector transistors or power FETs. For applications in which each motor winding draws less than 500 mA, you can use an off-the-shelf product, such as the DS2003 from National Semiconductor, which includes seven high-voltage, high-current NPN Darlington transistor pairs with common emitters and open-collector outputs. This package also includes built-in suppression diodes to eliminate the inductive kick produced when drive transistors are turned off. The DS2003 costs 26 cents (1000).

Several low-cost controller boards are available for experimenting with stepper motors right at your desktop PC. For example, the $45 A-100 stepper-motor controller from www.steppercontrol.com drives one or two unipolar stepper motors through your parallel port. You can download a free stand-alone Windows program to create short test and demonstration sequences for the A-100 or a Windows DLL to include in your application. Another low-cost controller, the STEP3PPI, from Technological Arts provides three two-amp stepper-motor channels and a parallel-port interface for less that $200. The controller is based on the STMicroelectronics L297D chopper stepper-motor driver and L298 dual-H-bridge chip set.

The dc motor is one of the earliest motor designs, and historians have traced its roots back to laboratory experiments by physicist Michael Faraday in 1821. Modern dc motors are widely used in applications that require control of rotational speed or torque. A dc motor rotates when two magnetic fields interact with each other. The stator creates a fixed magnetic field with a permanent magnet or energized electromagnet. Likewise, the rotating armature or rotor also includes a series of electromagnets that generate a magnetic field when current flows through one of its windings. For a brushed dc motor, a commutator on the rotor and brushes on the stator allow individual windings to be energized as the motor rotates. The opposite polarities of the energized rotor winding and the stator magnet attract, causing the rotor to move until it aligns with the stator field. Just as the rotor reaches alignment, the brushes move across the commutator and energize the next winding to maintain motion.

Controlling speed and torque

When developing controllers for dc motors, you should keep two basic relationships in mind: Motor speed is proportional to the applied voltage, and output torque is proportional to the current. Figure 1 shows the relationship among speed, torque, and current for a typical brushed-dc motor. Many dc-motor applications, such as fans and small pumps, drive a constant load and operate within requirements with simply a fixed voltage applied to the motor. Your design task is to pick the operating speed and then provide enough drive current to match the required load torque.

The control problem becomes more of a challenge when you must control the speed of the dc motor during operation. You can use a resistive divider to lower the voltage, but a large percentage of input power is wasted in the dropping resistor. For very small motors, this wasted energy may be tolerable, but designers are generally looking for a more efficient way to transfer power to the motor. The most popular approach to efficient dc-motor operation is to apply a PWM (pulse-width-modulated) square wave with an on-to-off ratio corresponding to the desired speed. The motor acts as a lowpass filter to translate the PWM signal into an effective dc level. PWM-drive signals are popular because they are easily generated from a microprocessor-based controller. Although the motor's speed is regulated by a precise pulse width, the actual PWM frequency is variable and should be optimized to prevent motor chatter, audible noise, and RF interference.

To reverse a dc motor, you must reverse the direction of the current in the motor, and the most popular way to do so is by using an H-bridge circuit. You can build an H-bridge circuit from discrete components (see sidebar "Combat robots: motion to the max") or purchase an off-the-shelf IC, such as the LMD18200T from National Semiconductor. The LMD18200 is designed to drive both dc and stepper motors and delivers a maximum 3A continuous output with peak currents to 6A. The IC accommodates supply voltages to 55V and includes a thermal warning flag and shorted-load protection. The LMD18200 comes in a TO-220 package and costs $8.10 (250).

Another popular variation of the dc motor eliminates the electrically noisy and maintenance-prone brushes but sacrifices controller simplicity. The brushless-dc motor is a synchronous motor with permanent magnets on the rotor and windings on the stator. Stator windings are generally arranged in a three-phase wye connection and produce trapezoidal torque characteristics. The energized stator windings create electromagnet poles that attract the rotor and generate torque. By using an appropriate sequence to apply voltages to the stator phases, you can create and sustain a rotating field on the stator. The stator current must be synchronized with the rotor field to generate a torque. Most brushless-dc motors use Hall-effect sensors to read the motor's rotor position and enable the controller to switch the three winding phases on and off in the proper sequence to produce rotary motion. Although they are similar to induction motors, permanent magnet brushless-dc motors have higher efficiency due to the elimination of magnetizing current and copper losses in the rotor.

Dedicated DSPs

As the motion-control problem becomes more complex through coordinated moves or intricate motion profiles, designers have turned to dedicated processors or DSPs to calculate real-time trajectories. The Texas Instruments TMS320C2000 line of DSPs with on-chip peripherals, such as flash memory, ADCs, and CAN (controller-area-network) modules, are popular in motion-control applications. Available in both 16- and 32-bit, fixed-point versions, the C2000 series is compatible with TI's Code Composer development suite includes includes a C compiler, an assembler, a linker, and a debugger.

Regardless of the motor type that you select, the easiest way to get started in motion control is with an off-the-shelf development kit. TI and Spectrum Digital offer new DSP users a series of development kits that provide software-development platforms for embedded products. I was able to work with the TMS320LF2407 DSP Starter Kit, a handy 3×5-in. pc card that includes the DS; an RS-232 interface for host debugging; 16k words each of onboard data RAM, program RAM, and flash memory; and expansion connectors for custom user logic. The $249 kit also includes an ac adapter and communications cable. I found the kit easy to set up and operate, but, without a built-in motor interface, it would be most useful during the later hardware- and software-development efforts.

The MCK2407 DSP motion-control kit from Technosoft proved to be an ideal evaluation platform for investigating both the hardware and software aspects of dc motors. This kit includes the same TI TMS320LF2407 DSP, 64K words of program RAM, and a serial communications interface, all mounted on a 2.5×4-in. pc board. It also includes a similarly sized 50W power module and a brushless motor equipped with Hall sensors and a 500-line encoder for direct experimentation. All communication between the host PC and the DSP board is via a flash-resident communication monitor with downloading, debugging, and inspection functions. The evaluation kit is complete except for a user-supplied power supply and an RS-232 cable. It includes a set of ready-to-run examples with assembly source code. The kit also features the DMCD (Digital Motion Control Development) platform with an integrated debugger, basic assembler, linker, and other facilities that allow you to create, modify, and test assembler applications within a project-management system (Figure 2). I was able to set up the kit, install the software, and run one of the supplied demo programs in less than an hour. My only problem was with the user's manual, which contained instructions for four versions of the kit, making it difficult to quickly scan for the next step in the setup procedure. I was able to graphically define motion scenarios and controller characteristics from the host PC. During runtime, the commanded speed, actual speed, speed error, and motor currents are saved in memory and displayed in graphical form. The MCK2407 DSP motion-control kit costs $1095 and is available directly from Technosoft.

A large number of motion-control vendors offer off-the-shelf, plug-in motor-control boards for PCI, Compact-PCI, or VMEbus systems. These boards allow designers to add motion control to a PC or an embedded system without digging into the details of controller design or feedback-loop optimization. The Galil DMC-1417 is an example of a low-cost controller for the PCI bus (Figure 3). The DMC-1417 can handle applications with such features as electronic gearing, multitasking, uncommitted I/O, and user-selectable stepper- or servo-motor control. Modes of motion include point-to-point positioning, jogging, contouring, and electronic gearing. The controller provides software PID (proportional, integral, derivative) compensation with velocity and acceleration feedforward, offsets, and integration limits. Programming the DMC-1417 is simplified with two-letter, intuitive commands and a full set of software tools, including a servo-tuning and -analysis application, an ActiveX Tool Kit for Visual Basic users, and a C programmers tool kit. You can purchase the DMC-1417 online at the vendor's Web site for $595 in single quantities.

If you want to integrate similar features into your own board design, you should investigate motion-control silicon devices, such as those available from Performance Motion Devices. For example, the Pilot MC3410 is a 132-pin, surface-mount, CMOS-technology, motion-control device powered by 5V. The MC3410 outputs a selectable 10-bit, 20-kHz PWM; an 8-bit, 80-kHz PWM; or a 16-bit DAC-compatible motor- command signal necessary to directly drive the windings of a stepping motor. The Pilot offers user-selectable profiling modes, including S-curve, trapezoidal, and velocity contouring. With more than 115 commands, the motion controller's instruction set offers flexibility for applications programming from a host processor. The MC3410's prices start at $28 (OEM).

One of the latest innovations in the motion-control industry is the software-only controller. By taking advantage of the processing power of modern desktop computers, vendors can implement a full-scale, multiaxis motion controller directly in software. For example, Soft Servo Systems offers ServoWorks, a PC-based soft-motion software product for real-time motion and CNC (computer numerically controlled) applications (Figure 4). With ServoWorks, a single PC performs all servo control, including feedback loops and numerical-control-path generation. It also provides the user interface, data processing, plant monitoring, network communication, and file management. Ormec Systems has integrated the ServoWorks technology with the company's ServoWire SM digital network drives and IEEE 1394 communications. You can network as many as 16 drives directly to a standard PC using standard FireWire cabling. The PC runs on Windows NT/2000/XP, with a Venturcom RTX real-time extension to the operating system.

Popular instrumentation environments, such as LabView, also offer motion-control add-ons. National Instruments offers Motion Assistant, a development tool to help make motion software easier to create (Figure 5). Motion Assistant has an intuitive point-and-click environment that designers can use to configure and prototype each move in their motion profile. Using the position, velocity, and acceleration preview windows, they can preview what their motion profile will look like before executing it. After completing the profile, they can use Motion Assistant to generate the LabView virtual instruments or create a "code recipe" that indicates the functions and parameters to use in creating the same motion profile in other environments, such as C or Visual Basic.

Motion control is a huge and growing industry with a constant flow of new technology, such as new and improved motors, better control algorithms, and more efficient controllers. For instance, motor development is growing in both directions—not only the huge and powerful, but also the very tiny. Miniaturization teams have developed piezoelectric motors no bigger than a grain of rice (Figure 6), and MEMS (microelectromechanical-systems) projects have produced micromotors less than a square millimeter in size. This growing inventory of new technology will provide designers with plenty of tools and opportunities to integrate motion control into the next generation of embedded products.


For more information...
When you contact any of the following manufacturers directly, please let them know you read about their products in EDN.
Galil Motion Control
1-916-626-0101
www.galilmc.com
Innovation First
1-903-454-1978
www.ifirobotics.com
National Instruments
1-512-683-0100
www.ni.com
National Semiconductor
1-800-272-9959
www.national.com
Ormec Systems Corp
1-585-385-3520
www.ormec.com
Performance Motion Devices
1-781-674-9860
www.pmdcorp.com
Pittman
1-215-256-6601
www.pittmannet.com
Spectrum Digital Inc
1-281-494-4500
www.spectrumdigital.com
STMicroelectronics
1-602-485-6100
www.st.com
Steppercontrol.com
1-336-998-9330
www.steppercontrol.com
Soft Servo Systems
1-781-891-9555
www.softservo.com
Technological Arts
1-416-963-8996
www.technologicalarts.com
Technosoft
1-727-939-8593
www.technosoft.ch
Texas Instruments Inc
1-800-336-5236
www.ti.com
Vantec
1-888-929-5055
www.vantec.com


Author Information
You can reach Technical Editor Warren Webb at 1-858-513-3713, fax 1-858-486-3646, e-mail wwwebb@cts.com.

 

Combat robots: motion to the max

Motion-control technology is getting a boost from engineers and hobbyists, who are having fun with combat robots. These fighting machines use dc motors, batteries, and remote-control electronics, along with a dizzying array of weapons, in an attempt to subdue or disable an opponent. The agility of these robots directly depends on the dc motor controller. Several companies, such as Innovation First and Vantec, offer off the shelf controllers to supply the high voltage and current needed in a battle situation.

However, one of the most useful spin-offs for design engineers is the OSMC (Open Source Motor Controller) project. This project began as an Internet-hosted collaborative effort to design and implement a high-power, H-bridge motor-control system for permanent-magnet dc motors targeting battle robots (Reference A).

You can purchase kits or download free schematics, parts lists, Gerber files, and software for the OSMC boards from www.robot-power.com. You can also join the OSMC project and follow new developments at http://groups.yahoo.com/group/osmc/.

Reference

A. Miles, Pete and Tom Carroll, Build Your Own Combat Robot, McGraw Hill/Osborne, 2002.



Reed Business Information Resource Center

Featured Company


Related Resources

ADVERTISEMENT

ADVERTISEMENT

Feedback Loop


Post a CommentPost a Comment

There are no comments posted for this article.

Related Content

 

By This Author


ADVERTISEMENT

Knowledge Center



Technology Quick Links

EDN Marketplace


©1997-2009 Reed Business Information, a division of Reed Elsevier Inc. All rights reserved.
Use of this Web site is subject to its Terms of Use | Privacy Policy

Please visit these other Reed Business sites