texts: Latching Press-on / hold-off toggle switch circuit. Works on breadboard not on PCB

texts:
I followed a schematic and mocked up a Latching toggle switch with NAND gates. (see picture below for what I followed)

(Source)

I have mocked it up onto a breadboard.  Using the exact same values of resistors and caps. The NAND gate that I used was a CD4011BE.

Datasheet is ( http://www.ti.com/lit/ds/symlink/cd4012b.pdf )

I had it jumpered to the actual PCB and using the actual button I want to use in the change of design.  (adding this circuit to the PCB on the next rev) and it worked great.

Now that the change has been made to the PCB and we have some in to test, it does not work.

My schematic is below.

I am actually driving an inverter that is driving a enable line.  When the enable line is high my device is on and when it is low the device is off.  This latching NAND circuit won't actually come on, which means my device never turns off.

Also it is all being powered (inverter, NAND, other circuits) from a lipo battery.  The data sheet for the NAND gate is http://www.ti.com/lit/ds/symlink/sn74lvc2g38.pdf

The voltage as I have been testing is around 3.78V DC as expected from the lipo.  Between R9 and R10 it's only showing 1V DC when the button is not pressed and between R10 and C11 it's showing about 0.87V DC.

I suspect that maybe the NAND gate I'm using is not able to work for this for some reason, but looking through the data sheet I couldn't find a reason it wouldn't. I have verified that the PCB layout is correct and in my schematic A1 and B1 is one gate and A2 and B2 is the other gate.

Any help would be greatly appreciated.


texts:
EDIT: Added a picture with values and a better explanation.
I need a little help over this calculation.
I have to calculate the average power dissipated by a bootstrap diode (actually a MOSFET connected as a diode) in a buck converter.
We know that \$P_{avg}= \int_{0}^{T_{SW}}p(t)dt\$
Since I have the instantaneous voltage across the diode (red) and the instantaneous current across the diode (yellow,) I can obtain the instantaneous power (green.)
Now to calculate the average power in a period just sum the area of the 4 blue triangles, right?
Doubt arises from the fact that by using \$ P_{avg}=V_{rms}I_{rms}\$ , I obtain an 8 times higher value than the one calculated with the triangles' area.  It seems that this formula cannot be used in this case
Many questions online referr to sine waves or in the case of the diode the answer is typically "use \$ P_{avg}=R_{D}I^{2}_{rms}\$ for conduction losses and then calculate reverse recovery losses with the triangle area" but I don't have \$ R_{D}\$ and I prefer to work over these waveforms.


texts:
For a project I need to switch on a simple handheld vacuum cleaner with an Arduino. I am thinking of using a relay or mosfet.
I opened the case and a 7.4 V 2200 mAh Li-Ion battery powers the motor, through a regular switch.

On the manufacturer's website, the power of this vacuum cleaner is 120 W, so according to my understanding:

I = P/V

I = 120 W / 7.4 V = 16.2 A

So according Ohm's law, the resistance of the motor has to be 0.46 Ohm right? Isn't this too low?

Thanks.


texts: In Verilog, How is a 4:1 Mux made using case statements without creating a D-latch?

texts:
Whenever I try to make a 4:1(32:8) mux in verilog using the following statement:

always@(*)begin
case(sel)
    2'b00:Din1=Qsel;
    2'b01:Din1={Qsel[15:8],data[7:0]};
    2'b10:Din1={data[15:8],Qsel[7:0]};
    2'b11:Din1=data;
    default:Din1=Qsel;
endcase
end

I get the error

[Place 30-574] Poor placement for routing between an IO pin and BUFG. If this sub optimal condition is acceptable for this design, you may use the CLOCK_DEDICATED_ROUTE constraint in the .xdc file to demote this message to a WARNING. However, the use of this override is highly discouraged. These examples can be used directly in the .xdc file to override this clock rule.
< set_property CLOCK_DEDICATED_ROUTE FALSE [get_nets sel_IBUF[0]] >

sel_IBUF[0]_inst (IBUF.O) is locked to IOB_X0Y34
 and sel_IBUF_BUFG[0]_inst (BUFG.I) is provisionally placed by clockplacer on BUFGCTRL_X0Y1

If I use if / else logic instead:

always@(*)begin
    if(sel[1]&!sel[0])
        Din1<={data[15:8],Qsel[7:0]};
    else if(!sel[1]&sel[0])
        Din1<={Qsel[15:8],data[7:0]};
    else if(sel[1]&sel[0])
        Din1<=data;
    else
        Din1<=Qsel;
end

I don't get the problem anymore.

The RTL schematic looks like this:

It's creating a d-latch whenever the "select" inputs are asserted. I only want the value to be stored whenever my FPGA's clock ticks. Any solution to use case statements with combinatorial logic?


texts:
I have been having a very hard time understanding what a I2C bus is. I would really like some help in understanding what this is. This is a very broad and a very extensive topic that you could go on and on about. Therefore, what I'm asking is for a online resource that could help me out in understanding what it is and how it works. From the sites I've located it has been very hard to understand it's features and uses. I'm just a beginner student and need a more applicable description. Thanks for any guidance you have.

Again I realize this is a very broad topic and apologize if this is unsuited for a thread. However, I'm really fascinated by this thing and I'm looking for the most educational source available in helping me learn how to utilize this and in general what it does.


texts: I repair treadmills and occasionally the motor causes the controller to fail. I use a 20v dc source with no load for the test.I have determined thru testing many motors of the same specs that a current draw above .75 amps will cause speed regulation issues and if it goes above 1 amp the controller may fail upon startup. A new motor will typically read .53-.60 amps. I also listen for bearing noise to eliminate that. My question is because I run into many motors I haven't tested and don't know what the "good reading should be can I determine that by any info off the label. Unfortunately some motors have only he HP and Wattage rating. For example the label says 2.8hp/2089 watts. Thanks in advance for your time to reply Jon


texts:
I am trying to understand the RF transmitter (Q1) part of this schematic:

(source: https://fccid.io/KUJCE9001/Schematics/Schematic-Diagram-171495.pdf)

What type of oscillator is it? Colpitts, Hartley, something else?

Some context: this is a ceiling fan remote control, range a few meters. According to FCC documents, it transmits at 299.6 MHz. The input (into R3) comes from a digital encoder chip SM5023RF (I believe equivalent to PT2262 - datasheet: http://www.princeton.com.tw/Portals/0/Product/PT2262_5.pdf) which is a simple 12-bit pulse-position modulated code.

Thanks in advance.


texts: How to build a programmable sticky button

texts:
I'm trying to build a button that can exist in two modes. Either it springs back after being pressed, or it stays pressed. I want to switch between these two modes using some complex logic, controlled by an Arduino or a RaspberryPi. The dimensions should be around 1'-by-1', and I'll have a 5-by-6 grid of these buttons to make a puzzle. I'm struggling to come up with a simple design for one such button.

I thought of using a solenoid, but they have a duty cycle and use a lot of power in one of the two modes. Ideally, I would only need power to switch between the two states. That way, a player can play with the puzzle for a while, then leave it alone overnight and come back to playing the day after. I'd rather not keep the solenoids powered overnight.

Another idea I had was to use two electromagnets to pull some kind of a latch back and forth, to jam the button in its pressed state. But that seems complicated and finicky.


texts:
Recently I have been trying to get myself an arduino made by hand (as where I live the original one costs about 10x and its fun to make things on your own). I made a compatible on the breadboard and tested it using the blinky program. Now I want to make it on a PCB. The problem is getting a PCB manufactured is also not so cheap (if you are getting only one board). So I was thinking I would use a prototype board. I have used those once before and it was a clear mess. I kept shorting IC pins while connecting lines to them fried a whole PCB (actually fried it, the LEDs went BOOT, the IC went WOOSH and the wires turned to a general copper ting). All in all it was a not so good experience. I attribute this failure to my incompetence in soldering on the prototype boards. I can do a clean solder on any PCB in a kit but I think prototype boards are a different ball game.

So I ask you all of any tips you may have on using such boards.

Thanks in advance.


texts: What is the difference between an inverting and non-inverting MOSFET Driver?

texts:
I'm looking for a High Side MOSFET Driver (have the MIC5014/15 in mind) to drive an N-Channel MOSFET, and I noticed that this IC had a Inverting and Non-Inverting variant. What is the difference between the two? Does this have to do with the Input Signal that turns ON and OFF the MOSFET?
Datasheet: http://ww1.microchip.com/downloads/en/DeviceDoc/mic5014.pdf


texts:
I'm controlling a 16x32 LED matrix with an Arduino and have it wired correctly (I think) but I'm having trouble with the power. I tried to follow the instructions from Adafruit but was unsuccessful in that they described parts (and claimed to include others) that I don't have.

Here is an Imgur album that I threw together of what I have. The first is the LED matrix and the other two are parts that I have that may be applicable to this solution. (The power supply is +5V 2A, as recommended by Adafruit).

I think I have the pieces of the puzzle, I just need help wiring them up and making things work without frying my matrix or Arduino.

P.S. I couldn't use a Molex connection from a power supply unit for a desktop, could I? This will end up being very close to a computer.


texts:
Can anyone help me how to identify the component in the following image ?
It's found on a power supply circuit (LED driver)

Thanks in advance


texts: How do I appropriately power a headphone amplifier and where do I place the volume regulating potentiometers?

texts:
At the moment I am building a device that splits an analog stereo audio signal into
3 signals and amplifies 2 signals for headphones.
I need to know how to supply -12VDC and where to put the volume regulating potentiometers for each of the 3 outgoing signals. Also should I use 3 op-amps for each outgoing signal or is one enough? What values should the inductors in the power supply circuitry be?

Supplementary information:

The input signal is coming from my audio interface and is enough to drive my old 32 ohm impedance headphones. Unfortunately they broke from old age and now I'm keen on switching to 250 ohm impedance headphones. Since the volume knob is already turned halfway with the old headphones, I figured that won't be nearly enough for my new high impedance cans. (Also different reviews said so.)
Since I need a new device anyways and headphone amplifiers are not particularly cheap, I will use this opportunity to build myself a device, that I have dreamt of for quite some time.

The device will need to split the incoming signal from my audio interface (2 RCA jacks to the bottom left) into a non-amplified signal for my active monitors and 2 amplified signals for headphones. Every signal here is stereo. It needs to be powered by a 12VDC/2A wall wart power source that is lying around in my flat. Now, I have got a general idea of how the circuit for the splitter and amplifier should look like. I intended to use a NE5532 op-amp, followed by a TPA6120A2. These both get decent attention in the HiFi community, so I figured they would be appropriate. Both of them need a -12VDC power source, which I have no idea how to construct. Both 12VDC and -12VDC will be regulated by a L7812 and a L7912. Please feel free to call me out on my idiocy and utter lack of experience when you notice any pitfalls or just general errors in my circuit. This is my latest design:

DISCLAIMER: Please be patient, I know it's probably convoluted and ugly, but this is my first (mostly complete) design ever, literally. I have no prior experience and tried to follow all the datasheets and reference designs I could find as closely as possible. Also, I'm neither an electrical engineer, nor a native English speaker, just some hobbyist.

If this project turns out to be useful, I will not hesitate to give back to the community and put everything on github, for other, probably more competent people, to build on.

EDIT: I may have phrased this poorly, but I do have some experience with respect to soldering. I do own all the necessary tools to deal with most SMD components, although I would really prefer to avoid BGA components. However, I have not created any designs on my own before and if I just botch together some kits for headphone amplifiers and a signal splitter, I know I won't be satisfied with the result.


texts: How to alleviate the negative effects of using parallel LEDs with a common resistor?

texts:
We all know the rookie mistake of using LEDs in parallel and not giving them separate series resistors. They are often doing it for ill-founded incentives like "I want to save money on resistors", "I don't want to solder that much", and "They all have the same color anyway so why bother?".

The correct answer in such a situation is to persuade the OP to use separate resistors. Forums and QA sites (including this one) are full with such examples.

However, consider a case when it's completely impossible to avoid using a single resistor for separate parallel LEDs. I know it's bad. I know it's evil. But in a case it cannot be avoided, what methods are there to at least try to slightly alleviate the problems such a circuit can will cause?

Consider a case with 2 to at most 5 LEDs of same color from the same production batch. The LEDs don't have to shine with their maximum brightness, so the current can be smaller than the maximum allowed current (although 1/x for the case of the device with x LEDs would probably be too low). The LEDs are inside a proverbial box, in parallel, and the box can not be changed. With the two wires hanging out from it, I can do whatever I want. Still, I would prefer simple solutions with few and only passive elements. (of course, complex microcontroller-driven solutions will also be appreciated, especially if no simpler solutions can be found)

Clarification: By "alleviate" I mean to reduce the brightness differences as much as possible, and, of course, to avoid them being damaged.


texts: Why is the output inverted for this SPICE model

texts:
I created a part from the SPICE code of a 4n32. I found the SPICE code from here.

And here is the section about this part:

*******************************************************************************
* A = diode anode
* K = diode cathode
* C = BJT collector
* B = BJT base
* E = BJT emitter
.SUBCKT A4N32 A K C B E PARAMS: REL_CTR=1
* 4N32 from Motorola Optoelectronics data book Q3/93  -  RPerez
D1 A D Demit   ;Gallium arsenide infrared emitting diode
Vsense D K 0    ;Diode Current sense -> IF
* Gpcg models CTR
Gpcg C B TABLE  ;Photodetector {IC@IF * (normalized CTR at IF)/(Q1 BF)
+ {70m*REL_CTR*(8.448148613*0.998979389^(1/(abs(I(Vsense))+0.1p))*
+ I(Vsense)^0.449371295)/18k} (0,0) (0.3m,0.3m)
Q1 C B V Qdtect1   ;phototransistor detector
Q2 C V E E Qdtect2   ;Darlington
.model Demit D IS=1P N=1.948621 RS=1.560495 BV=3 IBV=0.05U
+ CJO=18.8P VJ=0.532794 M=0.27985 EG=1.424 TT=500N
.model Qdtect1 NPN IS=0.625P BF=135 NF=1.0941401 BR=10 TF=0 TR=1.2u
+ CJE=8.24P VJE=0.99 MJE=0.247851 CJC=8.01P VJC=0.514483 MJC=0.370451
+ ISC=0 VAF=275 IKF=0  ISE=0.1p
.model Qdtect2 NPN IS=0.625P BF=135 NF=1.0941401 BR=10 TF=0 TR=1.2u
+ CJE=8.24P VJE=0.99 MJE=0.247851
+ ISC=0 VAF=275 IKF=0  ISE=0.1p ISS=0 CJS=3.82p VJS=0.99 MJS=0.200397
.ends
*$
*******************************************************************************

Then I use this part in the following circuit:

The pin number assignment are are:

What could be the reason that the output is inverted?


texts: I have designed a circuit where I want to give a pulse of very short duration using a switch. How can I implement it in spice.


texts: Should the output impedance of a function generator be high or low?

texts: As we know, \$R_{load}\$ should be greater than \$R_s\$ on a function generator to avoid loading effect. Does it mean that the output impedance of the function generator should be lower?


texts:
I have this circuit from the image below that I am designing myself.
part of this circuit is cut so 2 78xx is present.
This circuit is being designed and tested in parts.
This part of the circuit has to work basically by amplifying the signal from the electret microphone, as it will also work by sounding a siren sound generated by the 555 when the button is pressed.
The part of lm386 is ok, without noise.
the problem is when I connect output 3 of the 555 to one end of the button and the other to input 3 of the op amp;
the siren sounds very low in the background when I do this.
already tried to solve even with transistor and nothing solved.
does anyone have any tips on how can i solve this ?.

Thanks in advance

obs. I've tested it with other buttons, it seems that the buttons continue to drive even in cut


texts:
I am trying to figure out where I went wrong on the following problem:

simulate this circuit – Schematic created using CircuitLab

  The two batteries are identical, and each has an open-circuit voltage of 1.5V.
  The lamp has a resistance of 5\$\Omega\$ when lit. With the switch closed, 2.5V
  is measured across the lamp. What is the internal resistance of each battery?

    (Problem 2.1 in Agarwal and Lang's, Foundations of Analog and Digital Electronic Circuits).
    Note the answer printed in the back of the book: 0.5\$\Omega\$ .

Here's my solution:

Step 1

Use element law to find current, \$ {i}_{1} \$, through bulb.
$$
v=iR \rightarrow {i}_{1} = \frac{v}{{R}_{bulb}}=\frac{2.5V}{5\Omega}=\frac{1}{2}A.
$$

Step 2

Model the internal resistance of each battery as a resistor. State the equivalent resistance of the two resistors in series.
$$
{R}_{eq}={R}_{1}+{R}_{2}=2{R}_{n}
$$

Step 3

By Kirchoff's Voltage Law, the potential difference across the two batteries must be equal and opposite to the potential difference across the lamp. I combine the element law with the above expression in the following manner:
$$
v={i}_{2}{R}_{eq} \rightarrow {R}_{n}=\frac{1}{2}\frac{v}{{i}_{2}} (eqn. 1)
$$

Step 4

By Kirchoff's Current Law, the sum of currents at any node is zero.
$$
{i}_{1}-{i}_{2}=0 \rightarrow {i}_{2}={i}_{1} (eqn.2)
$$

Step 5

Combine eqns. 1 & 2 to find \${R}_{n}\$, the internal resistance of a single battery.
$$
{R}_{n}=\frac{1}{2}\frac{v}{{i}_{1}}=2.5\Omega
$$

Conclusion

After reflecting on the problem statement, especially the open-circuit voltage part, I know that I am committing some logical fallacy. However I just cannot see it on my own. Where did I go wrong? Should I not imagine that the internal resistance of the batteries can be modeled as a resistor? Would an energy / power approach be better suited to this problem?


texts: Controlling coreless DC motor using ESP8266-01

texts:
I want to control a coreless 3.7 VDC motor (quadcopter motor) using a ESP8266-01 module. I've used a BC547 (BJT) to act as a switch for motor. The circuit worked fine with LEDs but when connected to motor, the ESP8266 does not even able to establish a wi-fi connection. I think the ESP8266 is resetting itself. I have added an 1N4148 as a flyback diode but still the problem exists. Is it anything to do with back EMF? If so how to reduce it? Or is there any other good option to control a coreless motor with ESP8266-01?

simulate this circuit – Schematic created using CircuitLab


texts:
I have a PIC16F684 with buttons connected to PORTA:0 & PORTA:1 which are also used for ICSP DAT & CLK. The ICSP signals are coming from a PIC programmer which I've built using an Arduino. The DAT & CLK lines are driven by IO pins and I'm not sure of what to set the IO lines to so that they allow the buttons to be read by the PIC. I've enabled the weak pull-ups and buttons on other PORTA lines work fine. Should I use series resistors on the button lines? I've tried 180 ohms at points A & B but the signals are still being influenced by the ICSP lines. I've also tried 180 & 660 ohm resistors at C & D, still no luck.

So - how do I isolate the ICSP lines when the programmer is idle? I could use a FET but it seems like overkill...

simulate this circuit – Schematic created using CircuitLab


texts: What is current capacity of IDC connected of 7 stranded 36AWG wire (listed as 28AWG)?

texts:
Another engineer posted that 100mA was my current capacity for 5 volts over IDC connectors through 7 stranded 36AWG wire (listed as 28AWG) ribbon cable.  But I don't know where that information comes from. I'm going through about 12" of ribbon cable. Other tables I look up suggest that I could theoretically expect to pass between 200 and 250mA.
I'm pinning out IDC connectors that will carry between 100mA and 300mA of 5 volts and need to minimize the number of pins dedicated to the power.  If I'm out of pins, could I get away with 2 pins for 300mA?
Thank you for any replies.


texts: Verilog: Writing to a Register Happens A Clock Cycle Late

texts:
I have a Verilog module acting as a register file (a slew of registers and some access ports) with a control signal coming from another module that controls when the write to one of the registers happens.

The idea is that I raise a control pin and the specified register is set to the value on one of the module's data inputs as follows:

module RegisterFile(
input CLK,
input [4:0] RegA_Name,
input [4:0] RegB_Name,
input [4:0] RegC_Name,
input [31:0] RegA_In,
input [31:0] RegC_In,
input RegA_WrtEn,
input RegC_WrtEn,
output reg [31:0] RegA_Out,
output reg [31:0] RegB_Out
);

reg [31:0] r [31:0];

integer i;
initial begin
    for(i = 0; i < 32; i = i + 1'b1)
        r[i] = 0;
end

always@(posedge CLK) begin

    RegA_Out <= r[RegA_Name];
    RegB_Out <= r[RegB_Name];

    if(RegA_WrtEn) begin
        r[RegA_Name] <= RegA_In;
    end

    if(RegC_WrtEn) begin
        r[RegC_Name] <= RegC_In;
    end
end

I'm aiming for the register contents to get set and for that content to appear on the output on the same clock cycle that write enable gets set high.

I see the behavior that I'm shooting for when testing the module from a testbench, but when I wire it to the module that's actually going to be controlling it and test that, the write happens not on the clock cycle that write enable is set high, but two clock cycles after (depicted in the waveform below). Why might this be? How can I edit my code to achieve the behavior I'm shooting for, or something close to it?


texts: Multiple Options for Passive Audio Mixer

texts:
I have two mono audio inputs that I need to passively combine into a single output. Both inputs have built-in volume controls so I don't need any volume control in the mixer. I've been looking at ways to do this, and have seen a couple common options. About 50% of suggestions seem to be for something like this:

While the other 50% are for something like this:

So, my questions are:

1) What's the deal with the 20k resistor between the signal and ground wires in the second schematic? What purpose does it serve and why does the first schematic not have it?

2) Realistically, how important is the resistance value of the other resistors (1k in the first schematic, 475 in the second)? I understand it has to do with loading and volume reduction, but not sure how to choose a good value. In schematics for this kind of circuit, I've seen values ranging from 10 ohms to 10k ohms for those, with no decent explanation for the 1000x difference.

For context, this is summing the unbalanced mono input from two voice communications radios into a single unbalanced output, so audio quality is not super important.


texts: Why so few osilloscope with dedicated isolated channels?

texts:
Background:
I am a junior engineer who work with testing and designing inverters for motors. I have been looking at a new oscilloscope since the one I had gave up. There are alot of Tektronix TPS2024b being used since it has dedicated isloated channels on it. I was not sure how isolated channels worked to begin with but I now understand their usefullness. It is very hand 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 measurments.

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 of.
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 osilloscopes 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 isloated oscilloscopes, 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 to me seems very good and like a no-brainer, if it is possible to get one.


texts: is there any integrated circuit HEX to 7 segment decoder for a common anode 7 SEG display that generates codes to display hex digits from 0 to F as shown in the photo. Thanks


texts: Motor stall detector with a voltage divider in parallel to the motor and ADC: it does not work as expected

texts:
I'm trying to replicate a motor stall detector I found on a PCB of a commercial device (chinese). This is the schematic:

I'm using an ESP8266, resistors with same value as in schematic, two MMBT3906 as PNP and two MMBT3904 as NPN. Analyzing schematic when motor is running the Vadc is near to VCC/2 and when the stall occours Vadc should drop due to the motor stall which is like a short-circuit.

But when I try it, the voltage does not change when the motor stall.

What I'm doing wrong?

PS: I cannot find the transistors used in the original device, and their codes are very hard to read. These are two photos of them I take with digital microscope:


texts: Dividing current between inverter and relay

texts:
I want to make DIY ATS.
My power supply is from 120Ah 12V battery.
I have a 12V to 220 inverter and a relay circuit.
My problem is the inverter doesn't supply 220V when it is in parallel with the relay circuit.
The inverter is a 12V to 220V pure sine wave transformer.
I'm using an XH-M609 as a relay controller.
The XH-M609 will disconnect the voltage when the battery voltage is low.
The relay coil will be on when battery voltage is high, and will off when the battery is low.
Am I doing something wrong?
I think I need to limit the relay input current so inverter can gain more supply.
Can someone help me?


texts: So I have a non-inverting opamp configuration R1=20k and the system starts to oscillate if R2 is less than 20k. I need to make the gain margin equal to 6dB by choosing the right value for R2.


texts: How does an RS-latch work in the presence of propagation delays?

texts:
I've long wondered how an RS-latch can work, given the existence of propagation delays.

If the nor-gates have non-zero propagation delays (aka gate delays), wouldn't it need to be the case that:

The inputs to each are held stable during the propagation delay?
The outputs should not be used as inputs until after the propagation delay has passed with unchanging inputs?

This differs from other questions about RS-latches, which do not consider propagation delay:

how does RS flip flop works?
How does the basic RS Flip-Flop (also known as latch) works?

Consider the below picture, which illustrates the transition from {R=0, S=1} to {R=1, S=0}. After the transition is made, won't Q and Q' temporarily enter the forbidden region? When those bad values enter the other gates, won't those (possibly) enter the forbidden region, causing garbage to propagate?


texts: Why is the pulse reflection becoming like this in pulse?

texts: I use mosfet to generate a pulse, input the pulse into the transmission line, and after the reflection, test the waveform as shown. Why did the third reflected waveform become like this? I calculated a circuit output impedance of 50 ohms and a transmission line characteristic impedance of 25 ohms. Is it a simulation software problem or a calculation error?


texts:
In single phase motor copper or aluminum bars are permanently shorted at both end with the help of rings. So here what does the mean of shorted?

When I am looking on Google all results are showing the meaning of short circuit. And I think both terms are different. So please help me to understand.


texts: powering old portable 80's radio with powerbank

texts:
I'm trying to connect an old radio to a powerbank. I used the the wires from the 6v battery holder and connected them to a usb cable. Now, when I insert the usb cable into a powerbank, the radio will work fine. However, it soon stops working, most of the time after a couple of minutes. I would like to solve this problem and not re-insert the cable every couple of minutes.

When I insert the usb cable into a usb cellphone charger that is connected to the grid, the radio keeps working without a problem. Why does my powerbank 'refuse' to give elektricity to the radio the same way the grid does?

I've tried placing a 470uF capacitor between the + and - . This seems to have no effect.

I measured the amps that the radio draws from the power bank. It seems fluctuate between 43 mA and 150 mA max.

All help is greatly appreciated

Martijn


texts:
I am an EE student and recently we worked with Schmitt triggers, positive feedback loops, and hysteresis. I was curious and hooked up an mcp601 without a feedback loop as such:

In the above schematic the pulse generator is behaving as a triangle generator. This is labeled Vin on the oscilloscope. Vout on the oscilloscope is the output voltage of the op-amp.
I was surprised to find that I was able to measure hysteresis even though there was no feedback loop:

Couple of questions here:

Is this due to the internal circuitry or is there a measurement error on my part?
If this is due to the behaviour of the op amp - is it an intended use?


texts: Why in a MOS device the depletion zone width doesn't increase if the applied voltage is over threshold?

texts:
If a positive tension V is applied in a MOSCap, the depletion zone width will increase until the threshold voltage is reached. If the applied tension is above the threshold voltage the depletion layer will not increase in width.
What are the reasons for this behavior? Why over the threshold voltage the bands will only bend slightly, leaving the depletion width unchanged?

EDIT:
What I don't understand is that the threshold is defined as the condition in which the density of electrons near the oxide is equal the density of donors. In other words I've applied a tension which have caused the "conversion" of a p-type semiconductor in a n-type one. If I further increase the tension more electron will be collected under the oxide but the depletion zone will not increase in width. Why?


texts: Potentiometer or momentary switch, how to better recognise what was connected?

texts:
I have a working circuit and I'm looking for cues on how to improve it.
I'm building a device with a user controlled small stepper motor. Speed of the motor can be controlled by a pedal connected via audio-jack.
I need to properly recognise a type of the connected pedal and handle its value in the MCU.
There are 3 types of pedals that can be connected:

Type A - simple momentary switch, user can switch motor on or off.
Type B - pedal with a (10k) potentiometer, user can control speed
with her foot.
"Type C" - nothing is connected, empty socket

I have a circuit that works using two ADC pins on atmega328p, A5 reads pedal type, A1 reads its value, combination of readings from both pins allows me to control connected motor.
Question: how I can improve, simplify or make it more resilient?
I would be very grateful for tips from more experienced colleagues.


texts:
I am new here, I actually work on application programming.

As a hobby I started to work with arduino and dc motors. Soon I ended up with backlash problems. Right now I am using a rotary encoder which give 4000 counts per rotation.

This is with a 12v planetary geared dc motor. I also tried with spur geared motor.

I am able to control the motor. But it's not very precise. The difference between counts changes each time.

For example, when I try to stop motor at 2000 counts it will stop anywhere between 2004-2016 counts. This problem is due to backlash. I connected the encoder to motor shaft using a timing pulley.

What if I attach a disc to motor shaft and stop it using solenoid. Anyone ever tried something like that or any other inexpensive idea.

I am from India and I do not get precise products easily here.  I can post pictures of setup if needed. I shall give up with DC motor and opt for stepper?


texts: How to choose a bypass capacitor for a common emitter amplifier?

texts:
This site says: "To increase the gain for AC signals the emitter resistor bypass capacitor is added. This should be calculated to have a reactance equal to the emitter resistor at the lowest frequency of operation".
I assume that I have 1K ohm emitter resistor. If I added a parallel capacitor of reactance 1k ohm. The total impedance would be 0.5 K ohm.
In this case,
Should I increase the emitter resistor to be 2K and increase the reactance to be 2K so that I get 1K ohm (Which is the original value of emitter resistor before adding the bypass cap)?
Or it is ok to have an impedance of 0.5k ohm although the original value of emitter resistor is 1K?
Will a bypass capacitor affect the bias voltage of the biasing resistors?
Thank you very much,


texts: Accuracy error of ammeter from specification : is it really just a constant offset?

texts:
On ammeter specifications it is often written accuracy specification
$$ (....\% rdg+ ... digits) $$

While the ammeter can have a certain last digit on the screen, which determine the resolution if the instrument

My question is : is the error expressed in the specification really just an offset (i.e. a constant shift on the current) for all the measurements made with the ammeter?

In other words is it just a systematic error?

Or is it actually something more than just an offset?

I mean, if it was just a constant offset, then its value could be provided to correct all measurements and there would not be need of this error at all!


texts: Input/Output Impedance of DC/DC converters and Impedance matching

texts: I am interested in understanding how do DC/DC converters achieve impedance matching for maximum power transfer applications. After visiting this entry, you can see in the "impedance matching" paragraph some calculations that lead to D=sqrt(η*Z_out/Z_in). What I would like to make clear is what exactly do we mean by input/output impedance, what the above Z_out,Z_in are supposed to represent, and how can I achieve impedance matching with the source, when based on the above equation, by changing the duty cycle I can merely change the ratio of the converter's impedances.


texts:
I am designing a two stage Amplifier for class, and I had asked for help before on the forum which helped a lot.
Input is a 1v sine wave.
My design was for a 5 voltage gain however I am only seeing 2.4 volts across my load resistor.
I've ran through a number of calculations with the MOSFET common-source stage and I believe I should be getting a 5 volt gain, but I am not.
My current Design

Output across R8 in Blue
Input signal in Green

Here are the specifications I am designing to
Use one common-source stage and one common-collector (aka emitter-follower) stage
The amplifier must have an overall voltage gain magnitude of at least 5V/V during midband operation.
Generate an output signal > 3 Vpp
The input resistance must be > 100 kΩ.
Use a load resistance of 1 kΩ.
Use a single 12 V supply.
One of the amplifiers used need to be a MOSFET
At 27oC:
Low frequency cutoff between 100 Hz and 200 Hz
High frequency cutoff between 50 kHz and 150 kHz


texts: What is the name of this AC power outlet?

texts:
I have these power outlets on the ceiling in a (newly built) house in Sweden, they are meant for lamps. I could not find any information on them, what is their name?

Power outlet with plug. The hole/pole distance is around 11.5 mm center to center.

Size comparison with CEE/Schuko plug


texts:
I have this circuit and I am running code on the raspberry pi which checks the input pin continuously and converts the 10-bit digital signal to a readable voltage. So I can accurately see the voltage being generated.

I intend to stick the piezo disk onto an instrument to detect the note being played by the instrument this would require mimicking a sound wave so I can find the frequency and then the pitch of the note.

This is a graph showing the voltages when the E string of a guitar is played and the piezo is stuck to the body. To get a more accurate reading I would need the negative voltages. (x-axis is time and y-axis is volts)

The circuit only gives me values between 0-5v (0-1023), however, a sound wave would have negative voltage. Could anyone explain to me how I would alter my circuit to give readings between -5v -> +5v instead of 0-5v.

I have read this link and a few others : Read Positive and Negative Voltage in Arduino
but don't fully understand how they work.

Also, the datasheet recommends using an op-amp to buffer, filter and gain the original signal, but I am already getting 5V readings when I hit the piezo so could someone explain to me what an op-amp would do to my readings (other than amplify them)?

Also, can anyone tell me when I have a 0.02V reading all the time?

Thank you.

simulate this circuit – Schematic created using CircuitLab

Datasheet for the ADC: http://www.ee.ic.ac.uk/pcheung/teaching/ee2_digital/MCP3002.pdf

Piezo I am using: https://www.sparkfun.com/products/10293


texts: 7 segment LED display multiplexing for 9 digits

texts:
I want to build a 9-digit 7 segment LED display with basic components.
I am planning to use a 4-inch 7 segment LED display and an Arduino board for my application.

According to my understanding, I would be needing 17 I/O pins (9 pins for control lines of 9 digits and 8 pins for data lines of LED's of each segment).

I want to know about the electrical characteristics that I would need to consider before I rig up the circuit.
Would Arduino Leonardo suffice for my application?
Is there a need for an extra driver IC? If so, which one would be recommended?


texts:
I'm using the circuit to debounce a momentary push button switch (and drive a relay). Probably the switch is not that great (it is a stomp switch) so I got a lot of bouncing, and the end result is not reliable.

do you think there is a way to improve this circuit?
The PSU voltage is +9V, and the gates are CD40106 (Schmitt trigger)

Also, I'd like to try this one too. Do you think is an improved design over the previous one?


texts:
I have a book which is giving a brief solution to a theoretical question, it is skipping some steps of the solution,these missed steps seems to be important to me to understand them.I recite them below and i would like some help for a more detailed solution without skipping steps.

Question 1:
$$given\,\,x(t)= Acos(ω_0t+θ),\,\,\, T_0=\frac{2π}{ω_0}\,compute\,its\,power.$$
$$
\begin{align}
P &= \frac{1}{T_o}\int_0^{T_o} [x(t)]^2dt\\ \\
&=\,\,\frac{ω_0}{2π}\int_0^{\frac{2π}{ω_0}}A^2cos^2(ω_0t+θ)dt\\ \\
&=\,\,\frac{A^2ω_0}{2π}\int_0^{\frac{2π}{ω_0}}\frac{1}2[1+cos(2ω_0t+2θ)]dt\\
&=\,\,<missing\, steps\, start\, from\, here\, that\, i\, need\,them\, to\, be\, filled>\\
&=\frac{A^2}{2}\\
\end{align}
$$
i can proceed with the missing steps up to a certain point as follows:
$$
\begin{align}
&=\,\,\frac{A^2ω_0}{2π}\frac12\Bigl(\int_0^{\frac{2π}{ω_0}}dt+\int_0^{\frac{2π}{ω_0}}cos(2ω_0t+2θ)] \,dt\,\Bigr)\\
&=\,\,\frac{A^2}{2}\frac{ω_0}{2π}\,\Bigl(\,t\vert_0^\frac{2π}{ω_0}+\frac{1}{2ω_0}\,sin(2ω_0t+2θ)\vert_0^\frac{2π}{ω_0}\,\Bigr)\\
&=\,\,\frac{A^2}{2}\frac{ω_0}{2π}\,\Bigl(\,\frac{2π}{ω_0}+\frac{1}{2ω_0}\,sin(2ω_0\frac{2π}{ω_0}+2θ)\,\Bigr)\\
&=\,\,\frac{A^2}{2}\,\Bigl(\,\frac{ω_0}{2π}\frac{2π}{ω_0}+\frac{ω_0}{2π}\frac{1}{2ω_0}\,sin(2\cdot2π+2θ)\,\Bigr)\\
&=\,\,\frac{A^2}{2}\,\Bigl(\,1+\frac{1}{4π}\,sin(4π+2θ)\,\Bigr)\\
&=\,\,\frac{A^2}{2}\,\Bigl(\,1+\frac{1}{4π}\,????\,\Bigr)\\
&=??
\end{align}
$$
Looking at sin(4π+2θ), i know that sin(4π)=0 and that would have given the solution, but it has an additional term,which is 2θ and the book says nothing extra about θ. Maybe, i might have made a mistake or two in my incomplete solution.

Question 2:

If i integrate with respect to ωt instead of just t,how do i justify,explain this conversion? Also, what is the point of working with respect to ωt instead of just t?

(It seems that somehow t is multiplied by ω and also To is multiplied by ω. Thus, ωTo=2π. That is my best guess,although i do not fully comprehend why it would work if it is a correct guess).
$$P = \frac{1}{T_o}\int_0^{T_o} [x(t)]^2dt=\frac{1}{2π}\int_0^{2π}(x(ωt))^2\,d(ωt)$$


texts:
I always thought that capacitors (when used in phasor analysis) just had an impedance of $$1/jwc$$.

I understand that impedance $$Z=R+jX$$where R is resistance and X is reactance.
Now, in one book I found that the reactance of a capacitor is $$1/wc$$. So the impedance for the capacitor would be $$j/wc$$.

How come it's j/wc here and we always used 1/jwc before??


texts:
I seem to be having a weird and frustrating issue.

I have a Nokia 1616 LCD to which I am displaying images stored on an SD card. Everything worked fine when I was breadboarding it but when I assembled the circuit on a etched PCB, that's when the trouble started.

When I power on the circuit I see the lcd backlight with normal expected brightness. However right after that (when the avr starts initializing the LCD I presume), the brightness decreases dramatically and the image shown on the lcd is all streaked with color lines and has sort of whitewashed effect. Like the image is bleeding (don't have any pics as I removed the LCD to try n solve the issue).

However at this point if I press the reset button on my circuit (reset avr) and hold it for a brief moment I see the LCD act normal with the image shown as it should be.

Googling didn't help much. A single post on avrfreak suggested that this streaking happens due to 5v signal being applied to 3.3v terminals of the LCD. I am using a bss138 to do level conversion. So to check those I wrote a test program outputting 5v on all the output terminals and as expected I got 3.3v on the lcd inputs. So that's not the issue.

Another thing I noted is that on my breadboard the circuit pulls in about 200ma but on the PCB its constantly pulling in around 350ma.

This along with the backlight dimming is making me believe that there must be a short somewhere .

Am I along the right path. Has anyone had any experience of such kind?

This is what it looks like

This is what is should look like

Thanks!


texts: What's the role of Ground Plane in high frequency boards?

texts:
Here is an image of an LNB circuit:

As you can see there is some Vias that is pointless for me(blue circles). Why didn't the designer connect these components to the ground line around the circuit directly?

Some of these Vias are connected to the ground line around the circuit and some are not connected. Does the Ground plane have a specific role in high-frequency PCBs?


texts: How to power long (30 ft) nichrome wire from 120v AC wall socket

texts:
I am working on making a vacuum forming machine, and I need to power a significant length of nichrome wire off of a 120v AC wall socket. I have very little experience in electronics, but I have talked to a few people who are experienced in electronics, and they have suggested using mosfets or PWM for powering long nichrome wire coils. I have done some calculations on what I need to power the wire, and it has very specific voltage and amperage readings (304V at 2.4A to reach 1000deg F). Are those hard numbers? I have talked to my instructor, and they have said that for that length, I should literally just plug a wall outlet into a dimmer switch, and route the dimmer directly to the coiled nichrome. From there I could control the temperature with relative ease. I feel like that is a really bad idea, and that there should be some extra safeguards. I have done a ton of research online but either I am too inexperienced in electronics, or there isn't that much documentation on this specific problem.

The wire is 28g Nichrome 80 4.09ohms resistance/ft

https://www.amazon.com/gp/product/B07CHTT73J/ref=oh_aui_detailpage_o01_s00?ie=UTF8&psc=1

I realize it would be easiest to just buy a space heater from amazon, but it seems like building out a circuit and figuring out all the stuff I need is a valuable experience.


texts:
Does anyone know what's entailed in connecting a computer that has only an 'AUI' network interface into a modern LAN? By AUI port, I'm referring to one of those 15-pin D connector arrangements that used to be popular in the early 1990's. I know that establishing a network protocol will undoubtedly be a challenge in its own right, but that's beyond the scope of this question. At the moment, I just want to "get a link light" from it on one of my ethernet switches.

I would almost swear I once saw a jury-rigged connector that had just four wires with pins crimped on them jammed into selected points on the 15-pin D, though I don't recall what these wires ran to, but I thought it was an RJ-45. Could easily be mistaken on that. Just b/c someone had something wired with an RJ-45 doesn't necessarily mean it was 10BaseT.

Anyway, there are references to the AUI signal set being part of the IEEE 802.11 standard. Could it really be as simple as mapping a certain 4 of the 15 to the 1,2,3, and 6 of 10BaseT? Or could it be done with just a couple of line driver/receiver IC's?

I know there are $30 commercial solutions to the problem, but I am loathe to invest even that much on the system in question, as it would already be on its way into the electronics recycling bin but for academic curiosity about the old interface.


texts: Time domain reflectometry (TDR), initial pulse slope

texts:
A ~100kHz square wave through a 100m open end coax (RG-58) produces a slightly sloped shoulder during the time from initial pulse until reflected pulse (A-B), and from initial pulse drops until reflected pulse ends (C-D).

What are the correct explanations for these slopes [not being flat]?

(Scaling: 2.0V/ 2us/)

EDIT:


texts:
I need to calculate the total conversion time, i have been looking through the reference manual but without any luck.

This is my set up:

RCC_APB2PeriphClockCmd(RCC_APB2Periph_ADC1, ENABLE);
ADC_CommonInitTypeDef ADC_CommonInitStructure;
ADC_InitTypeDef ADC_InitStructure;

ADC_CommonInitStructure.ADC_Mode = ADC_Mode_Independent
ADC_CommonInitStructure.ADC_Prescaler = ADC_Prescaler_Div2;
ADC_CommonInitStructure.ADC_DMAAccessMode = ADC_DMAAccessMode_1;
ADC_CommonInitStructure.ADC_TwoSamplingDelay = ADC_TwoSamplingDelay_5Cycles;
ADC_CommonInit(&ADC_CommonInitStructure);

ADC_InitStructure.ADC_Resolution = ADC_Resolution_12b;
ADC_InitStructure.ADC_ScanConvMode = DISABLE;
ADC_InitStructure.ADC_ContinuousConvMode = ENABLE;
ADC_InitStructure.ADC_ExternalTrigConvEdge = ADC_ExternalTrigConvEdge_None;
ADC_InitStructure.ADC_DataAlign = ADC_DataAlign_Right;
ADC_InitStructure.ADC_NbrOfConversion = 1;
ADC_Init(ADC1, &ADC_InitStructure);
ADC_RegularChannelConfig(ADC1, ADC_Channel_0, 1, ADC_SampleTime_28Cycles);

And i know that the current samplingrate is 240kSPS but i can't remember how i got that number?
And can someone help me understand the effect of this:

ADC_CommonInitStructure.ADC_TwoSamplingDelay = ADC_TwoSamplingDelay_5Cycles;

on the total conversion time / samplerate ?


texts:
I have a motor, like to use it for a project.  I don't have the specification details of it(volt, Amps, RPM). Can someone help me in this regard?

Image source/Item description


texts:
The finished apparatus is supplied with 48V nominal ac (37V to 57V), and now I'm looking to design it so that it isn't destroyed if a technician accidentally connects the supply 48V +/- to the RS485 inputs.
I can't use reverse biased diodes to ground, since -5V is perfectly acceptable RS485 signal level.


texts:
How to measure creepage distance over pcb ?
Is creepage and clearance distance measure by pbc layout or soldering?


texts: Need help finding a high voltage, high slew rate Op-Amp

texts:
I am designing a single stage driver circuit that needs to be capable of driving a rectangular pulse wave up to voltages of +50V. The slew rate has to be at least 500 V/μs. So far, I have found 2 op amps that meet these criteria: the MSK613 and MSK600. Here is the datasheet for the MSK613:
https://cdn.anaren.com/product-documents/MSK/Amplifiers/MSK613/MSK613_DataSheet(Rev_B).pdf

However, the manufacturer does not want to sell these to my research group, so I am looking for alternatives that are as powerful. Any advice on how to design an alternative driver circuit would also help.

Thanks


texts: Appox. the Impedance of Single Phase Pole Transformers using only Nameplate Ratings?

texts:
I know the following of one pole transformer (don't have access to the nameplate):

  333KVA, Z = 5.75 % 25kV/12kV

Given another transformer, I don't know Z, but know it's rating and voltage

  250KVA, Z = ?, 25kV/12kV

How can I find Z roughly? Construction of transformer is roughly the same except for the higher rating. Higher rating would require thicker conductor for the coil and/or a bigger area for the coil on the high and low side? Are these good assumptions? Could I use these assumptions to make these very very rough conclusions:

Resistance would decrease but lets neglect R for now.

Since

  Z ~ L ~ A/l

Self-inductance and mutual inductance of two coils would increase because we are increasing the area of the coil that the magnetic field can pentrate.

I don't know that much about construction of transformers to make the correct assumptions about what would change by increasing the ratings. I would like to be able to make some linear assumptions and use the ratio of 333/250 to scale the impedance.


texts:
A couple of weeks ago I was visiting an eletronic exhibition, and I came home with five NEC LD-8035E VFD Tubes.

They look like this:

Being my first "date" with a VFD tube (and with a tube at all) I googled to find the datasheets, but unfortunately this device is not very well documented. I was able to find the following facts:

The filament has a current of circa 26mA @ 0,8V
A current of 0,85mA goes through the segments when they are switched "on" with 12V.
I couldn't find any information about the grid, so I assume I can drive it similar to the segments, maybe a half volt below the 12V to ease the passage of electrons from the filament to the segments.

I am now working on a project that uses two of these tubes, but I don't want to drive them using an integrated circuit. Instead, I want to use transistors.
The microprocessor that will steer them works with 3.3V logic.

I came up with this design (only one segment driver is shown, the other 8 are the same):

The basic idea is to use a high side switch for every segment and for the grid. The value of R5 and R6 are calculated to have circa 12V on the segment and 11.5V on the grid using the current values I previously described.

To get the 0,8V for the filament I used a diode, and a bigger resistor (R32, able to dissipate the circa 0.6Watt generated by the current @ 15V)

Now my question: what do you think of this design? Any correction, suggestion?

** UPDATE 04.07.2016**
I was able to found some useful informations on a Japanese online shop.
Here the full specifications of the NEC LD-8035e:

Filament: 26ma   @ 0.8V
Grid:     0.85mA @ 12V
Segments: 70uA   @ 12V

I re-calculated the values of R5 and R6 to better match grid and segments current consumptions, and updated the schema


texts: 3-phase Motor RPM depends on power line frequency?

texts:
I have a 3-phase motor but my knowledge on the topic is almost null.
But, you know, I have also curiosity to satisfy.

The motor's nameplate reads:

50 Hz, 7.5kW,
400V, 13.8A / 690V, 8.0A
cos phi 0.89
2910/min

60 Hz, 8.6kW,
460V, 13.5A
cos phi 0.89
3492/min

It looks like the RPM is proportional to power line frequency. Is this true? Applying i.e. 340V 50Hz, may I assume that the RPM remains 2910/min?


texts:
Have few of these components (TLP582) and I need to design a test circuit to test its functionality.
Datasheet of TLP582
I have no idea how to make a circuit for this.
What should I be testing in an optocoupler?


texts:
I'm currently in a first year circuit analysis course. While the concepts are relatively simple they don't seem like something you could use to design circuits.

I mean it's hard enough to analyze circuits that you already have. But I feel like it would be impossible to work backwards to figure out the circuit you need given the values you want.

So, as an electrical engineer working on designing circuits, how much of the circuit analysis techniques taught in a first year course (Nodal/Loop Analysis, Thevenin/Norton Theorems, Steady State Analyis of RC and RL circuits, AC analysis etc.) are actually used in the design of circuits?


texts: How to legally sell custom PCB, certifications etc?

texts:
I design a custom PCB, I use only RoHS components and RoHS PCB manufacturing.
Is that enough or not to sell my electronics in Europe legally?
I have read somewhere about certifications for any device that transmits signals(rf..wifi,433MHz etc). Is that only in the USA or also in Europe?
Can I still sell them legally without those certifications? My PCBs are being manufactured in china and soldered there as well, does that mean I do not need any certifications for Europe/USA and I can just import them and sell them here since they are not being manufactured here?


texts: What is the output voltage of this OP amp circuit?

texts:
I'm trying to solve (b):

This is what the solution manual gives as an answer:

However, this seems a little off to me. I tried using nodal analysis to solve this problem and I get the following result.

Where is the mistake?


texts:
ATTiny is generating PWM based tones with 32kHz sampling rate. Then I've created R-2R DAC and then trying to amplify it for speaker. However, LM386 is sinking signal from R-2R. If I don't connect LM386 then there is signal on DAC output. How to correct this circuit?

Also I'm planing to make low pass filter, to filter out PWM hiss during playback and some white noise during silence. But I will open separate question for that.


texts: I want to make the LED turn on only when it receives 0V after a timed 5V input

texts:
I am still a student and so this question might sound too easy to be asked here, for which I apologize.

I want a circuit that consists of a single LED. When this LED recieves a 0V potential difference, it should turn off and when it recieves a 5V input, it should turn off. Although this sounds like a NOT gate, but there is a complication. I want the circuit to work like this. At the beginning, when no input (0V) is provided, the LED should remain OFF. Then a timed 5V input is provided for some time, for which the LED should remain OFF. After that when the input is 0V, the LED should turn ON.

I have searched the Internet for any solution but in vain. Please help me with this problem if you know any possible way to achieve the above mentioned work. Thanks for the attention.

Figure 1. Timing diagram added by @Transistor for the OP to edit. 'T' is the minimum required on-time.

               _________               ___               ________
Input:  ______|       >T|_____________| <T|_____________|      >T|_______
                         _____________                            _______
Output: ________________|             |__________________________|

Output turns on if input pulse has been longer than T.
Output turns off on rising edge of input.


texts: What is the IL(t) of the RL Circuit of the IL(t=0) = I ini

texts:
I have a RL circuit

I have to find the current in the mash I L(t) so the mesh current but the initial I L(0) = I initial = 3 mAH, now I have the the I(t) when I assumed that t=0 which is:

I(t) = Vs/R (1 - e^((-R/L)*t)))

Then I have done everything again with the assumption that I L(0) = I ini
and then I have got this equation:

I L(t) = Vs/R + (I ini - Vs/R) * e ^ ((-R/L) * T)

And then I have the given values: Vs=10V, R=1kOHM, L=1mH and I ini = 3mA

Then I substitute everything but the function is so weird (I also should get the I L(0) = 3mAH, but I dont) and I cannot even procede to do the Euler's explicit interation to plot the results, can anyone tell me if my equation is wrong, if it is can someone explain why and how can I fix it in order to work?


texts: Optocoupler - input resistance in parallel with the LED

texts:
I would like to know what is the purpose of the resistor "Rin". I though it was for having better immunity against differential mode noise. Nevertheless, I saw circuit with a very high resitor, ie 10KOhm, so by applying a voltage source noise at the input, almost all the curent goes through the LED and so there is no immunity, as the output photo transitor will conduct, which we don't want to happen in case of noise. How to select Rin ?

Here is an example :

Thank you :)


texts: Consequences of mixing lead and lead-free alloys when soldering

texts: Would it be a problem to use a lead solder paste to solder lead-free BGA package parts? Are there contamination/compatibility issues? Does it affect the physical connection integrity between the board-component? How about using a lead-free solder paste for soldering components that contain lead? Which of the two is more reliable?


texts:
I am building the below web application to publish for free in order to help people individuals calculate what size generator they might need in order for their specific needs.

My question is whether the results shown in the app are correct from and electrical engineering point of view?

http://generator-calculator.com/

My basic calculation is based on:
(Appliance with the highest starting wattage
+ Total running wattage for all other appliances) =
Total wattage needed


texts: What is this functions Phase crossover frequency?

texts:
OLTF loop gain

My approach

What I have done wrong?


texts: Electronically adjustable PWM with 555 timer

texts:
I would like to create a PWM generator with a 555 timer (like suggested here), but I would like to be able to adjust the duty cycle with a microcontroller. I would simply use PWM from the microcontroller, but I need a high frequency as I am driving motors and they produce a tone with the frequency of the PWM. This happens to be audible when using PWM from the microcontroller. (The frequency is only 490Hz)

Please note that this signal will not directly drive the motor, as it will be fed into a controller which drives the motor.

What would be the best way to accomplish this?


texts:
I have a led in series with my toggle switch to be an indicator to power a 30/40amp relay. The power source is a 12v battery. When I close the switch the led comes on, but the relay stays open?

simulate this circuit – Schematic created using CircuitLab


texts:
I would like to compile a list of all the best electronics Kits you have come across.

"Best"  can be because you

learnt something from them
found them very satisfying
had something very cool at the end

Personally I loved the Lilypad Kit - cause it gets you started without actually having to make something specific and the Herbie Kit cause its fun to play with when its done.


texts: How does this specific boost converter work?

texts:
So I found this Geiger counter at https://mightyohm.com/blog/products/geiger-counter/. You can also find the detailed electronic schematics there. I tried to figure out how this apparatus works, but I'm stuck with the boost converter and the timer to create the PWM signal. Can someone explain?

Because it's not the typical 555 timer setup for an astable multivibrator. I don't get how the frequency and duty cycle of the PWM signal is setup. It boost up 3 V input to 400 V output.
Thank you!


texts: Overvoltage protection develops heat, is ok?

texts:
considering my old question: Here, i've made the following circuit using equivalent components on SMD, here is the schematic:

And these are the parts that i've picked from LCSC:

Fuse: Link here
Zener diode: Link here
Resistor: Link here
Transistor: Link here

The circuit is receiving 5.1V from the +5V netflag (using a regulated DC power supply) and giving out 4.93V from the netflag +5V-OUT (the circuit on the +5V-OUT draw a really low current: 250mA), everything works good, but the transistor itself (on the backside) develops a lot of heat (65/68°C at 21°C room temperature).
Is that normal?
I need to be worried?


texts: How to connect two (or more) BJTs (collector of Q1 to base of Q2 for instance) and still make their bias voltages independent?

texts:
The question is in the title. I'm learning about how to use BJTs and was wondering how I could connect them in blocks the way bias voltages (thus operation modes) are not being dependant.

Thank you!


texts: What are the holes on an optical flow sensor IC?

texts:
The right hand image is a flow sensor IC for an optical mouse available from Sparkfun. On the left is another optical flow IC with a camera attached from a Chinese distributor.  It seems that the holes in the IC are a common property for optical flow sensor ICs.

What purpose do they serve? Why are they there?


texts: Drive LED with open-drain active-low signal

texts:
I am planning on using an IC (https://datasheets.maximintegrated.com/en/ds/MAX38888.pdf) which has the following output pin:

It is an open-drain active-low backup indicator. The BKUPB is held low when the part is in backup mode. I would like an LED to light up when the IC is in backup mode.
I was wondering, is the following solution okay:

Do I need an additional resistor in series with the PMOS gate to limit current to the gate?


texts: How to disable the remainder of a circuit when a charger is plugged in, using minimal components?

texts:
Is it possible to detect if a charger in plugged in, and disable (or completely disconnect) any of the remaining circuit?

This image from Detecting When a USB Device Is Plugged In For Status LED provides an interesting idea to light up an LED when it is charging, but it uses way too many components for my use case.

I'm using a LiPo battery attached to a microUSB charging circuit. Assume that the non-battery circuit consist of a single op-amp. How would I disconnect or lower the power voltage beneath usability for the op-amp when the circuit is plugged in, without draining the actual battery charging part of the circuit?

Is the only option to use a mechanical switch?


texts: How to generate high frequency clock with high stability from a microcontroller?

texts:
I am using TivaC launchpad TM4C123G microcontroller, to generate a clock of 40 MHZ but I tested it on the oscilloscope and it doesn't look like a square wave it's more like a sinusoidal here is a screenshot:

and here is my code:

#include <lm4f120h5qr.h>
#include <stdbool.h>
#include <stdint.h>
#include "driverlib/sysctl.c"
#include "driverlib/pin_map.h"

void SYS_CLOCK(){  SysCtlClockSet(SYSCTL_SYSDIV_2_5|SYSCTL_USE_PLL|SYSCTL_OSC_MAIN|SYSCTL_XTAL_16MHZ); }
// Microcontroller Frequency 80MHZ

 void CLK1_SETUP(unsigned long Period){
 SYSCTL->RCGCWTIMER |= (0x1<<0);
 WTIMER0->CTL &= ~(1<<8);
 WTIMER0->CFG = 0x00000004;
 WTIMER0->TBMR |= (0xA<<0);
 WTIMER0->TBILR = Period;
 WTIMER0->TBMATCHR =Period/2;
 WTIMER0->CTL |= (1<<8);

 SYSCTL->RCGCGPIO |= (1<<2);
 GPIOC->DIR |= (0x1<<5);
 GPIOC->DEN |= (0x1<<5);
 GPIOC->PUR |= (0x1<<5);
 GPIOC->AFSEL |= (0x1<<5);
 GPIOC->AMSEL &= ~(0x1<<5);
 GPIOC->PCTL |= 0X00700000;
 }

 void CLK2_SETUP(unsigned long Period){
 SYSCTL->RCGCWTIMER |= (0x1<<1);
 WTIMER1->CTL &= ~(1<<8);
 WTIMER1->CFG = 0x00000004;
 WTIMER1->TBMR |= (0xA<<0);
 WTIMER1->TBILR = Period;
 WTIMER1->TBMATCHR =Period/2;
 WTIMER1->CTL |= (1<<8);

 GPIOC->DIR |= (0x1<<7);
 GPIOC->DEN |= (0x1<<7);
 GPIOC->PUR |= (0x1<<7);
 GPIOC->AFSEL |= (0x1<<7);
 GPIOC->AMSEL &= ~(0x1<<7);
 GPIOC->PCTL |= 0X70000000;
 }

 void main()
 {
 SYS_CLOCK();
 CLK1_SETUP(2); //40MHZ~25nsec~2
 CLK2_SETUP(190);//421KHZ~2.375usec~190
 ADC_SETUP();
 }

on the other side I generated another clock with the same code but with a frequency of 421 KHZ and it looks correct:

any suggestions on how to make the 40 MHZ more stable and accurate ?


texts: Do electronics distributers test each component before sending them out?

texts:
I'm trying to decide whether to order components direct from manufacturers in China or from distributors in the US. If I have to test each component either way, I'm not sure it matters to me if it's a knock-off or the "certified" one, especially when prices are 100x more expensive from distributors.

It's very important to me that my customer receives something that works and isn't let down either by a high price or a failure that could've been avoided.


texts:
I have a simple circuit which causes problems. This circuit should act as a switch but it is on when it should not be.
I have a VCC that can go up to 50/60 V. Q2 is a high voltage BJT so therefore I selected it. However, the circuit does not function very well. Without powering the opto-LED, when I put for example 9.5 V DC on the collector of Q2, the output at the emitter is also at 9.5 V, which tells me the BJT is on. This should not be happening.
The base is at 9.2 V and the collector of the opto coupler is also at 9.2 V which indicates the opto coupler is not on. The 9.2 V is a strange number because I suspected it to be somewhere around 8.7 V due to the diode drop.
I believe there is a small leakage current turning Q2 on.
Any idea what is wrong and how to improve this circuit?


texts: Determining Suitable Replacement Transistor?

texts:
I have a toy which developed a short, and one of the transistors on the board is now fried.

I've removed the shot transistor, along with the part of the toy which was shorting out, and everything else works fine.

There are no distinguishing markings on the transistor - all I know is it comes in a SOT-23 package - and, I believe, there is a duplicate identical transistor in the toy (for a similar but separate function).

I have a digital multimeter, and a digital oscilloscope at my disposal.

I'm also aware of the type of DC motor this transistor was being used to control (so I should have some idea of the voltage it's required to handle).

Based on this information, and with the tools I have available, how can I determine what a suitable replacement transistor would be?


texts:
I want to test a video IP core that reads a block of memory and writes to it again. The IP core is using the VFBC. My idea for testing was to write a core that looks like the VFBC, but just uses a simple 32Meg RAM as back-end.

It is allocated like this:

memory_size : NATURAL := ((2 * 2048) * 2048)
type memory_array is array (0 to (memory_size - 1)) of std_logic_vector(31 downto 0);
signal memory : memory_array;

ISim is crashing claiming that it needs more than 2 gig of ram, and questasim is allocating 12gig in the process of compilation for simulation.

Note: I don't want to synthesize this. It is for simulation only!

So the question is: how can I simulate such an RAM efficiently in VHDL?


texts: How to switch PIR sensor on/off based on photocell result

texts:
I've built the following circuit based on an ATtiny85 for a night lamp. The circuit is powered by a 3.7v LiPo battery. I'd like to turn off the PIR sensors when the photocell detects light in order to save battery.

I tried putting a 2N2222 transistor between the power and the PIRs VCC pins but that makes the sensors unstable as not enough current was going through. I suspect some resistance by the 2N2222 but I might be wrong. I'm successfully using a 2N2222 to switch the photocell off when I don't need it. The sensors draw 100 uAh when standing by.

Can someone tell me what would be the best and most efficient way to switch (on/off) the current of the PIR sensors?

Thanks.


texts: What process do you use to ensure your PCB works on the first try?

texts:
What are the best practices for catching stupid mistakes vs more subtle ones? Do you run over a checklist of things for each design? If so, what kinds of things are on it?

I'm interested in manufactured PCBs, as if a co-worker gave you a schematic and layout to review before sending the board out for manufacturing.


texts: How to run LED lights off wild DC from bike powered generator

texts:
I teach 6th grade physical science.  My electronics knowledge is limited.  I have a bike powered generator from windstream power, and I have it hooked up to a board with light sockets so students can feel the difference between different kinds of bulbs.  The students easily generate 120 volts, and can sustain .5 amps to power 60 watts of bulbs.

Problem one: I'd like to be able to have LED bulbs in the mix (Philips 12.5 watt, 110 volt edison base), but the voltage is too unpredictable.  My understanding is that fluctuating voltage will damage them.  The generator is capable of producing 150+ volts.  Am I looking for a voltage regulator?  Does it need to regulate minimum and maximum?

I also have a battery pack with an inverter from the same company, but it's giving me problems and I'd rather dispense with the battery altogether.  I don't want to deal with the maintenance issues, and the battery seems to make it harder for the students to understand the whole system.

Problem two:  What's the best way to build an array of LED lights that could be run continuously off of the generator. I'd like to have enough storage (in a capacitor maybe?) that the lights would stay on for a few seconds while one student gets off the bike and another gets on.  I'd rather not have a battery.  The purpose of this is to "light" the room for a day while teaching about other subjects.  I put that in quotes because 60 watts of even the most efficient LED's is a little dim for my classroom.  The lesson for the kids is to gain an awareness of how much power we're consuming regularly.  I can't use incandescents for this purpose because my room has no windows and it would be too dark.  I'm looking for bright white LED's as the most efficient lighting source.  The reason I'd like to have the lights stay on while the students switch on and off the bike is because otherwise it will be too dark in the room.


texts: Computing Current from known Capacitance and Time to Charge to Known Voltage

texts:
If I know how long it takes to charge a capacitor of known size to a known voltage (within 10%), how do I find out the average current for that period of time?  This only needs to be approximate.

Maybe I  should ask this from another angle.

Assume a capacitor of capacity C is charging to voltage V and discharging to 0v at a rate of 5 times per second.  How do I figure out the average current or what you might call RMS current?  I don't need this to be exact -- very rough approximation.


texts: Strange SPI behavior with a Microchip 25LC01

texts:
I have one of those situations where I believe that I have crossed my t's and i's, but things still are not working out; however, I'm new to SPI.  I have a Microchip 25LC01, in 6-pin package, that seems to need extra clocks to send out commands, which is contrary to the datasheet.   The best example of this behavior that can be illustrated in the command where I read the status register, and the Figure from the data sheet shows the following waveform:

So, you clock in an eight bit instruction and then 8 clocks after that you should have received your response.  What I see is what follows:

A note, the signals are indeed 3.3V, but my scope is set to 5V resolution, which is what the 5V note is under each channel label.  So, I send the command to read the status register, which is 0000 x101 and I get nothing back.  The rising edge of the clock sits nicely in the middle of the command.  However, this is where it gets stranger from here.  If I read the status register again, I get a response.

What is likely the proper response is occurring 8 cycles AFTER I would expect it.

With microsecond timings, I am well in the within the specification for the timing on the IC, so my question is:  Does Microchip have some special state machine behavior that is known well enough that they do not document it?

Solution
Apparently, the problem was from /CS being deasserted too quickly after the last clock edge fell.  Adding just a bit more time to /CS after the last clock seems to solve the problem.


texts: Debug Bricked Standing Desk IC Board Issue

texts:
I have an Apex electric adjustable desk Flex I bought in 2017 that got bricked out of the blue while I was raising it up this morning.
I tried performing a reset by holding the down button for 10 seconds but it just makes a repeated clicking sound from the IC board that the attached video shows. Click is emitted about twice per second in my estimation.
How can I figure out what's wrong with it? It may not be easily fixable, but at least I want to understand what's the issue. I assume that it must be something electrical and not mechanical because the desk has been completely stripped down to just the leg and it still won't move.
What I tried so far:

Completely strip down the desk to avoid weight related issues
Even remove the tabletop to ensure it's nothing to do with the tabletop forcing legs in a bad angle or similar mechanical issue.
Tried 'hard reset' as per the user manual several times (unplug one motor cable, press up, then attempt 'normal reset')

Clicking sound on video (50 seconds long): https://youtu.be/DT80XmWoDoA
Images of the IC board/desk components


texts: How much is the propagation velocity affected by the characteristic impedance?

texts:
Someone posted the (very educational!) video Similiarities of Wave Behavior from 1959 in another answer, and after watching the part about impedance mismatches, it strikes me that the propagation velocity in the two sections with a different impedance is remarkably different. It's hard to estimate from the video, but it looks like the wave moves at least twice as fast through the narrow section.

This made me wonder if the difference is really that big even in electrical circuits, and particularly on a circuit board.

I've mostly used the rule-of-thumb half the speed of light when estimating the signal delay on circuit boards using plain old FR4, but I have never designed anything that required me to know or care about the characteristic impedances of the trace. I do know that sometimes it matters, and that you may have to make sure that the board house can manufacture controlled impedance boards.

I have seen characteristic impedances of cables from 50Ω to 300Ω, but I'm sure there are ranges outside of this. Presumably, you can match these on a PCB, and that should make the propagation velocity different as well. I have also played with trace impedance calculators and they often give impossibly large trace widths for the common impedances when you use the standard 1.6 mm, two layer board. This makes me think that the impedance of a trace will vary by a lot even on the same PCB unless you actively manage it.

There are numerous questions and answers that explains how to match the characteristic impedance of a PCB trace to a given requirement, but is there an equation that relates this to the propagation velocity? If so, what is it? Can it be calculated just using the impedance?


texts: SMPS output regulation - should I use capacitance multiplier?

texts:
I'm trying to design a flyback converter to power my stuffs, I need about 3 A of current at 24 V.

At first I though this was straightforward. However, after reading "Design Guidelines for Off-line Flyback Converters"(AN4137) of Onsemi, I have found that it isn't that easy. Capacitors have max ripple current specification which mean I could risk blowing them if I just use a single of them. Therefore I think I should use some of them in parallel to distribute the ripple current (I think so). According to the appnote,

I calculated the output peak voltage ( about 88 V in my design) so using 100 V rated caps should be fine. Another problem arises : I don't have much 100V-or-larger electrolytic capacitors.

After thinking awhile, I remembered that there is someone who uses "capacitance multiplier" in there power supply design.

Will it do the trick ? Instead of going to the store and buying some caps, should I use it ?

By the way, please help me correct grammar error, I am aan English learner, not a native.

Thanks !


texts:
I require some help with selecting the right components for SPI isolation.
The attached schematic is how I intended to isolate the SPI signal between my Arduino and the digital pot MCP41010, I have measured the clock frequency at around 2MHz, and have realized that the MCT6 isolator is far too slow for this function.
I require part from JLBCP basic parts range and have come across ADUM1201ARZ-RL7 a magnetic coupler, I believe this can handle the 2 MHz?
Q1) Is this a suitable isolator for spi?
Q2) Can you suggest how to integrate this into my schematic.

I have updated the schematic following answers in the thread, to use a Texas Instruments/TI ISO7240MDWR


texts: Is it possible to drive a 12V DC motor with XL6009?

texts:
I am a beginner in robotics. I am planning to drive a 12V DC motor from Raspberry Pi 2 B. I know Pi does not have that capacity to drive such a device, so I am using L293D motor driver to control the DC motor. However, the problem is the 12 V supply requirement of the DC motor.

I know I can invest and buy these high power Duracell (any other) batteries and plug them to the DC motor supply. But the drawback is, that these batteries are non-rechargeable and as a result I'll be in constant need of purchasing new ones. The rechargeable batteries are very expensive for me.

So, I found about about these Boost converters, that can convert 5V to any other higher voltage say, 12 V. XL6009 is the module I'm interested in buying. However, I wanted to know that is it recommended to use XL6009 regulators to drive 12 V DC motors?

The XL6009 module will be powered with 5V DC supply from a separate source.

Please suggest any other alternatives, if XL6009/boost regulators are not an ideal source of supply for DC motors.

XL6009 details can be found here - https://www.sunrom.com/p/step-up-dc-dc-based-on-xl6009

L293D details can be found here -http://www.ti.com/product/L293D

Motor details can be found here - https://www.amazon.in/NTL-National-Multipurpose-Brushed-Applications/dp/B01FW9IHN0/ref=sr_1_1?s=industrial&ie=UTF8&qid=1517932524&sr=1-1&keywords=12v+dc+motor&dpID=41YN%252B0n3FYL&preST=_SX342_QL70_&dpSrc=srch


texts:
I'm using an ATTINY816 (the new series AVRs) to manage a system that includes the following tasks:

Simple audio "effect processing" (delay, pitch up, pitch down...) using internal ADC + DAC
Storage and retrieval of audio data from external serial (SPI) RAM
Display relevant data on LCD (SPI interface)
Wait for commands from a WIFI modem (ESP8266) connected with UART

The top priority is to handle the audio processing glitch free as much as possible (ADC / DAC / external RAM). The next priority is to respond to commands from the ESP8266 and lastly to update the LCD.

I'm trying to figure out a strategy to tackle these tasks. I've managed to write a driver for the LCD + using a buffer management library for the LCD output. However I'm not sure how to manage everything on the existing hardware (which can't be upgraded).

Advice will be appreciated. If you are familiar with the new AVRs please try to comment on taking advantage of some peripherals like the event system or DMA which I did not to this point as I am not sure what would be the correct way to use them really.


texts:
I have started trying to replace relays in my (12V) electrical circuits with MOSFETs. I have somewhat limited experience with MOSFETs, but I think I'm starting to understand it more.
I've drawn a circuit that I believe would work as a replacement for a DPST relay. However, of the 2 poles that are switching at the output, one is power and one is ground. If these were ideal switches, I would have no reservations about this, but these being actual devices I know the response is not immediate.

Is my circuit design correct? I'm just getting used to using MOSFETs and could've made a mistake. The intended functionality is for the output to be +12V normally, and GND when the 12V switch is closed.

Do I need to worry about the potential momentary short created when the 12V switch is closed? If so, what can be done to avoid the short?

This is the relay it is meant to replace:

[update] The circuit initially included a P-ch depletion FET, which (pretty much) doesn't exist. This has been replaced with an N-ch depletion FET and an inverter (P-ch enhancement) in the following updated schematic.

The same questions still apply.

Is my circuit design correct? I'm just getting used to using MOSFETs and could've made a mistake. The intended functionality is for the output to be +12V normally, and GND when the 12V switch is closed.

Do I need to worry about the potential momentary short created when the 12V switch is closed? If so, what can be done to avoid the short?


texts: signal/sense connectors rated for 400-600V, a few milliamps

texts:
Anyone familiar with connectors that have large enough spacing to support the creepage/clearance requirements for 400-600V, but that don't need to carry much current (only a few milliamps at most)?

We're presently using Molex Sabre connectors which are rated at 600V 18A but it's silly to need such a large contact. The spacing is what I need, not the contact size.

edit: I am looking for multipin systems with between 4 and 8 contacts.

Any suggestions? (besides buying smaller connectors and leaving out every other pin -- that's not very manufacturable unless the manufacturer offers this as a standard option)

I am offering an "honor system bounty" of 100 points: if I get an answer that is an improvement over the Sabre connector, I'll accept the best one and add an after-the-fact 100 point bounty.


texts: Minimizing(optimizing) digital logic circuit with multiplexer(s)

texts:
(this by the way was an exam question)

For \$F = \sum m(2, 3, 5, 7, 11, 13)\$, I am trying to implement a digital logic circuit using only the following:

2:1 MUX (cost: 12, and must use at least one 2:1 MUX)
2-input AND gate (cost: 6)
2-input OR gate (cost: 6)
Inverter (cost: 2)

It obviously is pretty easy to implement it without any restrictions -- that is, if I don't care about the cost at all. But if I were to minimize the cost, how should I go about it?

I first simplified \$F\$ using the K-map of it, and I got two representations of \$F\$, \$A\$ being the MSB:

\$F = BC'D + A'B'C + B'CD + A'CD\$
\$F = BC'D + A'B'C + B'CD + A'BD\$.

The second representation just looked nice to me because I can group all the product terms by \$B\$ like this:
\$F = BD(A'+C') + B'C(A'+D)\$. And apparently my design is indeed the implementation with the least cost -- I got:

But the way I solved it cannot be used for other expressions in general, and I honestly think I just got lucky. Is there a better way to solve this problem, that is, a general way that guarantees (or at least checks) that the implementation is that of minimal cost?


texts: Noise in an unconnected biopotential electrode lead wire

texts:
My question stems from a particular statement on page 256 of the textbook Medical Instrumentation - Application and Design, Fourth Edition (by J. Webster):

Relatively high potentials can often be induced in then open wire as a result of electric fields emanating from the power lines or other sources in the vicinity of the machine

Such a situation also arises when an electrode is not making good contact with the patient

The "open wire" above refers to an ECG or EEG electrode lead wire that has become disconnected from the electrode element for some reason.
Why is it the case that "relatively high potentials" are induced on an open lead wire or one without a good connection, as opposed to a wire with a good connection to the electrode?
I've heard plenty of times that "wires act like antennas", but why is an open/crappy connection lead more of an antenna? It seems intuitive, but I'd like a first principles explanation here.
thanks!


texts: Reasons for a voltage follower introducing voltage gain?

texts:
I'm using a 3130 op-amp as a voltage follower (unity gain buffer amplifier).  However it is introducing voltage gain.

It is wired the following way:

This is then just fed into a simple low pass RC circuit (R= 2k-10kΩ, C=0.5 μF).

With +Vcc @ +12V and -Vcc @ -12V, I get the following:

Vin ~ -0.4 VDC, Vout ~ 8 VDC

With +Vcc @ +5V and -Vcc @ -5V, I get the following:

Vin ~ -0.4 VDC, Vout ~ 3 VDC

What can cause voltage gain when using an op-amp as a voltage follower?

------------Edit 17-7-15---------------------

I tried a 741 op amp wired the same as above which is unity gain stable and I am still noticing a small voltage gain when supply voltage is +/-5V.  input is -0.41V and output is +1.04V.  However when supply voltage is +/- 12V there is no voltage gain.  I dont see how this can occur, as the 741 op amp is supposed to be unity gain stable.


texts: Issues with resistor heating, for an LED?

texts:
I am direly confused on this. I've used 220 Ohm resistors in the past for all of my LEDs (at least that I can remember), however nothing on my arduino+breadboard with a few leds on the 5V breadboard rail had worked.

I finally looked at the data sheet for the LEDs from the overseas place I ordered them from, and they seemed to require 35mA or so rather than 25.

I calculated that to be ~80 Ohms (5V-2V(drop) = 3V / 0.035A) = ~85 Ohm.

This explained perfectly why they had not started working, so I pulled out a 100 Ohm (which read out to about 95 with a multimetre) and set it up.

Now the LED did not light, to my surprise, feeling the resistor which was just out of curiosity felt sharply cold - of course realizing that it is so hot it overloaded the nerve endings on my fingers being too hot to touch.

My rough calculations were:

3V / 95 = ~35mA, and 3V? * 0.035A = .105W, seemingly not enough to cause much heat at all, especially over 3-5 seconds and being rated for ~.25W

Can you understand what I am doing wrong, or what could be going wrong?

My circuit is just 5V pin -> breadboard -> 100Ohm resistor -> LED -> Ground pin.

I just cannot make sense of it.

edit: I very recently shorted an LED without a resistor from 5v->gnd, possibly damaged something..


texts: Why is there a resistor between the primary and the secondary winding?

texts:
I recently opened up a linear power supply and found out it has a resistor of 8.2M ohm between the primary winding (specifically in the neutral) and the secondary winding of the step-down transformer.

What is that resistor doing there?

I couldn't fine anything related on the internet.


texts: Role of Resistor at the output of a comparator

texts:
What is the role of R1 at the output of this comparator?

simulate this circuit – Schematic created using CircuitLab


texts:
I’m trying to use this circuit:

falstad simulator

To drive a relay with the following specs:

Nominal voltage: 12V DV
Coil resistance: 960ohm
Must Operate Voltage: 8.5V DC

Nominal Power: 150mW

So I think it requires 12.5mA at 12V to operate.

I don’t have 12V available, so I’m using 9V, and then it would require 16.6mA.

On the breadboard is working, but I guess I need to put a resistor in parallel with the relay coil to lower the coil resistance in order to correctly use 9V. Is that right?
I guess that’s why it is not working on the simulation

Also, is the resistor on the base of the NPN really needed?


texts: How to assess the risk of touching a live wire

texts:
I know that a macbook charger works at 16.5 V and supplies 60 watts of DC through the laptop. There is a small area (in front of the AC to DC converter) where the insulation appears to be torn off exposing live wire with a small tear of about half a millimetre, where the wire is about a few millimeters in diameter. The charger has been supplying power at a reasonably quick rate for quite a while now.

I have 2 questions, one is when plugged into the mains, will this be able to do serious damage or kill me if I brush or hold this part of the wire? Second is, wouldn't it be more dangerous to touch it when it is not plugged in to the laptop, since the voltage is reduced?


texts:
I've been having a hard time debugging the DSU module on a SAM D20 (datasheet). I mean to utilize it to calculate CRC32 for a program I'm uploading through a custom bootloader (bootloader not mine).

Here is the code:

// enable DSU module - enable its clocks
PM->AHBMASK.reg |= PM_AHBMASK_DSU;
PM->APBBMASK.reg |= PM_APBBMASK_DSU;

// enable writes to DSU
PAC1->WPCLR.reg = 0x02;

// configure Addr and Length registers
DSU->DATA.reg = 0xFFFFFFFFUL;
DSU->ADDR.reg |= DSU_ADDR_ADDR(address);
DSU->LENGTH.reg = DSU_LENGTH_LENGTH(nbytes/4); // length should be in words

DSU->STATUSA.bit.DONE = 1; // clear the done bit
DSU->CTRL.bit.CRC = 1; // begin CRC calculation

// wait until done
while(!DSU->STATUSA.bit.DONE);

// read CRC out of Data register
volatile uint32_t crc = (DSU->DATA.reg) ^ 0xFFFFFFFFUL;

return crc;

Where address and nbytes correspond to the program I'm uploading. The variable names come from the ASF library, but they are pretty self explanatory about what they mean on the datasheet.

the problem is that it won't match a CRC32 generated previously from Python's zlib module:

crc32 = zlib.crc32(bindata, 0xFFFFFFFF) & 0xFFFFFFFF

I wish I knew what questions to ask but I am not used to debugging a hardware system. So what could be wrong?

EDIT: I finally figured it out. The address register needs to be configured with a WORD address:

DSU->ADDR.reg |= DSU_ADDR_ADDR(address >> 2);

Hope this helps someone eventually.


texts: LM13700 Bias Current via Resistor vs. Voltage-Controlled Current Source

texts:
I am trying to understand the advantage of using a voltage-controlled current source (VCCS) to drive the bias current inputs of an LM13700 OTA, compared to a simple application of the control voltage (CV) directly through a resistor connected to the bias input.

As I understand it, if the bias current input of the LM13700 sits two diode drops above the negative supply rail, then the easiest possible thing to do is calculate a current limiting resistor that yields a bias current around the maximum 2mA for the largest expected CV. This seems to be the approach taken by all the example circuits in the LM13700 datasheet and numerous other OTA design resources, with the assumption that the CV applied to the resistor comes from a low impedance source.

My understanding is that if we want to control the bias current exponentially, then it makes perfect sense to use a linear CV an exponential VCCS, as the control current would be less susceptible to noise than trying to generate exponential voltages directly. But what is the advantage that justifies the added complexity in the case of a linear VCCS like the one proposed in Musical Applications of Microprocessors p203 for biasing the 3080 OTA

The only one I can think of suits the need to drive multiple bias current inputs from the same CV, where we can connect more transistors in parallel and source the same amount of current from each, without dividing the current between multiple current limiting resistors (though I suppose we could also just lower the current limiting resistor values). Are there other advantages?

Moreover, I've seen another approach I don't quite understand in some Moog schematics, where the CVs are applied through a resistor following an op amp voltage buffer connected to a BJT common base current buffer. Why exactly is the current buffer necessary/desirable here?


texts: Forcing verilator to take loop label given in RTL

texts:
I want to force the hierarchy of signal to take the loop names given in RTL written in System Verilog.

Example:

for (genvar i=0; i<4; i++) begin: GenLabel

what I am seeing:

hiearchy1.hierarchy2.signal(1)(10)

what I need:

hiearchy1.hierarchy2.LABEL(1).LABEL(2).signal


texts: DC output of differential amplifier with active load

texts:
I've been looking around for some kind of explanation on how to get the output DC voltage on a single ended differential amplifier with active load like the one in the image

It's just that i don't really understand how the DC voltage is fixed there. It seems it's kinda randomly set, because neither M4 or M2 have their VDS fixed.

I would appreciate any help you could provide.
Thank you!


texts: HX711 adc read functions gives different accuracy

texts:
I'm reading data from HX711 with stm32F1 but accuracy of the data are awful. when i read data with arduino the data ten times good if we compare with stm32 results. these are my read functions.

Arduino function:

long HX711::read() {

// Wait for the chip to become ready.
wait_ready();

// Define structures for reading data into.
unsigned long value = 0;
uint8_t data[3] = { 0 };
uint8_t filler = 0x00;

// Pulse the clock pin 24 times to read the data.
data[2] = shiftIn(DOUT, PD_SCK, MSBFIRST);
data[1] = shiftIn(DOUT, PD_SCK, MSBFIRST);
data[0] = shiftIn(DOUT, PD_SCK, MSBFIRST);

// Set the channel and the gain factor for the next reading using the clock pin.
for (unsigned int i = 0; i < GAIN; i++) {
    digitalWrite(PD_SCK, HIGH);
    digitalWrite(PD_SCK, LOW);
}

// Replicate the most significant bit to pad out a 32-bit signed integer
if (data[2] & 0x80) {
    filler = 0xFF;
} else {
    filler = 0x00;
}

// Construct a 32-bit signed integer
value = ( static_cast<unsigned long>(filler) << 24
        | static_cast<unsigned long>(data[2]) << 16
        | static_cast<unsigned long>(data[1]) << 8
        | static_cast<unsigned long>(data[0]) );

return static_cast<long>(value);
}

STM32F1 Function:

    long hx711_read(){

        unsigned long Count;
        unsigned char i;

        Count=0;
        while( HAL_GPIO_ReadPin(GPIOB,GPIO_PIN_0)==SET){}
        for(volatile uint32_t n = 0; n < 3; n++){}

        for (i=0;i<24;i++){
            HAL_GPIO_WritePin(GPIOB,GPIO_PIN_1,GPIO_PIN_SET);
            for(volatile uint32_t n = 0; n < 10; n++){}
            Count=Count<<1;
            HAL_GPIO_WritePin(GPIOB,GPIO_PIN_1,GPIO_PIN_RESET);
            if(HAL_GPIO_ReadPin(GPIOB,GPIO_PIN_0)==SET){ Count++;}
             for(volatile uint32_t n = 0; n < 2; n++){}

        }
        HAL_GPIO_WritePin(GPIOB,GPIO_PIN_1,GPIO_PIN_SET);
        Count=Count^0x800000;
        HAL_GPIO_WritePin(GPIOB,GPIO_PIN_1,GPIO_PIN_RESET);

        return Count;

}

what could be the reason why these two functions give different accuracy?


texts: I am unsure if I am approaching this problem in the most efficient and effective way. What changes can I make to my process of finding A and B? My next step was to turn into phase form so that I could divide but I cannot take the inverse tangent of a letter.


texts: How to implement fire detector (smoke+temperature) for an electronics project?

texts:
I am doing a project of which fire detection (smoke detection) is a part. I want to detect smoke and then trigger a alarm via a micro controller (preferably MSP430 or PIC)
I am looking for basic circuits that can do the needful.
Any help would be appreciated.
I have found TGS308/813 ICs to be useful


texts: Why do I get a contention error for a simple combination circuit in CircuitVerse?

texts:
I created a simple circuit on CircuitVerse:

When I change the C input from 0 to 1, I get a Contention Error.

What does the error mean, and what is wrong with my circuit?
How can I fix it?


texts: Reading and writing analog voltages to two outputs of a lab bench supply from one microcontroller

texts:
I am planning on building my own lab bench power supply which should be software controlled and have two outputs. I am considering using the ATMega2560 due to its large amount of I/O pins, but I don't know how to read/write analog voltages to/from the two outputs. I think that they need to be isolated if I wan't to hook them up in parallel for more current which means that I can't just connect them both directly to the microcontroller.

Am I right or can the two outputs share the negative ground rail and just have the positive rails regulated?

If they need to be isolated, how would I go about reading and writing analog voltages to them (setting and measuring output voltage/current)?


texts: Are SR latches suitable to be used as RAM?

texts:
I've just recently started to become interested in electrical engineering after a couple years of programming and software development.

I've built a 4 bit ALU using a logic gate simulator and now I want to store a previous answer from the ALU into some memory cells.

I've been reading about flip flops and latches, and I've built an SR latch and it seems that I can easily store my answer in 4 of these latches, my question is, is this an efficient way of storing memory (considering the fact that I have no formal training or much understanding so I can't delve into optimization techniques just yet) or should I implement a clock triggered SR flip flop with clock input? How is the data read from the latch on demand?