0

I've designed an PCB and due tot the delivery times, I kinda want to order it right now. I don't yet have the components, so I haven't actually tried it on a breadboard.

Now I'm unsure if the PCB would work, as this also is my first try in PCB design.

It's a single-sided PCB. All parts (should be) through hole. I would be using SoftwareSerial since the ATTiny does not have serial (Rx/Tx).

[TL:DR] Would this PCB work?

Some points of which I'm unsure, or might be a problem:

  1. Is the spacing of the board/lines to other components/side big enough?
  2. Should I use a copper/ground fill? Which and why?
  3. Are the rounded-off traces actually better as sharp edges?
  4. It says: 36mm by 15mm isn't this too small to fit all those components?
  5. Can I actually use the RESET pin as other functions (without changing fuse bits)?
  6. Doesn't it need any resistors? I've seen some on the RS485 breakout boards.

Breadboard

Breadboard

Schematic

Schematic

Layout

Layout

File

If someone needs the file: It's opensource, no restrictions. Would be nice to give me some credits/donation, but you can freely use it for even commercial projects. Download below:

https://www.dropbox.com/s/lggjg5fxd6s3kqc/ATTINY485.fzz?dl=0

Some credits to Nick Gammon, I've used his schematics as a reference (especially on the TX enable pin, which was quite smart, using only 1 pin).

Version2!

schematic

layout

Changes: - replaced the "V" shape. - pull-up on the reset pin. - decoupling capacitors

EDIT: It's better not to use a pull-up resistor on the reset line. The ATtiny85 has this internally.

  • 1
    You could use the reset pin to make the chip reset. You can distinguish between resets and power-ups. So as long as your program doesn't require any variables to need to remain, you could add a button to the reset pin and make it do something. Or if it does you could use it to change some settings. E.g. changing baudrate. – Gerben Mar 2 '16 at 15:21
  • @Gerben interesting idea, but I was looking to use the pin for UART. I think I'm going to use the MISO pin, since I don't have to receive data from the slave device. I might get one of those HVSP, since that way I can actually get full UART and full SPI. Which would be awesome for a RS485 to SPI converter. – Paul Mar 2 '16 at 16:04
  • 1
    Version 2 is flipped. Are the orange traces on the top or bottom layer. Having a mirrored board would be a problem. Though with through hole this can be fixed by soldering to components on the same side as the copper. But his a lot harder. Especially with header, where you have to temporary remove the plastic for soldering. Always double check this. I've made this mistake a few times. – Gerben Mar 2 '16 at 16:34
  • @Gerben ah, yea, I switched to bottom view, I'll check it when I can. Thanks for the heads up :) – Paul Mar 2 '16 at 17:03
2

Would this PCB work?

Possibly, sometimes, under some conditions. See below.

Is the spacing of the board/lines to other components/side big enough?

Plenty.

Should I use a copper/ground fill? Which and why?

For your circuit there is no real electrical reason to use a ground plane. However, many fab houses like you to use at least a copper fill in the empty areas since it means less copper has to be etched off the board, and so their etchant lasts longer before it needs to be replaced.

Are the rounded-off traces actually better as sharp edges?

Yes. Always try to avoid right-angles. Sharp corners radiate EMI noise, mitred corners radiate a lot less.

It says: 36mm by 15mm isn't this too small to fit all those components?

Not in the slightest.

Can I actually use the RESET pin as other functions (without changing fuse bits)?

You can only disable the RESET functionality of the RESET pin using the fuse bits - and then it becomes somewhat difficult to program: you need a HVSP (High Voltage Serial Programmer) to get it back into programming mode again. This blog post details how it is done.

Doesn't it need any resistors? I've seen some on the RS485 breakout boards.

Your circuit isn't complete. There are a couple of things missing that you need to add, and some that you might want to add.

The things that are missing:

  • Decoupling capacitors (100nF) on the power pins of both chips
  • You should have one larger (10µF typical) reservoir capacitor at the power entry to the board
  • (Assuming RESET is enabled) Pullup resistor on the RESET pin

The things you might want to add:

  • RS-485 bus termination resistors

The latter are optional depending on where in the bus your module is. You need termination resistors at both ends, so it is common to have them on the boards but with jumpers to enable/disable them.

