Wednesday, May 11, 2016

Final V

No Pennies Plz


The final completed project!


1) the title and “strapline" of your project:
  • No Pennies Plz: The Small Change Solution for the Savvy User
2) introductions to the team members 
  • Just me: Brendan Ward, Gallatin Senior, Sociology and Design
3) the “elevator pitch” of your project:
  • It's a change box that tracks your total $$$ and sorts your coins into different recepticals. 
  • NO pennies though
4) description of the target audience:
  • Anyone who saves change and can do without pennies
5) description of the need and/or existing interaction that the project mediates:
  • It enhances the piggy bank into something that is interactive and much more useful
6) a step-by-step guide, with either photos or video, that clearly shows "how it works” from a user’s perspective
  • see video below:
    • Turn on
    • Put coins in visually and size coordinating slots
    • Read LCD total
7) a short discussion of where the project succeeded in its goals:
  • It works pretty great
  • With glass jars inside the sound of the coins dropping in is so satisfying!
  • I lasercut the housing so I think it is quite aesthetically pleasing.
8) a short discussion of where the project failed to achieve its goals:
  • The only real failure is the aesthetics of the inside of the box, which you wouldn't see very often anyway
9) what you would do differently next time:
  • I might try to make it smaller
10) final thoughts/observations
  • I will definitely use this thing! It's a great final/retirement of my Arduino!


Video of me using it:



Presentation:

My Presentation








Final IV

Implementation

Code:

Coding this change box was really tricky only because I needed a persistent variable that could be written and accessed over multiple program runs.

Arduino has EEPROM memory which is writable and persistent, HOWEVER you can only store one byte of data at each EEPROM address.

I did a lot of research online and was playing around with some functions to splice and store data over several addresses when I found someone who had written the functions already.

----------
Full disclosure and Attribution:

I used the functions EEPROM_Write_Int and EEPROM_READ_Int

StackExchange Question: "How to Store 2 analogRead values and read using EEPROM for Arduino uno?"

Question Id: 15910 (http://arduino.stackexchange.com/questions/15910/how-to-store-2-analogread-values-and-read-using-eeprom-for-arduino-uno)

Author: Anurag S. Vasanwala (AnuragVasanwala@gmail.com)
----------

I needed to change one thing in the write function:

It turns out that EEPROM has a limited number of writes before the address wears out. I changed the final EEPROM.write() to EEPROM.update(), because .update() will only rewrite if the data is different saving memory

This problem also meant that I had to flag each sense of a coin from the photo interruptors and only update my EEPROM within a flagged if statement. If one ended up outside of an if statement I could burn through the address very quickly because of how many cycles the program can go through every second.

I then just printed the total on the LCD screen in my void loop() so that it updates in real time

The reset button simply saves zero to all the EEPROM addresses 

Code:






Final III


Implementation


Housing:

I wanted to laser cut my housing so I built an Illustrator file that had appropriate tongue and groove walls for easy assembly

I also include raster etching for the lettering and detail work of the different coins


After I managed to get the laser cuts done I simply had to glue all the sides together expect the top (which I wanted to put on hinges so that you could access the coins/circuit inside.

I ended up going for the non linear slot position so that vessels could be placed under each slot catching the different denominations of coins separately.

The etching turned out great!


Sound = Glass!

I tried various materials for the interaction design component of dropping in the coins, especially with sound.
It turns out glass mason jars make a beautiful *cha ching sound so I have three small mason jars corresponding to the different slots


The Circuit:

Wiring the circuit turned out to be quite complicated, basically it went:
  • LCD has 6 pin connections one of which is a potentiometer to control brightness of the backlight
    • it also has 2 power pins and three ground pins
    • I ended up soldering it all together so that it could fit in the limited number of available powers/grounds/pins on the Arduino
  • Each Photo interrupter needed:
    • A power and ground on one side
    • A power and analog pin on the other side with a pull-down resistor to ground.
      • Depending on how much resistance you put across the emitter the reading varies
  • I also needed a reset button which was a basic button circuit to a digital pin
  • Finally I spliced a switch into my battery power supply to power the whole thing



I explain the Code in the next post!


Wednesday, May 4, 2016

Final - Ideation II

Components:
  • LCD screen:
    • This is to log the total amount of money in my change box
  • 3x Photo Interrupter:
    • These will log the amount of money put into the box
    • Each sensor will map to a certain coin / value
    • With each interruption the coin value is added to the total in Arduino memory
Things that are still needed:
  • I need a simple on / off switch to turn on the system and LCD screen
  • I need some mechanism of resetting the memory - maybe a button inside the box that you hold to reset.

Design:



I am working with the size of the Arduino plus the breadboard. What I'm thinking is forego the breadboard and solder all my components in, so that I can have more efficient space. The trick is that each slot needs to have an uninterrupted "fall" space to whatever container is collecting the coins.

I'm also playing with different configurations of where the slots will go. Either side to side or more spread out. Ideally I would like to be able to engrave the actual image of a coin next to each slot. 


Next Steps:

  • I need to buy a switch
  • I need to wire everything with the breadboard to make sure my code and circuit works
  • Solder components together
  • Need to make the precision cuts of the lid
  • Build the housing