Monday, June 30, 2014

This Must Be A Record (For Me)

Let me see what happens when I paste from Google Docs...


PartSourceQuantityPriceTotal
ELF TagATtiny85Tayda1$1.15$1.15
DIP SocketTayda1$0.12$0.12
Zener Diode 3.6VTayda2$0.04$0.08
Resistor 68ohmTayda2$0.01$0.02
Resistor 1.5KohmTayda1$0.01$0.01
TOTAL PER$1.38

Well that looks ok in the editor.  It's obviously the parts cost list of the Lost and Found Fidget that I have just re-dubbed... the ELF Tag for "Electronic Lost & Found Tag".

Obviously these are not expensive in any sense except of course for the labor.


Sunday, June 29, 2014

Sunday is Funday

Well I have started working on the PCBs for all of the Lost & Found Fidgets I am planning to make...



As such, I am getting good at making the boards.  These three are waiting for some components I should get later this week.  I have added everything that I do have, so that they will be quick to finish when the parts arrive.  The question is how many of these can I get made before then.  Here are the steps I have to perform for each one...


  1. Cut out the front and back print outs (5 min)
  2. Polish the blank PCB that has already been cut to size and clean (5 min)
  3. Iron the front and back patterns to the PCB (15 min)
  4. Soak in water, scrub to remove paper residue (15 min)
  5. Etch (30 min)
  6. Scrub excess toner away (5 min)
  7. Drill, grind and smooth (20 min)
  8. Solder components (20 min)
  9. Clean and dry (5 min)
Total Time: 2 hours (per board)

For the next set of boards, I am going to try using the White Vinegar, Hydrogen Peroxide and Salt solution to etch the boards.  The bottle of Ferric Chloride I purchased from Radio Shack some time ago is about depleted.  It has taken on a nasty greenish tint, but actually still seems effective at etching.  I am just anticipating the move to a "cleaner" etchant because it is cheap and not as toxic.


The Trials of Toner Transfer

I decided to do a couple of boards this evening and had trouble with one of them (again) in the toner transfer step.  In both cases, the toner was not totally transferred and I had to start over. Very frustrating.

It seems I had not ironed the pattern well enough so next time I will have to make sure I do a more thorough job.  Perhaps I will go out tomorrow and get that laminater after all.

On the software side, I have been working on some sort of "light alarm" sketch.  I want to utilize the features of the Sound-Sensor board which means something that uses...

  • 2 Buttons
  • 1 Buzzer/Sounder
  • 1 Light-Dependent Resistor
  • 1 Thermistor
or at least a couple of the i/o.  

So far all I have is an alarm sketch that will trigger if the light changes from a specific setpoint.  To set the setpoint, just click the inner button.  This has the double action of clearing the alarm condition and silencing the buzzing.  It works pretty well, so I will probably keep this version.

What I will work on next is a "delayed" setpoint sketch that will wait... say ten seconds before taking the "sample" light level.  This way the device can be "armed", placed in a closed container and used as an entry alarm.  You could place it in a cabinet or a drawer and sound an alarm if it is opened.

I need to try and imagine some more sketches to use the board.  I should probably work on seeing if I can calculate the actual temperature from the thermistor.  That way I could build a "comfort" alarm that could use real values such as 72-76 degrees.

Ahh I should sleep soon.  Maybe I will dream of something!  

Saturday, June 28, 2014

Weekend News

Here are some updates from this weekend so far...

I was able to figure out the problem with my Sensor Board and it was something really simple.  It seems the trimmed leads at the bottom of the sensor board were touching the tops of the pin selection headers of the Sound board.  Once I trimmed them a little more, the sensor board began reporting consistently.  Problem solved.

I finished the Lost & Found Fidget for Seth today.  I had run out of 3.6V Zener diodes, so I was waiting for my new order from Tayda to arrive.  But I found a pair that I had removed from an earlier board and they worked great.  So that leaves around 12 copies left to make for my co-workers.  I have most of the boards cut and the patterns printed, so I will begin transferring patterns en masse at some point.  I should do this so that I can etch multiple boards at a time.

One thought I had was to purchase a laminating machine for transferring the pattern to the copper-clad.  Right now I use a small iron and it does takes some time for each board.  Especially these double-sided boards.  I may look at a cheap one ($30) from an office supply outfit, to see if it is worth the purchase.

