Saturday, June 28, 2014

Moment of Truth; Drum Roll, Please; It's...

This story is longer than it should be, but... well, there is no "but."

Finished all the soldering, finally.  left the ribbon connector for last and thought it would be much more difficult than it was.  the soldering was probably not the best in some places, but it is done.

So I had low expectations when I plugged the USB cable into the duino and then into the laptop.  The red LED signifying a USB connection lit up on the duino, but Windows wouldn't recognize it.  I fiddled with a few whatnots and whatevers with no luck. I was convinced that I had a fatal short that fried the processor and was mentally preparing myself to find a new hobby.

I reinstalled the Arduino IDE and drivers and tried plugging in again, this time both of my yellow LEDs lit up for a minute or so, then all of my LEDs turned on and off somewhat randomly before staying off.

I should mention that between my original breadboard prototype and this perfboard version, some of the pins were changed, so I had to change around the code to account for this.  But when I plugged in, the duino was still running the old code, which probably explains the LED madness.

I uploaded the latest sketch and fired up the serial monitor in the IDE.  The "play state" LED set had red lit up but the "Server connection" LEDs were all off.

I typed "C" into the serial monitor, and the dartboard echoed "C" back, yet no LED action. "Q" got an "X" response.  A good sign that the duino wasn't fried and serial communication was functioning.  "P" got an echoed "P" and the play state LEDs went to yellow and then to green, a very good sign. Another "Q" inquiry prompted a "P" response.  Splendid, but now the big test... The Board!

A few random presses on the board resulted in serveral "H"s hollering back from the board to the serial monitor.  This revealed the second issue: the"H"s should have been followed by the point value and multiplier of the wedge being pressed. Soon I identified two more issues: one of the two halves of the triple ring was not registering, nor was one pair of numbers.  Other than that, everything else seems to work!

I consider this a victory.  I have a few relatively minor things to track down... The missing points and multipliers are likely a software bug introduced when the pins were switched around...probably the same with the second set of LEDs, since at least some of them were working to some extent under the original code.  Fixing this may also fix one of the other board hit problems.  I suspect a bad solder may be the cause of one of these things, but this should not be very difficult to track down and fix.  Oh, and I just need to wire up the speaker, but that's hardly a big deal.

It's pretty hard to believe that in a few days this thing could be hanging on the wall and all I have left is the game software (which will probably never be"done")...and not quite the end of June
- almost, but not quite.

Sunday, May 4, 2014

Step by Step (NKOTB)

Slowly and painfully,  but forward I go. Frustration smothers experience, yet close,  I am close. 9 points torn in space and time, lacking what they lacked.  A white hot iron, silver, molten blood. One step from, from done. Ugly blobs, globs, lobbed and flawed. Yet continuity continues, no short, possible it might work. Step by step.

Sunday, April 13, 2014

Back on Track

Finally was able to sit down and solder for a little bit yesterday.

Completed all connections from the 589 parallel outs to pull down resistors, from the 589 serial out to 'duino, grounds, voltage and control lines from 'duino to 589.

Remaining work:

  • control lines from duino to 595 set
  • ground from 595 set to duino
  • voltage from duino to 595 set
  • line from duino to speaker resistor
  • ground second set of LEDs to duino
  • and probably should expose some convenient pins to attach the speaker wires

Wow.  All of the sudden, the workload looks reasonable and testing is in sight.  I only have 2 months left to finish on schedule.

I am still not very confident in my soldering and hope testing isn't overwhelmingly painful, requiring a bunch of resoldered joints.  I am afraid that a few dart hits will cause some of the joints to fail.

I am really liking the idea of a printed board if there is a v2.

Sunday, April 6, 2014

Perf Board Diagrams

The diagram I made last night is very cluttered, so I broke it out into a series of specific diagrams that are easier to follow:
The full rats nest

Parts:
  • 2 x 74HC595 Serial-Parallel Shift Register
  • 1 x 74HC589 Parallel-Serial Shift Register
  • 6 x 5mm LED 
    • 2 x red
    • 2 x yellow
    • 2 x green
  • 15 x Resistor
    • 1 x 100 Ohm
    • 6 x 220 Ohm
    • 8 x 10 k-Ohm
  • 1 x Arduino
  • 1 x Electonic Dartboard
    • 1 x 20 pin Ribbon Connector in 2 rows of 10
    • 1 x Small Piezo Speaker


Here is the Shopping List exported from Fritzing:
AmountPart TypeProperties
1Piezo Speaker
1Generic shrouded header - 20 pinspackage THT; hole size 1.0mm,0.508mm; row double; form ♂ (shrouded male); pins 20; pin spacing 0.1in (2.54mm)
2Green LED - 5mmpackage 5 mm [THT]; leg yes; color Green (555nm)
2Yellow LED - 5mmpackage 5 mm [THT]; leg yes; color Yellow (595nm)
2Red LED - 5mmpackage 5 mm [THT]; leg yes; color Red (633nm)
1Arduino Micro (Rev3)type Arduino Micro (Rev3)
1100 Ω Resistorpackage THT; tolerance ±5%; bands 4; resistance 100Ω; pin spacing 400 mil
810k Ω Resistorpackage THT; tolerance ±5%; bands 4; resistance 10kΩ; pin spacing 400 mil
6220 Ω Resistorpackage THT; tolerance ±5%; bands 4; resistance 220Ω; pin spacing 400 mil
174HC589package DIP16 [THT]; type 74HC595; variant variant 1
274HC595package DIP16 [THT]; type 74HC595




Voltage (red) and Ground (black)

