Tasting Success at Carnegie Mellon

 Students Invent Automated M&M Sorters for Mechatronic Design Final

May 5, 2005

They may already “melt in your mouth, not in your hands,” but picking out the red M&Ms® just got a little easier, thanks to our Carnegie Mellon student inventors, who have made machines to color-classify the candy. Tasked with designing an automated M&M sorter for the final project in Mechatronic Design, more than ten teams of pupils proudly demonstrated their creations in the University Center during the undergraduate research symposium, the “Meeting of the Minds.”

“It was fun working in an interdisciplinary team with a CS and an ECE major, so we could all contribute different things,” said Brian Dellon, a senior in Mechanical Engineering.

Sarah Childers, a graduate student in ECE, valued the course for its lessons on how to work with people. She discovered “that having ideas and actually implementing them are different skill sets,” and enjoyed “watching it all work.”

Offered under three departments—ECE, MechE, and Robotics—the spring capstone design course was taught by Gary Fedder, Professor of ECE and Robotics, and John Dolan, Senior Systems Scientist, Robotics. Aiding with the activities were teaching assistants Chris Baker, a graduate student in Robotics, and Gautam Jain, a senior in MechE, ECE, and CS.

Each M&M sorter had to feed from a hopper (a container that dispenses the candy), discriminate between at least two colors with a discard pile, place them into at least three bins, and provide statistics on the operation. The device needed to be portable and operate continuously, from the hopper to the bin in less then 5 seconds, running through at least 50 M&Ms for the demonstration.

One variation sorts peanut, chocolate, and mini M&Ms; another processes 2-3 candies per second, or 7,200 per hour; while a third features a solenoid driven catapult.

It propels the chocolates into the air and senses their color as they fall. Solenoid devices convert energy into linear motion; at the appropriate intervals, the gates open, allowing M&Ms to exit the path using their own inertia.

Dellon said his team’s creation, which employs two rotating hamster balls to sort the M&Ms, was inspired by a bingo-cage lottery ball. The hopper dispenses one M&M per ball, and is the result of “a lot of brainstorming,” according to partner Christine Moeller, a senior in CS.

Unhampered by problems in design, including setting up the color sensor, Dellon’s classmates kept working: “There is a lot of redesign. You build something…it doesn’t work. You build it again,” he said.

Using multi-gated servoing (servos are known for steering), another version can control where the sweets land based on the color picked up by a sensor.

Compressed air powers a model with pneumatic drives, blowing candy through one of six tubes, with a different path for each color. As the M&Ms fired through the apparatus during the demonstration, ECE senior Gerald Zhou held one of the hoses and aimed the candy at Xian-Yi Wu, a MechE graduate student who good-naturedly held up a bull’s-eye target sign.

The concept for the “whack-a-mole” M&M color sorter game comes from the carnival both in which you must act fast to hit the heads of mechanical moles with mallets when they pop out of their holes. In the students’ adaptation, as soon as an M&M appears, you must quickly press the correctly colored button to win it.

Although the classmates were instructed to assemble their equipment without using any Lego or consumer toy kits, for inspiration, the instructors showed them the Parallax M Sorter Kit, a commercial product which has a robotic mechanism, color sensor, and microcontroller that can be programmed to sort M&Ms. Last year, Parallax held a contest for the best code to run the kit.

In the Mechatronic Design curriculum, students integrate mechanisms, electronics, and computer control to achieve functional systems. Through lectures, labs, and interdisciplinary teamwork, they learn about mechanisms, actuators, motor drives, sensors and electronic interfaces, microcontroller hardware and programming, and basic controls. This course fulfills the ECE capstone design requirement, which is intended to enhance the student's repertoire of professional problem-solving and engineering design skills in the context of realistic engineering situations.

View the photo gallery.

Sarah Childers (left) and Erik Andreassen demonstrate their M&M sorter.

Kwan Shim (left) and Brian Staskowski show their machine, which sorts peanut, chocolate, and mini M&Ms.

L to R: Catherine Sun, Derek Blitz, and Juan Pablo Caram Wigdorsky said their device sorts 7,200 candies per hour.

L to R: Uland Wong, Elijah Dobrusin, and Peter Battaglino built a solenoid driven catapult.

L to R: Christine Moeller, Brian Dellon, and Marta DePaul's model uses two rotating hamster balls to sort the candy.

L to R: Piyawat Kaewkerd, Amine Merdassi, Rick Allison, and Nathan Denver can control where their sweets land using multi-gated servoing.

Xian-Yi Wu (far right) holds up a bull's-eye for M&M target practice, as Joseph Trapasso (middle) watches and Gerald Zhou aims.

L to R: Andrey Polonsky and Andrew Petruska must act fast for their "whack-a-mole" game.