Thursday, June 26, 2014

Cleaning Out The Closet

Well for a change, I am going to have a crack at this at a decent hour.  Maybe my thoughts will be more clear (ha ha).


Versions
Anyway, the first item I wanted to bring up is... what I am doing with all of these "iterations" I am going through of this thing I am calling a "fidget".  Well the best I can explain it I like the process of an "iteration".  It involves building the schematic and laying out the circuit in the CAD software.  Then I get to build the object I imagined.  I enjoy the steps I have to go through to make the device.  I prefer a more evolutionary style of gradually changing the form and function... and because I can leverage previous successes to increase the likelihood of the new device working.  

I guess I find it frustrating when electronics do not work the way you want them... it's sometimes hard to figure out why and that makes me feel a loss of control.  Something I am not comfortable with.  But when I build something, because is not much different than what I have built before, it usually works.

From another angle, I am also testing different configurations so that I can evaluate a device that I could build to give away as gifts to friends, co-workers, etc...  So there is some reason for all the different forms I have tried.

And it has all come down to this...

Original Fidget Device




    • Set of 5 boards
      • Base Board
      • Comm Board
      • POV Board
      • RGB Button Board
      • Sensor Sound Board
    • 9v battery and connector
    • DVD with software
I have given two set away so far... to James Rowe and Carlos Beltran... and I have a third set ready to go to James Sorensen out in Utah.  I am still not sure what to do with the fourth and last set.

Fidget Experimental Set


    • Set of 8+ boards
    • Three passthrough boards
    • Four top boards
This is my personal experimental set.  I have an extra set that I could give to my father.  I don't think he would find the Original that compelling.

Fidget Lost & Found Fob



This is the last revision that has removed ALL extra features.
    • Minimal components
    • Built-In USB Male connector
    • One essential function
This is the final version that I have come up with in the last few days.  It is essentially an electronic lost and found tag.  You plug it into a computer and it starts up notepad and begins typing out a pre-defined message.  I think it will be my best choice for the rest of my co-workers that did not already get something. Maybe.

Sensor Board Troubles
As I have been experimenting with the thermistor and LDR I have noticed some anomalies with the values that I am reading.  What seems to be happening is that using the two analog inputs A0 and A1 does not give accurate values for either when both are read.  If only one is read then the values come out as expected.  Why is this?

I have tested this on my ATmega328 (Arduino) and it works as expected.  So I do not know what is going on.  There are some hints on the interwebs but nothing that has solved my problem.

The next step will be to test the two other analog inputs... with the only problem being...I cannot get the analog values anymore via the DigiUSB library... because they need those pins.  So I will have to devise some sketches that can indicate the values some other way.  One possibility is with LED lights... such as the Charlieplex shield that I have.
Probably the most fun solution will be via serial communications to an LCD screen.

Anyway, until I can figure some things out, the sensor will have very little to show in the way of sketches.  But I will work on getting some ideas up and running...
  • Drawer/Cabinet Alarm
  • Temperature Alert
  • Light Organ

Chalieplexing Success
On a final note, I was able to decipher the charlieplexing sequence and reliably control six LEDs from three data lines.  I was able to make this neat little die roller, using the button board.  I used the library found here.





Wednesday, June 25, 2014

The Daily Report

Only a few more minutes to get this report in...  :-)

Well I finished the fidget for Lisa and here it is...



I am pretty sure this would be the way I would go for the rest of the crew.  The only thing that bothers me is the USB connector.  While on one hand, it is very convenient, on the other it is rather "unprofessional".  I have seen through-hole, right angle USB A male connectors available on Aliexpress, but the do not seem common.  Although if the intent is occasional use then the connector is quite appropriate.

Monday, June 23, 2014

Weekend Update

I was able to get a lot done this weekend... and probably did not sleep enough.

I burned four small DVDs with the Fidget software.  That should be enough copies for the sets I am giving away.  The question is... how many sets and I going to make and give away?  As I consider my friends and co-workers that I believe would enjoy such a gift, one name comes to mind.  Matt maybe... he seems to have wide interests.

