MicroView Alien Scanner

15 08 2014

Thumbnail_MicroView_HeroBeen a while without any post on this blog. Anyway, a good time for a revival now as I have recently received my chip-sized Arduino with built-in OLED Display know as the MicroView (a project which I’ve been a backer at kickstarter). After I did all the tutorials to learn about Arduino and the MicroView I started to wonder what I could do as a first project. Hence the idea of building an Alien-like tracker. Something that would more or less beep like the tracker in the movies and display the actual distance between me and the next thing in front of me. I still own a Nerf N-Strike Longstrike CS-6 Dart Blaster and I thought it would be pretty cool to attach the sonar to the gun. This is how the final prototype looks like:


Basically the MicroView serves as the radar display and gives the rough distance of the object/alien in front of us. If the… thing comes closer then the bar graph is going to light up. The closer it gets the more LEDs get on. And the whole time, there’s a bip-bip sound going on so you feel even more in the movie. For now, it’s more of a simulator (except for the sonar which actually work but I’ll need to continue on the 3D position and movement).

Bill of Material (aka what you will need to build it)

Of course you’ll need the MicroView – OLED Arduino Module as soon as available, as well as its USB Programmer. In addition you will have to get the following elements:

  • Perma-Proto Half-sized Breadboard PCB – find it at Adafruit
  • SPDT Mini Power Switch – at Sparkfun
  • a piezo buzzer – at Adafruit
  • Female headers – at Sparkfun
  • 10 Segment LED Bar Graph – Blue – at Sparkfun
  • a bag of 10+ 330 Ohm resistors – find them at Sparkfun (this will be to protect the LEDs)
  • Ultrasonic Range Finder – Maxbotix LV-EZ0 – at Sparkfun
  • a 9V Snap Connector for the 9V battery – at Sparkfun
  • … and of course a bunch of jumper wires, which you can find at any electronic reseller.

With this… heat up your favorite iron, it’s solder time!


Start with the LED Bar Graph, insert the top left corner in F1 (or better, F2 as I found out later that F1 means you’re losing access to the screw hole…). The component should sit between F1and F10 and E1 to E10. Solder nicely and trim the trails. Save them for they will make handy jumpers shortly.

After you’ve soldered the bar graph, add 10x 330 Ohm resistors, B1 to the GND, B2 to the GND, etc. Finally, use the saved parts to create nice jumpers for we will group the LEDs in batches of 2. First jumper links J1 and J2, second one is for I3 and I4, then J5/J6, I7/I8 and then J9/J10.


Now we will put in the additional components. Cut out two 8-long female headers and solder them H13 to H20 and C13 to C20. They will form the socket for the MicroView. Add one more 7-long from J21 to J27, this will be for the range finder. Finally, solder in the switch between H28 and H30 and the piezo buzzer E22/E25 (E25 is the GND). That’s it for the components, we will now move to the actual wiring.

First we will connect the grounds from the top and the bottom of the PCB. Solder a connector wire from top GND11 to bottom GND11. As we’re doing grounds, let’s wire them all. For the range finder, connect I27 to the top GND. For the MicroView, connect B20 and the bottom GND: this is pin 8 of the MicroView, see the Pin Configuration diagram here). And for the buzzer, connect B25 to the bottom GND.

Onto the rest of the wiring:

  • connect 5 of the bar graph LEDs to the MicroView Arduino pins: G1 to G15 (Arduino pin 6), G3 to G16 (Arduino pin 5), H5 to I17 (Arduino pin 3), H7 to I18 (Arduino pin 2) and H9 to D17 (Arduino pin A2). This is because we’re not using an 8-Bit Shift Register here.
  • Connect H23 (range finder ANalog) to D18 (Arduino pin A1).
  • B22 to B19 (Arduino pin A0) for the buzzer.
  • I29 to the top VC++ (for powering on via the switch)
  • I26 to I14 (Arduino +5V to the range finder)
  • F28 to F13: this will be the VIN for the MicroView.

Finally, you may want to add a couple of male headers at the top on e.g. row 1 so that you be be able to easily connect the 9V battery at a later time.

You’re done! Next, insert your USB Programmer with the MicroView on top on the “socket’’” we have built in the middle of the PCB. Connect your USB cable to your PC, we’re going to the…

Code part

This code leverages code snippets found on the web. I have tried to name the authors when available. If someone recognizes his code, let me know and I will certainly addgive deserved credits. Likewise: this code is free to use, just let me know if you found it useful. I have inserted a fair amount of comments for documenting it, so it hsould be easy to read/understand. If not, just drop me a note.

  • Get the code here as a .docx file to accomodate WordPress’ requirements for media files.

Have fun!




Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: