Inspiration

In the 60s, NASA was figuring out how to safely land on the moon. To help the astronauts pilot the craft down to the lunar surface, they made a simulator to try out the situation in advance. NASA being NASA, this simulation was a $2 million dollar, 40-foot model of the moon, with a camera rotating around it to simulate an orbit.

Image

Amazing as this was, they deemed it not so helpful in the end. We figured we'd make our own version just to see.

What it does

You get a real time view of a physical model of the Moon, which you can fly around over using a HOTAS joystick and thruster.

How we built it

We have two model celestial bodies (The Moon and Earth) which are made out of florist's foam, mounted in a cradle of three of wheels controlled by stepper motors, which are in turn controlled by an Arduino. The motors allow us to rotate the globe to simulate the motion of the landing craft's orbit.

A webcam is mounted to a frame on top, whose z axis can be controlled using Z screws from an old 3D printer; this allows for very fine and precise control of its height above the planet.

We use Pygame to get the joystick and camera input, and to add after effects to the visuals. The main processing is done in this Python script, which simulates the flight mechanics and dishes out commands to the other systems over serial communications.

We've got four USB I/O connections to the main laptop running the systems. One for the Z-screws, one for the Arduino driving the wheels, one for the webcam input, and one for the joystick input.

Challenges we ran into

Hardware hacks, in general, are quite challenging;

First off, we spent about sixteen hours getting the stepper motors to rotate consistently in the right direction. We had to learn all about how stepper motors work at the mechanical level, and re-implement our own Arduino library to send the instructions in the right ordering and with the correct timing. This took WAY longer than it should have, but on the upside we now have a really good understanding of how these things work and also it made connecting it up to the Python central system much easier.

Secondly, although we came with a lot of electronics kit and hardware, we had trouble mounting things together and connecting things up. We went all around town finding suitable parts for the frame, including a tin pizza pan for the camera gantry and a toilet brush to dangle down from it.

Speaking of the toilet brush dangling down from the Z-screws, these Z-screws were a bit of a pain to interface with too. They want G-code rather than something more normal, and won't take regular serial connections.

A really interesting challenge we faced was that the camera we used didn't have autofocus. As a result, the camera would be blurry when close up and crisp afar, or vice versa. We couldn't manually go in with our fingers and adjust the focus ring on the lens (it's millions of miles away in space, after all), so we attached a toothed belt to another stepper motor, and then to an ad-hoc "gear" made of hot glue. This meant we could tele-operate the focus remotely from the joystick!

Finally, one big problem we continue to have is that we didn't have access to omni-wheels, which means that the rotation of the planet can be shaky in certain directions. Essentially, if we want the globe to rotate on the x-axis, two wheels need to rotate and one needs to remain still. This creates friction on the fast wheel in the lateral axis, which holds back the ball to some degree. This led to basically having to look for the optimal torque/rotational velocity to turn the wheels at in order that they would dig in just enough to be practical.

Accomplishments that we're proud of

We're super proud of this project. We've been planning it for a couple of days and it was very hard to not get started before the hack on Saturday, so we're just glad to see it all working well.

We're particularly proud of the range of systems and pieces of hardware we learned about and successfully integrated together. The hacky nature of this thing is stark when you look at it and see the sheer amount of hot glue, sellotape, various homeware products, and bare wires. By all accounts it shouldn't work, but it does!

We're also really pleased at the polish we were able to achieve. Incredibly, we managed to get this project done quite a few hours in advance with respect to "core mechanics", and then we were able to dedicate a good few hours to making it fun, usable, and aesthetic.

What we learned

We learned a huge amount about basically all of the hardware we used. Personally, I (Zac) learned a lot about stepper motors, and using Arduinos. It's not often I use microcontrollers, but they're really good fun. I also had good fun painting the moon and the Earth models.

What's next for Lunatic Lander

Mars.

Built With

Share this project:

Updates