I was also able to complete all the boards I had etched earlier.  That gives me two complete OSI sets, a complete Fidget set and some extra boards.  I should focus now on developing apps for the boards.

Finally, I constructed the key chain version of the clone.  I guess it is no longer a clone of anything anymore.  Here it is...



 It is a small board and has very little in the way of components... but is very versatile.  This first one I made for a co-worker and I think it turned out well.  I had to use double-sided copper-clad to get the traces for the USB connector.  Otherwise, the components would have to face down.  I was originally worried about alignment of the wire vias between the front USB pads and the back side copper.  Fortunately, this worked out pretty well by pre-cutting the PCB and using the edge lines as cutting guides.

The only problem I have is that of labor.  It took a good chunk of the day for the build and that is too long for some 17 odd copies that I need.

Sunday, June 22, 2014

Late Nights

Well its late again and now is when I think to post.  The problem is that I am so tired by now the posts become rather lame.  I have to type this on a little bluetooth keyboard which is not terrible... but not the best for long fits of writing.

I will try to do a decent job this evening (or morning) so that the post would be worth reading.  Not that anyone would.

First news is that for my birthday I received an awesome drill press tool for my new Dremel!  It makes drilling the boards go much faster... and the quality of the work is much better.  The only thing I need more of are the recycled carbide drill bits.  I looked for them at harbor freight but was unable to find any. And now, I just encountered a time suck at ebay.com.  I think I will order from there, but will have to first check what sizes I need.  I know of at least three I will need to check.


  • Resistor leads (thinnest)
  • LED leads (medium)
  • Header Pins (largest)

I will see if I can identify these sizes based on what I have left.  Then I will search ebay again... although I liked the stuff drillman1 had.

Second item... I was able to get several boards done and even have two more sensor-sound boards left to drill and assemble later.  I will have an extra set that I can give to someone at work.  I also have the two extra boards ready for James and Carlos.  I should give them disks at that time as well.  So that is what I need to do today... burn four copies of the Fidget software.

Third item.  I am strongly considering making "bare-bones" type device that goes on a keychain.  It would basically cost less than $2 and would be personalized in the etching process.  That would be something I could actually accomplish. I could load an informational message that included a link to a zip with everything on it... including instructions on how to change the message.

So that is all for now.  I will post in several hours.

Friday, June 20, 2014

Keychain Version

Here is a real quick post of my keychain version.  It has a nifty little program that, when plugged into a Windows computer, it will start notepad and begin typing out a pre-defined message.


Thursday, June 19, 2014

And Even More Parts

Today, I was happy to see that the Tayda order was arriving.  Now I have plenty of parts for boards I need to make.  Tonight I made one Sound board and one Sensor board.  These are based on the experimenter design that I am following at the moment.

What happened was that I realized I actually have two goals...

  1. The DIY Fidget
    A small electronic curiosity that was simple and easy to use and play with
  2. The DIY One-Square-Inch Stacking Microcontroller
    A versatile experimenting and development oriented microcontroller.

I need to design a final board for the Fidget.  I am thinking I will redo the board to include a piezo, two buttons and maybe a couple of leds.  Here are the pin assignments I am thinking about...

     P0 -> Green LED
     P1 -> Red LED
     P2 -> Button 1
     P3 -> Button 2
     P4 -> Buzzer
     P5 -> LDR (maybe)

But I will have to continue this later.



Wednesday, June 18, 2014

The New Parts Arrive

Well, I am happy to say my orders from Aliexpress arrived yesterday with the small piezo buzzers and the light-dependent resistors.  That's the good news.  The bad news was that 13 out of the 20 buzzers were not working.  At first I thought I had ordered the wrong type and that it needed more voltage, an AC power source or something.  Then later I tried another one and it worked! (Albeit very quietly)  I then tested the whole bag and only 7 of them worked.  Disappointing.  However, I did not pay much... but I did not like the failure rate.

Fortunately the LDR worked great so that can be worked in to the sensor board.  I may have to change the compare resistance to capture the best value range on the analog input.  I am going to use this formula

     Pull-Down-Resistor = squareroot(Rmin * Rmax)

Where the Rmin and Rmax come from testing a few of the LDRs for Minimum and Maximum resistance.

