Author Topic: My boring first PCB, what do you think?  (Read 1181 times)

0 Members and 1 Guest are viewing this topic.

Offline AnasMalasTopic starter

  • Regular Contributor
  • *
  • Posts: 69
  • Country: jo
My boring first PCB, what do you think?
« on: December 28, 2021, 09:58:59 pm »
Hello!

Im unsure at what point to stop calling myself a beginner (feels like never), but after tons of work, i've completed my first PCB ever (YAY)! Would you please take a quick look and let me know if anything jumps out to you? I dont expect a comprehensive review or anything, ive stared at this project for so long that I might be missing something obvious. This PCB takes commands from a raspberry pi and does some functions like operating a solenoid, driving addressable LEDs, etc.

Attached are photos of all 4 layers, the schematics. An error prevented me from attaching the kicad file, so here is a link: https://1drv.ms/u/s!AkWX-lk5t5U8kudpRYyJFfNO7H5TOQ?e=ljfaYH

Thanks!


 

Offline amosborne

  • Contributor
  • Posts: 38
  • Country: us
Re: My boring first PCB, what do you think?
« Reply #1 on: December 28, 2021, 10:52:34 pm »
I took a brief look at the schematic. It’s hard to understand exactly what this circuit is doing without knowing more about the specs of what it is intended to interface with, and what the operating principles are.

A few things caught my eye:
1. What’s the motivation for all the ESD protection diodes? My gut feeling is that ESD protection on things like the “door switch” interface is total overkill.
2. It looks like the solenoid is a low-side FET PWM control. Are you using a TVS diode on the low side to sink the back EMF? I’d put an anti parallel diode across the solenoid instead.
3. It looks like you are filtering the tachometer signal to get an analog signal. Are those corner frequencies right? The 318Hz filter (per the note) is not a 318Hz filter. I would also consider reducing R and increasing C, 5nF is kind of small in my opinion. I’d aim for 100nF.
4. I have no idea what is happening in the RGB strip interface circuit, but I’d like to understand why a 41MHz filter is necessary. As drawn I’m skeptical you’ll get the performance you desire… 41MHz requires you to start thinking about parasitics in both the components and the PCB layout.
5. I’m not grasping your note about the crystal oscillator ground. There will be common mode current injected from the crystal into the controller. If you do not provide a low inductance return path, it will find one on its own (and emit some radiation for the trouble).
 

Offline AnasMalasTopic starter

  • Regular Contributor
  • *
  • Posts: 69
  • Country: jo
Re: My boring first PCB, what do you think?
« Reply #2 on: December 29, 2021, 09:46:46 am »
Thanks for the reply! I would like to eventually opensource this as part of a larger project, so im ready to give full information. But realistically, who'd read a really long paragraph?

1. What’s the motivation for all the ESD protection diodes? My gut feeling is that ESD protection on things like the “door switch” interface is total overkill.
This is a one-off board to be handed to a university with people probably way too busy to be able to diagnose an ESD fault when someone eventually opens the case and touches something. It is supposed to last 4-6 years as a minimum, so throwing $10 of ESD protection is a worthy investment.

Quote
2. It looks like the solenoid is a low-side FET PWM control. Are you using a TVS diode on the low side to sink the back EMF? I’d put an anti parallel diode across the solenoid instead.
Thats the product of a very long thread with the wonderful T3sl4co1l. The TVS diode will be as good or better than a flyback diode because a flyback diode only concerns itself with the inductor, not the stray inductances of wires and traces.

Quote
3. It looks like you are filtering the tachometer signal to get an analog signal. Are those corner frequencies right? The 318Hz filter (per the note) is not a 318Hz filter. I would also consider reducing R and increasing C, 5nF is kind of small in my opinion. I’d aim for 100nF.
Good catch! You are right. That note is indeed inaccurate, it is left over from a previous revision. The filtering done throughout this PCB is because there are multiple 2W 860 MHz RFID antennas close by, and I don't trust ill shield it all properly. All lines that go to long wires are filtered to a frequency that shouldnt cause interference but otherwise maintaining the original signal. Previously, I was trying to just get the signal and was told that this is excessive (this is a 100 Hz signal).

Quote
but I’d like to understand why a 41MHz filter is necessary
It really isnt. The resistor is needed either way to protect the microcontroller from a short circuit, and I do not want to get into ferrite beads for my first PCB (this thing has been in the making for ages now, oh and the signaling includes a 300 ns pulse)... I consider that 8.2 puff cap to be a good luck charm  :D

Quote
5. I’m not grasping your note about the crystal oscillator ground. There will be common mode current injected from the crystal into the controller. If you do not provide a low inductance return path, it will find one on its own (and emit some radiation for the trouble).
Well, the lowest inductance path to the ground plane is a large via, so I hope that is enough? The microcontroller has a GND pin right next to the XTAL pins, what that notes says is that the GND used for the crystal casing and the load capacitors should connect to that pin, and no other signal goes into that GND via. As you see in the screenshot, the GND pin adjacent to XTAL has only the crystal and its capacitors on it, not even the decoupling capacitors.


Thanks for the reply, ill ammend the filter notes now :)

 

Offline amosborne

  • Contributor
  • Posts: 38
  • Country: us
Re: My boring first PCB, what do you think?
« Reply #3 on: December 29, 2021, 01:47:35 pm »
Yea, I guess I just am not grasping what you meant by that note on the crystal, but the layout of the crystal itself looks OK.

Just from the layout screenshot you attached, you might revise the power connection to the microcontroller. Generally you want:
1. Decoupling capacitors to be placed between the pins and the vias. Right now you have the vias between the pins and the decaps.
2. Same number of vias on power and ground pin entries. Right now you two 5V via and one ground via.

See if you can flip the decaps around and place them straight across the pins- this would be optimal. That’s not to say it would work as is, however.

Honestly you might want to add a bunch of 0ohm jumper resistors at power inputs and external interface points. Think about how you’ll bring this board up and test it. If you’ve been working on this a long time you might as well just build it… expect debugging and fixes!

 

Offline Terry Bites

  • Super Contributor
  • ***
  • Posts: 2513
  • Country: gb
  • Recovering Electrical Engineer
Re: My boring first PCB, what do you think?
« Reply #4 on: December 29, 2021, 04:16:13 pm »
The problem your struggling with is never in the FM!
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf