Follow all of PopSci’s Perseverance-mission coverage here.

Inside the Perseverance rover sits a gleaming, toaster-sized appliance. It has nothing to do with the mission’s primary objective of searching for signs of ancient life on the Red Planet, and it’s still technically a prototype, but the device happens to be one of the vehicle’s most demanding components.

When switched on, the gleaming gadget will consume nearly a third of Perseverance’s power, running so hot developers had to surround it with one of the best known insulating materials to keep it from damaging the 2.7-billion-dollar machine. Nevertheless, the scientists behind the prototype believe that the experience gained from field-testing it will far outweigh the project’s costs.

“Major mars missions will all depend on it,” says Michael Hecht, an MIT researcher and the experiment’s principal investigator. It could even be “something that people’s lives will depend on,” he adds.

The golden box is called the Mars OXygen In-situ resource utilization Experiment, or MOXIE for short. (Hailing from Boston, Hecht chose the name in part to honor the Massachusetts-born soda infamous throughout New England, and in 2017 he served as the grand marshal at Maine’s annual MOXIE parade.) MOXIE aims to act like a mechanical tree. It will inhale carbon dioxide from the Martian atmosphere, which is about a hundred times less dense than Earth’s but made up almost entirely of CO2. It will then exhale oxygen—back out into the atmosphere on this mission, but perhaps next time, into fuel tanks that will get astronauts back to Earth.

Perhaps a dozen times over the next Martian year (or two Earth years), Hecht’s team will fire up MOXIE, during which he expects it will produce between 6 to 10 grams of oxygen per hour—enough to support a puppy. The mission’s main goal will be to demonstrate that the technology works on the dusty, desert planet. “All sorts of things can work in the lab that don’t work in the field,” Hecht says. “Even on Earth we’ve learned that lesson constantly.”

One chief concern is how MOXIE will respond to the wildly variable Martian environment. The temperature can plummet by more than 150 degrees Fahrenheit after the sun sets, which has a huge effect on the density of the air (try putting a balloon in the freezer and watch it shrivel). Also inconveniently, a third of the atmosphere disappears every winter when the poles get so frigid that the CO2 condenses and falls to the ground as dry ice.

Manufacturing the many thousands of pounds of oxygen needed to blast off from the Red Planet will someday require a supersized MOXIE with hundreds of times greater capacity than the prototype, running around the clock for at least a full year, with no downtime.

“We want to show we can operate in all conditions, no matter if the air is thin or if the air is thick, if it’s cold or if it’s warm, or if it’s dusty,” Hecht says.

The researchers also aim to learn how to best operate MOXIE, which is more complicated than just turning it on and bottling the output. The machine is essentially the opposite of a fuel cell, — the engine in certain prototype vehicles that accepts chemical fuel and returns electricity with an oxygen containing compound (H2O). Instead, MOXIE takes in all the electricity that Perseverance can spare and an oxygen-rich compound (CO2), and uses heat and the electrical energy to split the carbon dioxide into carbon monoxide gas (CO) and oxygen (O).

At least that’s the ideal case. Run the machine too gently, and CO2 will get through intact, rusting internal nickel components. But run it too hard, and an overzealous MOXIE will pluck off both oxygens. That would be a problem; Instead of a colorless CO gas, it’d suddenly have to deal with a bunch of naked carbon atoms that’d choke the machine as soot, a problem known to engineers as coking.

“At some level, I find it amusing that the enemy of MOXIE is coke,” Hecht quips.

On this mission, the team will tune MOXIE by hand, evading coking and rusting by tweaking how much CO2 it takes in, the voltage it uses, and the temperature it reaches. But Hecht expects future versions will need artificial intelligence to manage it well enough to guarantee astronauts a ride home.

Perseverance is the first Mars rover to devote a portion of its precious payload to direct preparation for that future crewed ride, a strategic shift that has been in the works for years.

The division of NASA responsible for advancing human exploration has had four burning questions about Mars for decades: what’s the radiation like, how much will dust interfere with equipment, how can one land a heavy spacecraft on the surface, and how can astronauts take advantage of the Red Planet’s resources to lighten the load they carry with them from Earth. The agency planned to use Perseverance to answer that fourth question as far back as 2013.

“Way back at the get-go when they first were soliciting proposals, they said ‘we’re carving out a portion of this to get ready for human exploration,’” Hecht says.

NASA hasn’t nailed down the details of its crewed Mars missions, which could begin in 15 to 20 years, but almost all proposals assume the ability to make oxygen there. Otherwise, bringing enough propellant—which is three quarters oxygen—to get home just isn’t feasible. Breathable air for humans (and any companion puppies) is a nice bonus too.

That means the next MOXIE to leave Earth might be the real deal, and the work on the full-sized version is well underway. OxEon Energy in Utah, one of the many institutions involved in MOXIE’s development, is already testing a next generation prototype device that can pump out more than two pounds of oxygen per hour. “You put two or three of those together and you’re done,” Hecht says. (Setting up the nuclear power plant necessary to power them, however, is a problem for another day).

For now, the MOXIE team is focused on smaller steps. After Perseverance’s landing they checked in with a single command. A run-of-the-mill communications glitch stopped them from receiving all the data they’d been hoping for. But they were able to get a simple response indicating that the golden box had survived the harrowing landing, which helped everyone breathe a bit easier.

“That was enough to tell us we made it,” Hecht says, “and that’s not a trivial accomplishment when you’ve just traveled from one planet to another.”