# Decision Maker

2,642

36

3

I got the idea for this from another instructable i saw a few days ago. It was made using an Arduino And a dual colour led. i thought it was a really cool idea and i wanted to make my own with a few small changes.....

1.i wanted two separate led's rather than one. to me having one button (like a starting point) and two Led's (one for each option like a fork in the road) seems more proper and decisive. it also gives the face of the box a nicer fuller look.

2.another thing i wanted was a nice wooden looking finish either natural or stained.

3.thirdly i wanted to eliminate the need for batteries and make it usb powered.

4.and lastly i just wanted it to be a nice looking (bezels, rubber feet, etc) conversation starter made to the best of my ability that could sit on my desk for as long as can be.

p.s. My writing sucks but i did my best.

### Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

## Step 1: Components & Planning

I made the circuit straight after i saw the other one on here. it comprises of a download circuit for the chip one button as an input a Picaxe 08M2 microcontroller and two led's (one red and one green) as outputs. also a resister is needed to ground the pin the button is connected to in order to reduce bounce and stop false signals.

## Step 2: Program

The Program for this circuit had to do the following

1. sense the button being pressed

2. decide on one of two outcomes

3. light an led corresponding to its decision

After a few tries i came up with the code you can see in the picture.

The only challenge here was a to make the decision random. Im still new to Picaxe so i just set a variable to equal 1 then rapidly added and subtracted 1 from in then at the time the button is pressed it takes the variable and if its a 1 then one light illuminates and if its a 2 then the other one does. that was random enough for my liking and seems to work well.

I played around with the timing and eventually decided on 2 seconds between pushing the button and the light coming on. i did this because iv read a few things like the one i linked below that say when you flip a coin you know what you really want while its in the air. the same goes for this, when you push the button you have two seconds to wait and will know what outcome you are hoping for.

http://lifehacker.com/5927934/flip-a-coin-to-decide-which-action-you-really-want-to-take

## Step 3: Making the Box

originally the box was to be a perfect cube. the first three attempts were made out of some scrap wood i found at school and all of them cracked and got caught on drill bits so for the forth attempt i used a piece of jarra i had at home. jarra is very hard and dense so it was much easier to work with, also it had a nice colour to it eliminating the need to paint or stain it. i cut a length of it with a drop saw but didn't think about the blade thickness so the perfect cube idea finished there. it became more of a sqare-ish rectangle. i roughly hollowed out the whole inside with a milling machine at school leaving the walls and top of the box about 3mm thick and leaving to corners a bit thicker to allow a baseplate to be screwed on into them. i sanded all the rough corners and it was all done.

## Step 4: The Insides.

I took the circuit that i made on a bread board and drew it as compact as i could on a grid of dots including a download circuit so i can change the program on the chip at any time. i did this so i can plan how it will fit on a piece of vero board, where i need to break tracks and how small i can make it (it ended up 7x9). next i soldered wires onto both led's and the button put the bottom of the bezels onto the led wires and soldered it all to the circuit board.

## Step 5: Assembly Part One

I drilled all four holes, one for the usb cable, one for the button and two for the led's.

for the forth box i turned it round so that the holes would all be drilled across the grain not into it... made such a difference!

i put the bezels in and all that was left was the button. i didnt want just a plastic button sticking out, i think that looks tacky and cheap so i found a rubber keypad cover of an old gps i has lying around and cut one of the buttons out of itthe problem with this was that it was stepped and i needed to drill the 3mm hole for the button and then a 8mm hole halfway through the lid for the shoulder. (see drawing) to do this you really need a milling machine as the bits are flat ended.

## Step 6: Assembly Part Two (the Goods)

i got an old cellphone sync cable and stripped the end of it, cut out the two data wires leaving me with a nice 5v power supply. i threaded the cable through the 3mm hole i drilled in the back and tied a knot in it so it cannot slip back or tug on the electronics inside.

i put the led's into their bezels red on the left green on the right of course ;) and then put the button in.

the button it turns out was the most annoying part of the whole project, i had to find a way to keep it in its little rubber cover. after a while i came up with the idea of making a little wooden bridge that would go over the back of the button and glue to the wood either side of it (see my amateur drawings) being such a small little box it sucked trying to get keep pressure on it while the glue dried and after a long time of trying holding it down with the end of a paintbrush, i was getting pissed off. Along came Papa New Guinea (dad) with a model making clamp i didn't know we owned. that sorted that, and the button was in :D

## Step 7: Finishing Touches

to cover the bottom i cut a square of aluminium and ground it down until it was exactly the same size as the box. i drilled four holes and countersunk them so the screws would sit flush. the screws i used were just some random ones i found in the garage and to make it just that extra bit nicer and to protect my new desk i cut little slices of heat shrink tubing and shrunk it around the head of the screws. having the heat shrink there makes in stand a tiny bit off the desk and helps it grip whatever its sitting on. All the electronics were then tucked away nicely inside and the bottom screwed on before one last rub down with some sandpaper and emory paper.

(before i put the insides in i cut a tiny bit off the bottom of the box with a drop saw to give it a sharp clean corner that the aluminium base would meet)

And thats that, my first Instructible done! hit me up if you have any questions or anything

Matt Hyde

mattchou@hotmail.com

Participated in the
Epilog Challenge VI

## Recommendations

• ### Large Motors Class

13,145 Enrolled

## 3 Discussions

I love this kind of project. The wooden box is awesome. I'm actually building one for my friends.