So, I have order a new batch of buzzers from Aliexpress.  Since it was hard to tell if I would get the same result (even from another vendor) I decided to try the big lot-cheap price strategy.  So I ordered a lot of 100!  This time it will run me about $8 but I think the shipping will be a little faster (China Air?).  I can't imagine what I would do with 100 buzzers (especially if they all work).

Anyways, I have enough to start work on the new boards.  The first will be a new sound board with pin selection and passthrough headers.  The next should be a proper RGB board with a selectable blue pin. Fun!

Tuesday, June 17, 2014

Latest Thoughts

Well as I wait for some new hardware to come in, I am contemplating the design, the trade-offs, the options... for future projects and builds.   One idea I had was to actually put the piezo on it's own board with passthrough headers.  I could use the last pin P5 because it is not used on the RGB board.  But then, should I take the POV board down to 5 leds?  I have a CharliePlex Board in the works and that will take 5 pins.  It will have 6 leds and two buttons and I imagine using it as some type of versatile game tool.  You'll be able to roll a die (randomly pick 1-6) or perhaps have a 60 second countdown timer that turned off an led every 10 seconds.  You might wonder why not just use this for the POV stuff.  I am guessing, but I am pretty sure the charlieplexing would not be suitable for POV display.  Anyway, the buzzer/speaker could be an add-on to both boards.  That would leave the sensor board with two buttons, a thermistor and the LDR.  This makes sense for the LDR... it should be on top... just like the RGB led.  One possible problem... if the buzzer is too tall. I just checked and it looks like it may be 8.5 mm tall, which might fit with extra space (the pins don't go all the way in)... but there is also the risk that it fits... but is muzzled.  Oh well... we'll see... one day whenever they come in.

In the mean time, here is a pic of the last USB connector being put to use...


I used my new Dremel to round the corners for putting it on the keychain.  I'll see how well it holds up.  For well under $3 in parts, I think I can experiment.  

I also wrote a nifty little sketch that will have the device emulate a keyboard and ten seconds after it is plugged in, it will begin typing out an embedded text file.  I have it spit out my contact information... like an electronic lost and found tag!

Here is the final board layout...


On another note, since I am out of USB Mini connectors (again) I thought I should order some more.  It turns out that the best deal on Aliexpress was for a lot of 100.  At least while being able to trim 1-2 weeks off of the shipping (hopefully).  The order was shy of $7 so I am not really too concerned... I could afford this kind of mistake.  The connectors ARE through hole so we will have to see how that goes.  The only concern I have is for the small pads... much like the RGB led.  I worked on a KiCAD footprint for the part and I think I have gotten the pads as large as they can be.  The problem is is that I now have to route one of the data lines with a via.  I am not sure if the trade off is worth it.  Again, I will find out when the parts arrive.

Waiting, waiting waiting.....

What to do next?  

Sunday, June 15, 2014

Happy Father's Day

I will have to call my father when this is posted, but to any other fathers out there... Happy Father's Day.  I was lucky enough to receive some wonderful cards and gifts.  Thank you Shelley and Sam!

One thing I got which I am really stoked about is a new Dremel 4000 tool.  It's awesome!  I will use it today, to buff out the PCB for the latest build.  I decided to make another version of the Digispark clone that... well makes it not much like a Digispark or a Trinket.  I guess it could be called my own watered down version of a Attiny85 V-USB microcontroller.  Here in the layout...


If I removed the extraneous LEDs, it could be even simpler... which is kind of the goal.  But for this version, I will keep the little lights.

All Source Code and Program Files Coming Soon

I did an extensive Google search (not really) and settled on Github to host all of my project files.  To get the ball rolling, I have set up the repository here...

      https://github.com/joewez/Fidget/

I only have a few files so far, but look for more as I get the time to organize them and clean them up.  

I am finding that it can be a lot of work taking care of all these things... but not a bad kind of work... but work none the less.  I figure that I am going to have to organize myself a bit so that it less of an effort to post source code, publish pictures, etc...  So bear with me as I stretch my wings online and attempt to fly. 

Saturday, June 14, 2014

Saturday Diversion

For a little diversion, I decided to re-design my "Tinket" clone into a "Digispark" clone.  The original PCB looks pretty bad because my laser printer was just about out of toner.  The traces are grainy and I have had to repair it a couple of times now.  So when it began acting flaky again I decided I would give it another go.  I now have a little more experience with KiCAD so I should be able to do better.  The new toner will certainly help!

Here are the results:






I got rid of the reset button (Digisparks use it as a 6th I/O pin) and added a simple 7805 power supply.  It's not up to Digispark standards but it was what I had on hand.

My copper etching has gotten good enough that I wanted to try using a copper fill to help my etchant last a bit longer.  I had not done it until now because my soldering was just too sloppy.  I would bridge traces and cause all sorts of problems.  But now, I have to say, I am good enough at it that it just is not a problem anymore.  How?

  • Better iron
  • Smaller solder
  • Practice
I still occasionally get too much on a joint... and I really should go back and wick them down... but I am lazy... and there are a lot of things to solder.  Anyway, I have fun and am proud of what I can build.  Now on to my next project...





New Introduction

I have written a short introduction to the microcontroller and it can be found here on google docs...



     LINK

If you have any comments, please let me know.  

I guess I am a little tired of writing so I will keep this short.  It is difficult writing out instructions and explaining things.  And it does not help for me to be so picky.  Ah well I hope you understand.

Thanks!

Friday, June 13, 2014

Need My Hardware

I'm really getting anxious to receive my piezo speakers and light-dependent resistors.  I already have a revision of the PCB done based on the online specs (the last images of my last post).  What I also included was the input of a thermistor... which can be used to measure temperature.  So I am calling the board the Sensor Sound Board.  I will probably rename this to just Sensor board, since technically the piezo could be an input as well.

For thermistors, I ordered from Tayda Electronics and expect it within a couple of weeks. I did not feel any need to rush, because the AliExpress orders will arrive at some unknown time anyway.  I basically got 20 little speakers for less than $4!  So I will wait until they arrive. 

Here is my order for Tayda...

Product NameSKUPriceQtySubtotal
Subtotal$16.73
Shipping & Handling$2.90
Use your Store Credits$0.0000
Grand Total$19.63

Copper Clad Board PCB Single Side 6x6" Phenolic

A-5162$1.89Ordered: 1
Shipped: 1
$1.89

Premium Jumper Wires Male / Male 200mm Pack of 40

A-2376$3.99Ordered: 1
Shipped: 1
$3.99

PUSH BUTTON SWITCH LATCHING DPDT 0.5A 50VDC 6x6mm

A-330$0.08Ordered: 10
Shipped: 10
$0.80

Mini Relay SPDT 5 Pins 5VDC 10A 120V Contact

A-1016$0.62Ordered: 2
Shipped: 2
$1.24

LED UV 5mm Ultraviolet

A-1155$0.10Ordered: 10
Shipped: 10
$1.00

Stackable Header 6 Pins 2.54mm

A-1048$0.14Ordered: 10
Shipped: 10
$1.40

40 Pin 2.54mm Single Row Pin Header Strip

A-197$0.15Ordered: 10
Shipped: 10
$1.50

10K OHM NTC Thermistor 5mm

A-409$0.12Ordered: 10
Shipped: 10
$1.20

1K OHM Trimpot Variable Resistor 6mm

A-2509$0.06Ordered: 10
Shipped: 10
$0.60

10K OHM Trimpot Variable Resistor 6mm

A-2514$0.06Ordered: 10
Shipped: 10
$0.60

LM386 LM386L Audio Power Amplifier IC

A-206$0.23Ordered: 2
Shipped: 2
$0.46

2 Pin 2.54mm Single Row Female Pin Header

A-1057$0.04Ordered: 10
Shipped: 10
$0.40

Tact Switch 6*6mm 7mm Through Hole SPST-NO

A-863$0.04Ordered: 10
Shipped: 10
$0.40

Coin Battery Holder CR2025 and CR2032

A-869$0.10Ordered: 1
Shipped: 1
$0.10

DS1307 Maxim 64 x 8 Serial Real-Time Clock IC

A-254$1.04Ordered: 1
Shipped: 1
$1.04

32.768 kHz Crystal Cylender 3 x 8 mm

A-1592$0.11Ordered: 1
Shipped: 1
$0.11


That's almost 100 items for less that $20.  Nice.