ColorComponentConnectionPinComponentConnectionPin
Red'duino5v5v>74HC589vcc16
>74HC595-1Master Reset10
>vcc16
>74HC595-2Master Reset10
>vcc16
Black'duinogndgnd>74HC589gnd8
>Output Enable10
>74HC595-1gnd8
>Output Enable13
>74HC595-2gnd8
>Output Enable13
>LED (x6)Cathode-
>Piezo SpeakerNegative Terminal-
>10k-Ohm Resistor (x8)
[pull-down]



Shift Register Control:
Shift Clock (blue), Latch Clock (yellow) and Parallel Load (white)

ColorComponentConnectionPinComponentConnectionPin
Blue'duinodigital 5d5>74HC589Shift Clock11

digital 10d10>74HC595-1Shift Clock11

>74HC595-2Shift Clock11
Yellow'duinodigital 6d6>74HC589Latch Clock12
digital 11d11>74HC595-1Latch Clock12
>74HC595-2Latch Clock12
White'duinodigital 4d4>74HC589Parallel Load13

Serial to Parallel - 'duino to Dartboard:
Serial In from 'duino (orange), Serial Daisy Chain (green), Parallel Out to Dartboard (purple)

ColorComponentConnectionPinComponentConnectionPin
Orange'duinodigital 9d9>74HC595-1Serial In14
Green74HC595-1Serial Out9>74HC595-2Serial In14
Purple74HC595-1Parallel Data Out15, 1-7>DartBoardRow 1: 1-81-8

74HC595-2Parallel Data Out6-7>DartBoardRow 1: 9-109-10
Parallel to Serial - Dartboard to 'duino:
Parallel In from Dartboard (brown), Serial Out to 'duino (orange)


ColorComponentConnectionPinComponentConnectionPin
Orange'duinodigital 7d7>74HC589Serial Out9
Brown74HC589Parallel Data In1-7>DartBoardRow 2: 1-71-7


Parallel Data In15, 1-7>10k-Ohm Resistor (x8)
[pull-down]

LEDs and Speaker:
Parallel Out to LED (rgb), 'duino to Piezo Speaker (pink)

ColorComponentConnectionPinComponentConnectionPin
RGB74HC595-2Parallel Data Out15, 1-5>220 Ohm Resistor (x6)

Pink'duinodigital 8d8>100 Ohm Resistor

Silver220 Ohm Resistor (x6)
>LED (x6)Anode+
100 Ohm Resistor>Piezo SpeakerPositive Terminal+



Follower Hoax and Winter Sucks

OK, I think the whole follower thing was a hoax.  Probably someone hired to try to keep bloggers posting or something.  whew!  Things are going to be a lot easier now that nobody is watching again.

I was going to get a lot done over the winter, but winter sucks.  No motivation.  Winter's still trying to linger, but spring is squeezing in enough to matter. So I got a little inspired tonight.

Downloaded the latest version of Fritzing and whipped up an "accurate" perf board diagram:

Well, the "no motivation" thing wasn't entirely true.  I did spend a little time messing with Pygame and OpenGL, 'cause when you are making progress on a project and need to focus on its tasks to make the project a success, it's always a good idea to start more projects.

Sigh.  I'll probably end up posting about the "new" game projects.

Me out.

Monday, February 17, 2014

Still Breathing

So, I'm still here and still of the opinion that I will finish this thing by the end of the summer.

I have done a little bit of work on the game engine over the past month, so will have to check my code into git for posterity.  I am still risking over-engineering the game engine, but we'll just have to wait and see... it might be worthwhile.

I forget just about everything I learned about the circuit and the arduino and the shift registers... and this thing that looks like the pictures in the last post is sitting on my desk, waiting for me to solder some more wires from some parts to some other parts.  Without this blog, it would be very difficult to know what goes where, sooooo, yay blog.

There were actually several page hits last month.... curious why people are looking at this gibberish and if any of it has ever been useful to anyone else.   Hmmm.

Maybe next post I'll have some of the python code checked in and some more soldering done... next soldering session I'd like to finish all the connections to and from the duino.

Trying not to let this project die...'cause I'm not letting myself build a theremin until I get this to work, and you know how much I want to build a theremin.

Sunday, December 8, 2013

Under Pressure

Wow.  A follower.  Now I know exactly how Jesus feels, soooo much pressure.

I did a little more soldering in the past 3 months, but not much.  I am a little down on my soldering skills and intimidated by the reality of soldering it all together.

Hopefully The Follower will encourage me to overcome my fears and inhibitions and soldier/solder on.

My solution to the lack of headroom for the duino in the dartboard case was to order a brand spankin' new boarduino and assemble it without the socket, so the chip sits lower and it all fits in the case.  Not only does  this solve this stupid problem, it also means I have another arduino to play with while this one is busy playing darts.

I soldered the new duino to the perfboard along with all the wiring for the LEDs and the ribbon connector, and most of the grounds.

Next would be the 5v wiring from the duino.  I was thinking - soldering would be so much easier with 3 arms, so anyone who hasn't gotten me a xmas present yet... hint, hint.

I am not certain that all of the connections are wire-to-wire and might be relying on the solder too much in some cases.  Maybe I'll try to head down to the neighborhood hackerspace or makerspace or whatever we have here and get some advice and some help fixing some of the joints that might need fixing.  I have the feeling my current board would be on the cover of "How Not to Solder Your Crappy Project."

I thought about the game engine a little but haven't made much progress there.

I also picked up another cheap-ass electronic dartboard from the local sporting goods store in case I totally ruin this one, or in case I get this working and want to mass produce them (does 2 constitute a mass?).  My local Target just started stocking one for $15 in case things get nutty one way or the other.

This thing has been sitting right next to me on my desk all this time, I just need to do it.

It's been so long since my last post and I didn't go back and read any of them, so I might be repeating some things here.

Hopefully my next post will be soon and hopefully it will report some real progress.