text
stringlengths
83
79.5k
H: Illuminated LED and push-button using only 2 wires I want to make a circuit with an illuminated LED push-button that is far away from the input board and I only have 2 wires available. The push-button is not something specific. The input board will have many buttons, but not all buttons will have LEDs. The input board will probably be a MCP23017 16-bit expander with an MCU. I came up with this circuit: simulate this circuit – Schematic created using CircuitLab The MCP23017 is powered with 5V. When the push-button is not pressed, the voltage at the MCP input pin is about 1V, low enough to register a 0 on the digital input. When the push-button is pressed, the voltage is 5.6V without the added 5.1V zener diode D3, and 5 volts with the zener in place - well above 0.8 * 5V VDD required by MCP23017. But because the circuit is just a voltage divider 220+220 ohm resistors over the 12V supply, it will draw ~28mA, resulting in a bit of heat from the resistors. Because the push-buttons will not be pressed for more than a few seconds, I can live with this. D2 LED was actually an opto-coupler to separate the long wire from the digital input, but I gave up on this protection for now. I searched a lot on the internet for other ideas about how to power an LED and have a button using only 2 wires and no complex circuitry, but could not find any relevant info. I built this circuit and it works, but one thing I cannot test is the influence of mains wires that run alongside my long button wires. They are separated and individually protected, but parallel to each other. Do you have any other suggestions on how to use a button and an LED on 2 wires? Later edit: The buttons can only be normally open. They are European type light push buttons available only NO. LED is added by me. Led should be lit all the time when the push-button is open. When the button closes there is no problem if the led tuns off or remains on. In this particular case, the led is used for night time finding only. One other idea I had recently was to use input-output feature of the IO expander chip. Using the output to turn on the led, and then switch to input to check for the push-button state. Doing this fast enough not to see a flicker. But I haven't drawn any circuit yet. AI: If you still want isolation, you just need a source of low-voltage AC power: simulate this circuit – Schematic created using CircuitLab Each switch controls the LED at the other end of the long 2-wire cable. Either LED could be part of an optoisolator. D2 and D4 are only necessary if the peak voltage out of the transformer exceeds the LED reverse voltage rating.
H: Problem simulating current controlled current source in LTspice I've been trying to simulate the following circuit in spice. (I'm plotting the voltage over R7) Everything is okay, and works as expected until I change the gain of the current controlled current source to a value that's greater than 58. And I should simulate this with a value of 290. Any idea on how to fix this? Here is another photo with the gain in 290 When I set the gain in 58. Spice trows the following error "spice analysis: Time step too small; initial timepoint: trouble with node n002" The node n002 is the node that connects R4 with R1. For greater values the error doesn't show up anymore but the result is the one from the picture. Thank you for any help you can give me on this issue! AI: Behavioural sources are very versatile, but sometimes can suffer. Using the VCCS (aka G-source) should eliminate the problem. In this case, since you are only taking a current and multiply it by a constant, you can replace B2 by a VCCS like this: It takes the voltage across R3, divides it by its value (1/16k), and then multiplies it by some constant (290). Alternately, you can either insert a zero-valued voltage source in series with R3 (let's presume it's called Vx), then use an F-source with the value Vx 290 (careful at the direction of the source, + ---> -), or replace R3 with the same zero-valued voltage source, but with Rser=16k added, same F-source.
H: How to invert PWM signal on STM32 I am trying to control a WS2812 LED with STM32F103. The LED is a digital RGB LED also known as Neopixel. They are controlled by sending 24 bits of color data per LED to the first LED's data pin. The STM32 is 3.3V and the LED is 5V. To be able to control it I put a transistor in between like this: This solves the level shifting problem, but causes another one: now the data signal for the LED is inverted. When the STM32 pin is low, LED data is high and vice-versa. I USE Timer PWM and DMA to control the LED. I pass the buffer with color value bits to DMA like that: HAL_TIM_PWM_Start_DMA(&htim4, TIM_CHANNEL_1, (uint32_t *)&BUF_DMA, ARRAY_LEN); This produces a nice PWM signal on MC pin. Here is how a bunch of zeros at 800KHz look like: But the transistor inverts the signal making it useless: I need to pass the inverted signal from the MC pin somehow. So that the transistor will UN-INVERT it back. Is there a way to invert PWM/pin signal completely? So that MC pin is always HIGH by default, so that LED data line stays LOW? A few notes: I use PB5 and PB6 to control two separate lines of WS2812 The PCBs are already printed and all the components are SMD, so hardware workarounds are barely possible. I already tried to remove the transistor completely and use MC pin to pull 5V line to ground internally in open drain mode, but PB5 is not 5V tolerant. No luck here. AI: According to the reference manual: OCx polarity is software programmable using the CCxP bit in the TIMx_CCER register. It can be programmed as active high or active low. So you need to look up the bit assignments of that register and set/clear the bit as appropriate, or look at the API for abstraction library you are using and ask it to do this, for example set the appropriate struct value documented to control inversion, or if such does not exist modify the library source or in extremity even change the hardware bit behind the library's back. For example, since it looks like you are using the STM32F1 HAL drivers, in your instance of an TIM_OC_InitTypeDef you would set OCPolarity to either TIM_OCPOLARITY_HIGH or TIM_OCPOLARITY_LOW. I will refrain from guessing which you should use (easy to just try both) but as the first has a value of zero, if you have zeroed the struct to start and not yet set anything that is probably what you have, so the second is probably what would give a different result from what you have been getting. Ordinarily for something like this, software pre-processing of the values could work, and I'm not 100% sure that cannot here, but it would be tricky as in your depicted Manchester-ish scheme the framing period of a of a hi-low is consistent, but that of a low-hi spans two different bits and varies as a result. Besides, you already paid for the on-chip hardware inverter. If you didn't have the hardware inverter, something that probably would work would be to approximate the signal in thirds and clock 110 or 100 sequences out the GPIO via DMA at 3x the bit rate (or using a synchronous serial peripheral). That's also a handy solution if you ever need to do this kind of thing on pins that don't have timers. If you don't have much else for the processor to do you could also potentially do one channel in code using semi-calibrated delays (the timing doesn't have to be all that precise).
H: How do I convert a Eb/No from a dB value to a linear value So for example how would I convert an Eb/No value of 2dB into a linear value? AI: For a power value, the decibel value is given by \$10\log_{10}{\text{SNR}}\$. To obtain the SNR from the dB value, take the inverse of this formula: \$\text{SNR} = 10^{\text{SNR}_{dB}/10}\$. In your example, 2 dB SNR corresponds to an SNR of approximately 1.58. Note that this gives SNR power ratio. If you want an amplitude ratio (assuming there's a square-law relationship, as with electronic signals in many cases), take the square root of the power SNR.
H: Combinational System Theoretical Question I'm currently taking an MIT-OCW course, where it says that a system built from smaller combinational systems following the following compositional rules is combinational: Each component of the system must itself be a combinational device. Each input of each component must be connected a system input, or to exactly one output of another device, or to a constant voltage representing the value 0 or the value 1. The interconnected components cannot contain any directed cycles, i.e., paths through the system from its inputs to its outputs will only visit a particular component at most once. However, it then states: is combinational. However, it looks like C is connected to two outputs of other devices - to A and B. How is this then still combinational? In general, I don't understand the point of why it would only need to be connected to exactly one output of another device. Apologies if this is the wrong StackExchange, wasn't sure where to ask this. AI: C has two inputs. Each input of C is connected to exactly one output of another device. Connecting two outputs together usually results in smoke, or the mathematical equivalent, when they compete.
H: CAN BUS Termination Resistors For CAN Logger Device I am making a CAN logger device that will be connected to the vehicle OBD port. Since the CAN bus inside the vehicle is already terminated, do I need to terminate the BUS lines on my device end, right before the line feeds to the CAN Transceiver? Please check the attached picture. The J1939+ and 1939- are the BUS lines available on the Vehicle OBD port. I have read that if the stub lines are not too long(<0.5m) , termination is not needed. The stub lines in my case is much less than 0.5m. AI: No. You only need to keep the stub length below the specification for the bitrate. Which according to j1939-14 (4.2.1) is a maximum of 1.67 meters.
H: How to drive an 100 mA forward current LED using STM32H743 Microcontroller to the collector without using external power supply? I am new to electronics hardware so kindly help me and give me suggestions. I am working on STM32H743 microcontroller for dual camera interface and LED interface. The total current of my STM32H743 Nucleo board is 500 mA in that both the cameras and microcontroller consumes 450 mA of current, so there is only 50 mA left to drive an LED (forward current 100 mA). I am planning to drive an LED using PWM signal from the microcontroller using an NPN transistor. Since I have only 50 mA left for supply current, I'm not able to drive my LED (forward current 100 mA). Is there any solution for it? Please find my circuit below: AI: LEDs still work well when driven below their rated current. So if you only have 50mA, you can set the current limiting resistor in your circuit so that the current is only 50mA.
H: PIC24EP: What exactly are IOL, IOH currents I'm going through the 'Electrical Characteristics' section of datasheet of PIC24EP128GP206 to find out minimum and maximum voltages and currents specific to GPIO pins. While doing so, I came across the terms IOL, IOH in the following section: What do the IOL, IOH currents exactly represent? Are these the sourcing / sinking currents associated with the output pins? Why is the IOH limit is mentioned negative? AI: Why is the IOH limit is mentioned negative? It's just a convention thing. Normally currents into the device (supply currents etc.) are attributed positive values therefore, currents from chip pins are given a negative sign. What do the IOL, IOH currents exactly represent? Are these the sourcing / sinking currents IOL is the current into the pin (sinking) when the pin has a logic level of zero. IOH is the current from the pin (sourcing) when the pin has a logic level of one. All the data in the table in the question refer to the pins being outputs (3rd column of table).
H: Why my current mirror results in wildly different currents? Let me start with that I'm new to current mirrors and my idea may be conceptually wrong. Feel free to ask any clarifying questions. I'm designing a dual "LED lamp" with very finely tunable brightness including very dim levels. The control loop for the brightness is only for a single lamp, with the second lamp added to double the max brightness possible, and this is where I use the current mirror (I want the second lamp shine as brightly as the first). I don't have the second LED string yet, so I've substituted a 5W 220ohm resistor. The relevant part of the schematic is: simulate this circuit – Schematic created using CircuitLab A MCU is controlling Vgs of the MOSFET, and sensing the actual current via the R3 shunt. The current mirror PNP pair is a single-package device - BC807DS,115, a SOT-457 part. The LED string is "cannibalized" from a commercial mains-voltage LED bulb. Only the LED PCB is used, where it has just the +/- terminals, and the LED string needs ~29V for full brightness. The problem If I slowly increase the gate voltage, to the point that the left leg conducts 5-10mA (measured at R3), the second leg starts conducting close to 100mA (measured at R4), more than 10 times more. However, if Vgs is 0, then both legs don't conduct. Also, at higher currents, the mirror sort of works, with both legs conducting relatively similar currents (yet not perfect). Example at low currents, where the problem is most pronounced: Left leg is yellow, right leg is cyan. Both traces are 50mA/vertical div. At higher currents the matching is closer (about 110mA for the left leg, 130mA for the right): Same settings for the traces. Question Is a current mirror really a good approach for this task? Any idea why does mine fail so miserably? I know, of course, that you can alternatively wire both led strings in series. That would require 60+V supply which starts to be somewhat dangerous for the intended application of the device - I strongly prefer the 31.5V solution. AI: Consider the two transistors in the current mirror. With only 1.8R emitter resistors, any 1mV difference in Vbe between both transistors will cause a difference in current of 0.55mA. This transistor's hFe stays above 200 even at 100mA, so base current is not the main cause of your current mismatch. The two transistors are in the same package, but the datasheet does not say anything about them being Vbe-matched, so you can expect maybe 10-20mv Vbe mismatch at the same Ic and Vce. So, with such a small emitter resistor, you won't get a good current matching. This will be more apparent at low current (as you noticed) -- with 5-10mA current mismatch, setting it to a low current like a few mA won't work. Even if you could get matched transistors, their temperatures and Vce will be different, and this will cause a change in their Vbe also. Basically, a current mirror can be reasonably accurate with high value emitter resistors and/or precision matched monolithic transistors. But in your case, that won't work. I'll suggest solutions, without current mirror. 1) Wire both LED strings in parallel, with an additional resistor in series with each string. The resistor will help balance current between both LED strings. If your LED strings have 30V Vf, consider dropping at least 3V on this resistor. You can check if the current is well balanced by measuring voltage on the resistors. This should work well if both LED strings are at the same temperature (same heat sink) so their Vf will track. 2) Use PWM ; high-frequency if you want it flicker-free. 3) Duplicate the FET, current sense resistor, and use a dual opamp (one opamp per FET) so each LED string is driven independently. This won't cost much more but it will save lots of hassles of both LED strings are on two heat sinks at different temperatures.
H: Measurement of Resistor Parasitics Inductance and Capacitance I have seen people doing some measurements of parasitic capacitance and inductance of some resistors, by using a vector analyzer and analyzing the graph of S11 with respect to frequency. To get this measurement they have soldered the resistor to a type N connector, and that connector has been connected to one port of the Vector Analyzer. My question is: how can this measurement be correct? It is like putting the resistor under test in parallel to a 50Ohm resistance (since the characteristic impedance of the type N connector was 50Ohm). AI: It is like putting the resistor under test in parallel to a 50 ohm resistance (since the characteristic impedance of the type N connector was 50 ohm). No, that is incorrect; the characteristic impedance of a piece of coax or a connector is a value that is the square root of the inductance to capacitance ratio of the part or cable. It isn't a real value of resistance i.e. if you put 1 volt across an N type connector, 20 mA doesn't flow continuously. 20 mA does flow but, only for a fraction of a nano second or so. If you applied 1 volt to an infinitely long piece of coax then 20 mA would flow indefinitely.
H: RF Power Meter vs RF Power Sensor What is the difference between a power meter and a power sensor? If I got this right a power meter is the instrument that reads and displays the measurements of the power sensor. Also, power meters have some reference RF signal to calibrate power sensors. Are there power meters with integrated power sensors? So are these two independent things or each one needs the other? AI: I think there is no well-defined difference, and it depends on context. I get the impression you are referring to a lab-instrument type of meter/sensor and my answer will be along that line: The power meter is the big box with the screen. The sensor is the little box that you connect to the DUT. The meter: These often have a 'calibration' output that generates a precisely leveled CW tone to 'zero' the error of the power sensor. The power meter will also do a lot of the math to flatten the frequency response of the sensor. Older power sensors came with a piece of paper containing the calibration coefficients: a bunch of numbers you had to plug in to the meter. You also had to set the frequency you are measuring (the sensor couldn't tell) and the power meter would use that to figure out what calibration constants to use. The power sensor is the little box that you actually connect to the reference plane you want to measure. It usually operates based on thermal or diode sensors (both have advantages and disadvantages). I believe (historically) these sensors were just that - an analog sensor that generated output signals based on the input power. Modern sensors will contain some basic digital circuitry to communicate the calibration constants to the meter, to speed up the process. On the meter side, I'm starting to see the calibration port being omitted on more modern meters. I'm no expert on the state-of-the-art power-sensor design, but I suspect the stability of modern sensors is simply such that they don't need constant re-calibration. Finally, you do get fully integrated sensors/meters now. I think all of R&S's NRPxx series of power sensors can just be connected to a computer with a USB cable, or (if you have the LAN version) you can hook them up to ethernet. In both cases you can just talk to them like any other VISA instrument. You can also stick them into a NRP2 or other power meter box, but in this case I think they just operate as a screen. (kinda expensive screen, if you ask me...) There are also frequency-selective sensors, which have a narrow bandwidth. This can give you much more accurate measurements for narrowband, low-power signals.
H: Understanding equation for capacitor-voltage For an simple RC-network the following solution of an ODE is given: \$u_c=A_1+A_2\cdot e^{\frac{t}{\tau}}\$ I fully understand how the solution is calculated, but I want to have an feeling for it.. Am I right if I say that \$A_1\$ is the Voltage that would be across the C if the actual circuit would remain like it is for \$t -> \inf\$? and \$A_2\$ is the voltage defined like: \$A_2\$ = actual voltage over the C - \$A_1\$ Is my assumption right? AI: I find it more intuitive to interpret the solution as $$v(t) = A_1 - A_2 \times e^{-\frac{t}{\tau}}$$ Now \$A_1\$ is the final voltage, at \$t = \infty\$. The value of \$A_2\$ is how much the voltage will change, from \$t=0\$ to \$t=\infty\$. In other words, \$A_1 -A_2\$ is the initial value of the voltage. When \$t = 0\$, \$e^{-\frac{t}{\tau}} = 1\$ so \$v(0) = A_1 - A_2\$ as expected. As \$t \to \infty\$, \$e^{-\frac{t}{\tau}} \to 0\$ so \$v(\infty) \to A_1\$ as expected.
H: Why is the impedance zero at cutoff frequencies in a series RLC resonance circuit? I see that, in many derivations in the frequency analysis of series RLC circuits, \$X_L - X_c = R\$ or \$Xc - X_L = R\$ is considered at lower and higher cutoff frequencies. So does that mean that the impedance \$Z = \sqrt{(X_L-Xc)^2 + R^2}\$ is zero at cutoff frequencies? AI: So does that mean that the impedance (Z = sqrt((Xl-Xc)^2 + R^2)) is zero at cutoff frequencies? No, your math is wrong. If \$|X_L - X_C| = R\$ at either of the 3 dB points (cut-off frequencies) then : - $$Z=\sqrt{R^2 + R^2}$$ or $$Z=\sqrt2 R$$
H: How can I calculate the amplitudes of this signal's harmonics? How can I calculate the amplitude's of the harmonics? This signal is the voltage of a capacitor bank. There is a few amperes of current on the capacitors in form of PWM. On the signal the 200mV Jumps are the voltage drops on the ESR. The jump occurs when the PWM changes from Ton to Toff or vica versa. On the second picture I approximated the 200mV jumps with an instantaneous jump. How should I derive the Fourier transformation on this signal? AI: You can find the harmonics of a signal by computing the Fourier series of the signal, given that the signal is periodic. You have a non-periodic signal here . However, you can still calculate Fourier series between the full finite interval \$T\$ of the signal, assuming that the signal is 'periodic' with \$T\$, ie., assuming that the signal repeats over and over like that afterwards. How should I derive the Fourier transform on this signal? You can calculate the Fourier transform of the signal using integration by parts. For eg: $$F{\{v(t)\}} = \int_{-\infty}^\infty v(t)e^{-j\omega t}dt$$ $$=\int_{0}^T v(t)e^{-j\omega t}dt$$ $$=\int_{0}^{t_0} v(t)e^{-j\omega t}dt+\int_{t_0}^{t_1} v(t)e^{-j\omega t}dt+\int_{t_1}^{t_2} v(t)e^{-j\omega t}dt+\int_{t_2}^{T} v(t)e^{-j\omega t}dt$$ Each of the four terms are simple linear equations for line on the respective intervals, which you can derive if you know the values of \$a, b, c, t0, t1, t2, T \$
H: Is a triangle waveform a type of pulse width modulation? I'm confused as I have seen a triangle waveform referred to in terms of PWM but a triangle waveform does not actually modulate the pulse width. Is a triangle waveform a type of pulse width modulation? AI: Is a triangle waveform a type of pulse width modulation? No, without pulse widths, there can't be a PWM. Especially: Since the average of the triangle waveform is constant / can't be parameterized, there's nothing to modulate.
H: Applying Ripple to a DC Source? I have a system that is powered by a 25V Lithium ion battery pack. I need to test the system with a 1 Vpp sine applied on top of the 25V supply, so 25V +/- 0.5V ripple. I know theoretically to get this signal I could use a function generator generating a sine wave and feed that through a series capacitor, but is having an AC signal applied this way bad for the battery? Can I put a large inductance between the battery and the capacitor such that none (or very little) of the AC voltage is seen at the battery? Does the function generator need to be able to source much current? The system may pull 1 to 2 amps maximum. AI: Q: Can I put a large inductance between the battery and the capacitor such that none (or very little) of the AC voltage is seen at the battery? A: Yes, that is the way to go Q: Does the function generator need to be able to source much current? A: that depends on the AC input impedance of your equipment under test. (You can test it: The function generator will not get damaged)
H: Is there a chart that translates old tube symbol to the new tube symbol Im looking for a chart that helps you translates the old tube symbol into the updated format. AI: Your tube symbol is indeed ancient. It seems to be a triode having three elements: A directly-heated filament/cathode (filament + cathode are combined into one element) A grid A plate Most modern tubes have indirectly-heated cathodes. They separate cathode and filament into two separate elements. If you do have a tube with directly-heated cathode, you would show this as a filament, and omit the cathode. You should make it clear that the filament symbol serves two purposes: cathode + filament. Many modern tubes contain two triodes. Like 12AX7. They are shown with a split-open envelope. One would be titled 12AX7a, the other 12AX7b. Tube base pin #'s are very often added to a schematic. It is often customary to not show indirectly-heated filaments. Their wiring clutters-up a schematic diagram. Filaments are shown elsewhere on a schematic, with pin #'s and text added to show which tubes they belong to.
H: Is the transformer leakage inductance increasing or decreasing VS. size I have built an sine filter for a small inverter that feeds a transformer 250VA. The filter is basically a LC filter, that uses leakage inductance of the transformer with a capacitor connected in parallel to the secondary with a small value damping resistor. I did use the function generator and scope to tune the resonating frequency so that is below switching frequency of the inverter and higher than highest possible fundamental output frequency. But this was tight tune: \$F_{SW}=8kHz, \ \ F_{OUT_{max}}=400Hz\$ Now they simply changed the inverter and the transformer with more powerful one. Now I would like to ask what should I expect: the leakage inductance has increased, since the transformer is bigger? the leakage inductance has decreased? Logical assumption is that big transformer has very low leakage inductance, compared to small one, because otherwise they would fail to supply the powerline. simulate this circuit – Schematic created using CircuitLab AI: Let's call your small transformer the "apple" transformer, and your large transformer the "orange" transformer. You would expect that if you're operating at the same voltage but higher currents, that all of the inductances of the "orange" transformer are proportionally lower. So the individual coil inductances, and the leakage inductances, would go down. But you're comparing apples with oranges here -- in general this would be the case, and I would certainly expect that if I were shopping for transformers from a manufacturer that cared about consistency and quality that in general inductances would be roughly proportional to rated current divided by rated voltage and divided again by rated frequency. In fact, I'd expect smaller transformers to be "cheaper" in terms of all of their specifications compared to ideal. What I would not expect, however, would be that such trends were followed strictly, or that a manufacturer that doesn't care about quality would necessarily do what I expect -- even to the point of delivering product that actually performs as rated. So -- read the data sheet carefully, trust the manufacturer as far as you can throw their reputation, and if you're working on some one-off project with off the shelf or surplus parts, measure what you've got before you trust it.
H: What is "Supply Input for Analog Functions" on a buck converter? Regarding this datasheet for a DC Buck Converter, there is a VCC pin that on pg-2 shows an arrow pointing "out". What is this "out" connection arrow used for in practice? Further along on the datasheet (pg-12), they show a board layout with that pin connected to GND via a capacitor. Is that a viable way to connect this converter if I don't have a use for whatever that "out" arrow is for? AI: What is this "out" connection arrow used for in practice? It's on the first page: "The AOZ2253EQI-30 integrates an internal linear regulator to generate 5.3V VCC from input." It means that they make some regulated power available with all the advantages and disadvantages of a LDO linear regulator. I can't speak for anyone else, but if I used it at all, it would be for some low current consumption circuit that needed to come up before the switching regulator did. Is that a viable way to connect this converter if I dont have a use for whatever that "out" arrow is for? It's certainly what they call out. You do need the cap, according to the datasheet -- LDO regulators, particularly those of a certain vintage, tend to need them.
H: Trouble designing a low pass filter I was trying to design a simple 3rd order low pass filter by cascading 3 first order low pass filters along with an amplifier at the end. The transfer function is straightforward: $$ H(j\omega )=4\bigg(\frac{1}{j\big(\frac{\omega}{\omega_c}\big)+1}\bigg)^3 $$ where $$\omega_c=\frac{1}{C_f10k\Omega}$$ is the cut-of frequency. Thus when I want to make the filter have a cut off frequency at 1KHz I simply replace values and figure out Cf: $$ C_f=\frac{1}{2\pi\times f_c\times10k\Omega}=\frac{1}{2\pi\times10^3\times10\times10^3}\approx16nF $$ However the circuit below when simulated gives me a cut-off frequency of 500Hz. What am I getting wrong? simulate this circuit – Schematic created using CircuitLab AI: You cascaded 3 filters each with a cutoff frequency of 1 kHz. Since the cutoff frequency is defined as the frequency where the filter is 3 dB down, your cascaded filters will be 9 dB down at 1 kHz. The actual cutoff frequency of your cascaded filters is that for which the gain of each individual filter is 1 dB down which will be lower than 1 kHz. Your simulation shows it to be 500 Hz. If you really want a cascaded filter cutoff frequency of 1 kHz. you will have to increase the cutoff frequency of each of the 3 separate filters.
H: Is another diode needed when using a tip120 transistor? I am using the circuit in the second picture, which clearly uses a diode. (Found here) However the TIP120 data sheet transistor already has a diode in the schematic symbol. Do I need to add another diode (like in the schematic) or should I remove the diode in the circuit, as the transistor has one built in? AI: The datasheet does not say about the internal diode ratings, so external protection is a good idea when connecting to loads that may generate negative voltage undershoots. But what is important when driving inductive loads is that they can generate positive overshoots that can break the transistor, so there is even more need for a diode over the motor.
H: What kind of clamp is this? This clamp is being used on a piece of equipment that is a few years old. I am trying to identify the type of clamp this is. If you the reader cannot identify it, leave a comment with something similar that will not damage thin wire when clamped. AI: Ok, they look like the Kelvin clips on my cheap pair, which look identical to this one. Please note the insulated hinge found on both. Here is a set of clips from Amazon and one from Ebay. If so then you need to replace it with another Kelvin clip, like one of the following: Found at Amazon Found at Ebay AST Labs That is just a small selection.
H: ESP 01: Sketch uploading but not running I have this ESP8266 I've been trying to get to work with a USB to TTL converter. I can flash the code through the Arduino IDE to the ESP8266 and it supposedly succeeds, but the ESP8266 isn't running the code. If I try to make a Wi-Fi network (to create a webserver), it won't appear, and if I try to print something to the serial log, it won't appear. Here is a Fritzing model of my circuit: (Note: The pins of my TTL converter are actually GND, CTS, 3V3, TX, RX, and DTR. I wish I could change the text of the Fritzing part I downloaded, but it is what it is.) Here are the options in the Arduino IDE I used: Note: I saw this question, but the answer only made it worse (wouldn't upload at all), so I am asking this question. AI: The ESP8266 has different boot modes. i.e. The ESP-01 module will keep booting into uart programming mode if gpio-0 is connected to GND. You can verify this by taking a look at the serial monitor output while powering up or resetting the esp8266. In order to fix this, after the code is uploaded, you need to connect gpio-0 to 3V3 and reset the esp8266 in order to see the code running on the module.
H: Why are there so few oscilloscopes with dedicated isolated channels? Background I am a junior engineer who works with testing and designing inverters for motors. I have been looking at a new oscilloscope since the one I had gave up. There are a lot of Tektronix TPS2024b being used since it has dedicated isolated channels on it. I was not sure how isolated channels worked to begin with but I now understand their usefulness. It is very handy to have a scope being able to do the same measurements as a multimeter without making mistakes, but also very nice to be able to avoid long paths to ground for more precise measurements. So I decided an isolated scope that can measure high and low voltages well would be a a good choice for me, especially since differential probes sometimes can cost quite a bit, and adding that to the cost of the oscilloscope it quickly takes off. So I started looking and it seems it is quite unusual, very unusual in fact. So I thought it would be a good idea to ask here to see if you can tell me what I am missing. I have noticed that the bandwidth seems lower on the isolated scopes, but it is hard to draw any conclusions with so few alternatives to compare. Question(s) Why are there so few bench oscilloscopes with dedicated isolated channels? Is it a design issue, a cost issue, a business issue or is it just better with differential probes? Other Oscilloscopes I have found: Tektronix TPS2000 series (~15 year old design) Cleverscope CS448 Handyscope HS6 DIFF There are also some hand-held isolated oscilloscopes that I could add to the list but I have not written them down since I was not looking for a hand-held scope. USB scopes seem to me very good and like a no-brainer, if it is possible to get one. AI: Why are there so few bench osilloscopes with dedicated isolated channels? Is it a design issue, a cost issue, a business issue or is it just better with differential probes? It is a cost (price) and demand issue. Most users don't need isolated inputs. Most users have ground-referenced signals so a scope with non-isolated inputs is OK. Cost is an issue as isolated inputs require more complex circuits compared to the standard solution. This makes the oscilloscope more expensive. Also note that isolated inputs and differential probes are different things! You can use an isolated input as if it is a differential (floating) input but it's not really the same as the connection on the oscilloscope is a BNC connector which is a single ended input. The two electrical connections on a BNC plug aren't precisely the same, one is also the shield, the other (inner connection) is shielded. For DC and low frequency that usually doesn't matter much but for higher frequencies ore low noise measurements it can matter. Then a true differential probe is the better option.
H: What parameter of this sensor necessary to decide about the required ADC resolution? From the datasheet of this accelerometer, I need to decide about the adequate ADC resolution. If my reasoning is not wrong the output noise floor of this accelerometer will decide the adequate ADC bit depth. So if the accelerometer output has 1mV noise floor then a 3.3V 10-bit ADC would not be adequate because 3.3V/1024= 3.2mV. On the other hand a 16-bit ADC would be an overkill. Is my reasoning is correct? How can I refer find such parameter(noise floor) from the datasheet of this accelerometer and make a conclusion about the adequate ADC? I also cant figure out the outputs' voltage ranges from the datasheet as well:(( Is it mentioned in the datasheet what output voltages corresponds to -3g and +3g? AI: How can I refer find such parameter(noise floor) from the datasheet of this accelerometer The noise floor is suggested in the parameters in table 1 under noise performance. For instance, in the X direction the noise is typically \$150\,\text{µg}/\sqrt{\text{Hz}}\$. To make this a clearer number for your application you need to state the bandwidth of filtering you might use. So, if you are low pass filtering the signal to a 20 Hz bandwidth the RMS noise is \$150\,\text{µg}\cdot\sqrt{20} \approx 671\text{µg}\$. Convert this RMS value to a signal voltage seen at your ADC and you then have a noise voltage seen by the ADC. However, you may want to read this section: DESIGN TRADE-OFFS FOR SELECTING FILTER CHARACTERISTICS: THE NOISE/BW TRADE-OFF It gives you a little more information about filtering and anti-aliasing. It's on page 11.
H: What kind of FSM is it, if outputs depend on internally generated signals? The classical definitions are that in a Moore machine the outputs depend only on the state, while in a Mealy machine they are also allowed to depend on inputs. But what if outputs and/or state transitions and/or register transfer opertions depend on a signal, which is generated inside the module/entity itself and controlled by the state machine? What kind of finite state machine is it? Is it still a Moore machine? This question puzzles me since ever I learned digital design. Update: here a simple constructed example. let's there is a state that should be executed 5 times, and output a signal on the last. case STATE is--inside a process --other states when COUNT=> if COUNTER=4 then STATE_NEXT<=OTHER_STATE;--state transition depends on internal signal COUNTER_READY<='1';--external signal depends on internal signal else COUNTER_READY<='0';--external signal COUNTER_NEXT<=COUNTER+1;--increment counter. this RT operation depends on internal signal STATE_NEXT<=COUNT; end if; --when OTHER_STATE=>... end case; ``` AI: The counter value is actually part of the state of the machine. Everything that is stored in a flip-flop inside the machine and has the potential to change the behavior of the machine is its state.
H: Is this a reference of an AC/DC REGULATED adaptor? I need to choose an 230 VAC / 12 VDC converter which is regulated, that-is-to-say I need the voltage to be 12 V with a current of 0 to 5 A. I found this one because it is the cheapest (price really matters) : https://www.mouser.fr/datasheet/2/260/GSM60A-SPEC-1147092.pdf But I do not see any information regarding its regulation. Is it regulated ? Generally speaking, how do I know in datasheet if an adaptor is regulated or not ? Thanks. AI: You read the datasheet specifications on line and load regulation and voltage tolerance and see if it meets your specific requirements. The devices in that datasheet sport total voltage tolerance of +/-2.5% to +/-5% depending on model, including line and load regulation. I don't see a temperature dependency specification. So if you buy a +/-3% 12V model, the average (nominal 12V) output will be between 11.64V and 12.36V at 25°C ambient for all valid combinations of mains input and load. There will be some ripple on top of <100mVp-p under the specified conditions. Since the input can vary from 80 to 230VAC (or 113 to 370VDC) with the output varying less than +/-1%, obviously it's regulated.
H: Is current provided by a transformer fixed? I would like to connect a bell to a transformer as part of a project im working on. The only thing i cannot seem to find an answer to is wether or not the output from a transformer is fixed: Say i was to plug a 24v 330ma step-down transformer into the bell (which operates at 24v 30ma), what would happen?: A: The transformer overprovides, the bell takes everthing it's given and burns itself out. B: Only the required amount of current is taken by the bell and everthing operates as normal. C: Something else (?). AI: B, power supply is capable of providing more amps than the load requires.
H: What 'rated voltage' means in VDE certificates? In a VDE certificate for a component (plugin green terminal blocks), a column gives the "Rated voltage(s) / V" with a value of "400" without specification wether it's VAC or VDC. Does this mean that the component is safe to use for both DC and AC at this voltage ? A 400VAC voltage will be applied on the component (three phases, one neutral, one earth wire / Europe). As the voltage on the electrical network can fluctuate, is this "rated voltage" given with these variations taken in consideration ? AI: Unlike switch contacts that can break inductive current, without looking up the relevant std. specs. I say both AC & DC. It's my opinion that the basic insulation here applies to both AC_rms and DC. For moving contacts the DC rating can be <1/3 Vac rating which does not apply here. These tests include lightning impulse AC voltage. There would be some industrial contamination level provided in the spec. There is no reason to derate a Terminal block for DC vs AC so the same level applies. That would be true for 70kVdc as it is for 400Vdc. Beyond this the pollution level is a critical factor design factors for creepage, which does not apply here, just FYI. If you are doubtful on the pollution or dust levels, add a dust shield.
H: External 0~10v controlled by a MCU Newbie question : I have an external power supply which gives me 10volts reference. The machine I need to command is reading an analog order from 0V (minimum speed) to 10V (maximum speed) and I use a STM32WB55. My solution is to add a DAC and then an op-amp. Do you see another solution? Thank you AI: 1) PWM output and low-pass filter 2) digital potentiometer.
H: Using LED driver as PWM digital outputs I'm building a robotics project where I need to control a lot of DC motors. I picked the DRV8870DDAR H-bridge motor driver chip which needs 2 PWM input signals to control the speed and direction. Since I need a lot of PWM signals, I'm thinking of driving them with a TLC59116IPWR LED driver. Unfortunately all LED drivers I found are built to sink constant current. To turn it into a digital signal I've added a 10K pull-up resistor to the signal line. Switching the "LED" on should then sink 0.5mA (at 5V) current from the resistor and output a LOW value. See the schematic below; the PWM0A line leads to the motor drivers: My question is whether this will work fine? If not, is there any alternative I should look for? My worry is that the 0.5mA current I need to sink to output a LOW signal is too low for the chip to work. In the recommended section it mentions 5mA minimum output current, but that seems to be the lowest constant current target I can set via the REXT resistor. I don't know how the internals of the chip works, so I'm unsure if that's a problem. AI: Don't (ab)use an led driver for this purpose. Even though it'll probably work as push-pull-multiplexer (with little disadvantages though) there are dedicated ICs that do exactly what you want. Search for "24 channel SPI PWM controller" and you'll find a device I would recommend.
H: S parameter meaning I have designed a rectangular patch antenna and have tested it. From the results I noted a value of - 25dB on the S11 parameter graph. The - 25dB is also at my resonant frequency of 915MHz. Is this a reasonable value for a patch antenna? The application for this antenna is in the RFID sector. It has a gain of 2.5dBi and measures at 20x20cm. AI: S11 is the return loss. -25 dB is very good for a return loss parameter, almost too good to be true. This means that only 0.3% of the input power is reflected back to the source, and implies an almost perfect impedance match at the input to your patch.
H: Current measurement opamp, is this circuit flawed? Output all over the place This is a circuit to measure a current flow that is 0-10A DC. The output goes to an ADC. The circuit itself works fine, however, over a dozen cards, the output of this circuit is all over the place. At rest, I=0, the output offset can vary by a factor 10 (300 to 3'000 count on the ADC) from one board to another; but is stable in a specific board. So far, it might be related to the input offset voltage, given at 0.11mV typ. but this would account for perhaps 10%. The manufacturing of the cards was also poor and noticed some pads seem not well soldered, I wonder if that could be a cause as well. Are there other fundamental flaws in this circuit? I need to fix an existing batch of boards. VDD: 3.3V ADC is 0-3V with 0.1% reference. the ADC is not saturating. ADC is 12bits, 16 measurements summed: 16*12bits = 65535 counts. Two random cards measured at rest I = 0A voltage at the circuit output: A: 150mV / 3445 count B: 34mV / 336 count AI: Your input signal is 10A, which through your R19 sensing resistor develops a voltage of 10mV. Your opamp is specified with a maximum offset voltage of 7mV, which is 70% of full scale! Note, calacuating the offset like this, it doesn't matter what your gain is (it's about x250), or your ADC resolution or scale, it's presupposes you have the gain and ADC correct to get a full scale measurement, and gives the offset in terms of full scale. You have several options: 1) Calibrate the offset. The specified offset drift is fairly small, 1uV/C, or in full scale terms 0.01% FSD per degree C, which also fits with your description of the error being stable on any particular board. 2) Use an amplifier with a bit better offset, down to 1mV should be easily acheivable for not too much money with a bit of research. Offset down to 10% FSD. 3) Use a 'zero offset' amplifier, chopper or AutoZero based, which will be pricey, but will work. There are several options now from the big beasts TI and AD, which will get you 0.01% FSD offset. 4) Can you increase the size of R19? 10mV is quite a small burden voltage for an ammeter, though it could be all you want to budget for an in-circuit meter.
H: what is the pin connectors called that is used on through hole pcb with space above for swappable microcontrollers (or other devices)? I have a medium size through hole PCB for prototyping. I remember a project in school that gave us a female to male connector that allowed us plug in a microcontroller (atmega328p, but could be any length of ucontroller) by hand without soldering or directly wire-wrapping the atmega's pins. It provides black spacing above the PCB for the microcontroller's pins, but we solder the bottom through hole side (I believe the through hole was the standard 2.54 mm round opening). And the above female accepted the standard 2.54 mm as well. Not sure of the length of the metal. I just remember the black portion was that standard plastic material that would melt when applying too much time soldering the metal. I think its through hole DIP socket header but when I google that I can't find it exactly. AI: sounds like some sort of IC socket ordinary flat pin or perhaps machined pin: But sometimes a lever-operated zero insertion force socket is used
H: Why does the MAX30102 only work on a finger? I am using a MAX30102 sensor with Sparkfun library for heart rate monitoring. It does work for a finger, but when the sensor is mounted on chest I am not getting a reading. Why is that? AI: The article that Transistor pointed to goes into some detail on how pulse-oximeters work. I won't try to reproduce all of it, but I'll summarize: A pulse-oximeter counts the pulse by detecting changes in the light passed through the blood due to the increased volume of blood during each heart beat. The article uses a pulse-oximeter with the emitter on one side of the finger and the detector on the other side - it works "through" the whole finger tip. The MAX30102 is a reflective type - the emitter and detector are both on the same side. That looks a little different, the principle is the same. Now, as to why the MAX30102 works on your finger but not your chest: Your finger tip has fairly decent blood flow. There are arteries in the finger tip that transport a lot of blood. The pulse-oximeter detects the blood flow in the arteries. Your chest doesn't have much in the way of arteries. The skin has a lot of capillaries, but no larger arteries. There are arteries in the muscles beneath the skin, but they are too deep for the pulse-oximeter to "see." The LEDs have a limited light output (brightness.) That limits how far the pulse-oximeter can "see" into or through your body. The brightness is limited for a couple of reasons: Low brightness = low power. The MAX30102 is intended to be used in battery powered devices. Low power means longer run time for the device - or a smaller battery. High power would be warm or even hot, possibly causing burns to the skin. Short version: There's not enough blood flow through the skin of your chest for the MAX30102 to detect a pulse in it. While the article linked above gets the technical details correct (it correctly describes how a pulse-oximeter works,) it consistently gets the location of the arteries in the finger tip wrong. It shows the arteries on the top of the finger (same side as the finger nail) when in fact the arteries run along the "pad" side opposite the finger nail. This drawing shows what I mean: (Image taken from this paper on reattaching fingers. Arteries in red, veins in blue. Fingernail is drawn on the dorsal side.) I figure a couple of doctors who reconnected arteries and veins on 24 fingers should have a good grasp of where the arteries and veins actually run.
H: stm32 which timer and DMA channel should I use? I am trying to control two lines of digital LEDs (WS2812b) with my STM32F103 using Timers with DMA and PWM. LED strips data lines are connected to PB5 and PB6 of the MC. I used STM32CumeMX to create the inital code for my project. I click channel 1 and set it to "PWM Generation CH1". PB6 tuns green and in DMA settings it says TIM4_CH1 and DMA1 Channel1. Looks OK, and it works. But when I try to configure PB5 weird stuff happens: I select TIM3 and Channel2. PA7 turns green(!?). I click PB5 and select TIM3_CH2 manually. The black pin appears next to it. In DMA settings it says TIM3_CH4/UP(!??) and DMA1 channel 3(!???). What is the logic here? What does /UP even mean? Where are all possible combinations of Timer/DMA channel are listed? As the result PB5 does not work. Also I noticed that CubeMX produces this: /* Several peripheral DMA handle pointers point to the same DMA handle. Be aware that there is only one channel to perform all the requested DMAs. */ __HAL_LINKDMA(tim_baseHandle, hdma[TIM_DMA_ID_CC4], hdma_tim3_ch4_up); __HAL_LINKDMA(tim_baseHandle, hdma[TIM_DMA_ID_UPDATE], hdma_tim3_ch4_up); I deleted the last line, but it didn't help. I just want to configure PB5 similarly to PB6. What am I missing here? Is it possible to use DMA on PB5 at all? AI: TIM3_CH2 can be connected to one of two pins: PA7 or PB5. When you select TIM3 & PWM Generation CH2 in CubeMX, it assigns it to PA7. You can CTRL+Click (and hold both) to PA7 and see that PB5 highlighted. Then you can drag & drop it while holding the CTRL key. The black pin means that it's manually assigned and CubeMX won't move it if you try to enable another peripheral which uses the same pin. If you refer to the Table 78 in the reference manual, you see that DMA1 Channel 3 is shared by TIM3_CH4 and TIM3_UP (update event, basically timer overflow). That's why it's named that way in CubeMX. When a DMA channel is shared by more than one sources, you shouldn't enable more than one at a time. Update: After the OP's comment, I realized that I overlooked Table 78. It appears that TIM3_CH2 is unable to make a Capture & Compare DMA request as it's not present in the table. However, I also realized that what you actually need is a DMA request tied to the update event. This allows you to update CCRx registers every time TIM3 overflows. You can even update all the CCRx registers at once by using the DMA Burst Mode of the timer. BTW, DMA capabilities are not related to the pins that peripherals use. So, it doesn't matter if it's PA7 or PB5. CubeMX shows TIM3_CH4/UP option because the update event is not related to any timer channel and that DMA request is available even if no CH pin is used.
H: Proper way of connecting wires to pins on polymer films What is the proper way to connect wires to contacts from a thin semitransparent "plastic" foil (see images). There are slightly different types; the first one with the 4 pins in a row is the more important one)? It is a thinflexible foil with pressure sensors, which are connected via the thin metal streaks to the "pins" on the right. Just solder, or are there kind of clamps that I can use? Are there any normed/standardized connectors/clamps? I'd like the contacts to be as "non-destructive" as possible (considering my current soldering skills, to be honest, but I can try to improve), and to be absolutely as flat and stable as possible (max. 1 mm (ok, maybe I have to relax that to about 3 mm), must stand a person's weight stepping on them multiple times). I was searching on the web for a long time w/o success, and realize I may not even know the correct term for this kind/type of electronic constructions on foils, so even that might help a little bit - may I ask you to tell me the correct name? AI: The fact that they are shaped more pointedly at the end suggests that these are in fact meant to be directly soldered. max. 1 mm, soldering seems to be your only option, then. must stand a person's weight stepping on them multiple times That sounds questionable, at best. Wire-to-anything-solid connections are notoriously prone to breaking under repeated stress; you'd want to add enough housing and strain relief to make sure pressure is only (if at all) applied flat on the contacts, and nothing pulls or shears on the cable connection. In fact, since this probably has to go into a housing with confined space: Consider designing a flex PCB with matching contacts on one and, solder to that, and use it to get the signal out of the mechanically stressed region.
H: 8085 SIM instruction don't care bit While reading about the SIM in 8085 i came upon the accumulator state at the data pin 5 where when SIM instruction is executed we have to consider pin 5 of the accumulator to be don't care. So I am not able to understand why do we need to define or mention about a don't care bit while processing the SIM instruction execution? AI: In defining interfaces between hardware and software (because that's what the SIM - Set Interrupt Mask instruction does), it is good practice to tell the user, the programmer, what all the bits mean, and what they do, or don't do, so that the programmer doesn't have to guess.
H: Electret microphone weird offset problem Hi I am trying to amplify my output from electrec (analog microphone) with below design. When I used 1uF capacitor it has -300mV offset, so that I changed capacitor to lower value with trial-error applications. With 200pF ı was able to remove offset (it was something like -10 mV). But when I connec it to an opamp it had an offset again from the same point! To be more clear When I don't connect it to opamp I was getting a nice output from the - leg of the capacitor. When I connect -leg of the capacitor I got an offset around -200 mV from the -leg of the capacitor. Which is really weird I think I couldn't come up with a solution. I am Using LM741 AI: The electret microphone has a FET buffer inside of it and has a DC offset. The capacitor blocks the offset, however you need a path for the bias current of the op-amp. Bias current is a current flowing into or out of the op-amp input. The capacitor also blocks that voltage, so it will tend to float up towards one rail or the other rail depending on the op-amp. A resistor to ground is the usual way to provide that path. The pole formed by the capacitor and the resistor to ground gives you low frequency roll-off. So if you use a 100K resistor to ground and a 0.1uF (100nF) capacitor the response will be -3dB at 16Hz. If your op-amp has a bias current of 100nA then the input offset due to the 100K resistor will be 10mV (the op-amp will have a bit of offset voltage in addition, which may add or subtract from that). If you match the resistances seen at the inputs the total input offset may be less if the input bias currents are well matched, however that's not always necessary or desirable. simulate this circuit – Schematic created using CircuitLab The LM741 has a typical input bias current of 80nA at room temperature (though it can be as much as 1.5uA under extreme conditions). 80nA * 100K is 8mV. The op-amp has an offset of typically +/-1mV so the typical output offset with your gain of 11 should be less than 100mV at room temperature.
H: How optical sources having narrower spectral width gives higher data rates? How optical sources having narrower spectral width '\$ \Delta \lambda \downarrow \$' gives higher data rates '\$ R_B \uparrow \$'? For example: Laser having lower spectral width gives higher data rates ,similarly LED having higher spectral width gives lower data rates My Thoughts: For Laser: Typical spectral width \$\approx 1\$ nm Let us consider the wavelength of light \$ \lambda= 1000 \$ nm,then $$\because \frac{\Delta \lambda }{\lambda}=-\frac{\Delta f }{f}$$ \$\implies \Delta f= 300 GHz \quad \because f= \frac{c}{\lambda} \to f=300THz \$ $$\implies R_{B_{max}}= 300Gbps$$ Similarly, For LED: Typical spectral width \$\approx 20\$ nm so,for the same wavelength of light \$ \lambda= 1000 \$ nm \$\implies \Delta f= 6 THz \$ $$\implies R_{B_{max}}= 6Tbps$$ But,this contradicts the fact that optical sources with narrower spectral width gives higher data rates, So, where i have done the mistake? Any help please... AI: You're probably missing one thing : the transmission medium. Optical sources for high bandwidth communications normally use glass as the transmission medium, in the form of optical fibre. Now the glass is carefully chosen, and I expect one of the factors they optimise for is low dispersion, yet I don't believe the dispersion is 0. (EDIT : confirmed by a commenter : dispersion is deliberately engineered, to mitigate non-linearity by dispersing the mixing products). Now in a dispersive medium, different frequencies travel at different velocities. Thus a pulse will smear out as it travels down the fibre, according to the different propagation speeds of its spectral components. The receiver will see a sharp pulse after a 1 km fibre, a broader pulse at 10 km, and broader still at 100 km and so on. Thus the pulse width depends on the dispersion of the medium, the link length, and the frequency spread of the signal. And that pulse width determines the usable data rate. A narrower line width reduces pulse broadening due to dispersion, enabling higher data rates for a given link length using a given dispersive medium. (Improvements to this answer from an electro-optics specialist are welcome).
H: Adapting the 74LS170 open-collector "register file" to active-high TTL input This is a question related to swapping a 74LS170 4 x 4 register file chip for a 74LS173 single 4-bit register. In the other question I wonder if there are even simpler ways to Turn a positive clock edge into a negative pulse to make a 74LS170/670 register file synchronous. But here I need to deal with the issue that the 74LS170 is an open collector chip (and for now I am unable to get the '670, which is a three state). I read a number of things about open collector, and especially the other pretty decent entry here Understanding Proper Implementation Of Open-Collector. However, I think I need to get spelled out a clear "yes" or "no" answer to my following doubt: If you want to drive further TTL inputs from open-collector output, you need to consider your signals effectively inverted. In other words, you can tie the open collector output pin high, and then when it is active it will be pulled low through the enabled transistor. There is no way to source current from an open-collector output. Hence, if I want to use the 74LS170 as an actual register file, I need to also use an inverter for the 4 bits. It just so happens that if I actually want to turn the 74LS170 into a synchronous register whose load is driven by the positive clock-edge, I need the inverter anyway, along with an OR gate. So there simply is no other way. simulate this circuit – Schematic created using CircuitLab Or is there? As a bonus question: the '670 was developed much later, supposedly, and it has 3-state output, so it no longer effectively inverts the output. But why in the world would they not have driven that by a positive clock edge, instead of using the pin for the 3-state logic? I mean, nobody could have just dropped in the '670 for the '170 because the sense of the output bits are inverted. Why even bother with the 3-state then? I feel that the answer to this question might help me appreciate the annoying situation with the open-collector need for inverters. Or, another one of those pleading questions: was the open collector output so much easier to do that they would determine that it's better this way than to let the user add their own (power) transistor to adapt to voltage and current levels? And finally an idea: perhaps this explains the odd customs with these active-low signals on most "load" or "write enable" pins of most flip flops and SRAM and EEPROMs? And from there, perhaps, by using open-collector OR gates instead of normal TTL outputs, I effectively get NORs and other inversions which might simplify my clock edge detection IC overhead? Yet another possible explanation: if the register file's output is expected to be output onto a bus, were the original designers expecting that it be connected as an effective NAND gate with the other devices on that bus? Still can't quite see the rationale for this. Final whining question: so why in the world would I even want to use the 74LS170 (even decades ago) when with all the work I need to go through I can just as well adapt the 74LS189, fitting it with a clock edge detector and the inverter, using the same number of chips I get 16 instead of just 4 registers? (OK, because I can not read from one address and write to another in the same cycle, fine.) AI: The 74LS170 is not inverted from input to output even with the open collector outputs when looked at logically (i.e. input pin to output pin); the datasheet truth table shows it, but a better source is the logic diagram. Looking at the inputs (at the top), the inputs are inverted prior to storage (in the red ellipse) and therefore what is actually stored in the internal latches is \$ \overline D_n\$ When reading the data back out, the effective open collector inversion (in the blue ellipse) converts the stored data back to the original input. Open collector predates tri-state outputs by some time (possibly decades) and was used primarily for bus applications (so that one of many outputs could drive a single signal line); tri-state achieves the same thing but by disconnecting the output from the signal line, but came much later and when it first showed up there was a significant price premium and it had it's own issues when used (the timing between driving nodes needs to be controlled so that we don't get bus contention; an issue that is irrelevant in open collector architectures). That does not mean we don't have to take timing into account - we do but in open collector there won't be any damage to parts if two (or more) outputs happen to be driving the same line at the same time, so from that perspective it is much easier. The concept of Wire-OR (or really wire-AND) was specifically designed so that we could have an effective output gate on a bus as effectively a data selector [we needed to know which output we had selected. of course] (apart from the numerous other applications it is used in). As noted in comments on your other question(s), when the '170 came out it had designers drooling (dual port, read from one register while writing to another enabling primitive pipelining) - it really was a 'wow' part at the time. As you note, the '670 came out quite a bit later (when tri-state was more the norm in bus architectures and had become the de-facto standard and the price had dropped). Tri-state has advantages of course; rise and fall times are close to equal because they are actively driven for both high and low (in open collector the effective RC time constant had to be evaluated for how fast the signal line would rise back to a high). So it is a mixture of target application and history as to which type of output is suitable. The 74LS189 was introduced (if memory serves) around 1980, some years after the '170 (almost 10 I believe). Open collector is also often used in window comparator circuits, incidentally.
H: Why do we have to discharge the capacitor before testing it in an LCR Meter? LCR meters charge and discharge the capacitor to find out the capacity value (by using the time constant formula.) I wondering why a charged capacitor(even few volts) can damage the LCR meter? Why do we have to discharge the capacitor before testing it in an LCR Meter if the tester must charge it to find out the capacitor value? AI: Both of the meters in question use some means of charging the capacitor under test by driving it with a controlled current and measuring the time it take to go between two voltages. When you charge a capacitor with a constant current the voltage rises linearly. (From \$ V = \frac {Q}{C} \$ we can differentiate to get \$ \frac {dV}{dt} = \frac {1}{C} \frac {dQ}{dt} = \frac{1}{C} I \$ since current, I, is charge per second. These circuits are typically powered from a 9 V battery and the actual test voltages will only be a couple of volts. Capacitors, on the other hand, may be rated at much higher voltages - hundreds of volts - and if a charged capacitor, even if only a few volts higher than the test range, may destroy the test circuit. In practice a small charge of one or two volts shouldn't cause a problem other than a reading error.
H: Output voltage of AT28C64B into HC CMOS IC I am trying to load the output of a AT28C64B parallel EEPROM into a 74HC194 shift register. The datasheet for the AT28C64B states that the minimum high level output is 2.4V, which I believe is not enough to drive the input pins of the HC type shift register. Therefor, I considered running the 74HC194 on 3.3V, and using a level shifter for the other input. Then 2.4V should be enough. But when doing measurement, I found that the actual output voltage from the AT28C64B was 4.8V, which is too much for the 74HC194 running on 3.3V. The AT28C64B is powered with 5V. So what should I expect the output voltage of the AT28C64B to be, and how can I ensure that the output voltage of the AT28C64B and the input voltage of the 74HC194 matches. AI: Few different solutions. In general TTL outputs are made compatible with CMOS inputs by using pull-up resistors. Put pull-up resistors on EEPROM output to make them go up to 5V, and switch the shift register to 5V. Another solution might be to use HCT type shift register that has TTL compatible inputs, but it would still require 5V supply for the shift register.
H: Why did they design new connectors for USB? At the time when the USB standard was being developed, there were a number of widely-available connectors that they could have used instead of making a new custom connector. Why did they not use mini-DIN or DE-9 or some other common connector of the time, instead of inventing entirely new physical connectors, which would then need to be manufactured with entirely new (expensive) machinery? I can think of a few possible partial causes (e.g. something new would be less confusing to consumers, or maybe the new connectors are more mechanically sound than anything else available at the time) but I'd like to see a more developed analysis of what was available at the time and why it wasn't suitable--and hey, maybe someone who actually worked on the spec can give the actual definitive reasons, if we're lucky. AI: Most likely many reasons, at least the following. It was a requirement for the connector to support hot-plugging. The connectors you mentioned do not support hot-plugging. Using an existing connector also means it is possible for someone to plug in two incompatible devices together just because they use the same connector. The connector also needs to support enough mating cycles to be usable. And the connectors you mention are old, as technology to make connectors advances, it makes sense to use that technology to make a modern connector that is smaller and more durable and otherwise better, and most importantly, a connector that is suitable for the specific application.
H: How do I really turn 3.7volts to 5 volts (simple explanation, please) Look I understand a couple of things in electronics but I need clarity with this one thing. See for power banks to produce 5 V from 3.7 V, how exactly is an inductor used? I have a 5 V regular and I know how to use it but I need to know how I need to use the inductor to first step up my 3.7 V supply. Do I connect the power source, inductor and capacitor in series then put the regulator across the capacitor to extract the output or combined power source + inductor output? Do I add a transistor in the circuit and put an oscillating pulse at the base so the circuit can turn on and off, is that how you use inductors? I need to know, to have more voltage in a circuit, do you connect everything and the output is made high or do you need to make the circuit go on and off first before you get a voltage higher than the power source? How DO YOU USE AN INDUCTOR PLEASE? ON AND OFF OR JUST NORMAL UNINTERRUPTED DC SUPPLY? AI: Ever got that big voltage spike when de-energizing a relay without diode? A boost converter uses exactly that effect. Except instead of shorting this surge, it stores it in the capacitor. Controlled, many times a second. I suggest you try to build one. Tip: MC34063 Tutorial by EEVBlog
H: Implementation of Adjustable Current Limiting Circuit I have a circuit that can deliver 0-10V and 0-100mA to a load, and want to have an adjustable current limit that will limit the current delivered. To do this I have a current shunt that I monitor, and when the shunt voltage exceeds a threshold a error amplifier starts to turn off a NMOS transistor M1, that behaves as an adjustable resistance. The NMOS drops the voltage at the load to the desired value. When the current is underneath the threshold, U1 is saturated on and M1 is completely on. This circuit works, but has to have compensation that slows down it's response, or else I see oscillations due to the feedback loop. The real problem is that the circuit takes too long to kick in, and lets the current pass through for a time. The load current is limited properly eventually, but before that it receives all the current the source can provide. The voltage at the gate of the NMOS slowly ramps up until its DS resistance provides the correct voltage drop to pass only 50mA. Ideally I would like to see a damped response where the current ramps up, and if starts to exceeds the limit it stops. Is there a good way to implement that with this circuit? I have looked into NTC/PTC, but due to the fact that if the user wishes the current limit can be changed to arbitrary values I don't think they will work as intended. For example, if the current limit is 5mA, receiving 10mA delivered is a failure. But if the current limit is not set, any current from 0-100mA is acceptable. This means that the temperature isn't really a good indicator of if the circuit needs limiting or not. My current thought is to use a comparator that will control a transistor that will steal all of the current from the load until the value is stabilized. This means that during over current events, the load voltage will temporarily drop to ~0V until the voltage ramps back up to the limit. Additional notes: I can't change the supply rails of the error amplifier U1. U1 and M1 don't need to be the OP07 or FDR84OP, I just used them for testing. AI: The problem you are hitting is common to all voltage sources that have current limiting. Consider a lab power supply, where you've dialed in 10V, 100mA. You haven't connected anything to the output posts, so it is in CV mode, holding the output at 10V. If you now connect a 1Ω resistor, the lab supply should quickly switch to constant-current mode; however this cannot happen instantaneously. There will always be some capacitance present at the output, the PSU needs it for stability. Lab PSUs are typically designed to have low capacitance outputs for this exact reason, but as said some capacitance is unavoidable. This capacitance quickly discharges through the 1Ω you connected, so the load (= the resistor) receives a current that exceeds the limit many, many times, for this brief moment. Your circuit does not exhibit this specific issue, however it is of the same general kind: the voltage at the output of a power supply cannot change instantaneously, so some brief overcurrent should be acceptable, and I don't think 1ms is that bad at all. Your comments that you also have a voltage limiter (not shown in the circuit) hints at that you've designed your own linear regulator, too. You can ask this as a separate question, I suspect that part can be improved. The current limiting part is not bad as far as reaction time is concerned. I would be more worried about the oscillations you have until the current stabilizes though - the feedback loop needs more dampening.
H: Bridge rectifier outputting 338 volts DC with 120 volts AC input I am measuring the live voltages right now and am seeing these numbers. I thought 338 volts DC was the result of rectifying 240 volt AC? I understand that 120 volts AC is the Vrms reading and that the Vpeak reaches up to 170 volts. I just don't understand how I'm getting 338 volts from 120. The number ~338 comes from the peak voltage of a 240 volt RMS: \$240\sqrt2 = 339V\$ I am using one of these types of rectifiers (not this exact one because I cannot find any details about the markings on the one I have it says PEC 5079: The voltage read between the two center pins is 120. The DC voltage read from the outer pins on my DMM says 338. This seems impossible? Could it be my meter is faulty? It has always been decently accurate for everything else and I've had it for over a decade. AI: Sounds like you have something resembling a voltage doubler, albeit one with very little current output capability. The top schematic is a conventional voltage doubler as found in classic 120/240 power supply designs with a voltage switch. The bottom schematic is what you have described. simulate this circuit – Schematic created using CircuitLab Here is a simulation of the output voltage of each circuit: The blue trace represents the top circuit, and it provides a smooth DC output if the capacitor is large enough in relation to the load. The orange trace represents your described circuit, and as you can see, it averages out to almost the same voltage. If you put a substantial load on the bridge output the voltage will drop to closer to the average (not peak) abs voltage on the mains, more like 108 VDC.
H: High power opamp-based constant current source circuit I am currently working on a high-power 28S lithium-ion charger for EV. I'm on a constant current stage, so you don't have to worry about all that balancing thing, I just want a constant flow of 15A through my 28S cells. I looked upon some circuits online that achieve a constant current with a control loop with an op-amp and a current negative feedback as can be seen in the following image: This is all fine and standard and I get how it works, basicly the opamp increases its output voltage until that is negative input current feedback is the same as its positive input. However, I was looking for some other proper charger circuits and stumbled upon the an iMAX B6 like circuit, which is can be seen here: RC-Power_BC6_Charger I am trying to analyse this circuit and my question briefly is: what those parts I marked are responsible for? I get R7 and C3 form a low-pass filter, as well as R17 and C14 and I think R14 adds a gain to the circuit. But I don't get what those marked parts are for. I though I was some sort of summing amplifier, but this got me nowhere. AI: The input to R22, labelled OC1A appears to set the output current level. At a guess, it's a 0-5 volt signal. The two 100k resistors drop this to 0 to 2.5 volts. This is important because PA7 appears to be a digital signal which forces the current to zero by forcing the - input of DA1:2 above the 2.5 volt maximum of the + input, driving the output of DA1:2 low, thereby turning off the FET. In normal operation, PA7 is held low, and the diode is back-biased, so it has no effect. R37 is there as a safety feature. If PA7 is completely absent, such as might happen if the source of PA7 loses power or there is a cable break, R37 pulls up the anode of VD2 and forces the output current to zero.
H: What type of glass fuse is this and what does the spring do? This is a standard sized glass fuse like what cars used before the 80s. I can faintly make out 20A, but I’m not sure what to call it in order to find a replacement. The fuse in the picture has not blown, but it is the only one I have. I don’t think it matters, but this happens to protect a transformer for a pool salt generator. I’m also interested in what purpose the spring serves. I’m sure I can find another 20A fuse, but I’m not sure I can find one exactly like this, so I’d like to know why it is special. AI: 20 amp glass cartridge type slow blow. It has a thermal mass that generates a delay before the solder melts at the left hand end. The spring pulls the mass away from the wire, making sure the two conductors separate and stay separated.
H: Possibility of dissipating 20 W via Nichrome wire safely I am looking to use 1 foot (0.3 meters) of 32 AWG nichrome wire to dissipate roughly 20 watts of power. Assuming the wire was submersed in still transformer oil, would I be able to do this without melting the nichrome? AI: Let's try to ball park this to see if it's reasonable to use only 12" of such thin wire dissipating 20W: The surface area of your AWG32 wire is \$\pi \cdot \text {(0.008")} \cdot\$12" = 0.3\$\text{in}^2\$, so the watt density is 67W/\$\text{in}^2\$. Maximum recommended watt density for vegetable oil with operating temperature of 400°F is 30W\$\text{in}^2\$, and even less for lubricating oils with 250°F operating temperature (more like 13-23W\$\text{in}^2\$) so I would say that you are likely well above the maximum watt density for reliable operation using transformer mineral oil. You would be better off using a commercial cartridge heater with a much lower watt density (much more surface area but similar wattage).
H: Passive bandpass filter simulation gives wrong cutoff values I'm simulating the following passive bandpass filter in LTSPICE, and can't figure out why my calculated cutoff values don't match the -3db values in the simulation. Here's the circuit I'm simulating: Here are my calculations: \$f_{cutoff, HPF} = {\frac 1{2π(20k)(100p)}= 80kHz}\$ \$f_{cutoff, LPF} = {\frac 1{2π(1k)(1n)}= 160kHz}\$ Here are the simulation results (See the values in the lower left for Freq and dB): Maximum value of plot is about -0.4dB @ 106kHZ: Measured HPF cutoff is around 6kHz @ -3.4dB: Measured LPF cutoff is around 1.8MHz @ -3.4dB: So what gives? Why are my calculated cutoff values so much different than my simulated cutoff values? AI: Just "fill in the blanks." Suppose we use Thevenin for the left-most divider network to find: $$V_\text{X}=V_\text{IN}\frac{R_2}{R_2+Z_{C_2}}$$ and $$Z_\text{X}=\frac{R_2\,Z_{C_2}}{R_2+Z_{C_2}}$$ With that Thevenin source (whose \$Z_\text{X}\$ is now in series with \$R_1\$), it then follows that: $$G_s=\frac{V_\text{o}}{V_\text{i}}=\frac{R_2}{R_2+Z_{C_2}}\cdot\frac{Z_{C_1}}{R_1+Z_{C_1}+\frac{R_2\,Z_{C_2}}{R_2+Z_{C_2}}}$$ Of course, \$Z_C=\frac1{s\,C}\$. So, with a little bit of algebra stuff: $$G_s=\frac{R_2\,C_2\,s}{s^2+\left(\frac1{R_1\,C_1}+\frac1{R_2\,C_2}+\frac1{R_1\,C_2}\right)s+\frac{1}{R_1\,C_1\,R_2\,C_2}}$$ Set \$\alpha=\frac12 \left(\frac1{R_1\,C_1}+\frac1{R_2\,C_2}+\frac1{R_1\,C_2}\right)\$, \$\omega_{_0}=\frac1{\sqrt{R_1\,C_1\,R_2\,C_2}}\$, and create the unitless \$\zeta=\frac{\alpha}{\omega_{_0}}\$. It follows that \$f_{_0}\approx 112.54\:\text{kHz}\$ and \$\zeta\approx 8.132\$. We want to find \$K\$ such that: $$G_s=K\:\left[\frac{2\zeta\,\omega_{_0}\,s}{s^2+2\zeta\,\omega_{_0}\,s+\omega_{_0}^2}\right]$$ (If you are curious about the separation of these two factors, examine what happens to the second factor when \$s=j\,\omega_{_0}\$.) We find here that \$K=\frac{R_2\,C_2}{R_1\,C_1+R_2\,C_2+R_2\,C_1}\$. (You can instead just compute \$K=\sqrt{G_{j\,\omega_{_0}}\:G_{-j\,\omega_{_0}}}\$, but there are less formal methods of getting to the same place.) With your values, I find \$K\approx 0.08695\$ or that the filter peaks at about \$-21.214\:\text{dB}\$. The denominator is quadratic and the roots are: $$\begin{align*}\left\{\begin{array}{l}s_1=-\alpha+\sqrt{\alpha^2-\omega_{_0}^2}\\s_2=-\alpha-\sqrt{\alpha^2-\omega_{_0}^2}\end{array}\right.\end{align*}$$ \$\zeta\$ is handy. The following cases arrive (if you look at the square-root term of \$s_1\$ and \$s_2\$ you may note that it can be imaginary or real): $$\begin{align*}\text{Damping factor conditions}\left\{\begin{array}{l}\zeta = 1 \left(\alpha=\omega_0\right)&&\text{Critically damped}\\\zeta \gt 1 \left(\alpha\gt \omega_0\right)&&\text{Over-damped}\\\zeta \lt 1 \left(\alpha\lt \omega_0\right)&&\text{Under-damped}\\\zeta = 0&&\text{Un-damped}\end{array}\right.\end{align*}$$ In your case, you have a bandpass because \$\zeta\approx 8.132\$ and it must be the over-damped case. So the square-root part of the solution is real and therefore \$s_1\$ and \$s_2\$ are both real (and different from each other.) Here also, the \$s_1\$ and \$s_2\$ poles actually represent your \$\omega_{_\text{L}}\$ and \$\omega_{_\text{H}}\$: $$\begin{align*}\left\{\begin{array}{l}\omega_{_\text{L}}=-s_1=\omega_{_0}\left(\zeta-\sqrt{\zeta^2-1}\right)=\omega_{_0}\,\zeta\left(1-\sqrt{1-\frac1{\zeta^2}}\right)\\\omega_{_\text{H}}=-s_2=\omega_{_0}\left(\zeta+\sqrt{\zeta^2-1}\right)=\omega_{_0}\,\zeta\left(1+\sqrt{1-\frac1{\zeta^2}}\right)\end{array}\right.\end{align*}$$ Easily computed from the variables earlier developed. (And note that \$\omega_{_\text{L}}\,\omega_{_\text{H}}=\omega_{_0}^2\$.) So \$f_{\text{L}}\approx 6.946\:\text{kHz}\$ and \$f_{\text{H}}\approx 1.82334\:\text{MHz}\$. Note that the prior transfer function is but one standard way to write it. It's not the only standard form. Another approach is to simply replace \$s\$ with \$j\,\omega\$ (we are assuming that it doesn't spiral out of control or that it doesn't dampen into nothing -- in short, we are assuming \$\sigma=0\$.) Also, since \$s_1\$ and \$s_2\$ are real roots (for a bandpass filter that is over-damped, by definition), we can re-arrange as follows: $$\begin{align*} G_s&=-K\:\left[\frac{2\zeta\,\omega_{_0}\,s}{\left(s-s_1\right)\cdot\left(s-s_2\right)}\right]\\\\ &=-K\:\left[\frac{2\zeta\,\omega_{_0}\,j\,\omega}{\left(j\,\omega+\omega_{_\text{L}}\right)\cdot\left(j\,\omega+\omega_{_\text{H}}\right)}\right]\\\\ &=-K\:\left[\frac{2\zeta\,\frac{j\,\omega}{\omega_{_0}}}{\left(1+\frac{j\,\omega}{\omega_{_\text{L}}}\right)\cdot\left(1+\frac{j\,\omega}{\omega_{_\text{H}}}\right)}\right] \end{align*}$$ The point is that there are different ways to represent the same thing. Your choice will depend on what you want to emphasize. (And, of course, it's worth the time to play a little with the equations to see where they take you.) (By the way, the above only applies to the case where we are talking about an over-damped bandpass filter. I made some assumptions about the fact that we have real and distinct roots for this last development.) Your Results I notice that you used AC 11, not AC 1, in your simulation. You should correct this. The standard way to approach this is to use AC 1 in your simulation's input source. If you fix this in your simulation, everything else will work out fine. Here are the results from LTspice: I think that should suffice. Summary You have to take into account the loading that one sub-network has upon another. So you need to use the full Thevenin approach that takes into account all of the loading effects.
H: Can I use solid state output and relay output with the same components? So I have a OTB1E0DM9LP Schinder Electric I/O distributed module and I want use it'output to control some 24v electro-valve's and some 24V contactors. The module have 2 Solid-state outputs of 24V 0.3A 6 Relay outputs 30V 2A I'm having 3 valves and 5 contactors. Can I use the relay and the solid state output to control both the valves and the contactors? This means I can switch max 8A with the relay and 360mA with the Solid state? AI: I think you are asking can you mix or feed some of your devices from solid-state outputs and some from relays. The answer to that is yes, subject to the limits specified in the datasheet. The device is supplied with both because for some applications the SS outputs are more reliable when used for high-frequency switching but they only work with DC. The relay outputs can be used on both DC and AC over a wide range of voltages and so are more flexible.
H: datasheet register address is not in HEX? I am reading the this datasheet for the CAP1188 touch sensor and can't figure out what these "register addresses" in the far left column mean. I am used to seeing HEX addresses in datasheets such as 0x00, 0x72 etc., but this datasheet is adding an h to the end of.... I don't even know I just don't get it. For example, I am porting this library which has all these addresses in HEX form, but how did they get say 0x29 from 03h? AI: Those addresses are also in hex. 0x1F means the same as 1Fh. The XXh notation comes from Intel assembly syntax (source) Those addresses are used to identify a device register in the I2C transaction and are orthogonal to the address of the device on the bus. In particular, the device address is given on page 17, as a function of how a certain pin is configured: The device address 29h corresponds with a 150k pulldown resistor on the address configuration pin. Note that this is a 7 bit address; the 8th bit is used by I2C to distinguish reads and writes.
H: Why does LTSpice simulation give me negative value on NPN emitter current? So I built this circuit and I am trying to measure the emitter current, and the LTSpice simulation is giving me negative value reading... any idea why? AI: This is what I found in the Electronic Devices book by Stephen Fleeman. During the development of the V-I curves (and on manufacturers' data sheets), it is customary to apply the transistor convention. The transistor convention has been defined in Fig. 4-10(a). Currents that flow into the transistor are called positive. Conversely, currents that flow out of the transistor are called negative. If the actual conventional current directions agree with the transistor convention, they are called positive. If not, they are called negative.
H: Low pass LC filter goes "wrong" with capacitive load I have been experimenting with this circuit: simulate this circuit – Schematic created using CircuitLab Vin has a lower frequency ripple of 2V and a high frequency (switching?) noise of 6.5V. At V1, lower frequency ripple is about 200mVpp and the high frequency noise is 4.2Vpp. On Vout, the high frequency noise is the same, 4.2Vpp. But if I remove C4 then the high frequency noise at Vout decreases to 1.3Vpp. I don't understand why? How it that possible? Low frequency is ~100Hz high frequency is 25Khz this is when I remove C4: and this is when I add it: UPDATE: after replacing the power supply of the buck converter with a battery: AI: Welcome to the sad realities of doing real electronics work. There's two possibilities (one of which I missed at first). Frankly, I'm not sure which is the problem. The first problem is that your filter impedance is roughly \$\sqrt{\mathrm{\frac{220\mu H}{100\mu F}}} \simeq 1.5\Omega\$ but you're terminating the filter with 100 ohms and 6.8k ohms. So even with ideal components, the filter response will be very underdamped. This is probably not the problem if you have ideal components (edit: it's not the problem -- the resonances are there, and they're strong, but they're between 1kHz and 2kHz), but it would show up if you analyzed the filter response or simulated it. The second problem is that with those component values, you may be having issues with parasitic effects: when you design with any cap, you think you're getting this a nice pure capacitor, like you write down on the schematic. But you're really getting this infinitely complicated thing that may act like a cap in series with a resistor, or in parallel with a resistor, or in series with an inductor, or all of the above, or -- as you push into higher frequencies or lower impedances -- ever more complicated stuff. Aluminum electrolytic capacitors are made by taking a couple of strips of aluminum foil, layering them with paper soaked in salty goo* and winding them into a a cylinder. When you use the cap outside of its intended frequency range, the fact that there's a coil of conductors involved, it starts to look inductive. Similarly, inductors act like inductors in parallel with capacitors (because the wires are spaced closely together, and have winding-to-winding capacitance). That's a pretty big cap to be using in the presence of a 100kHz signal; I suspect that if the filter as designed doesn't have a resonance at 100kHz, then the parasitic elements of your various parts (coils + caps) is causing a resonance.
H: Grabbing EMF meter magnifies signal 10fold I have a Tenmars tm‑195. Holding it in my hand arm's length, still, I read \$2 \mu W / cm^2\$. In exactly the same spot, without me holding it, I read 10 times lower, \$0.2 \mu W / cm^2\$. I can reproduce this consistently. As far as I can tell, the main source of EMF should come from standard city electricity wires from the streets, but I am not sure. Is this strange behavior normal? What does it mean? AI: Any conductive object has a strong effect on the electric fields around it. One of the effects is that fields are concentrated where the curvature of a conductive is greatest. You are basically an animated bag of salt water, and you modify the electric fields wherever you go. The curvature of your body is greatest at the ends of your limbs, including your hands. So putting an E-field meter there is going to measure those effects. There is nothing surprising about this.
H: Shift Registers for generating codes can you explain me in simple words how does a linear feedback shift register work for generating a code? Consider for instance this scheme: If I have understood it correctly, each block is a D Flip Flop whose output bit becomes equal to its input bit after a clock cycle. So, let's suppose the first sequence of bit equal to 1011 How do we decide this sequence? It is the random sequence which is generated when flip flops are activated?. At the input of M1 there is 1 + 1 + 1 = 1 (in binary arithmetic). So at the next clock cycle we will have: 1101. At the input of M1 there is 1 + 0 + 1 = 0. So at the next clock cycle we will have 0110 etc. Which is the number of coded bits we see at the output? Does it generate a periodic sequence? If yes, how? AI: Let's suppose the first sequence of bit equal to 1011 (first question: how do we decide this sequence? It is the random sequence which is generated when flip flops are activated? Normally you'd provide a SET or RESET input to the flip-flops to ensure they start up in the state you want. For an LFSR using XOR gates, any starting state besides all-0's can be used. If using XNOR gates, then any starting state besides all-1's can be used. The second question is: which is the number of coded bits we see at the output? As drawn, you'd take one of the flip-flop outputs as your LFSR output. The output would be only one bit. There are ways to arrange to take more than one bit at a time as output, but they require changes to the logic. Third question: does it generate a periodic sequence? Consider Four flip-flops can only encode \$2^4=16\$ different states. The all-zeros state is not allowed (because 0 XOR 0 = 0, this state won't cause any change on the next cycle) The state transitions are entirely deterministic, so we know if we are in (for example) state 0110, the next state will always be 1011. Therefore the system must repeat its sequence of states at most every 15 cycles. And its output will be a periodic signal with period no more than \$15 T\$ where \$T\$ is the clock period. The trick is to choose how to connect the XOR gates so that the state sequence uses all 15 possible states and gives the maximum period. Rather than work it out from scratch, tables are widely available giving the required "tap" positions for various LFSR lengths.
H: What is meant by power well in IC terminology? Intel PCH Datasheet refers to power wells: Core well, Suspend well, Active Sleep well. Is power well same as power rail/power plane? Does it have any connection with p-well or n-well in IC fabrication process? AI: In the Intel terminology a power well refers to portion of the chip that is powered from a particular voltage rail. This voltage rail could be supplied from externally applied voltage levels on particular pins or it could be an internally generated voltage rail that is derived from another power rail. When multiple voltage rails are used on a particular chip reverse biased semiconductor diffusion junctions are used to isolate sections of the chip from other sections. The term "well" is used to describe the area within the boundaries of these isolation junctions. Safe operation of the chip generally requires that the most positive externally applied voltage rail be applied first followed by the next most positive and on down to the lowest. The reverse order is required for safe power down sequencing. Observing this proper ordering assures that the isolation junctions remain reversed biased at all times any applied voltage is over about 0.5V.
H: Can I use a PWM controller to control the speed of a motor? First off, I’m starting electronics as a hobby so excuse my lack of knowledge about electronics in general. As a staring project, I was going to try and make a magnetic stirrer to use in a chemistry project. I was intending on attaching a magnet to a gear motor and control the speed using a PWM controller. My question is: Is it ok if I use a PWM controller to manage the speed of the motor, considering it is a gear motor? I’m using a DC current of 12V 1A. The PWM module should lower the peak voltage, therefore lowering the speed of the motor right? Also, I searched the motor up and I couldn’t find a current rating. Is it ok if I use 1Amp? Again, I apologize for my lackluster knowledge about the subject, but I did do research, although I could not find anything regarding to this topic. Gear Motor https://www.amazon.co.uk/Motor-50-2000RPM-Speed-Reduction-Gearbox/dp/B07SR9GSR9 and PWM controller https://www.amazon.co.uk/Controller-Adjustable-Stepless-Governor-Regulator/dp/B078TC3DTX AI: Generally abrupt starts to Motors will draw up to 10x the rated current in the 1st cycle and then reduce to the stable value when acceleration reaches the final velocity. If one considers the heat rise of over current and the application does not demand rapid changes in speed then the current rating can be reduced from 10x the motor rating to much less. Spinning a magnet is not much of a load compared to abrupt turn on to max speed. Speed control is done by changing the average duty cycle of the supplied pulsed voltage not by reducing the peak amplitude. Therefore a 30A PWM is a good choice for a 1A motor with 10A worst case expected surges even if draws < 1 A at steady speed. One might consider a smaller rating, but at this cost, reliability is improved by over-design as there is often little or no active cooling. Stable low speed settings should not be expected if the load changes. This only controls average voltage and not power or RPM.
H: Fourierspectrum of the output voltage of an real inverting amplifier First a quick descripton of my circuit: The inverting amplifier amplifies by 20dB, the input voltage is a sinus signal with the Frequency 10 kHz and the peak to peak voltage is 200mV or 10V. The used amplifier is a OP177G. I've measured the Fast Fourier Transformation (FFT) of the output Signal. The Bandwidth of the amplyfier is 60 kHz. The outputsignal gets altered by the Slewrate for frequencys greater than 477 kHz if the input voltage is 200 mV and 9,5 kHz if the input voltage is 10 V. I only look at frequenys lower than 60 kHz cause im only interested in the altering by the slew-rate. Now to the interpretation and my question: If the input voltage is 200 mV I get a big peak at 10 kHz in the Fourierspectrum and no other peaks, as expected. The frequency of the input signal is way lower than the critical frequency 447 kHz, so I get a sinus signal as an output signal. If the input voltage is 10 V, the critical frecueny 9,5 kHz is lower than the frequency of the input signal so my output signal should be a triangular function an therefore there should only be peaks at 10 kHz, 30 kHz, 50 kHz and so on after the fourier transformation. But I also have peaks at even multiples e.x. 20 kHz, 40 kHz, ... . I dont get why this is the case, because there are none in the fourier transformation of a triangular function? Here is my plot for the input voltage 200 mV: Here is my plot for the input voltage 10 V: AI: Not looking at your design , I can see your 1) slew rate limiting AND/OR 2) hFE is unequal. Each polarity of push-pull driver may have a different impedance and thus the asymmetry causes even harmonic distortion to you added to anticipated odd harmonics. -You should realize the GBW requirements increase dramatically when you include specs for THD at a signal in the same decade as your BW, since you have very little excess gain to feedback for linear error correction. Also it is important to remember that when designing sharp or high Q RC active filters this also raises the GBW requirements significantly, much higher than you may expect due to phase shifting 1 decade below breakpoint becomes more critical with higher Q filters like Chebychev vs Bessel. TI's Active Filter designer tells GBW requirements for each stage. . 2. Unequal current gain is another reality near current limits for high voltage outputs. This affects the THD by adding even & odd harmonics. e.g. (Disregard the frequency, I adjust the harmonic levels to resemble yours)
H: Series identical power supplies Recently I made a thread about parallel supplies, however my helper fried one of them... Wonderful. So I got myself 4 of the famous DPS-1200FB-1 12v 100A power supplies. So I am an electronics noob, hence my name. I know the issue with parallel supplies is current sharing, but I don’t see anything wrong with putting all 4 12v power supplies in series to get 48v at 100A. I am still not clear with what galvanic isolation is. I believe it is making power supplies so the ground wires aren’t touching each other or something like that. So could I put these 4 PSUs in series to get 48v at 100A? Do I need to float them? What if I don’t float them? I cannot find a datasheet for these, but I bought them from here AI: Galvanically isolated means there is no DC coupling between the input and output. Here is the best step by step on how to remove the ground strap on all except the 1st supply. Then add a bus resistor to enable the supply. https://www.rchelination.com/index.php/tech-tips/how-to-setting-up-the-hp-dps-1200fb-power-supply Y caps are line to ground used for line noise EMI filters. PE is the Protective Earth ground.
H: AVR ATtiny1634 - Programming Issue I've have already used Arduino as ISP Programmer to load codes to Atmel chips like ATmega328p and ATmega8 quite a few times without any problem. On my last project though, I decided to use an Atmel ATtiny1634 microcontroller with QFN package instead of the bigger chips I used before. The soldering was ok, and the board has an ICSP header (MOSI, MISO,...) for the connection with the Arduino to program the chip. I loaded the ISP Programmer sketch into the Arduino and connected it to the board. I use avrdude in Cmd Prompt for setting fuses and loading the code, so I wrote the following line to check if the communication was ok: The device signature was correctly readed and so were its fuses. According to the datasheet information, I had to change lfuse to 0xFF because I am using External Crystal Oscillator >8MHz, so I wrote the next line for changing the lfuse: Apparently the lfuse change was successful because at the end it reads "Fuses OK (E:FF, H:DF, L:FF), as it should. Then I wrote the same line I did at first to check if everything went ok, but that's what I got: The programmer (Arduino) simply cannot read the chip anymore, as it gets 0x000000 invalid signature. I wonder if there is any issue with the lfuse I sent to the device (0xFF) and also if there is any way to maybe reset the chip or reestablish connection to find out what happened. The circuit of the microcontroller is down bellow, with the ICSP header, Crystal Oscillator, Power and the other I/O connections of the project: Thanks in advance for any help! UPTADE As @Kevin White corrected, I expressed myself badly when I said External Crystal Oscillator. I saw on the datasheet it has the option of External Clock Source and Crystal Oscillator or Ceramic Resonator. According to the CKSEL and the lfuse tables, the proper fuse value for Crystal Oscillator >8MHz is 0xFF: Is that right or am I misinterpreting those tables? SOLVED Yes, I was misinterpreting those tables. Beyond the table about the clock frequency range, there is another table that relates the CKSEL bits with the SUT bit of lfuse. By setting lfuse to 0xFF I was selecting SUT=1, which sets the external ceramic oscillator, and not the external crystal. The correct lfuse value for my situation is 0xED. I'm stating to get familiar with the datasheet and its "hidden" information. AI: You are not using an external "Crystal Oscillator", you have an external crystal. An external oscillator is an active device that produces a signal by itself, a crystal (or a resonator) is a passive component that is a resonant element to control the frequency of the oscillator internal to the AVR. This is a fairly common error that people make that is not helped by the nomenclature Atmel/Microchip uses. The solution to "unbrick" the device is to provide an external clock to the controller X1 pin to allow the fuses to be reprogrammed with the correct value. There are many ways to provide the clock and even an Arduino can do it as a wide range of clock speeds are acceptable provided it is at least 4x the speed at which the programmer operates. Here are a couple of links to help you on your way: Recovering a bricked AVR Unbrick bricked AVRs
H: Momentary overloading of a mains transformer at low duty cycle operation - what could go wrong? I'm planning on using a 120 VA Hammond 1182P12 toroidal transformer to deliver 24 VAC to a 2.5 Ω resistive load (a JBC C245 soldering iron cartridge), implying 9.6 A RMS, 230 W if continously applied. A microcontroller-driven solid state AC switch in series with the load would open or close at zero crossings, modulating the delivered power. A slow fuse would protect the device at the primary side. simulate this circuit – Schematic created using CircuitLab The transformer is rated for 5 A continous (at 24 V), and I suspect this limitation to be determined almost exclusively by the heating of the transformer due to losses. Mains transformer losses can be split into two components - core losses (hysteresis and eddy currents), which are mostly load invariant (determined by primary frequency and voltage) and copper losses, which are only proportional to the square of the load current (neglecting the small primary current present due to core losses). Assuming a worst case scenario where all transformer losses are due to copper losses, half a cycle (50 ms) of operation at 9.6 A produces the same losses as 50 ms * (9.6 A)2 / (5 A)2 = 184 ms at the rated 5 A. My control algorithm would make sure that: DC balance is maintained to prevent core saturation (the number of positive half cycles delivered to the load always matches the number of negative ones, +/- one) The average power delivered on a timescale of 10 minutes or more is always 85 W or less (with the above assumptions, 85 W average in the form of 9.6 A pulses generates the same copper losses as 5 A continous) The average power delivered on a timescale of 5 s or more is always 140 W or less Can I avoid a bulkier, heavier and more expensive transformer and larger case? AI: I believe you have a handle on it. P = I^2 * R. The thermal rise in a resistive device will be the square of current. That puts the square in RMS. This is why RMS has the relationship it does with peak. This is the AC voltage that, when applied to an incandescent light, will provide the same light, heat and service life as that DC voltage.
H: How to program micro-controller after PCB is printed noob here So this may be a very dumb question but: after you program a micro-controller and get a PCB printed, how do you reprogram it if you want to change it? Also let's say you get a surface mount version of your initial prototype, how do you program that? As I said, these may sound very silly, but I really don't know what's up with this PCB process On another note, let's say I am prototyping with a HC-06 Bluetooth module and want to make the final version of my project much smaller, is there a SMD equivalent of this module? AI: The microcontroller manual will have a section that tells you which pins are associated with programming (usually some type of in-circuit serial programming interface (ICSP), typically a JTAG nowadays). You run these pins out to a connector on the board and you plug your computer into it through a piece of hardware called a programmer. It usually looks like a block with a USB cable on one end that goes to the computer, and a cable on the other end with a connector that plugs to your PCB. Then you use the programmer's associated software on the computer to upload code to your microcontroller. Below is what I used for an STM32F303. It was to connect to a Segger J-Link USB programmer through a Tag-Connect TC2050 cable. Those 6 pins with net-names run straight to the MCU. The cable plugs into the PCB through 10-pins and plugs into the programmer through 20 pins (about half of which are just GND). I didn't use the programmer's original 20-pin ribbon cable to save PCB space. Some microcontrollers also have a bootloader pre-loaded onto them at the factory so that the microcontroller can program itself through signals received through one of it's regular interfaces (i.e. like UART or RS-232 from a PC). Of course, you can also write and upload your own bootloader to a microcontroller using the programmer. You might do this so that you do not need to use it in the future (so a customer can update their firmware in the field, for example), or allow other fancy programming behaviour. Bootloaders work by detecting searching for a specific signal sequence or jumpers on startup to know they are supposed to enter bootloader mode, otherwise they will execute their "normal" software.
H: Measuring voltage across 1 ohm resistor This might be a very stupid question, but I can't seem to figure this out and I'm going nuts thinking about it. Assuming you are trying to adjust the fixed bias of a tetrode push pull pair in a tube amp. In many amps, for convenience, the cathode will have a 1 ohm resistor connecting it to the ground, so you can easily use a multimeter to measure the voltage and thus the current flowing through the tetrode. My confusion arises when trying to comprehend how the resistance of the multimeter probes themselves would contribute to this measurement. I realize the probes are likely not thin enough wire or long enough to make any difference, but assume the resistance of each probe wire is also 1 ohm for this scenario. Would it make any difference here? AI: If you were using an analog multimeter with, say, 20,000\$\Omega\$/V on a 0-150mV F.S. range, the meter looks like an approximately 3K resistor. Thus the voltage across the 1\$\Omega\$ resistor will be a bit less since it is shunted by about 3K (3002 ohms if you count the leads) and the voltage making it to the 3000 ohm meter movement is a bit less as well (3000/3002 of the voltage across the 1\$\Omega\$ resistor) because 1/3002 of that voltage is dropped across each lead. simulate this circuit – Schematic created using CircuitLab In total then, in this example, the voltage read at the meter is lower than ideal by about 0.1%, which is going to be totally insignificant compared to the tolerance of the resistors and the accuracy of the meter. A typical digital multimeter will have an input resistance of something like 10M\$\Omega\$ on the 199mV scale so the effect will be several thousand times less, so even with a very accurate resistor and meter it's negligible. Not to mention that the leads are probably closer to 0.2\$\Omega\$ than 1\$\Omega\$.
H: Scam or Legit: High Voltage Capacitor Manufacturing? I have been looking for an 0805 10uF ceramic capacitor rated for 100v. Mouser and Digikey have only appalling prices for such specs (50 cents/piece at 5k for example). I recently made this shocking discovery on Aliexpress from a (somewhat) reputable dealer: https://www.aliexpress.com/item/33053004449.html The price per item comes out to a few cents, and when comparing to U.S. prices, I am wondering if it's a scam. I can see one of these sellers selling 50v caps (much cheaper from U.S. distributors) as 100v caps, and my design blowing up with a bang. Are these legit? I know it couldn't hurt to test them (100 of these is the same price as three from Digikey), but if there's a 0% chance they will work I would rather look elsewhere and not bother waiting for the shipping. Perhaps this is an opportunity for someone who knows more than I do about ceramic capacitor manufacturing to explain the cost impact of increasing the capacitor's capacitance and voltage rating. Three factors that come to mind are more expensive materials, specialized design process, and lack of demand to produce economically in large batches. Are any of these remotely reasonable? AI: 0805 10uF 100V ceramic = scam , The dielectric constant is not high enough For ceramic with very thin , many layers you can achieve 10uF in small area but not 100V. You can achieve nF 10kV in 1 layer , but not 10uF at this voltage and size. The product of these 3 parameters : size, capacity and voltage is not achievable in ceramic. Since capacitors are highest stress components of all. Caps have the lowest MTBF, along with high demands for low ESR for performance. It is wiser to design with conservative expectations, add redundancy and derate limits to improve MTBF. Thus use more components to share the stress of ESR, ripple current, and operate < 75% of rated voltage or less. Just as e-caps have a design limit of ESRC for any ,size/family, ceramics have a design limit for VC*size which must be respected and used conservatively. Never try to use 100% of capacitor ratings. This like buying 6000 mA Li Ion 18650 cells. They do not exist or are extremely unreliable. 1210 10uF 100V ceramic = possible but never perform with full charge Q=CV=10u*100V because charge capacity limits in size cause capacitance to reduce with raised DC voltage in ceramic.
H: Leakage Current in a AC/DC PSU without earth? I'm looking at the data sheet for a Meanwell NPF-40 PSU. This is a class II unit and hence does not have an earth connection (see also mechanical specifications, page 6), yet the data sheet specifies a leakage current of <0.25mA @ 277VAC. I was wondering how a class II unit without earth can even have leakage current. Where does the current leak from and to? This is a similar question, but the accepted solution states that there is leakage from the DC ports to earth, which I don't think can happen with this PSU. AI: If you look at the datasheet block diagram, there is a capacitor between mains input block and isolated DC output. It is there for EMI suppression. Also even if it was not there, there would be stray capacitance over the transformer coils that can leak AC voltages. Oh and forgot to mention, mains voltage is usually referenced to earth as neutral and earth are connected at some point anyway.
H: Is this transfer function impossible with a low-pass Sallen-key filter? I was given this transfer function and instructed to use a Sallen-key cascaded with a 1st order filter to achieve it. $$H(s)=\frac{628^3}{(s+628)(s^2+628s+628^2)}$$ The first order transfer function is $$H(s)=\frac{628}{s+628}$$ So if I choose \$c=10\mu F\$, then \$R=159\Omega\$. That leave the Sallen-key transfer function to be $$H(s)=\frac{628^2}{(s^2+628s+628^2)}=\frac{\frac{A}{R^2C^2}}{s^2+\frac{2}{RC}s+\frac{1}{R^2C^2}}$$ So \$A\$ must be equal to \$1\$ and \$\frac{1}{R^2C^2}=628^2\$. The same values for R and C as the first order filter work here. The problem is that middle term, \$628s=\frac{2}{RC}\$. This contradicts the other values. It works fine if this was a typo and that term was meant to be \$\frac{1}{2}\$ that value. Did I make a mistake here? I've wasted hours deriving and rederiving the transfer function for the filter to no avail. AI: Start with a 2nd order low pass filter transfer function in its general form: - $$H(s) = \dfrac{\omega_n^2}{s^2 + 2\zeta\omega_ns + \omega_n^2}$$ And then mulitply this with a single order low pass filter transfer function: - $$\dfrac{\omega_n}{s+\omega_n}$$ Giving you this: - $$\dfrac{\omega_n}{s+\omega_n}\cdot \dfrac{\omega_n^2}{s^2 + 2\zeta\omega_ns + \omega_n^2}$$ Can you see that this is the same form as your equation and therefore, \$2\zeta\omega_n\$ must equal \$\omega_n\$ or put differently, \$\zeta\$ = 0.5. The problem you have in your analysis is that you haven't factored-in the effect of zeta (\$\zeta\$) and a sallen key filter can quite often have a zeta below 1 because this can optimize the transfer function. Look up butterworth sallen key filters for example.
H: How much electromagnetic/electric radiation does laptop/computer emit? How much electromagnetic or electric radiation does laptop emit? I don't know in what measurement system you have to answer, but at least, I want to get the answer which should be enough "research" background to ask the question on Health.SE, whether "Can someone get a harmful emission from laptop in long-term" (otherwise, that topic was closed as off-topic, because I asked something vague without any specifications). (NOTE: I exactly don't know how to ask, because the over-educated users (or moderator) repel my question. Call it "magnitude, spectrum, radiation meter" or whatever, I don't really matter. ALL I matter is to get any approximate answer to quite simple question. Health.SE moderator just laughed at my question and closed it (oh, accept our apologies your majesty, we don't know that much specifics of magnetism..) However, the reason I am asking this, is whether 24/7 laptop users should worry about any related health affects and should worry about blocking that emission or not, and I was not directly interested in the technical specifications of emission amount. However, that moderators forced to get that specifics (amount of radiation) and then ask the question "if that amount of radiation is bad or not"). Hope now you understand AI: Jeroen3's comment has the short, correct but not particularly useful to the layman answer of EN 55032. It's remarkably hard to turn that into a specific number, but I can assure you that it's quite small. Without getting into the details of specific levels, I would like to make the following argument: Firstly, distinguish between the "nuclear" kind of radiation and electromagnetic (EM) radiation. We are talking about EM radiation here, there is no significant emission of nuclear radiation from consumer equipment. For nuclear radiation read UNSCEAR. The main consideration of EM radiation is whether it can effect other electronic equipment. Electronic equipment (especially computers and radio receivers) is much more sensitive to EM radiation than biological material. A legally required testing regime exists to ensure that EM emissions are kept low so that radios continue to work properly. There is no reliable science indicating any adverse health effects to humans or other mammals from even fairly high levels of EM radiation. The only way we know that harm could be achieved is by being very close to a high power radio transmitter: something deliberately designed to emit EM radiation. The only one of those you're likely to encounter in consumer equipment is (a) microwave ovens and (b) mobile phones, which use moderate (~2 watts) power for very short bursts. The EU "SAR" system is used to control how much EM is likely to be absorbed by the head of the user while making a call. Finding specific numbers is difficult, but in e.g. https://www.govinfo.gov/content/pkg/CFR-2017-title47-vol1/xml/CFR-2017-title47-vol1-part15.xml "15.109 Radiated emission limits"; the highest number in that table is 500microvolts/meter. That's a very small value. One of your links has a meter giving numbers in "gauss", which is only really suitable for fixed magnets. The "8h/day" question is not normally relevant; because there's no known mechanism for harm from low level EM fields, there's no dosimetry that would enable us to say how long exposure differs from short exposure. (Yes, very high level EM fields can be dangerous. A 500W microwave is approximately a million times more powerful than the number above, which is why it must not be operated with the door open.)
H: Voltage Regulator for Amplifier I am wanting to create an amplified speaker system with a subwoofer. I am fairly new to electronics and this is complicated for me so please be as descriptive as possible and patient with me. The internet has been my guide, so some of my knowledge may be incorrect. Any additional information required I am happy to provide. I am understanding most of the amplifier circuitry and am following this tutorial on creating it for the correct components. Edit: Now using D class thanks to user110971 recommendation I was wanting to use this subwoofer that takes to a max power input of 100W, as stated on the document. My issue is finding/building a DC voltage regulator that will suit this speaker using a standard Australian 240V power socket. It would be best if someone could direct me towards a pre-made regulator if possible as I don't want to breach any government regulations. Part of my problem is that I am unsure of how to obtain the correct voltage/ampage from the watts required. (FYI I know about the W=I*V formula, just cant see a way of solving my issue with it as I only have W) Any links to tutorials providing an overview of building regulators or constructing an entire amplifier including regulator would be much appreciated. Even giving me directions to general electronics books that I can obtain would be helpful. Thanks, BFB Edit: Many thanks to user110971, Justme and Swedgin for thier help on my issue. A quick recap of the solution for anyone wondering the same (I wish more people would do this XD) As outlined by user110971 I needed to use a D class amp for such high wattage as 'the transistor would melt'. Again, user110971 provided feedback on using the SMPS (Switching Mode Power Supply) as a voltage regulator. Justme clarified my misunderstanding of the speakers power draw (Its 50W) Swedgin provided me with useful links I recommend checking as well as alterations to the circuit to improve its performance. Thanks all for the quick and helpful support!!! BFB AI: For starters, I'd buy a premade module based on the TPA3116 chip. This gives you a subwoofer channel and a left and right channel. A good reason to buy one premade is that it's difficult to design the filters with feedback in the class D amp. Also it's cheap. You can add your own bass/treble circuit in front of the module. Also, you could replace the potmeters (which you should) with smd resistors and add a volume circuit before the module if needed. So that the class D board has the largest possible gain. I noticed that the potmeters on these modules are of below average quality and can introduce noise in the signal. As for the powersupply. Something like this will work, maybe look for one with a bit more amps if you want to be safe. With this powersupply you can also supply your own circuits with a simple regulator since your input voltage to your circuit will be 24V. 5A should be enough for only driving the subwoofer. If you use the 2 main channels, I'd buy one with at least 240W (24VDC 10A). As for the calculation of Justme in the comments: P = V*I = V^2 / R = R * I^2 (by Ohm's law). P is fixed (P=100W) and R is fixed (R=4/omega), with this you can calculate both V and I. While keeping the ratio V \ I = R = 4
H: Compromising on placement or routing of decoupling cap with BGA package As far I know there are two important points related to power-supply decoupling capacitors. First the placement be less than 3 cm from the digital IC. Second the power tracks route pass through this capacitor first and then connect with the digital IC power pins or balls. If I have problem in fulfilling both requirements especially in the case of BGA package then where can I do some compromise, in its placement or in its power-trace routing so that it causes lesser harm to the operation? AI: For any type of decoupling application, closer is better. "... the power tracks route pass through this capacitor first and then connect with the digital IC power pins or balls." That's better than having the power tracks go to the BGA first, then to the cap. Note that in many applications, the small ceramic decoupling caps are mounted on the back side of the board, directly under the BGA just outside of the ball field. Like Peter Smith said, a lot depends on the speed/edge rates of what the device is doing. To really do this right, you would need to build a model of the PDN (Power Distribution Network) and simulate that with your application. Finally, we could give a more definitive answer if you wold provide some more details of you application, such as: Clock rate of the device Device type, part number, etc Size of the package, how many balls Number of IO that switch, and at what rate
H: What are the common footprint naming conventions This question is ultra verbose, but I'm doing this in an effort to help other newbies (like me at the moment) as they first get into a CAD program like eagle. In the past when I've been new to a field I've always appreciated when people wrote out detailed explanations that are aimed for people that don't know what they're doing yet, so I'm try to pay it forward here. I want to ask a general question in the context of a specific problem: The scenario I'm just starting to learn Eagle CAD and I'm trying to build up a schematic of a circuit board I've built. I have two capacitors in my board that I'd like to add to my schematic: I know I have the following givens to identify the capacitors in eagle's library: They're polarized electrolytic capacitors They're through hole components They're radial capacitors I know each of their diameters I know each of their values (though that seems to be moot when finding the component in the library) When I look through the eagle libraries I can narrow down my choices a bit based on what I know about the components: But I'm not sure how to find the right component from here. The questions I know the names seem formulaic, so is there a particular naming convention of the components that I can use to search? Am I even going the right way about finding these components? And I'm talking about these specific capacitors at the moment, but I have the same question about finding components within the libraries in general. How should I go about identifying the library component for physical components I have on hand? Thanks! UPDATE: More detail based on the feedback I immediately got helpful feedback so thank you Eugene, awjlogan,and Steve (and other people that may reply with helpful info in the future). To help other newbies in the future I thought I'd add a bit more detail about this specific scenario based on the feedback I got. Vendor specific naming In my opinion, one of the most helpful pieces of feedback is knowing that the naming conventions are vendor specific and change from library to library. I find this helpful because it makes me feel a bit less lost when looking through all of the possibilities. When I first started looking I felt like there were secret languages and meanings that I didn't know (and there are), but knowing that these change from vendor to vendor makes me better about it because there isn't some ultimate secret convention that everyone but me knows that I need to figure out, I just need to get to know how various vendors identify their own parts. I don't know if that's helpful, but it def made me feel better about it. Looking to the datasheet for the naming convention This kind of fits into the vendor specific naming, but I wanted to call it out in a different heading. I should be able to look to the datasheet or catalog for naming conventions and identification. In this case the capacitors came in a kit that didn't come with a datasheet and I'm not able to find one online, but knowing that I should look to the datasheet for this kind of information will be helpful when I start looking for other part footprints like the buck converter and stepper motor driver that I'm going to add in a bit. I'm sure this is another "no duh" fact for experienced people, but as a newbie it wasn't immediately obvious. Pin spacing A piece I was missing from my list of identifiers above when looking for the component in the library was the pin spacing for the through hole component (facepalm). It's obvious once I read the feedback, but initially I didn't think of that as a variable to include. These exact spacings should be taken as rough when it comes to looking in the library it seems, so we're just looking for close matches. The anatomy of a specific naming convention Pulling from awjlogan's answer: Every EDA package will handle its library differently and also, within the tool, it's likely the libraries are not consistent. In the CPOL library in Eagle, you can see in the 'Description' column things like 'E5-8.5' - this corresponds to a radial capacitor, 5(.08) mm pin spacing, and 8.5 mm outer diameter. So, in this particular library it is: E[pin spacing]-[diameter]', with dimensions in mm. You've searched as far as you can, so you just need to select manually now. This breakdown is ultra helpful when it comes to looking at the names. I knew that the names had a pattern and meaning, but I wasn't sure how it shook out, so knowing that in this library's case the different sections of the names correspond to the common identifiers for the part (and knowing what those common identifiers are). I'm sure if I step through several libraries looking at the equivalent parts I'd be able to parse out the way they embed meaning into their part names. The specific component doesn't matter much if you're only doing a schematic This is also a helpful point to know. In this case I am planning on taking the plans over to my local maker workshop and milling out a circuit board so the footprint does matter, but it's good to know that if all I'm planning on drawing out is a schematic the specific component in the library doesn't matter as much. That takes some pressure off. The components I picked Based on what I knew before and what I know now I picked the following parts. Here's the part I picked for the 470uf capacitor: And here's the part I picked for the 100uf capacitor: I think/hope these are the correct pics (def let me know if I picked incorrectly). Fingers crossed! AI: Every EDA package will handle its library differently and also, within the tool, it's likely the libraries are not consistent. In the CPOL library in Eagle, you can see in the 'Description' column things like 'E5-8.5' - this corresponds to a radial capacitor, 5(.08) mm pin spacing, and 8.5 mm outer diameter. So, in this particular library it is: E[pin spacing]-[diameter]', with dimensions in mm. You've searched as far as you can, so you just need to select manually now. This is just the way things are with tools as there's not really any one obvious good way of doing things - there are a lot of components out there. You just have to accept it or get annoyed (and only one of those gets things done..).
H: Detecting low currents in high current industrial environment I would like to detect if a current flows in a 3-phase industrial environment where currents can go up to 120A. Anyway, for me is only important information current is flowing/current is not flowing. The threshold should be somewhere about 0.5A - 1A. I excluded shunt and current transformer solutions from consideration because I cant put shunt anuwhere (but I also think it is not quite applicable for such high current environments) and the later seems to be more expensive than solutions with Hall-effect sensor which I would like to consider here. In this question I would like to consult you about the principles in order to choose the one that fits the best my application. Is there a Hall-effect sensor which is able to provide a digital output based on the absolute value of the magnetic field? I checked various types of Hall-effect sensors, bipolar, unipolar and omnipolar. The closest to what I want is unipolar but none of unipolar sensors can actually treat south and north poles in the same way. By this I mean, that threshold should be for +- x T. Using such an element I believe I would minimize my BOM. Since all three phases are in vicinity of each other, how sensitive might be using Hall sensors in such environments in terms of flux cancelations? Would it be possible to implement this without a ferrite ring for concentrating magnetic flux? My calculations give in the worst case, 3mm away from the conductor about 0.5G (2/3e-4 T). Is there any other interesting way of doing this that I missed completely? AI: 120A is at least 6mm2 of cable. A current transformer is then the typical way to measure current. However, that is very big. Especially for three. And may be expensive at the precision you require. You can get a bit smaller with a hall sensor current transformer. Such as LEM LZSR. When even that won't fit then you can go looking for separate magneto resistive current sensors. At cost of a significantly more complicated design, validation and calibration. Sensitec and Allegro Microsystems are famous for these. Using a traditional discrete hall sensor will probably not work reliably at the low ranges you are looking for. If you can find them with proportional output at all.
H: High short circuit failure rate of aluminum electrolytic capacitors during the production processes I have produced 1000 units of our new developed energy meter. Almost 20 aluminum electrolytic capacitors (2%) have failed short when we test them during the production processes. The Capacitor is a 470uF 35V (UPW1V471MPD) made by Nichicon. The failure itself varies between total short circuit to small variable resistance. One of the caps spit out its electrolyte. I have 3 other different aluminum electrolytic caps from the same manufacturer that didn’t fail. A year ago, I have produced 300 units (same design and part no.) and they running perfectly and didn’t find any failed capacitors. My question has 3 parts: How this occurred? Is it normal to have an infant mortality of 2% with short circuit failure for aluminum electrolytic caps? Or, may be the cap is counterfeited and the con manufacturer didn’t do enough quality testing. (I bought them through a PCB and components supplier in Shenzhen). If they are counterfeit, how to verify that? What should I do with the rest of the batch? If I release the batch, would I guarantee that there will be no more short circuit failure? If it didn’t die during the manufacturing, it will not die in the near future! (U shape/bathtub graph). Or it is better to run my meters for a period of time (24 hours) if didn’t fail it will not fail in the future. Or I should go the hard way and change them all? How to avoid this in the future, because I will be going for large quantities > 100K. I didn’t find very useful notes about electronics parts quality and reliability other than MIL-HDBK-978B. But it is out dated and didn’t have the electrolytic caps. Added Operation condition: Voltage = 20V. Inrush and ripple current = the capacitor is used to store energy to supply a latch/rely only when operate. it operated about 5 times during production. latch/relay impedance 60 ohm. it draw its voltage from a capacitive power supply capable of supplying a 17mA at maximum. Temperature: about 30C. there is a guarantee that no cap have been reversed biased. AI: That high a failure rate is unheard of for a top-quality supplier like Nichicon when properly assembled and operated conservatively. Even for no-name parts it’s not at all usual- one in 10,000 might be plausible, but that’s on the high side. Short circuit failures are very rare for aluminum electrolytics. I did once see a few in a bag of 1,000 from a Taiwan supplier that were completely missing the rubber seal so the electrolyte also had gone AWOL- that was actually funny. You can contact Nichicon directly to confirm the parts are genuine (or not). They may be able to tell just from photos or you might have to courier samples. You can review their application information to make sure you are not abusing the parts in some way- not only voltage but also ripple current, possible reverse voltage or reverse installation (that is one thing that will cause shorts). Poorly made counterfeits might be marked incorrectly so they are reversed even though they appear to be installed correctly. Your transformerless supply might be stressing the part upon application of power. Also confirm that the chemicals and processes used in the PCBA and any subsequent operations such as cleaning are approved. I would definitely pull 100% of the parts from that batch of boards and replace them with known good ones. Use good tools and skilled technicians so that reliability isn’t unduly compromised by the rework. Field failures are extremely expensive in dollars and in reputation. Give them a good visual inspection under a microscope, or at least with a magnifier, and see if you can identify differences between batches or within a batch. As far as prevention in the future, that is a bit off-topic, but there are a few approaches to control “quality fade” and substitutions of inferior parts - one of which is third party inspections. The assembly house or supplier you used is suspect if they allowed counterfeit parts to be procured. You may have a better choice of suppliers at higher quantity levels and you can ask how they intend to guarantee genuine parts are used. The Shenzhen markets are a bit of the Wild West, so you need to take care. Nichicon will have authorized distribution channels there, but it’s also possible to procure parts of unknown history at the many retail shops in Huaqiangbei or online at Taobao etc.
H: Lt-Spice doesn't give me all the information Here is my LT-spice simulation of a simple circuit. I need to find the voltage across R6, but Lt-Spice doesn't give me that information. Does anybody know why this is or if there is something wrong? AI: It is there. It is one of the voltage nodes relative to ground so it is not associated with any one component.
H: TI PCM51xx DAC Charge Pump Failure I'm using a PCM5122 and previously a PCM5102 (this is the same part, but without the I2C/SPI interface) in my design and I've had a couple of prototypes end up with the 3.3v rail shorted to ground. A little investigation has yielded that the CPVDD (Charge Pump) pin is bringing the rail near ground. Similarly, the VNEG pin has only 20k ohm resistance to ground. No other pins appear to be shorted. The outputs of the DAC connect directly to an onboard amp, as well as being tee'd off into a vehicle amplifier. My question is this: What could cause this kind of damage to the DAC and what can I do to prevent it? I have not done anything outside the box with the implementation, other than change the output filter to supply a higher output load. Here is my schematic: Here's my PCB layout: AI: The DGND is disconnected in the schematics, it can cause all kinds of problems.
H: What condition must be verified by the frequency so that an RC circuit acts as a differentiator? So I am theoretically planning to make an RC differentiator circuit but I'm still a rookie with it so if someone can help me it would be appreciated. AI: The condition is defined by time domain exponential behavior and frequency domain. You requirements must include some specification to be below some cutoff frequency or exponential constant T=RC with some tolerance such T defines the voltage decay to 64% of target. e.g. differentiator for f < fo/10 or 20 dB down or T=1/fo=1/2piRC The current phase leads voltage by 90 degrees. e.g. a High Pass Filter performs differentiation (to some tolerance) below fo/10 typ. A ideal differentiator has no upper limit in frequency gain +6dB/octave. Other equivalent conditions to + 6dB/octave are +20dB/octave for the frequency range of interest. passive methods a) It can block DC current with a series C with a shunt R b) or shunt DC current to 0 volts with a series R and a shunt L.
H: What item could this PCB board be from? (NOT serious, misc. question) This is a fun, light-hearted question and not meant to be taken too seriously. As a little fun thing between a group of friends, we found this question on a desk at work sometime ago about a PCB that had been removed from a typical household object. The question basically was what household object do you think this could have come from and what could the function of the board be. We've come up with all sorts of possibilities such as a smoke detector, microwave oven, old TV, etc, however none of us can confirm whether any of us are right as there isn't any answer to the question available. Given the large number of capacitors and resistors, we don't think it's a simple clock. Furthermore, we haven't been able to deduce what the large plastic piece in the middle is - we're hovering towards a transformer (some are thinking it's a speaker), but the shape of it is throwing us off. Can anyone shed some light as to what they think this board could be from or what they think it is used for so we here can stop debating on this. Battery is there for size reference. Different image also of a similar device AI: What you've got is a switched mode power supply. Mains AC goes in at one end and well regulated DC comes out at the other. There are a few clues: The obvious one is the switching transformer in the middle and the "no-man's land" beneath it on the underside of the PCB. The combination isolates the low voltage side from the mains. Figure 1. SMPS block layout. Source: Wikipedia Switched mode power supply. The red leads at the bottom are the mains input. The mains is rectified to high-voltage DC by the four diodes beside the blob of goo. The large capacitors beside the diodes smooth out the rectified AC. The voltage on these capacitors is typically one and a half times the nominal mains voltage and DC. It can hurt or kill! The 8-pin chip is the switching regulator. It switches the DC supply to the transformer at high frequency - maybe 100 kHz - creating an alternating signal that can be transmitted through the transformer. I can't see it but usually there is a largish transistor to switch the power rather than the chip doing it itself. On the top of the board we see some more diodes and capacitors to rectify and smooth the DC output. Finally we need some feedback from the output to increase or decrease the switcher as required to maintain the correct output voltage. The feedback needs to be isolated so the 4-pin opto-isolator on the right of the transformer provides this. Internally there is an LED and a photo-transistor separated by a transparent isolator capable of withstanding 1000 V or so. What item could this PCB board be from? It could be from anything requiring an isolated low-voltage regulated DC supply.
H: Compare tiny capacitance using comparator I want to compare the capacitance of two tiny capacitors at around 10^-15 F each. One will change compared to the other by at maximum factor 3. I need to measure the relative difference between them to an accuracy of around 1%. My idea is to connect them in series to form a ”voltage divider” and then connect the middle of them to a comparator which can then compare the voltage between the capacitors to some external reference voltage. However, I have no experience with comparators or exactly how they work. Would the comparator try to draw a current from the capacitors it was comparing (and thus not work since there’s basically no charge to draw)? What should I look for when buying a comparator for this application? If this is simply not possible, how else might I accuratley (and cheaply) compare the values of these two capacirors? Note, not looking for some expensive high tech solution here, looking for something which can be done at home by an amature. AI: The smallest general purpose electronic capacitor in the world is 0.1pF. \$=10^{-13}~F\$ Your requirement so far does not have any merit as \$ 10^{-15}~F\$ is only 1% of this. Unless you can define your dielectric, conductor geometry and purpose, nothing close to what you suggest is suitable. You are asking how to measure capacitance less than two 1mm square pads separated by 1 meter. try something else.
H: Calculating inductance values from transformer datasheet I want to simulate this transformer using LTSpice: This is a microphone transformer. To do a simulation in LTSpice I need to know the inductance values for the windings. The datasheet gives impedance values and a frequency range of 30-25kHz, which is strange from my understanding, since impedance can only be specified at a specific frequency. Is there some convention in the industry that would explain how to calculate the inductance values? Is it possible to calculate the inductance from these values? AI: Low frequency cutoff is determined by the interaction of circuit resistance with primary winding inductance. High frequency cutoff is determined by the interaction of circuit resistance, leakage inductance, and winding capacitance. The -3dB cutoff frequency of an LR filter is \$ fc = \frac {R} {2 \pi L} \$. Here resistance is the Thevenin equivalent of source and load resistances, which in a 600&ohm; circuit is 300&ohm;. So for a low frequency cutoff of 30Hz the transformer primary inductance should be 300&ohm;/(2π*30Hz) = ~1.6H. The ratio of primary to secondary impedance is 600&ohm;:25kohm; = 1:41.7, so the secondary inductance should be 1.6*41.7 = ~67H. At the high frequency end the transformer's leakage inductance (caused by imperfect coupling) can have a large effect, as it forms an LC low pass filter with the winding capacitance. Without a specified leakage inductance all we can do is guess what the coupling coefficient might be, then choose a capacitance that produces the specified high frequency cutoff. I put the specified 19.2&ohm; and 1140&ohm; winding resistances and calculated inductances into LTspice, chose a coupling factor of 0.998, and adjusted winding capacitances to get a high frequency cutoff at 25kHz. This was achieved with 340pF on the secondary winding, and (since winding capacitance is approximately inversely proportional to the number of turns) 2.2nF on the primary. The frequency response looked like this:- For a more reliable simulation you would need to measure the leakage inductance and/or actual frequency response of the transformer. Your specs don't even tell us what 'frequency range' means. Is it the 3dB points, or something else? Here's the measured frequency response of a line input transformer specified for +/-0.25dB from 10Hz to 60kHz:- Sowter type 4383
H: solar pv micro-inverter strings According to wikipedia; a solar micro-inverter is a plug-and-play device used in photovoltaics, that converts direct current (DC) generated by a single solar module to alternating current (AC). I can understand the benefits of having micro-inverters on every panel increases efficiency for a number of reasons; owing to moving AC is more efficient than DC and their MPPT capabilities. The question that I wanted to ask is, how do you create micro-inverter strings? Let's say you have 10 panels rated at 300 watts, each tracking their maximum power point. Now each micro-inverter outputs 110v AC. That's 10 panels each outputting 110v AC. How do you combine those AC output? AI: Solar Micro Inverters are DESIGNED to connect to a "stiff" 110 VAC (or 230VAC) bus. They synchronise in frequency and voltage and adjust phase angle to control energy transfer. In the absence of system wide control they maximise energy transfer based on available energy input and their maximum capacity. Many such devices can be controlled by a centralised system but this is not essential to their operation. They are largely, as you note, "plug and play". Connect PV input, Connect mains output to mains AC bus. Done.
H: DC analysis of Darlington pair So I'm having this darlington pair here I'm doing DC analysis of this darlington pair Can anyone explain why is R2 is 6.58, shouldn't it be aprx 7.39? AI: I think Vbe of Q1 is equal to Vbe of Q2 which is 0.7 volts, so the voltage drops about 0.7 volts through each transistor, like Q1(E) equals to 8.8 - 0.7 = 8.1 as shown. No, it's not as simple as that. If you look at the data sheet for the 2N2222 you will see that the base emitter voltage might be as high as 1.3 volts for a collector current of 150 mA. But it's all a bit hit and miss with the 2N2222 transistor because there are no graphs in the data sheet that could give typical values that are representative of actual circuit conditions. What can be said is that assuming a forward voltage of 0.7 volts for either transistor's Vbe is overly simplistic. It will be greater and quite possibly nearer to 1 volt for each transistor. Also, worth pointing out is that the simulation tool that predicted 6.59 volts is subject to some speculation. The model it uses will have inaccuracies and these might slightly compound the "true" analysis.
H: Ground Plane for Flying Antennas (literally) I am building a weather balloon sensor baord with a LORA 868 MHz radio module (RFM95x). The sensor will rise up to 30km and should transmit the full time. I am using a PCB trace antenna with ground plane. For ground applications it is fine to have the antenna on the upper side of the board. My question A is if I should flip the board upside down to get the ground plane out of the way and have a clear view to the basestation? Question B is if I flip the antenna (rotate the board), what happens to the polarizastion? Do I have to consider this in the trace (or basestation antenna)? Is this type of PCB antenna the way to go, or should I use an external (dipole) antenna? Thank you for the help! 868 MHz PCB antenna like this: AI: Without knowing what other analysis you have done, I would recommend doing what you suggested and flip the PCB so that the ground/reference plane is "up" and the radiator is "down". While you will probably get some performance with the ground plane down, that will be because of RF leakage around the edge of your finite ground plane, and maybe from reflections from objects above the antenna. If the ground plane were infinite, you would get absolutely nothing (or close to it) on the ground plane side of the antenna. Did you or anyone else simulate the antenna performance using an E&M tool such as CST Microwave or HFSS? There are other tools out there, but those are the two that we use for antenna element pattern analysis and design.
H: Confusion regarding voltage division I am looking through some old exam problems and I came across one with a solution, I don't quite get. "In the circuit below what is the voltage drop across R3?" Their answer is zero, and they come to that conclusion the following way: $$vb=va\cdot \frac{R5}{R4+R5}=\frac{2}{3}\cdot va$$ $$vc=va\cdot \frac{R6}{R2+R6}=\frac{2}{3}\cdot va$$ $$v_{R3}=vc-vb=0$$ My question is how they can just ignore R3 when making the voltage division equations in the first place. Doesn't voltage get distributed to R3 as well? It almost seems like they know it's gonna be 0 volts and therefore they ignore it immediately. Can anyone explain to me why this is, and if my intution of how voltage division works is wrong? AI: My answer is how they can just ignore R3 when making the voltage division equations in the first place. In order to make a judgement on this circuit, various techniques can be used and, it is advantageous to the person solving the problem, to choose the method that delivers an answer in the shortest time. The most sensible first method to try (as a thought experiment) is any method that attempts to compare the voltage at node VB with that at node VC with R3 disconnected. Clearly, within a couple of seconds, an experienced engineer will see that those node voltages are equal and, the impact of this is that no current can flow even if R3 were a short circuit. You don't even need to form the equations; it's enough to see that the ratio of R4 to R5 is the same as R2 to R6.
H: Reverse Polarity Protection relay calculation i want to make reverse polarity protection without voltage drop ,i was searching and i found this https://www.edn.com/design/analog/4368527/Simple-reverse-polarity-protection-circuit-has-no-voltage-drop now , i want to size this relay . load ( 30 A , 48 V ) 1440 Watt Does load ( normally closed ) matters with relay? Where load is normally closed so relay is not operated when power supply is connected correctly. so if that right then Does relay ( 12 V , 5 A ) 60 Watt can do the work ? if all above right , then the load will taken into concern is when relay energized so the led ( in photo above ) and resistor here will be loads . Thanks you . AI: In a word, no. You say your load requires 30 A, but your relay is only rated for 5 A. Relays are resilient and can handle a bit of pulsed overcurrent, but you're trying to use this relay for six times what it's rated for--it won't survive. There are better reverse-polarity circuits out there, by the way. Relays are expensive, but a MOSFET is much less so.
H: How to read this memory map of LPC1769 microcontroller? I'm trying to understand the memory map of the LPC1769 microcontroller using the official NXP datasheet. The screenshot below shows at 0x00004000 to 0x00008000 there is 512kB of flash memory mapped, however the number of addresses between 0x00040000 and 0x00080000 can't reference all 512kB of flash memory? How does this mapping work so all 512kB can be referenced? Or have I misunderstood something? AI: There are parts with different amounts of Flash memory. The Flash memory starts at address 0 for all devices and if it has 512kB of Flash the final address is 7FFFFh and reserved area starts at 80000h. Parts with less memory such as 256kB has last address of 3FFFFh respectively so the reserved area starts at 40000h. They are all just stuffed into one picture that is clipped from bottom if you look carefully. Here is an extract from the relevant User Manual where this is better explained:
H: Removing silkscreen paint which overlaps copper padding after printing I am new to advanced PCB printing and, as it turns out, my PCB printing vendor prints the silkscreen white text over some copper padding according to my design, which i don't know that would happen. Is there any way to fix this issue, Should i try using rubbing alcohol, and would that damage the copper padding? Here is what it looks like AI: Only three things I can think to try: a) Try gently scraping it off with a scalpel b) Try fine emery cloth to rub it off c) Ignore it, and see whether you can still get a reasonable connection when soldering
H: Getting different impulse responses by solving with Laplace transform and plugging delta-dirac If I know that the output of a system $$y(t) = 2e^{-3t} \cdot u(t)$$ and it's specified that the input is $$ x(t) = u(t) $$ I was trying to find the impulse response h(t). So I solved it using Laplace transform and I got the output $$ h(t) = 2\delta(t) - [6 e^{-3t} \cdot u(t)]$$ by doing the following: $$ y(t) = x(t) * h(t) $$ therefore $$ Y(s) = X(s) \cdot H(s) $$ and by doing the laplace transform to y(t) and x(t) I optain: $$ \frac{2}{s+3} = \frac{1}{s} \cdot H(s)$$ $$ H(s) = \frac{2s}{s + 3}$$ $$ H(s) = \frac{2(s + 3) - 6}{s + 3}$$ $$ H(s) = 2 + \frac {-6}{s + 3}$$ therefore, by using the inverse Laplace transform, I got: $$ h(t) = 2\delta(t) - [6e^{-3t} \cdot u(t)] $$ Until now I think I understand it. From now on, I'd like you to correct me if I'm wrong at anything. I know that h(t), the impulse response is the output if the input is the impulse function delta. so I did the following: I substituted x(t) in place of u(t) in the output equation, as x(t) = u(t) $$ y(t) = 2e^{-3t} \cdot x(t) $$ and then I applied delta as the input to get the impulse response. $$ h(t) = 2e^{-3t} \cdot \delta(t)$$ which can be reduced to $$ h(t) = 2\delta(t) $$ I don't know what I've done wrong in that process to obtain a wrong answer in the second way. Also, I'm pretty sure that the first impulse response is the right one because I've solved it in another way and obtained the same result (getting the step response and then differentiating it to obtain the impulse response.). It just didn't work out when I try to plug in delta. Also, I apologize if the tags are not very accurate, but I just don't know how to categorize the question. AI: The step where you substituted \$x(t)\$ for \$u(t)\$ was incorrect. It's like saying "\$x(t) = 1\$, so I can substitute \$x(t)\$ for \$1\$ everywhere in my expression". Observing that \$h(t) \star u(t) = \int_0^t h(\tau) d\tau\$ and then taking the derivative is correct, however.
H: How to conclude the nature of interference for such scenarios? This is abit a hypothetical question. Imagine a signal chain where a AC-DC power supply is powering a transducer and the transducer output is coupled to a data acquisition input by a BNC cable. Or I can illustrate the chain like: AC mains->PSU->Transducer---------------->DAQ. And the DAQ is single ended as well. I tried to simplify this by the drawing below: Now Vsig represents the transducer; Vcm represents the common-mode voltage. X and Y are the output terminals of the transducer. Rs is the output impedance, Rw is the BNC resistance. A and B are the terminals of the coax cable right at the DAQ side where signal is BNC coupled to the DAQ. Rin is the input impedance of the data acquisition board. Now assuming inside the dotted line is a black box to us and we don't know initially what we measure as noise is CM interference originated or not. And our aim to make a quick test to verify if the noise is originated due to a CM interference. After that premise my two questions are as follows: 1-) If I short the terminal Y with a wire to the power supply ground, and if in that case the noise disappears does that reveal the existence of Vcm? 2-) If I only have access to A and B terminals, is there any way to reveal the existence of Vcm? Can this be done by a multimeter between the terminal B and DAQ ground(when the BNC to DAQ is decoupled)? AI: In some cases, \$V_{cm}\$ is an AC voltage produced by current in a ground loop (in orange, below). It cannot be shorted out. If this ground loop can be broken, no current can flow around the loop, so no voltage is developed across Rw. One way out: disconnect (float) \$V_{sig}\$ so that Y doesn't connect to ground. In some cases, the signal source cannot be floated, and is unavoidably grounded. And it is likely that the DAQ is grounded as well. So the loop cannot be easily broken. Adding extra ground wires likely increases loop area or loop current. \$V_{cm}\$ gets worse, or at least doesn't decrease. A very annoying problem to solve, especially in complex measurement systems where lots of equipment is grounded.
H: "DC" Impedances seen looking into terminals of a BJT Our professor in college was making us understand the stiff voltage-divider bias concept of a BJT. simulate this circuit – Schematic created using CircuitLab (Ignore the resistor and voltage source values) Here he says, "The voltage-divider can be called/assumed a "stiff" divider if the current through R1 and R2 is quite large compared to the current going into the base (which makes sense ofc). Such an assumption can be made if the resistance seen looking into the base is much larger compared to (R1+R2), which ensures very less current flowing into the base". How do we measure this resistance looking into the base at bias conditions? I can understand and calculate small signal impedances no sweat, but this confused me idk why. Or for that matter, how would we calculate the impedance looking into any of the terminals at DC? Any kind of hint will help. Thanks! AI: It’s all about Ohm’s law. The voltage at the base is $$V_b = R_e I_e + V_{be} = I_b (\beta + 1) R_e + V_{be}.$$ Hence $$R_b = \frac{V_b}{I_b} = (\beta + 1) R_e + \frac{V_{be}}{I_c / (\beta + 1)} = (\beta + 1)(R_e + R_{be}).$$ Since \$\beta\$ is large, the resistance looking into the base will be large as well.
H: Using a small Li-Po as a backup power source for a model I am building a model of a trolleytruck (similar to a trolleybus but with a truck) and I'm adding an Arduino to get data. The microcontroller should never lose power because it would restart. I was planning to add a small Li-po battery to supply power to the microcontroller when the truck is not getting power from the lines (in case of some oxide forming on the wires or anything else). Both the Arduino and the motor can be powered with 3.7v, so a 1S battery would be ok. Is there anything that I can buy that manages the charging and discharging of the battery? Will the battery get damaged because of those quick intermitent charges and discharges? Thanks for all and sorry for my bad English. AI: If you can get your trolley power to 5V with a buck regulator module or whatever, you can use a USB-powered LiPo charging module to charge the battery. Chinese modules based on the TP4056 from NanJing Top Power are popular at the moment. However, powering the motors and the Arduino from the same supply may cause issues with start-up surges. You could consider a relatively large reservoir capacitor and Schottky diode to isolate the Arduino from momentary drops in the battery voltage.
H: The error "requires SystemVerilog extensions" while declaring an error What's wrong with the following code? The array "FIFO" is declared correctly, but an error appears. Can you please help how to fix this? module fifo( input clk, input [7:0]data_in , output reg [7:0] FIFO [0:8] ); integer i; always@(posedge clk) begin for(i = 8; i > 0; i=i-1) begin FIFO[i] <= FIFO[i-1]; end FIFO[0] <= data_in; end endmodule Error (10773): Verilog HDL error at fifo.v(29): declaring module ports or function arguments with unpacked array types requires SystemVerilog extensions AI: Exactly what it says: you have a two-dimensional output port which is an unpacked array. This is a packed array: output reg [7:0] FIFO This is an unpacked array: output reg FIFO [0:7] Therefore your two-dimensional array is an unpacked array. Verilog allows only packed arrays for ports. If you want two or more dimensions you need to compile with System-Verilog.
H: stm32f1xx how to use DMA to write to TIMx CCR I am trying to control WS2812b digital LEDs with stm32f103. I have a buffer of color values for the LED strip and to transfer them I need to write the next value to the timer's CCR every time the timer updates. As the result I should see this buffer as a PWM signal on the pin of the MC. The guy, who helped me with the PCB wired LED's data pin to PB5 of the MC. PB5 is connected to TIM3_CH2. According to the manual there is no DMA request for TIM3_CH2. Does this mean it is impossible to use DMA to change TIM3 CCR2 every time the timer updates? I know about the DMA burst mode which can write to any CCR of a timer, but looks like it is impossible to send a big buffer to one CCR. What am I missing? AI: Turned out I just needed to use TIM_CHANNEL_UPDATE as update source for the DMA and set TIM3 CCR2 as an output. It just works. I used HAL library and I had to create my own HAL_TIM_PWM_Start_DMA and HAL_TIM_PWM_Stop_DMA functions. Here is the code, it contains hardcoded values for CCR2 and TIM_DMA_ID_UPDATE channel HAL_StatusTypeDef HAL_TIM_PWM_Start_DMA_HACK(TIM_HandleTypeDef *htim, uint32_t Channel, uint32_t *pData, uint16_t Length) { /* Set the DMA Period elapsed callback */ htim->hdma[TIM_DMA_ID_UPDATE]->XferCpltCallback = TIM_DMADelayPulseCplt; /* Set the DMA error callback */ htim->hdma[TIM_DMA_ID_UPDATE]->XferErrorCallback = TIM_DMAError; /* Enable the DMA channel */ HAL_DMA_Start_IT(htim->hdma[TIM_DMA_ID_UPDATE], (uint32_t)pData, (uint32_t)&htim->Instance->CCR2, Length); /* Enable the TIM Capture/Compare 1 DMA request */ __HAL_TIM_ENABLE_DMA(htim, TIM_DMA_UPDATE); /* Enable the Capture compare channel */ TIM_CCxChannelCmd(htim->Instance, Channel, TIM_CCx_ENABLE); if (IS_TIM_BREAK_INSTANCE(htim->Instance) != RESET) { /* Enable the main output */ __HAL_TIM_MOE_ENABLE(htim); } /* Enable the Peripheral */ __HAL_TIM_ENABLE(htim); /* Return function status */ return HAL_OK; } HAL_StatusTypeDef HAL_TIM_PWM_Stop_DMA_HACK(TIM_HandleTypeDef *htim, uint32_t Channel) { __HAL_TIM_DISABLE_DMA(htim, TIM_DMA_UPDATE); /* Disable the Capture compare channel */ TIM_CCxChannelCmd(htim->Instance, Channel, TIM_CCx_DISABLE); if (IS_TIM_BREAK_INSTANCE(htim->Instance) != RESET) { /* Disable the Main Ouput */ __HAL_TIM_MOE_DISABLE(htim); } /* Disable the Peripheral */ __HAL_TIM_DISABLE(htim); /* Change the htim state */ htim->State = HAL_TIM_STATE_READY; /* Return function status */ return HAL_OK; } ```
H: Wich battery configuration I should use to supply raspberry, arduino and stepper motors I'm working on a project about a self-stirring robot with sensors to avoid walls. This project is composed by one Raspberry responsible for all the algorithms, one Arduino to deal with the sensor and the motors, one sensor to measure the distance in front of the car and two motors to make the car walk though the environment. I need to place everything correctly in such a way that the car moves freely without wires connected to it for not much than 1-2 hours. What I'm actually doing is powering up the Raspberry with his micro-usb wire then connecting the Arduino to the Raspberry USB port and then connecting the rest to the Arduino power source. Obviously the Arduino isn't providing the necessary power for the two motors and the sensor although when I was searching I read that the motors need an independent power source because of network distortion they make... So what kind of battery configuration circuit will I need to keep all this up? Maybe a 12V lithium battery? Information I've collected about the power needed in: 1 Raspberry (3): Works with 5V/2A 1 Arduino (Uno): Works with 7-12V 1 Sensor (HC-SR04): Works with 5V (normally from Arduino) 2 motors (28BYJ-48 with driver ULN2003): Works with 5-12V AI: We did something similar back in college for the IEEE micro-mouse competition. Chris Stratton is correct in that I wouldn't mess with Lithium batteries just yet. Use a bunch of NiMH batteries, as they are robust against shorting (though the wires may not be!) and easy to charge. I think for my project I used about 8 AA batteries in series with a buck regulator to step it down for the CPU. We used a micro-controller to drive stepper motors drivers which drove the steppers directly from the battery. We would get about 30 minutes of dev time per charge with this configuration. Now in your case you have some power hungry computing specified, so you may need to do a little math: Estimate your instantaneous power draw. \$5v*2A + 3.3V*0.1A + etc... = ?W\$. Most NiMH are around 2000mAh. So 8 in series gives you \$1.2V*8*2Ah=19.2Wh\$ Finally divide your estimate by your battery pack to get a time estimate: \$\frac{?W}{19.2Wh}=?h\$
H: hex inverter oscillator I stumbled across this clock generator, and it is new to me. I'd like to calculate its frequency (actually min and max, since there is a trimmer), but I don't know how to do, since similar oscillator looks simpler than this. I tried to simulate this schematic, but it didn't work. AI: This design might fail on some simulators if the internal ESD diodes are not included. The gain margin frequency have not have enough gain at the limited slew rate where the frequency is unity gain to produce an output. If AC noise at Vdd/2 the 2nd stage is less than the offset voltage from mismatched FETs , it may not oscillate and just stay at 2.5V I could simulate failure without diodes and success with internal diodes here. As for frequency, guess what RC=T is when the ramp goes from diode drop outside rail to Vd/2. Hint f=1/2T with some tolerance for thresholds +/-25%
H: Could a resistor work as well as a signal diode in this level-shifting circuit? The following hackish circuit uses the internal circuitry of one "sacrificial" WS2811 LED to level up the logic voltage to 5V for the remaining strip by placing a signal diode in series with the power supply input of that first WS2811 circuit. Since all we're trying to do is drop the voltage by 0.7V, could we conceivably have found a resistor to be used in place of the diode to drop the voltage by a comparable amount? If so, are there any considerations that make the diode the better choice? If not, why not? (I'm sure that to veterans this very question exposes a deep lack of understanding of electronic basics on my part. You probably don't need to point that out - I'm here to learn.) AI: I don't think so. For one thing, the WS2812 chip receiving 3.3V data may actually work. It may not be reliable, but you can't count on the LED's to stay off nor on or in any consistent state. So then if the first chip changes output state of its LED's, then the supply current will also change. If the supply current changes, then the current through the diode will change. If you substitute a resistor instead of a diode, with the potentially non-constant current, you won't get the voltage drop you are trying to get. You will get a variable voltage drop that depends on the state of the LED's in the first chip. Also, these chips have internal switching. This means that even if the LED's are in a consistent state, the current will not be constant. So, all around, it is not a good idea to try to use a resistor. In my opinion this circuit is really crappy. I would suggest you use a level shifting buffer if you want reliable operation. The sacrificial LED makes no sense to me.
H: Voltage reference using zener diode and transistor Below is a circuit presented in a book as a stable voltage reference circuit. The other says that "Vref=Vz+0.6". I am not convainced about this equation, and I think that Vref is just VZ because of the virtual ground of the OPAMP. If I am not right, that means there is a trick in that circuit. Please can anyone confirme to me the formula given by the other and how he did that ?? AI: I think the designer (grad student) was having a bad day.... MC3401 has NPN inputs unlike the quad LM324 with PNP inputs that operate to Vee =0V. The 3401 must have Vin+>Vin- by having a slight +ve input offset current. Otherwise if Vin->Vin+ the output goes low and stays there no matter how much negative feedback. When this condition occurs. the Zener current, Iz causes Iz*R1 = __ mV for the stable low Zener current then near null offset and Vout=Vz @ Iz Since Vin+ has lower input bias current than the collector Vin- then Vin+ will have a lower input voltage than Vin- which forces the output at 0V. So Vin+ must never be 0V=Gnd. It must be slightly > Vin- otherwise the Norton or any Op Amp will not work. This takes 3 R's/ Pull up/down and series R.
H: Step down transformer vs Electronic voltage regulator for appliances between 220v to 110v I recently purchased an Instant Pot 6 Quart with specs(Electric Pressure Cooker) from the US(outlet supply 110v) and would like to send it to a country that has outlet supply of 220v. The cooker is rated at 1000W to only run at 110v. This means that the usage of a step down transformer is a must. I am looking at something like this. The 5000 in the image means it can take upto 5KW. However, I came across these electronic(SCR) voltage regulators that can do a step down function also. Pictured below is one such device My question is the following: Do both these appliances convert 220v to 110v in the same fashion as far the usage is concerned(Off course the mechanism to achieve is different)? If yes, would it be ok to use any of the two for the pressure cooker? If not, why not? AI: Your cooker is described as:- America’s most loved multi cooker, built with the latest 3rd generation technology, the microprocessor monitors pressure, temperature, keeps time, and adjusts heating intensity and duration to achieve desired results every time. It may use phase control (like a light dimmer) to control cooking power. This would be done with an SCR or TRIAC, which delays switching power to the heater until part way through each mains cycle. Alternatively it might use 'zero-crossing' switching, which lets through a proportion of full mains cycles to vary the average power. The THYEISTORELETEONINICVOLTACETTCUATOR probably also uses phase control to produce the heating effect of a lower voltage (another name for SCR is Thyristor). This works well with purely resistive loads such as a heater or incandescent lamp, but not with devices which are expecting a full sine wave input - such as your cooker. The step down transformer reduces voltage without changing the waveform, so it should work with most devices. The only potential problem is that countries with 220V mains often run at 50Hz rather than 60Hz. Hopefully the controller in your cooker is smart enough to adjust itself to the different mains frequency. Symptoms of not doing so may include 20% slower timing (eg. cooking for 12 minutes when set to 10 minutes) and incorrect power levels if using phase control.
H: Understanding electric torque of a motor I'm missing something fundamental in my understanding of the torque of a motor. Consider the following analogy: I have a 10kg dumbell on the ground and a 1kg dumbell next to it. Let's say that I lift the 10kg dumbell off the ground with a certain force 'F'. Now let's say I use the same force 'F' to lift the 1kg dumbbell. Naturally, I would lift the 1kg dumbell much faster, right? Now coming to electric motors, let's say I attach a 10kg load to the motor shaft. The motor would produce a torque T and rotate at a certain rpm. Now, I put 1kg load on the shaft. As per the dumbell analogy, wouldn't the 1kg load cause an increase in speed because it's lighter than 10kg? But we know that a motor's torque keeps changing with the load. So for a 1kg load, does the motor produce just enough torque required to rotate a 1kg load? If yes, how would the motor know what the load is so as to produce the right amount of torque? If no, them wouldn't the motor produce the same amount of torque for all loads and only the rpm keeps changing? AI: Assuming we are talking about a shunt wound or permanent magnet brushed DC or BLDC motor, torque is proportional to current, so the more torque load you put on the motor the more current it will draw to match it. However the current causes a voltage drop in the winding resistance, which reduces rpm. How much the rpm drops depends on the resistance. A large motor with thick low resistance wire could lift a heavy weight without its rpm dropping significantly, while a small motor with thinner wire might drop down to stall speed and not draw enough current to lift the heavy weight at all. To understand the relationships between torque, current, rpm and voltage, consider this simplified model of a PMDC motor:- simulate this circuit – Schematic created using CircuitLab When the motor spins it generates a voltage proportional to its speed. This is a result of Faraday's Law, which says that moving a wire through a magnetic field induces a voltage in it proportional to its velocity, and occurs whether it is driven by an external force or by its own power. Depending on how it is constructed (number of turns, size, stator or armature slots, magnet poles etc.) each motor has a characteristic 'Kv' (Velocity constant), commonly expressed in rad/s/Volt or rpm/Volt. Output torque is proportional to current according the Lorentz force law, which says that the magnetic force on a wire is proportional to current x magnetic field strength (which is constant in a permanent magnet or shunt wound DC motor). For a particular motor this relationship is a constant, called Kt (Torque constant), often expressed in N.m/A. By symmetry, Kt is the inverse of Kv. So if you know one then you know the other. If Kv = 10.5 rad/s/V (100 rpm/V) then Kt must be 0.095 N.m/A. For this simplified model we will ignore any internal losses due to magnetic hysteresis, eddy currents, friction and air drag. If the motor has no load then torque and current are zero, and no voltage is dropped across Rm. That means the generator voltage must equal the supply voltage, and the motor must be spinning at 100 rpm/V * 10V = 1000 rpm. Now put an external torque load on the motor. It will slow down and produce less voltage, causing voltage to be dropped across Rm. By Ohms Law a current must then flow, producing torque. Speed continues to drop and current rises until output torque matches the externally applied torque. If the torque load is high enough to stop the motor spinning then there is no generator voltage and the full 10V is dropped across Rm, causing a current of 10V/1&ohm; = 10A. With Kt = 0.095 N.m/A and current = 10A, the 'stall' torque must be 0.95 N.m. Now imagine an otherwise identical motor which has thicker wire, reducing Rm to 0.1&ohm;. The same 10A current (producing the same 0.95 N.m torque) now only drops 1V across Rm, so the generator must be producing 9V. This motor must be spinning at 9*100 = 900 rpm (only 10% less than the no-load speed) while lifting the weight that stalled the other motor.
H: Impedance Control in Twisted Pairs and PCB Why do differential signal traces on a PCB require a reference plane to have a controlled impedance? Whereas, in an unshielded twisted pair there is no reference, there are only the two conductors? Thank you for any answers that you can provide. AI: Why do differential signal traces on a PCB require a reference plane to have a controlled impedance? They don't is the short and long answer. However, if you are wanting to fully utilize the space on your PCB for other components and other non-connected circuits you need to use ground planes to avoid upsetting the controlled impedance and avoiding unnecessary cross-talk or interference.