CD1109-feat2

Simulation: Prescription for Success

Sept. 11, 2011
Machine Builder Uses Simulation Software to Design and Test Feeders, Robots and Pallets in a Complex Medication Packaging System

By Jim Montague, Executive Editor

Just as it can be hard to see the forest for the trees, sometimes it's hard to see an overall production system for all its machines and components. In the woods, the trick is to get up above the trees and look down. In manufacturing, a thorough and dynamic simulation can give machine builders the overall operating perspective they need before construction.

Even Experts Need Tools

MTS Medication Technologies (www.mts-mt.com) has been building drug packaging systems for more than 25 years, and its engineers are experts at designing and building increasingly automated and patient-specific prescription packaging machines and related equipment. As a result, it typically has long-term relationships with many pharmacy customers.

However, about three years ago, a large European pharmacy company began seeking a way to centralize supplying medicine to its hundreds of retail pharmacies across regions and even countries, so MTS proposed designing a much larger retrieval and packaging system with more feeder stations, robots and other supporting devices than it had ever built before. To best coordinate all these components, MTS and its engineers knew they would have to design and test numerous new operating variables and parameters, and so they decided to use simulation to speed up this process, save time and expenses, and build fewer prototypes.

"Each pharmacy traditionally fills its own prescriptions, mostly by hand, and so our customer was looking to consolidate a lot of its usual distribution efforts into just one or a few centrally located systems," says Robert Barrett, MTS's controls, software and mechanical engineering fellow.

From Punch Cards to Robots

Located in St. Petersburg, Fla., MTS manufactures medication packaging systems, related consumable packaging, software and pharmacy information system interfaces. The company serves more than 9,000 institutional pharmacies in the long-term care and correctional-facility markets in the U.S. and also internationally.

Founded in 1984 by practicing pharmacist Harold Siegel, MTS developed the first automated packaging machine to fill and seal medications into disposable punch cards, and now has a product line that includes automated and semi-automated packaging machines and hundreds of consumable products.

"MTS started out making punch cards, labels and blister packs, and it eventually just made sense for us to move into building machines that would allow our customers to use these end products more efficiently," Barrett says.

"With the level of complexity and multitude of variables involved with this type of system, a static design simply would not cut it."

The company's standard line of packaging machines are designed to fill, seal and label punch cards at up to 12 cards per minute. Many typically have one feeder station, conveyor system and robot. Equipped with automated barcode verification and tracking, the machines allow pharmacies to fill prescriptions as soon as they receive the orders. Their automation also helps ensure packaging accuracy, and lets users grow their businesses without adding staff.

Barrett adds that MTS's OnDemand machines employ a variety of robots and motion control software, and then use single-board computers and backplanes to interact with and control I/O devices. "These embedded computers allow us to use an embedded Ethernet adapter to distribute I/O and process data throughout our whole machine, and control different parts of it," he explains. "We also do PC-based control via Visual Basic by using multi-threading and ActiveX objects to instruct other motion devices such as servo motors and servo actuators. We also overlay an Oracle database on top, which allows different areas of our systems to understand what they need to do and when to do it."

Centralization Demands Coordination

To enable the European pharmacy firm to fill prescriptions from so many retail outlets in one or a few locations, MTS estimated the larger CentraFill packaging system would need about 30 feeder stations to dispense multiple medications into multiple compartments on one punch card with daily doses arranged by week or month. For example, if a patient needed medication four times per day, the machine would produce a 4x7 punch card for a one-week supply.

"Our larger machine also needed three different types of filling areas," Barrett adds. "The first is dedicated to high-speed filling of single medications. The second uses two robots to pick drugs from 104 different cassettes, and place them in the packages. The third is a more manual station for handling partial tablets."

In addition, besides employing up to a dozen or more robots working together simultaneously, the many feeder stations are located along a 120 m track occupied by dozens of small, independent, servo-driven, 400 mm pallets. Each pallet is dedicated to filling one prescription, so it visits assigned feeders, and cycles through the machine along the track until it's completed.

Though the larger machine's design combines many of MTS's existing components and expertise, it also presented many new complexities for which the builder had no prior design concept. As a result, MTS was faced with testing and validating many new variables to minimize risk, optimize engineering time and secure buy-in from its European end user. One of the biggest challenges was determining the precise number and configuration of the machine's many feeder stations to prevent over-engineering the machine or miscalculating the volume of support equipment it would require. MTS also needed to give its customer an accurate cost estimate for the machine, determine its footprint, and verify its production rate and throughput. Finally, the customer wanted the machine's design to be scalable to meet future demands.

"With the level of complexity and multitude of variables involved with this type of system, a static design simply would not cut it," Barrett says. "The only way we would be able to verify the performance of the machine and calculate the many variables that can occur in the process was through simulation."

