Developing PCB layout

General discussions and questions abound development of code with MicroPython that is not hardware specific.
Target audience: MicroPython Users.
Post Reply
Posts: 81
Joined: Mon Feb 19, 2018 6:31 am

Developing PCB layout

Post by ajocius » Mon Mar 18, 2019 11:51 am

I know this is not direct Micropython question, but related. I do not have knowledge about PCB layout build up. I follow instructions I find online, add capacitors, resistors or other elements as described. However I do not have understanding why do we need them and if I can use element with slightly different parameters. Let's say if scheme I follow uses 200 ohm resistor, but I only have 150 ohm on my hands, I do not understand if that is acceptable or if I risk to damage something.

I have made several ESP32 projects and am happy with them, however I am not sure if I can develop them further. For example: I have connected ds18b20 temp sensor to ESP32 pin, but also used capacitor and resistor as described online. I would now like to add additional sensor and naturally I would add capacitor and resistor the my scheme. What I do not understand if that will impact my first sensor readings. At the end of the day it is all on the same PCB.

I do not search answer to above mentioned example only. I am looking for advice on how can I project my layouts myself. Hopefully there is some smart software for this, if not then some "Electronics for dummies" would be great to browse. Or some forums that questions like that could be posted?

Posts: 288
Joined: Sun May 04, 2014 8:54 am

Re: Developing PCB layout

Post by Turbinenreiter » Mon Mar 18, 2019 2:35 pm

This is a pretty hard question.

Have you ever learned the fundamentals of electronics, i.e. at school? Like what is a resistor, what is a capacitor? Basic laws, like U = R * I and stuff like that?

This is the first level of knowledge you need and I guess this is taught at most schools.

After that, you have two options - going deeper into the physics of electronics or going towards the application side. On the application side you can get by with a lot of "rules of thumb", best practices and simplified models. From there you can learn the physical reasons on a case-by-case base.

Let me try to give you some keywords that you propably can easily find online material:

voltage dividers (here it would be a really bad idea to change resistor values)
pull-up and pull down resistors (here it's fine to change resistor values)
decoupling capacitors (sometimes the value is more important, sometimes less)

I guess these are most common kinds of passives you will find starting out.

For designing circuits there is a couple of options. For a complete starter, Fritzing is an option, although many people (like me) don't really like it. @deshipu however makes awesome designs using it, and it is really simple to use for beginners. The other free and open source option is KiCAD - which is very powerful, but harder to use.

Posts: 81
Joined: Mon Feb 19, 2018 6:31 am

Re: Developing PCB layout

Post by ajocius » Mon Mar 18, 2019 3:12 pm

Thanks, I do have basic understanding from school, just like you described: (Like what is a resistor, what is a capacitor? Basic laws, like U = R * I and stuff like that?). I did also soldered several projects, but only following predefined set of components and layout. I have read about Fritzing and KiCAD, understood this is the tool to project layout prepare files for PCB printing. However I am not sure if that software could protect me to do rookie mistakes? Like if I connect something stupid , will it give me warning? Or does this software show voltage and current readings at different places on PCB (don't know if this kind of software exist)?

If the only way to become better in this is to go through steep learning curve, then perhaps I need to find right forums and hope that people understanding this subject would advice. I do not plan to make sophisticated PCB, just simple layout with ESP32 or ESP8266 in the center and several sensors, relays connected to it.

User avatar
Posts: 3467
Joined: Mon Jan 06, 2014 6:08 pm
Location: Peachland, BC, Canada

Re: Developing PCB layout

Post by dhylands » Mon Mar 18, 2019 3:42 pm

Unfortunately, the software isn't going to protect you. If you connect things up badly, you can damage components.

I like to look at schematics of circuit boards and then try to understand each of the components and what their purpose is.

Many datasheets will have typical circuitry for particular purposes.

Posts: 11
Joined: Tue Mar 19, 2019 4:55 am

Re: Developing PCB layout

Post by oclyke » Wed Mar 20, 2019 7:00 pm

dhylands is right about the strategy for adapting existing designs - think about why the components exist in the schematic. In your example with the 200 ohm resistor you'd have to look at the context of its use and think about what would change with the different value. Therefore it would be good to be familiar with some of the most common things you'll see in a design and how they work.

I really liked Turbinenreiter's keywords for typical digital designs. I'd add a few of my own that it would help to know about:
voltage dividers
pull-up/down resistors
decoupling capacitors
open-drain vs push/pull
transistors / mosfets
clocks (R-C, crystals, mems)

In more of a theoretical sense you might check out these too (but you probably won't use these directly on a simple design)
RC circuits
LRC circuits
digital logic

You mentioned 'other forums' so I think it's worthwhile to mention a few decent places that I've used to learn PCB / electronics design.

Electronics Tutorials
Electronics Stack Exchange
- Someone asked about good PCB Design Workflow

And of course, try to do a proof-of-concept of your design before putting in all the effort to lay out a PCB. Electronics can often be thought of as a bunch of smaller groups of parts that do a special function.

Hope that helps

Posts: 25
Joined: Thu May 08, 2014 9:31 pm

Re: Developing PCB layout

Post by nekomatic » Fri Mar 22, 2019 2:12 pm

If you're simply dealing with pull-up or pull-down resistors and decoupling capacitors, then you can almost certainly vary the value by a factor of two or more each way without problems. The only exceptions might be where the resistors are terminating a long or high-speed communication bus, or when using a switch-mode regulator IC where stability can depend on the specific capacitor properties.

If you're going beyond that, you're really asking about how to learn analogue electronics. There are lots of books and online resources for this but I would suggest you start by experimenting with components on a solderless breadboard before you start worrying about designing your own PCBs. If you create a design on the breadboard that you want to keep, you can solder it on a prototyping board (single pad, stripboard or whatever is most suitable) and until your designs get quite complex, it's easy enough to design those with pencil and paper.

If you do want electronics design software, I like what Fritzing aimed to be, and used it for a few projects, but it's had no development for a few years now and the last version still has too many bugs and too many missing features to really recommend it. Apart from KiCad a lot of people use Eagle (commercial, but there's a reasonably capable free edition). Meanwhile CircuitLab doesn't do PCBs but it might be interesting as it will simulate your circuit for you, which might help you both learn and avoid damaging things. If you're not a registered student you can get the 'micro' edition for a cheap subscription which will be OK as long as you are just learning.

Post Reply