Difficulty reading schematics - Page 1
Forum section: electronics / beginners

author: Takconn
author_rank: Newbie
timestamp: January 22, 2025, 09:34:23 am
content: Hey all. I'm currently designing a PWM controller for 3 server fans. I grabbed a schematic from the internet, replicated it in easyeda, and then started building the PCB. I don't understand exactly how all this works, but I've got a funny feeling that the traces aren't supposed to look like this. Any help would be really appreciated

author: Zero999
author_rank: Super Contributor
timestamp: January 22, 2025, 09:47:01 am
content: Have you built it or at least simulated it?I can tell just by looking at it, that it won't work.

author: pcprogrammer
author_rank: Super Contributor
timestamp: January 22, 2025, 09:49:58 am
content: Within EasyEDA you can download your schematic design with the menu option File->Export->EasyEDA. THis gives you a .json file. Post it here and I can check what is wrong in the schematic.

author: Zero999
author_rank: Super Contributor
timestamp: January 22, 2025, 10:11:34 am
content: Quote from: pcprogrammer on January 22, 2025, 09:49:58 amNo need. The lack of power to pin 8 is a dead give away, it won't work.

author: pcprogrammer
author_rank: Super Contributor
timestamp: January 22, 2025, 10:53:02 am
content: Quote from: Zero999 on January 22, 2025, 10:11:34 amI think the question is more about why the two capacitors are connected with shorts on the PCB, while in the schematic this is not shown.Either Takconn has no idea how to use EasyEDA and converting the schematic into a PCB with the use of the ratlines or there is an error in the schematic drawing.But you are right that the VCC connection to pin 8 is missing.

author: Takconn
author_rank: Newbie
timestamp: January 22, 2025, 10:54:20 am
content: Right then, rebuild the circuit it isSo, looking at thee schematic, pin 6 of the 555 timer needs to go to both the wiper of the potentiometer, and also through a cap to ground??Please excuse my stupidity, but I'm trying to learn here, and having a pin going to both ground and the pot wiper just doesn't sound right.

author: JohanH
author_rank: Frequent Contributor
timestamp: January 22, 2025, 12:46:23 pm
content: You aren't supposed to manually draw and guess where to connect PCB traces. You should first create the schematic as shown, then export from the schematic to the PCB editor. The so-called rat's nest (wires connected to their components) will then guide you how to draw the actual traces.And nowadays, when the cheapest option is to order a two-layer PCB from any of the online vendors, you should use e.g. the bottom layer as a ground plane and then draw power and signals on top. It feels like wasting a lot of copper on the ground plane if you only have a few ground connections, but it's good practice for various reasons, and it's in theory cheaper and faster to not etch away copper from the PCB.

author: pcprogrammer
author_rank: Super Contributor
timestamp: January 22, 2025, 01:10:45 pm
content: Quote from: Takconn on January 22, 2025, 10:54:20 amIf you want to learn, start with reading the datasheet of the NE555. It needs a RC time to do its work. So a resistor and a capacitor. To make the time variable you replace the resistor with a potentiometer, which is a variable resistor.Secondly JohanH already pointed this out, use the tools in a proper way. Finish your schematic first, then use the menu item "Design->Convert Schematic to PCB" to start making your PCB. Once you started with your PCB and make a change in your schematic, use the "Design->Update PCB" menu item.

author: Zero999
author_rank: Super Contributor
timestamp: January 22, 2025, 02:06:00 pm
content: Quote from: Takconn on January 22, 2025, 10:54:20 amHere's the correct way to produce PWM with a 555 timer.

author: inse
author_rank: Super Contributor
timestamp: January 22, 2025, 02:14:09 pm
content: The question is whether this is really worth a PCB.Learning factor is higher with a hand wired perf board - unless you plan to go into series production

author: Nominal Animal
author_rank: Super Contributor
timestamp: January 23, 2025, 02:25:32 am
content: I prefer to use a microcontroller for this, because the PWM duty cycle may not correlate exactly to a specific RPM, in the long term.Intel specified how these 12V PWM fans work (PDF), although the wire colors vary. In essence, the PWM is a 25 kHz open collector signal, pulled up to 5V or 3.3V in the fan, with maximum current 5mA. The tachometer output is two pulses per rotation, open collector, pulled to 12V by the controller (although many fans don't mind it being pulled to only 5V by the controller).I use inverted logic on the microcontroller (i.e., PWM is active high, tachometer pulses are detected on the falling edge), andNXP NX138AKN-channel MOSFETs in SOT23 package. These are similar to BSS138 MOSFETs, but slightly faster due to smaller total gate charge. NXP has a model for this so one can easily test ones circuits in KiCAD. For the PWM output, I connect the MCU PWM pin to the gate via a peak current limiting resistor (220Ω), source to ground, and drain to the to the fan PWM input. For the input, I connect the tachometer output to another MOSFET gate (optionally via a peak current limiting resistor, which can be 1kΩ or larger since this is pretty low-frequency signal, a kilohertz at most) and via a pull-up resistor (10kΩ) to 12V. The source of this MOSFET is also ground, and the drain is to the MCU tachometer input pin and via a pull-up resistor (10kΩ) to MCU I/O voltage (3.3V or 5V); depending on the microcontroller the internal pull-up might suffice.Each control potentiometer (10kΩ linear) is in voltage divider mode, one end to ground and the other to your ADC maximum input voltage. The wiper is connected to an analog input pin, optionally with a small (1nF to 10nF) capacitor to ground to "top up" the sampling capacitor in the microcontroller, and to filter the input a bit.The microcontroller logic is very simple, but you do need to program it for the minimum and maximum RPM for each fan. You periodically read the potentiometer voltages. At the minimum position, it corresponds to the minimum RPM, and maximum position to maximum RPM. If current RPM is lower than the target, you increase the PWM duty cycle; if the current RPM is higher than the target, you lower the PWM duty cycle. During fan start-up, you can wait (with no PWM output, as that causes the fan to go full blast) until the fan is rotating at high enough RPM before applying the PWM output, to ensure the fan starts. (They typically can go much lower RPMs than they can start at.) You'll need to fine-tune your feedback loop, say filtering the RPM values a bit, or have a "dead zone" or allow some difference between target RPM and actual RPM, so that your fans won't "pump" up and down in speed all the time.The benefit of this approach is that even as the fans age, this scheme keeps the fan speed (and thus hopefully the airflow) at the desired value.I do have schematics of a couple of differentfan controllercircuits at oshwlab.com, but some members here find my schematic drawing style unacceptable, so I won't link to them directly. I'm sure you can find better ones there and elsewhere.

author: CaptDon
author_rank: Super Contributor
timestamp: January 23, 2025, 01:55:24 pm
content: Never fails to amaze me how much wrong information, bad advice and totally flawed schematics can easily be found with a google search. One really dumb one I recently read was on biasing the tubes of a guitar amplifier. Mr. Dumbshit said "Adjust the bias until the plates glow red then slowly back up until the glow is barely visible". It was a push pull class B amplifier. He is probably right on the doorstep of biasing it class A. I am sure the power transformer, output transformer and output tubes will enjoy a short lifespan. Maybe the guy repairs burned up amps for a living? At least here on EEV the correct advice and schematics can often be found.

author: Nominal Animal
author_rank: Super Contributor
timestamp: January 23, 2025, 08:51:56 pm
content: Here is a complete circuit to safely interface to12V PWM fansusingMOLEX 47053-1000connectors, ignoring how you generate the PWM or use the tachometer signal:Click to embiggenThe tab does not reach pin 4, it only covers pins 1, 2, and 3. If you look at the PCB connector, with pins pointing upwards and are between you and the tab, then pin 1 is on the right. See the above MOLEX PDF to verify.The PWM frequency should be about 25 kHz, but anything between 21 kHz to 28 kHz should work. PWM signal is inverted by this circuit. PWM signal below 0.6V or so makes fan PWM high, and PWM signal above 2.5V (okay up to 12V at least) makes fan PWM low.Tachometer signal is two pulses per rotation, so even at 20,000 RPM (tiny 1U server fans) the pulse frequency is under 700 Hz, well over a millisecond between pulses. VCC is the logic level (high) for the tachometer signal. The tachometer signal is inverted by this circuit.Q1 and Q2,NX138AKR, are N-channel logic-level MOSFETs in SOT23 footprint from NXP, similar to BSS138 from many manufacturers, but slightly faster due to smaller total gate charge. (Remember, MOSFET gate acts like a capacitor.) At Vgs=2.5V, Rds(on)≃10Ω, and with Vgs(max)=±20V, these are well suited for logic level stuff down to 2.5V or less, and can safely handle the 12V signaling. You can get ten of these from Mouser/Digikey/LCSC for around $1/1€; I paid Mouser about 8€ for one hundred; it's my go-to logic level N-channel MOSFET. Many other MOSFETs, including BSS138, should work equally well here.The MOSFETs are used in open collector/open drain/low-side switch configuration, with source to ground, where a 2.5V or higher voltage on the gate pulls the drain to ground, and a 0.6V or lower voltage on the gate means the drain is not connected to ground, as if there was a very high value resistor between drain and ground. You can read more about this at e.g. WikipediaOpen collectorarticle. (For simplicity, I use "open collector", but since this uses a MOSFET, it would be more correct to use "open drain". In practice, the two, and "low-side switch transistor", all refer to the same thing.)The purpose of R1 is to limit the peak current spike during switching. These spikes are very short (depend on the slew rate of your PWM output signal), and many PWM signal sources don't need R1 at all. For 2.5V to 5V logic levels, 220Ω seems to work well, limiting the current draw to 23mA (5V) / 15mA (3.3V) / 11mA (2.5V). In practice, the actual peak current draw is even lower.R2 is optional, but if used, does the same for the fan. The tachometer output is open collector, and the circuitry inside the fan uses a transistor to pull it to ground. Thus, R3the pull-up inside the fanalready limits the current draw, and there is no reason to have R2 at all. I personally do not use R2, but it is shown in this schematic for completeness, in case inquiring minds wonder why Q2 doesn't have a gate resistor like Q1 has.R3 is the pull-up to 12V theIntel 12V PWM fan specsrecommend, although some controllers/motherboards do pull it to 5V instead. The resistance is not at all exact, and anything between 3300Ω to 33kΩ should work. 10kΩ is used here because it means 1.2mA current flows when the fan pulls the tachometer signal to ground, and is a very common value. If the resistance is large, the current will be small, and electromagnetic noise coupling to the tachometer wire more easily affects the voltage, causing mis-readings. If the resistance is too low, the transistor on the fan may fail to pull it low enough, or will heat up due to excess current.R4 is the tachometer signal pull-up resistor to your logic level voltage, which can be anywhere from 2.5V to 12V at least. Again, the 10kΩ is not a specific value, and a wide range of values perhaps up to 100kΩ will work. In many cases, weak microcontroller input pull-up circuitry will suffice. The proper value here depends on the distance between the MOSFET and the device or circuit handling the tachometer signal, as high values means low current, and noise more easily couples to the signal. (R4 does not affect the current in the tachometer fan cable; that's determined by R3, and R2 if used.)The above circuit (with R2 omitted) works with basically all Arduino-compatible microcontrollers that can generate a roughly 25 kHz PWM signal. Each fan requires their own MOSFET even when driven from the same signal. If you do not use the tachometer signal, connect the fan tach signal to a pull-up resistor to 12V (say, 10kΩ to 33kΩ), don't leave it floating. For individual control of three fans, you need 9 I/O pins: three analog inputs (for the potentiometer in voltage divider configuration), three PWM outputs, and three inputs (perhaps with falling edge interrupt, or counter input). You could also use various I²C or Dallas 1-wire temperature sensors, to control the fan PWM or speed.While this is the complete circuit, many fans work fine with even simpler circuits. I personally believe using two transistors and three resistors per fan to diligently follow the Intel standard is worth it, but many disagree, and use even simpler and cheaper circuits. I post this in the hopes that anyone reading this wall of text will understand how to properly drive these 12V PWM fans, even if they choose to use something simpler.

author: inse
author_rank: Super Contributor
timestamp: January 23, 2025, 08:57:49 pm
content: I don’t know if Takconn is going to show up again, but please don’t overcharge him with too complex design or requirements, he is a self stated beginner.Also we don’t exactly know how or what for he plans to use the server fans.

author: Nominal Animal
author_rank: Super Contributor
timestamp: January 24, 2025, 10:36:23 pm
content: Quote from: inse on January 23, 2025, 08:57:49 pmThe above is the simplest way to safely control an 12V PWM fan, and explains what each component does. I've modified it to correct an error about the tachometer pull-up, and added the paragraphs about the transistors, so that even a beginner canunderstandthe circuit, at both the general and the component level, even without much previous electronics knowledge.Whatever the use, if I do not see an NPN transistor or an N-channel MOSFET in a PWM fan control circuit, I will not trust it for any of my uses. Some of the fans I use are rather "expensive" (~ 20-30€ apiece), and I am not willing to save 0.20€ to risk burning out my fan early. (The above circuit costs me at most 0.20€ in components, per fan. If you only use PWM output – one MOSFET, one 220 ohm resistor, one 10k resistor –, it's about 0.12€ per fan. Why would you try to save that? You can even solder the NX138AKR and the resistor directly to wires, and cover them with heatshrink tubing: no PCB necessary. And this one is compliant with the Intel 12V fan spec, too; why risk it with non-open-collector driving circuits? I won't.)I already mentioned that if one doesn't care about the tachometer output from the fan, just omit Q2 (and R2), and connect the tachometer output from the fan to 12V via a 10k resistor.Others here could easily help by showing a 25 kHz adjustable duty cycle PWM circuit based on a 555. Add a small regulator from the 12V supply to 5V for the logic, and you have the simplest safe 12V PWM fan controller. Anything simpler, and anything without explanations, is a disservice to beginners, in my opinion.If someone just wants to build something without understanding them,OSHWLab has hundreds of schematics and PCBsto choose from, all drawn in EasyEDA, which is what OP also used.The answer to the question in the title, and in the initial post, is that the given schematic is not fit for the purpose, and the PCB is drawn incorrectly.It is better to start examining existingPWM fancontrollers (OSHWLab EasyEDA "PWM fan" projects), and simultaneously read the EasyEDAtutorialanddocumentation, since you're already somewhat familiar with it.For example, if you open one of the PCBs in the EasyEDA editors, you can switch between the schematic and the PCB (tabs). Hovering over any PCB track will tell you the track name. Go back to the schematic, clickDesign Manageron the left, thenNets, and you can click on any of the corresponding net names. When you do, EasyEDA will highlight it in red and a slightly bit thicker line style. This way, you can understand how the schematic traces and PCB tracks correlate.In EasyEDA (and many other schematic capture and electronic design tools, like KiCAD, which is free and open source and available for just about all current operating systems), it is important to create the schematic first. All unused pins are marked with the "No connect flag" (X). You can use theDesign Managertab on the left to make sure all nets are connected, and all pins on all components are used/marked. Then, when you create a PCB, you can use the "ratlines" to show which pins need to be connected. This way, you get maximal help from the program, and don't have to recreate the work you already did for the schematic; you can concentrate on how to place the components best, and how to route the tracks between them. TheDesign>Check DRCwill check all connections, components, and traces (according to rules you set inDesign>Design Rule...), and will warn you if you've forgotten some tracks, tracks are shorted to each other, go too close to pads or vias, and so on.In general, this stuff is fun and easy, if and only if you have the patience and werewithal to read the help you get. If you find this and my previous post too long for you to read, and you are a beginner in electronics, I believe you'll have a very hard time with repeated failures ahead.