Similar to other packaging operations, support equipment and a range of operational variables can affect overall machine performance. Normal operating speed, reliability, mean time between failures and changeover time all are factors in the planning process.

"We've done projects this big before, but they usually involve multiples of the same machines," Barrett says.

We'd never done an environment in which this many devices had to be coordinated, even though the individual machines were similar to our existing equipment. This larger machine needs to run 60-80 pallets at the same time to be efficient, but the logic of how they move and act in relation to the feeder stations quickly gets very complex. We just had a lot of questions to answer, and that's why we had to use a simulation."

Simulation Setup

To build its simulation, MTS enlisted a consultant, Doerfer Companies (www.doerfer.com), and in late 2009 they jointly examined all the planned stations, robots, required performance characteristics and other information needed to accurately reflect the larger packaging machine that MTS wanted to build. Similar to designing a real machine, Doerfer and MTS used Rockwell Automation's Arena discrete-event simulation software to assemble and tweak a virtual version of MTS's larger machine.

For example, Arena aided MTS's initial design concept by identifying potential problems in the machine's packaging process and calculating the impact of variables that could occur. The software also demonstrates, predicts and measures system performance, such as the effectiveness and efficiencies of design changes. In this case, it allowed MTS to test many process variables and scenarios in a controlled environment under various conditions. By manipulating the data inputs, engineers could analyze proposed changes, and refine efficiencies before construction (Figure 1).

Going with the Flowchart

Figure 1: MTS Medication Technologies improved its design for a new, larger CentraFill machine that packages multiple medicines in individual, patient-specific cards by using simulation software to more easily model robotics, test and compare different process variables and application scenarios, and refine efficiencies before actual construction.
MTS and Rockwell Automation

"One new challenge that came up was how to coordinate the pallets and other individual components so they could be productive and efficient," Barrett says. "For instance, the pallets are given a list of feeder addresses to visit in a particular order, but they often have to wait in line at different stations. The number of pallets in line and the time it takes a station to process them is called the buffer. Because our multi-medication packages usually have seven or eight drugs per package, we have to determine when it would be best for each pallet to wait, and when it would be more efficient for it to skip a station and go back later. For example, if there were only two or three pallets in line at a station, then a new one arriving might wait. However, if there were seven in line, then the new one would bypass that station, go fill other parts of its order, and return later. The simulation let us test and understand our buffers much faster, and achieve the most efficient balance."

"The only way we would be able to verify the performance of the machine and calculate the many variables
that can occur in the process was through simulation."

In the past, Barrett says, they would have had to do physical experiments with a prototype, which would have required far more time. "The simulation also allows us to be more free-thinking with our design process because we're not locked into conserving the resources used by a prototype, and so we can easily try out more unusual scenarios," he explains.

MTS still assembles and tests physical prototypes for many of its smaller stations and robots, and uses CAD software to design these mechanical systems, Barrett adds.

Virtual Machine = Real Savings

Consequently, Arena's system-level analysis gave MTS a valid picture of the larger machine's overall performance. MTS engineers created a fundamental flow diagram of the packaging process. From there, they could define and validate processing rates and reliability of the equipment, conveyor and feeder capacities, sensor locations, maintenance schedules and operator-staffing requirements. In fact, Barrett reports that the simulation also enables MTS to run an entire day's worth of activity in 15-20 minutes, which lets its engineers evaluate different performance characteristics much more quickly.

"If you know that a feeder system has a 0.1% failure rate, you can build that into the simulation to ensure the most realistic view," Barrett adds. "That's why it was important that we used a simulation tool good at handling errors and exceptions. Without it, there can be a disconnect between what's simulated and what ends up really happening in real time. Once the model is fully optimized, we can then begin the manufacturing process. With more detailed simulation, we have more empirical data from machine operation and can go back to the Arena software and make sure it will perform based on the model. We can then design and build the robots and feeders based on the simulation data."

The European pharmacy company's larger machine is still under construction, Barrett reports. In fact, after the simulation was completed in mid-2010, it subsequently aided MTS even more when the customer decided to scale its system down from one overall processing center to a few slightly smaller ones, which enabled MTS to use it to develop a new simulation during the past six months.

"It was important that we used a simulation tool good at handling errors and exceptions. Without it, there can be a disconnect between what's simulated and what ends up happening in real time."

In general, MTS reports, Arena's simulation cut its design time in half, from about two years to 12 months. Likewise, MTS estimates the simulation will help reduce the larger machine's startup and installation time by about 60-70%.

"In fact, because we love to use past knowledge, we're already using what we learned from this larger project to build a much smaller multi-medication system that can run twice as fast as earlier equipment," Barrett says.