Mars Rover

By Russell Barnes. Posted

If you’re going to build a robot, why not aim for the stars and build your own Mars Curiosity Rover?

NASA’s Curiosity is one of the most famous robots on... well it’s technically on Mars, but it’s more famous here on Earth. We think this Curiosity-based build is out of this world.

The full article can be found in The MagPi 45 and was written by Lucy Hattersley

Marcio Rovai used Curiosity as inspiration for his final project for Coursera’s ‘Create Your Own Internet of Things (IoT) Device’. His Mars Rover - or ‘Mobile Station for Environmental Data Capture’, to use its official name - uses a Raspberry Pi to form the brains of an environmental data capture robot.

“It’s a mobile station prototype responsible for environmental data capture, [such] as temperature, humidity, and luminosity,” says Marcio. “The idea is to help students and hobbyists learn how a robot could be remotely controlled, and information captured and displayed over the internet.”

“The Rover was based on the Curiosity,” he tells us. “Both were developed for image and environment data collection.” There are, of course, some physical differences (beyond one being slung to another planet). “The real Curiosity has six wheels that makes [it] all-terrain; my Mars Rover is a simple differential wheeled robot with two motors.” Curiosity also has an articulated arm and drill for sample collection, which is missing on the Raspberry Pi Mars Rover. “But the basics are there,” says Marcio.

 The robot is quite complex

Mars Rover uses both a Raspberry Pi and Arduino. “The Pi is responsible for more complex tasks, such as web communication, sensor data capture, and live video streaming – leaving the core stuff like mobility, obstacle avoidance, and remote control with the Arduino.”

“Controlling servo motors using PWM outputs directly from RPi GPIO isn’t easy,” he explains, “and it’s best to have a HAT for that. So I decided to leave this job for my little friend, the Arduino Nano.” The Nano’s main tasks are to receive commands, control the servo motors, and monitor the ultrasound sensor for obstacle avoidance.

“Curiosity has a more advanced REMS (Rover Environmental Monitoring Station) system that incorporates the following sensors: atmospheric pressure, relative humidity, temperature (ground and air), ultraviolet radiation, and wind currents. So I included sensors for temperature, humidity, and luminosity (as a simulation of ultraviolet). My Rover doesn’t capture wind and pressure data [like] the real Curiosity.”

The Raspberry Pi Mars Rover is controlled from an Android phone, which also provides a video stream. Marcio used MIT AppInventor ( to create the app.

 There are some remote controlled elements

“The Rover isn’t fully autonomous,” admits Marcio, “as you must give [it] directions using the remote control. But I incorporated automatic obstacle avoidance capability, which will prevent a ‘bad pilot’ [from crashing it] on a rock, for example.”

Data captured by the Mars Rover is sent from the Raspberry Pi to ThingSpeak (, which turns it into visualisation. “One of the great advantages of IoT,” says Marcio, “is the large range of public websites to record, analyse, and visualise captured data.”

Marcio thinks it would be great to make it even more like NASA’s Curiosity, including adding a robotic arm to do mechanical work and a more robust body. Solar panels are on the cards, too, although Curiosity is nuclear-powered; perhaps a step too far for realism.

From The MagPi store


Subscribe to the newsletter

Get every issue delivered directly to your inbox and keep up to date with the latest news, offers, events, and more.