| improve this answer | |
  • Setting fuses can't be done with an USB-ISP? And good catch on the termination resistors & decoupling capacitors. In this case, one big capacitor on the power-in line wouldn't be enough? I'm not planning on using a switching circuit and the IC's don't have a big transient load? Is it more of a cherry on the top as a requirement? – Paul Mar 2 '16 at 15:18
  • 1
    Sharp edges can also be problematic in etching. Mostly a problem with home etching. But with the thickness of the traces and the spacing between them, it doesn't really matter if there is a bit more copper etched away in the corners. – Gerben Mar 2 '16 at 15:18
  • 1
    @Paul Yes, you can set fuses with a low voltage ISP, but once you have disabled RESET you can no longer use the low voltage ISP since it relies on using the RESET functionality to enter program mode. So once you have done it you can't undo it without a HVSP to enter program mode through the secondary High Voltage method. – Majenko Mar 2 '16 at 15:20
  • @Gerben Yes, right-angles can trap copper in their inner angle, but sometimes right-angles are the best you can hope for - for instance, always use T junctions; never join a trace to another at an acute angle or you get a nice place to trap cruft. – Majenko Mar 2 '16 at 15:22
  • 1
    @Paul The large capacitor is to deal with larger power droops caused by low speed switching, such as the communication drivers. The small capacitors are there to deal with the high speed transients caused by the internal circuitry of the chips. They cover different frequency ranges, so they are both needed. The ATTiny especially. It is a switching circuit whether you like it or not - it has a clock and things inside switch on and off very fast. – Majenko Mar 2 '16 at 15:24
2

Is the spacing of the board/lines to other components/side big enough?

Looks ok. You might be able to squeeze it a few mm smaller each way, although since the board already is small, that probably would make little difference in cost.

Should I use a copper/ground fill? Which and why?

Copper/ground fill on a single-sided board won't make much difference for this circuit. It would be reasonable, however, to make the ground traces two or three times as wide as they are.

Are the rounded-off traces actually better as sharp edges?

If you mean, make square corners rather than the 45° turns as shown, either way will make little difference for this circuit. The 45° turns are ok.

Note, sharp V-notches, like the one inside the traces at pin 2 of the Tiny85, are undesirable; I think they etch less accurately than more-open junctions do.

It says: 36mm by 15mm isn't this too small to fit all those components?

Looks like there's room to spare and the board could be made slightly smaller.

For homemade boards that are drilled using a hand-cranked XY table, keeping drilled holes on the intersections of a .1"x.1" grid is a good idea. For commercially-made boards, it's less important but can help with assembly.

Edit: Regarding “Making ground traces bigger makes sense, but does that also mean 5V traces should be bigger?”, yes, both ground and power traces typically should be large, if board layout allows. It's desirable that those traces have low inductance and it's ok to have high capacitance between ground and power traces.

Regarding how long it takes to get your PCB back from a manufacturer: The PCBshopper.com website makes it easy to compare time vs cost across a range of manufacturers. For small circuits like yours, OSHpark is an inexpensive choice (you would get three double-sided boards for under $5, in about 15 days). If you need up to about 10 medium-size boards, Maker Studio is quite economical but standard delivery may be slow (2-3 weeks). If you are in a hurry and need a larger number of boards, consider (eg) PCBway. By paying $25 for DHL shipping, you can have a batch of boards in 9 or 10 days – about three days for manufacture and a week for delivery. The pictures below show an example of PCBway's order tracking, the left side at about two days after the order was placed, the right side 11 hours later. This order for 50 each 36 mm x 56 mm two-layer boards with silk both sides cost $27 for manufacture and $25 for delivery.

enter image description here

| improve this answer | |
  • Good catch on the V shape. The size question was quite silly, I can't yet imagine it to be 3,6cm long (which isn't a lot). Making ground traces bigger makes sense, but does that also mean 5V traces should be bigger? (They're 24 mil, can't make them bigger in fritzing?) – Paul Mar 2 '16 at 15:27
  • 1
    @Paul, see edit – James Waldby - jwpat7 Mar 2 '16 at 17:43
  • I went with OshPark since they've got a Gerber viewer built in (so I could re-check each layer). Pricing was around 5x better as Fritzing and will get some nice purple-colored boards, without shipping cost. I now actually realize I don't have any programming headers or reverse current protection. But I guess I'll make it on a breadboard beforehand anyway, and take a good look when wiring. – Paul Mar 3 '16 at 8:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.