SparkFun Forums 

Where electronics enthusiasts find answers.

Have questions about a SparkFun product or board? This is the place to be.
By n1ist
#67247
It's hard to tell from the layout, but it looks like your power and ground traces are way too thin and too long. Also, the "ground" plane (which doesn't appear to be tied to ground) seems to be broken into isolated islands.

As you mention, you need bypass caps right next to all of the ICs. I also don't see the usual RC circuit for reset.

There's a trace running very close to the upper left mounting hole. I would move it so it wouldn't get damaged or shorted by the hardware.
/mike
By azmodean
#67250
I'll post my design files (eagle) tonight, after making a few recommended corrections.

In a previous design I had the same comment about the power and ground lines and had addressed it, but I had forgotten to do the same with this design, thanks.
By Mike, K8LH
#67291
For the P-Channel MOSFET I would use something with specs' similar to the Vishay Si2323DS (http://www.vishay.com/docs/72024/72024.pdf)...

I would also like to see the schematic. Could you post it in a graphic format or as a PDF for those of us who don't use Eagle?

Kind regards, Mike, K8LH
Last edited by Mike, K8LH on Thu Feb 26, 2009 5:15 pm, edited 1 time in total.
User avatar
By bigglez
#67299
Mike, K8LH wrote:Could you post it in a graphic format or as a PDF for those of us who don't use Eagle?
The student version of EAGLE is free. It will allow the
viewing of any files from higher versions of EAGLE.

It's a lot of extra work to generate duplicate formats and
upload files, you know.

If the OP was not using EAGLE, and I had to do more
work to see their project files I'd pass on helping them.
By Mike, K8LH
#67300
bigglez wrote: It's a lot of extra work to generate duplicate formats and
upload files, you know.

If the OP was not using EAGLE, and I had to do more
work to see their project files I'd pass on helping them.
Are you saying you think it's unreasonable for me to ask the OP to do "extra work" when I'm willing to do the "extra work" to review his design and share my knowledge and expertise?

Mike, K8LH
User avatar
By bigglez
#67301
Mike, K8LH wrote: Are you saying you think it's unreasonable for me to ask the OP to do "extra work" when I'm willing to do the "extra work" to review his design and share my knowledge and expertise?
Not at all! Perhaps you need non-EAGLE files as you
don't have EAGLE, and you think its expensive?

Also, the OP is now asking for guidance on an EAGLE
specific step in their project. Expert EAGLE help is
unlikely to come from someone without a means to
read his or her EAGLE files.
By Mike, K8LH
#67303
The OP was not asking exclusively for Eagle expertise.

Are you trying to "pick a fight" or do you have some specific problem with me that you'd like to discuss?

Mike McLaren, K8LH (Michigan, USA)
User avatar
By bigglez
#67304
Mike, K8LH wrote: The OP was not asking exclusively for Eagle expertise.
Agreed!
However, to complete their project they do need to
clean up their PCB design, which is done in EAGLE.
Mike, K8LH wrote:Are you trying to "pick a fight" or do you have some specific problem with me that you'd like to discuss?
Nope! I thought you might like to know that the demo
version of EAGLE is free, and will read the OP's EAGLE
files (when they are posted). Nothing more.

BTW, if you come up to speed on EAGLE you'll
have access to a lot of material on this site.
By Mike, K8LH
#67309
azmodean,

I just wanted to see how you're connecting the 16 bit serial-to-parallel constant current sinking driver. There are a couple ways to do it. I showed the Output_Enable and the Latch pins connected together and driven by the PWM output but you might want to use a seperate pin for each.

As for adding switches, you could take advange of the row driver pins and construct a single pin row driven switch matrix since only one of those five pins will ever be low at any given time. Sample one switch each interrupt cycle when you're updating the display (each switch sampled once every 5 msecs), perhaps something like this (using parallel switch logic);

Regards, Mike
Code: Select all
//
//  ISR, 1 msec interrupts
//
//  update display, sample switches, new press beep
//
void isr_display()
{ int data;                  //
  pir1.TMR2IF = 0;           // clear timer 2 interrupt flag
  rownbr++;                  // bump row number, 0..4 (led array index)
  rowsel >>= 1;              // shift row select bit
  if(rownbr == 5)            // if end of display refresh cycle
  { rownbr = 0;              // reset row number and
    rowsel = 0b10000000;     // reset row select bit
  }
  data = led[rownbr];        // update driver shift register
  for(i = 0; i < 16; i++)    //
  { datpin = 0;              //
    if(data.0) datpin = 1;   //
    clkpin = 1;              //
    clkpin = 0;              //
    data >>= 1;              //
  }
  portb = 0b11111000;        // blank the display
  latpin = 1;                // latch shift register data onto outputs
  latpin = 0;                //
  portb = ~rowsel;           // display new row

  sample &= ~rowsel;         // clr switch bit at "rowsel" position
  if(sw_pin == 0)            // sample active low switch input pin
    sample |= rowsel;        // set switch bit at "rowsel" position

  sample ^= swlatch;         // changes (press or release)
  swlatch ^= sample;         // update switch state latch
  sample &= swlatch;         // filter out "new release" bits
  if(sample)                 // if any "new press" bits
    beepctr = 32;            // task a new press beep
  swflags ^= sample;         // toggle sw flag bits for Main

  if(beepctr)                // if beep task running
  { porta ^= 1<<spkr;        // toggle speaker (500 Hz tone)
    beepctr--;               // dec 32 msec beep counter
  }
}
Image
Last edited by Mike, K8LH on Fri Feb 27, 2009 6:43 am, edited 3 times in total.
By azmodean
#67346
Here is the new board layout:
Image

Here is the Schematic and the Project Files. I'm linking the schematic image because if I make it small enough to fit on the forums properly the text is illegible, so link is to a large png.

Alright, a bit closer to being fully populated now, I added the backup battery holder for the RTC, reset circuit, enlarged the power/ground lines to 20mils, removed the ground plane for now, replaced with a plane just around the crystal and RTC, and moved some of the transistors to be near the LEDs they are feeding.

Now that I think of it, that extends the signal lines to them as well as the power lines, so I'm thinking there's probably no benefit other than distributing them around the board to make the upper portion less crowded.

Known Issues:
Right angles in traces
Need a diode I think between RTC and battery to keep the RTC from trying to recharge the battery. Must consult datasheet.
"extra" LEDs scattered around haphazardly, trying to figure out if I have a use for any of them.
A resettable fuse and/or power diode (avoid damage on reverse polarity DC connection) would probably be a good idea, and I seem to have some spare room now. Oh, and a power switch.
Still haven't added any buttons (other than reset),
Since I seem to have the room now, I might as well increase the size and spacing some of my wiring.


Questions:
Still wondering if it is worth the trouble to rearrange all the LEDs to make the overall trace length shorter, also I could probably reduce the length a bit more by carefully reassigning the traces going into the driver.

As for connections to the driver, I currently have all the pins connected separately for more flexibility, though I'm not sure if I really need Output Enable switched separately.
User avatar
By bigglez
#67351
Mike, K8LH wrote:Image Deleted
Please limit your images to 600 pixels width (or smaller)
- larger PIX distort the forum pages for many of us.
By reklipz
#67354
azmodean wrote:Here is the Schematic
Is it just me, or are those LEDs all reverse biased?
By Mike, K8LH
#67361
Your layout is looking very nice...
As for connections to the driver, I currently have all the pins connected separately for more flexibility, though I'm not sure if I really need Output Enable switched separately.
You can tie OE to ground if you like. I only drive it with the PWM signal when I want to control overall display brightness.
By Mike, K8LH
#67363
bigglez wrote:
Mike, K8LH wrote:Image Deleted
Please limit your images to 600 pixels width (or smaller)
- larger PIX distort the forum pages for many of us.
I apologize. Some Forums (ie.; Sourceboost, Instructables, etc.) automatically resize graphics to fit your broswer width. That feature (and others) seems to be missing in this Forum.
By azmodean
#67378
reklipz wrote:
azmodean wrote:Here is the Schematic
Is it just me, or are those LEDs all reverse biased?
Holy crap, you're right. I had put together this version of the design with a TLC5920, but dropped that once I realized that it was a part I'd rather not try to use with the equipment I have available (0.025" lead spacing) and also there doesn't seem to be a DIP package available for prototyping. Also, I'm not totally sure the LEDs would not have been reverse-biased in that configuration as well.

thanks