texts:
I am trying to get a lever micro switch working with my raspberry pi GPIO. This is the lever switch in question.

On the switch it has the model number on one side KW11-3Z and then the other side it says 5a250vac.

I have wired it to COM to GND and NO to GPIO 18. I have tested with a simple push button and this work as expected again wiring to GND and GPIO 18. Therefore I know the python code is correct.

The part I dont know is correct is the switch itself and the wiring.

Here are some images that will help to show how I have things currently.

You can see I have a breadboard with a tactile switch here and this is working as expected. Each time the button is pressed the output on terminal is "Button pressed".

Running the same python code I have swapped for the micro switch with using the same pins on raspberry pi of GND and GPIO 18 however each time the lever is pressed it isn't showing anything in terminal, no echo of "Button pressed".

Can anyone please advise what I am doing wrong here. I suspect I have got the configuration of the wires wrong as the code is ok.


texts: Finding output voltage of a MOSFET using its datasheet

texts:
Given a supply voltage of 4800 mV to a resistor loaded NMOS inverter with a single Nmosfet (2N7002) and a 6 ohm resistor, what would be the output voltage when the input voltage is 3500 mV?
How should I use the datasheet of 2N7002 mosfet to find output voltage for these conditions, exactly?
(I'm attaching the images of the 2N7002 datasheet. This is not a homework. I'm just trying to understand how to use a datasheet.)
Thanks for any ideas in advance!

simulate this circuit – Schematic created using CircuitLab


texts:
I bought a sim900 (the chip itself, not a module) and have gotten stuck trying to figure out how to power it. I hope to power it using a pin from my RBBB arduino clone, which outputs 5 volts and though sources differ,  either 250mA or 300mA. It uses a L4931 power regulator, if that makes a difference.

So far, the most helpful website has been this one which has schematics for an usb powered 500mA power circuit.

I don't understand what is happening on this diagram. For one thing, the part I was most worried about, the capacitor, seems not to be listed. The description of the diagram states that "A low ESR tantalum capacitor is usually used. The value for the capacitor should be more than 470uF."

It also says that "When there was no on/off pin in the LDO or DC-DC IC, the customer can follow nether reference schematic to control the VBAT on/off." which seems to imply this doesn't actually show all of what goes into the VBAT and there's more to the circuit outside the VBAT_IN.

I'm also confused as to what the MCU_CTRL is. The pinout here: simcom(dot)us/act_admin/supportfile/SIM900_HD_V1.01%28091226%29.pdf#page=16 of the sim900 shows no such pin.

There is also a different diagram from this site that looks completely different.

If somebody could explain which diagram is right to use, and what the parts do in that diagram, that would be fantastic!

[Edit: after looking at the parts more closely, it seems that figure 5 is a better fit, despite figure 3 specifically mentioning usb power. I am still confused on that one what the purpose is of the capacitors leading to ground, and the inductors. Also, if this is a LDO, then the diagram on the 1st website a litter higher up might be a good fit. That site mentioned that it needed a 2 amp power in to the regulator. Is that what the capacitors are for?]


texts:
I am overlooking something with a very simple program for my ATtiny45. A program that divides the 16MHz system clock by 16 and outputs that on pin 5 (OC0A) using Timer0 and on pin 6 (OC1A) using Timer1.

Pin 5 (Timer0) works as expected, I measure 1MHz.

Timer1 should be configured in a similar way, making pin 6 (OC1A) toggle at the same 1MHz frequency, but somehow this doesn't work as intended.

Pin 6 (Timer1) carries 32kHz. Even when I change the value for OCR1A, the frequency stays at 32kHz.

I know I'm overlooking something here, but I can't figure it out.

Here is the source code I use:

#include <avr/io.h>

#define _BS(bit) ( 1 << ( bit ) )
#define _BC(bit) ( 0 << ( bit ) )

/*
 * 1 PB5 !RESET
 * 2 PB3 XTAL1
 * 3 PB4 XTAL2
 * 4 GND
 *
 * 8 VCC
 * 7 PB2      SCK
 * 6 PB1 OC1A MISO
 * 5 PB0 OC0A MOSI
 */

void setup( void ) {
        /*
         * Setup timer0 for divide by 16 from system clock
         */
        TCCR0A =                                                // Timer/Counter Control Register A
                _BC( COM0A1 ) | _BS( COM0A0 ) |                 // COM0A[1:0]  = 01   - Toggle output pin on every match.
                _BS( WGM01 )  | _BC( WGM00 );                   // WGM0[1:0]   = 10   - Clear timer on Compare Match (Auto Reload)
        TCCR0B =                                                // Timer/Counter Control Register B
                _BC( WGM02 )  |                                 // WGM0[2]     =  0   - Clear timer on Compare Match (Auto Reload)
                _BC( CS02 )   | _BC( CS01 )  | _BS( CS00 );     // CS0[2:0]    = 001  - System clock, no prescaler.
        OCR0A  =                                                // Timer/Counter0 Output Compare Register A
                ( 16 >> 1 ) - 1;                                // System clock divider. The OC pin toggles on each match introducing an extra factor 2.
        TCNT0  =                                                // Timer/Counter0
                0;                                              // Initialize counter to 0.

        /*
         * Setup timer1 for divide by 16 from system clock
         */
        TCCR1 =                                                 // Timer/Counter Control Register
                _BS( CTC1 )   |                                 // Clear Timer on Compare match
                _BC( COM1A1 ) | _BS( COM1A0 ) |                 // COM1A[1:0]  = 01   - Toggle output pin on every match.
                _BC( CS13 )   | _BC( CS12 )   |                 // CS1[3:0]    = 0001 - System clock, no prescaler.
                _BC( CS11 )   | _BS( CS10 );
        OCR1A =                                                 // Timer/Counter1 Output Compare Register A
                ( 16 >> 1 ) - 1;                                // System clock divider. The OC pin toggles on each match introducing an extra factor 2.
        TCNT1 =                                                 // Timer/Counter1
                0;                                              // Initialize couter to 0.
        /*
         * Enable output drivers
         */
        DDRB =                                                  // Data Direction Register B
                _BS( PB1 ) |                                    // Enable output driver for PB1/OC1A
                _BS( PB0 );                                     // Enable output driver for PB0/OC0A
}

int main( void ) {
        setup();
        while ( 1 ) {
        }
}


texts:
I know that is probably an extremely stupid question but Can I get 12V out of a 3.6V battery? I have a faulty LED hula hoop (which currently has rows of LED's, some broken!) and I want to insert a strip of LED's (Like theses ones  (which say that they run at 12V)) but the battery I have in there at the moment is a 3.6Volt battery.

Is there anyway to boost the charge to make it work? What voltage do LED's usually run from?


texts: SiC MOSFET SPICE model not behaving properly

texts:
I have been trying to simulate a fully controlled full bridge using SiC MOSFETs and so far haven't gettng at least expected results. So I tried to check what is happening using a single MOSFET and a simple circuit like this -

However, when I run the simulation, the current through the resistor looks like this -

I need to uderstand what I am doing wrong while simulating this circuit.
1. Does the gate need a resistor in series ?
2. The floating terminals of the MOSFET are Tj and Tc (temperatures) I have assumed that they can be kept floating.

Update-
Zoomed in waveform -

Edit -
The MOSFET is rated at 1200V and 90A. The simulation works fine up until Vds as ~55V. Thereafter it breaks down and shows these similar results for any voltage above ~55V


texts: Relating RAM usage with stack allocation and random resets in a microcontroller

texts:
This might appear to be too much data way too scattered to understand, but I'll make a genuine effort to explain.

Controller: R5F111MJ (ROM 256KB, RAM 16KB), RL-78/L1C family. Datasheet can be found here.
IDE: CS+ V7.00.00
Compiler: CC-RL V1.07.00

We have designed a custom hardware with references from an eval kit. The team that designed the hardware is well-versed with the design approach as they have been doing this for decades.

Problem statement:
I had been developing the firmware for a couple of weeks and the board was powered up using the debugger all the while.
When I tested the same functionality with debugger disconnected and board used to  powered up using the power supply, it would reset randomly.
Note that the reset issue got resolved with something that I tried (explained below). My question is not how to resolve the issue but why it solved the issue?

What have I tried:

Ensured that the internal watchdog is not causing it, it has been disabled temporarily
We have verified the hardware and power rails, they seems to be okay and voltage level never drop below 3V3 through the reset
System clock is 24 MHz I have tried reducing it to 1 MHz, the issue remains
I have added a debug data (UART) for knowing the cause. At bootup I read the registers that hold the values that indicate the cause of reset (RESF and PORSR registers). They always remain 0 as if the reset wasn't due to low power detection or invalid memory access.
There is a 'Memory Mapping Profiler' which lets developers know the amount of memory consumed so far. The code as of now consumers 10 % of the total flash and 11% of RAM. There is no memory allocated dynamically (i.e. Heap usage is 0).
I've tried debugging with some fragments in the code disabled. If there is nothing after the initialization and just a simple while(1), the issue disappears. I enabled some part of the the code (based of functionality/module), the system resets when about 80% of functionality is included, but then it resets at random places. That made me take a guess that its related to stack rather than a stupid logical error in code.

Now, I scorched through the user manual of IDE and understood that the toolchain (probably a utility with linker) does the stack allocation. And the total stack allocated is equal to 'total RAM available on controller' minus 'whatever is used by user through code'. Somehow I didn't comprehend this. So I went on to manually override the stack allocation in the .asm file and set the stack size to 8192 Bytes. And, the issue disappeared. Like I said, my question is not how to resolve the issue but is more about why did it resolve the issue.


texts:
I'm a beginner who's become interested in Xilinx CPLDs. I get what CPLDs do, but I have no feel for the quantity of logic a macrocell can support or the sorts of situations where macrocells become inefficiently utilized.

Will someone shed some light, please?

EDIT -

Apparently I am not the only one; this is a dark art.  However, if when using ISE one finds oneself out of macrocells, one can use the 'Exhaustive' fitter option and pretty much brute force a fit or show that there is no fit.


texts: What type of Resistors be used with Triac terminals? 1/4 or 1 watt

texts:
I have used BTA41-600 with MOC3083. I Keep frying my MT1/2 connected 330E and 360E resistors. Resistors were used as per datasheet recommendation. I was using 330E and 360E but, both kept frying. 240V ac load of 100W (incandescent bulb) was connected exactly as per datasheet recommendation. Circuit is shown below.

Capacitor is MPC Triac fires "OK"(thanks to ANDY aka), but as soon as it fires it blows the resistors as told. Help needed.


texts: Power supply with opamp and BJT transistor

texts:
I am studying for my EE exam but I couldn't quite get how this circuit works.

Source

Assume R1 = R2, Vout = 10V Vref = 5v. This is stable as it is, and when Vout decreases for a reason below 10V, - input of opamp becomes less than Vref that output of the opamp becomes higher, thus allowing current to escape to ground rather than going to the Load, which decreases Vo more. Where is the thing I am missing?

If I assume an ideal opamp, + and - inputs are equal. Vref = 5V Because of voltage divider rule Vo = 10V. But I am not sure if that's the explanation.

Edit: There is also a reversed one.

I think this is the correct form, when ref is connected to - input, but I am puzzled seeing two different examples.


texts: What causes the electric field to change over series resistors?

texts: So for example if we have a a wider and a narrower wire of the same length in series, since v1A1=v2A2, in the narrower wire the charges will move with a greater velocity. Since v is proportional to the electric field, this means that the electric field will also be greater in the narrow wire. Thus it will have a larger potential drop. So this is pretty trivial and directly related to Ohm's law. My question is what exactly "causes" this changing of the electric field? I'm sure this is a pretty stupid question and probably the best way to look at it is from another angle but I just can't see the intuition behind it right now.


texts: The text that is above the figure is from my textbook and i am having difficulty to understand what it is trying to say because it's not in detail!! why only remove high frequency and prevent low frequency using capacitor on ground G2? also What is the difference between both the grounds?


texts: How long will the batteries last when hooked up to this light?

texts:
The light being used is here:
https://www.amazon.com/Germicidal-254nm-U-shape-150mm-Purification/dp/B01CV2W12E

Lamp Current: 5.0mA
Wattage:    8 watts

It will be hooked up to 2 AA batteries in series
The batteries are 1.5 V and 3000 mAh

How long will the batteries last?

My first assumption is to do this:
 =  /( )=(3000 ℎ)/(5 )=600 ℎ=36,000

But that doesn't use the wattage?  Is this correct?


texts: How do I identify the important specs for this part?

texts:
How do I figure out the relevant specs needed to order this chip?
I found a really cool and insanely expensive ski waxing iron at the dump and am pretty sure I can fix it if I can figure out the relevant specs for this triac sense gate!
https://www.digikey.ca/en/products/filter/thyristors-triacs/300?s=N4IgTCBcDaIEIBU4EYwFoBsAGLIC6AvkA

** Update **
The iron works! Dissembling it jostled a loose connection back into place and the chip wasn't needed after all.
To answer my own question of how to decipher specs off a mystery chip, the aha moment was finding this schematic in the data sheet (intuitively called ordering information  though in my defence the chip had an old code on it that didn't exactly match):

It seems like a simple thing to say "just make sure the specs match" but there are so many values it's tricky as beginner to figure out which ones don't have to match exactly.
I don't need to order the part anymore but I think I figured out which triac I would have needed to order and am curious if I got it right!
T1235H-6T is compatible with BTB12-6CWG
https://www.st.com/content/ccc/resource/technical/document/datasheet/a3/76/a9/5d/d0/3d/41/4d/CD00161295.pdf/files/CD00161295.pdf/jcr:content/translations/en.CD00161295.pdf
https://www.st.com/resource/en/datasheet/t1250.pdf


texts: XC8's Microchip compiler long type doesn't go up 32bits value

texts:
I need a big number in my firmware, So i choosed long for the job.
In the microchip's documents the long type provides 4Bytes for use:

So i created this variable (timeCounter):

In a interrupt of 100us of timer2 this variable is incremented:

Problem:
The variable is unsigned long but when i plot his value the max value achieved is aproximately 32725! and the variable is SIGNED!!!!
image:

The code below shows a sizeof(unsigned long) equals to 4bytes...

I've already disabled the compiler optimizations.
Using PIC18f26k80.

=========================================================

code:

#include "main.h"

void main( void ){

char string[100];
unsigned long timeCounter;

setupHw();
initHw();
initSw();

while( true ){

    clearWDT();

    /*============================================================================*\
     * Task3 (60s)
     * Processo...
     * Dependências:
    \* ===========================================================================*/
    if( f60s ){
        f60s = false;

        sprintf(string, "TimeCounter (60s): %d\n", timeCounter);
        txStringUart1(string);
       } // end da task2
    }
}


texts: touch negative and positive side of battery briefly

texts:
I on accident made a brief connection between the positive and negative size of a 3.7v battery.  Connection was for less than half a second but I saw small amount of smoke come out from the wire.  Can I still use this battery and is there damage?

link of battery
https://www.amazon.com/Samsung-INR18650-35E-Rechargeable-BD-Electronics/dp/B0762M1WDD/ref=sr_1_19_a_it?ie=UTF8&qid=1536353635&sr=8-19&keywords=inr18650


texts:
Among Cadence Virtuoso Calculator functions, is there a function that returns the y value when given an x value?
I know the "cross" function can return the x value when given a y value. But what I need is the opposite - given x, return y.
Could anyone help? Thanks a lot.


texts: How to normalize PWM signal from RX and TX serial lines

texts:
First off, I just want to apologize for any part of this question that may not be properly phrased. This is still very new area for me.

I am building an adapter for my Commodore 64 that lets it connect to a RS232 DB9 serial port over its user port. I've already made the connector and it works beautifully.

What I want to do now is get fancy and create LEDs that light up when the adapter is either sending or receiving data. I've followed the schematics used in this picture here, but the LEDs are barely visible due to high flicker when data is coming or going. I assume this is PWM and the LEDs are barely lit because the rx and tx lines on the serial adapter are turning on and off at super high rates (its a 9600 baud adapter).

I've tried connected a few different sized capacitors at different points in the circuit but I'm still not getting the desired effect, which is to see the LEDs light brightly at times of rx and tx signals going across. Is there a way to "tone down" the pwm so that the LEDs are brighter? One LED is wired to tx and another to rx.

Thanks.


texts: How to convert an array of pixels to jpg or png?

texts:
I am doing image processing project in VHDL. And as output am getting array of pixels (32 bit each). I want test this output data visually, for that it must be converted to image either png or jpg or bmp. How can I do that?

Edit:  Or if am getting same data in four different files like alpha, red, green and blue in a.txt, r.txt, g.txt and  b.txt respectively. Does this make it easier to get the image ?


texts:
I am new here and hope to glean some expert opinions.
I am a disabled veteran and will be starting a bitcoin mining enterprise
in the near future. I have done some research and feel that inquiring
with some large asic makers to make a more profitable system is the smarter way to go. Can someone please provide some insight on the following build to mine bitcoin.

Power Circuitry: Texas Instruments TL7700 Voltage Supervisor
Communications: SHA 512 or Whirlpool 512
5 nm die
BGA Design: Texas Instruments CFCBGA GDZ or best applicable model
Processor: Multicore DSP+ARM KeyStone II System-on-Chip (SoC) 66AK2H14
Cooling: EVGA Kingpin
PSU: Cisco XPS 2200 x 14
Server: ASIC Chips x 30

I am budgeted at $150 - $200k for the entire server setup including ASIC's.
A separate budget of $100k will fund a 10 Kw solar array.

As I'm shooting for the stars, my goals are 150 TH/s per chip and 1000 watts per chip.

Thanks for any feedback.


texts: Using Arduino relay board outside its intended voltage

texts:
I am making a multistage coilgun, with the switching of stages controlled by an Arduino Uno R3. There are ten stages total, and each stage has 5 80uf 330v photoflash capacitors. I need a way to switch that high voltage into the coils, and I have decided to use an Arduino to control that. The problem is, I don't have the money or time to use correctly rated relays, and wire them up to work with the Arduino. So I was looking at the relay boards sold for switching 120VAC, but the voltage I am switching is very far outside the rated voltage for the relays. Would it still work, at least in short term, or would it fry the relays instantly, or weld their contacts? any help is appreciated.

The relay board I am considering: http://www.ebay.com/itm/16-Channel-5V-Relay-Module-Optocoupler-Protection-Power-Supply-Arduino-PIC-DSP/252124532517?_trksid=p2141725.c100338.m3726&_trkparms=aid%3D222007%26algo%3DSIC.MBE%26ao%3D1%26asc%3D20150313114020%26meid%3D167e4df2b792461f8cfaff32c63a7e26%26pid%3D100338%26rk%3D1%26rkt%3D17%26sd%3D291440146340


texts: Compared to 3-port circulator, what is the use of 4 port circulator?

texts: What is the use of 4 port circulator, compared to a 3 port circulator?


texts: Interpreting the open loop gain of a linear power supply

texts:
This question is related to a question asked earlier regarding a linear power supply build.  It turns out that the circuit is oscillating quite badly; an issue not uncommon in feedback circuits.  I've been researching compensation techniques in order to cure the problem and, as an introduction, I've found this tutorial series to be very helpful.

It doesn't deal with my situation exactly (which is to be expected) but (thanks to its intuitive approach), I've been able to create a simulation model in spice that attempts to help me understand the open loop frequency response, which is also as the text explains, the loop gain Ab when the closed loop gain is unity.

The original Farnell power supply on which this circuit is based can be found here and you can see from the spice model image below that I haven't changed much from the original.

In order to find the OL response, I've removed any negative feedback (including the original local compensation) and tied the inverting input to control ground (0V).  Then running the AC analysis, I get the following:

If I understand the result correctly, the response across the entire frequency domain is attenuated.  If this is true and I'm doing this correctly, how can this circuit ever really oscillate? Since according to the tutorial mentioned above, the circuit is unstable (at unity gain) when the gain at f(-180 degrees) is greater than 1.

UPDATE:

Fix suggested by Andy, some local feedback to equalize the inputs (but not enough to affect the response at FOI):

With open loop AC response 100Hz to 1GHz:


texts: Simple project. Two servos are burnt. What's wrong?

texts:
It is a simple project - a focus system for a taken lens and anamorphic adaptor. I have three pots. The first one I use as a manipulator. The second is used to get the position of the continuous rotation servo motor#1. The third pot is used to control the position of the other continuous rotation servo - motor#2.  Motor#1 rotates the taken lens and motor#2 rotates the adaptor.

I use an AOZ1014AI to step down a 7.4V Li-ion battery to 6.5V. First I used two 360-modified JX DC6015(4.8V-6.6V) servos. It worked ok for a minute and then motor#2 burnt. Next I tried Doman servo (4.8-7.2V). This time motor#1 burnt.

Is it ok to connect two servos to one source in parallel?

AOZ1014AI Schematics:

Here is my project schematics:

And here is AOZ1014 schematics:

And here is the calculations that I've done in the supplier's xls file:


texts:
I'm trying to control my RGB led strip using my arduino.
I'm using the following schematic:
http://www.engineerathome.com/upload/rgbledschema.png

For some reason the led strip turns on when I connect the power, so the MOFSET conducts without a voltage from the gate.
I've set the pin to the gate on LOW so there should be no voltage to make the MOSFET conduct.
I'm using a BUK454 800A, the datasheet can be found here:
http://pdf1.alldatasheet.com/datasheet-pdf/view/17129/PHILIPS/BUK454-800A.html

I'm new to MOSFET's so I have no idea what's wrong.
Can anyone tell me what could be wrong?
I've tested the MOSFET on a single led and it worked fine.


texts: Compact way to generate a square wave with double pulse (like a heartbeat)?

texts:
I'd like to drive a small vibrating motor to produce a heartbeat-like effect by feeding it a square wave such as the one below.

Times t1 and t2 will be on the order of ¼ second. I'd like time tb to be user-variable eg by a potentiometer on a dial.

I can see how to generate this by ANDing together two 555s (or halves of a 556) of different frequencies, but that requires a bunch of additional components - 4 RC networks, diodes, a FET to AND the signals together, etc. But I'm trying to fit this all into a 4sq.in. space and along with the battery and switches that might be a tight squeeze.

Is there a more physically compact way to achieve the same effect?

This is for a one-off piece made by hand, not mass-manufacture.


texts: Designing a low-temperature furnace for melting metals

texts:
This is only peripherally an electrical engineering question, but there are no other engineering forums on stack, so forgive me.

I am designing a homebrew device to melt low-temperature metals (like tin).  I have a coil of heating wire.  I am going to use an Arduino and a relay to turn the power on and off, and I have a thermocouple and a temperature sensor for thermostat control.  The electrical side seems fairly simple.

The issue is that this wire is uncoated, as are all the others I can find.  Since I want to wrap it around a metal container to heat it, I need a thin layer of insulation to prevent shorting the wire, while maintaining the best heat conductivity possible.

I found some ceramic insulators, but I'm not thrilled:

For one thing, I would need a lot of those.  They are thicker, and have an air gap inside.
Ideally, each insulator should be as small and thin as possible.  A coated heating wire would be ideal.  A coating would be great.  I would like to wind the heater coil around a metal cylinder, possibly a can.  I would love to coat the can with thin layer of clay, but I'm fairly sure thermal shock will rip it apart after one or two heating cycles.  I would like the insulator to be able to tolerate at least 600°F, possibly 800°F.  The can should be good until at least 1200°F from what we've seen so far putting them in hot wood fires.

I'm also interested in anyone's solution for regulating heat at the top and bottom as well.  I was planning on a double-walled cylinder, with a bigger (insulated) outer cylinder, but I should probably heat the bottom as well.  For the top, all I could think of was creating some kind of double-walled glass cover, but it would have to be able to take a lot of thermal stress, maybe the inside layer (or both layers) pyrex?

Ideas?  Suggestions for parts/materials?


texts: Differential equation solving circuit didn't result the right solution

texts:
According to calculations, this circuit should have solved the differential equation 25y''+ 5y' + y= (15,5)x

So when I give x= 0,1 V, y should be 1,55.But it becomes -10V. Why?

For the ltspice file


texts: transmitting 3.3v/5v signal over a 2 meters cable

texts:
Sorry to send homologous question.
I have looked through this site, but for my limitation on electric knowledge, I have to ask still.
I'm trying to build a DIY project based on arduino and other function modules, there are two PCBAs need to communicate over 2 meters long lines(5V),and the frequency is low (few hundreds K), and almost two way for each line. one sides looks like this：

Two IIC interface(simulated with normal pins) and 4 isolated signal lines. I have test the IIC lines, it gets unstable while the distance exceeds 1.5 meters. So I need to add something to keep it works while the distance reaches 2 meters(max).
On my application scenario, out influencing factor (EMI and so on) is not serious.
it is impossible to use general bus buffer chips, and it is too expensive to use IIC driver chips(it can support far long distance, it is "quality overflow" for my case).

I can use this solution in my case?
transmitting 5v signal over a long cable

I have doubts on that:
1)the voltage at the receive end is enough? (there is 1K resister)
2)it is mirroring on two sides?

Thanks for any guides/advices.


texts: Can a 3W pot be connected to a 5W LED baton?

texts:
Situation:

I got a LED baton and the brightness was higher than required.

I added a regular 22k pot in series to it, and achieved lower brightness, but within a few seconds, the pot was burnt. I went to an electrical store and asked him for a pot that can withstand the high power drawn. He said the max available was a 10k 3W pot. I've tried it, and it has lasted longer than the previous pot, but it heats up a lot and I'm not sure of it working long term. The metal pin for the trace heats up crazy and I can't adjust the resistance either.

I'm not sure how a 3W pot can hold up when the power that was to be drawn was 5W to the LED.

Specs: LED Baton 5W 10k 3W pot set to max resistance.

The light connects directly to the wall socket, and now I've added the pot in series.

If my calculations are right, given the series connection, the 5W baton would draw 20.8mA (V = 240AC) and since I've added the pot set at 10k, the current getting to the baton is 24.0mA.

So is the heating up because of the 3.2mA that is excess? If yes, will it reduce if I add a 1k resistor in series to the pot? And what would be the power rating of the resistor I should ask for when I get it?

Update:


texts: LC filter before analog pin of microcontroller

texts:
I am measuring analog DC voltage at the analog pin of dspic33 series microcontroller. The source of the signal is AC. So, I rectified it with diodes and amplify it with op-amps. In order to reduce the ripple I am using RC filter as first phase filtering and LC filter as second phase filtering.

Single RC filter cannot satisfy my need that it outputs a voltage with 100mv of ripple content in a signal which is going to be measured by ADC. Also, I cannot increase the capacitance since it violates my timing constraints of the requirement due to high RC time constant. So, I decided to go for LC filter as second phase filtering to reduce the ripple content of the DC signal.

My doubt is, whether using LC filter near the analog pin of microcontroller is technically ok or not? Is there any interference come with LC filter when the setup undergoes environmental tests and noise tests?

RC filter has 1k ohm resistance and 1uF capacitance. LC filter has 470 mH inductance and 1 uF capacitance.

Help please!

Edit : I have added filter portion of the schematic. As per comments I need to clarify my points.

Input to the circuit is AC (0 - 200V)
The output of the circuit is DC (0 - 3.3V)

Timing constraint means, I need to detect the voltage within certain milli seconds to process and do other actions based on this value within a second.


texts: Is a bigger resistor different from a smaller resistor with same color stripes?

texts:
I changed a resistor with same color stripes Yellow, Purple, Gold, Gold on a Pioneer surround system but the only difference was that the I put was a bit bigger. The problem is the system went into protected mode because of an error, I forced reset it and the fuse blew up. Was it because of the resistor I changed?
UPDATE: It was not a fuse that blew up, It was 2 of D5SBA60 silicon bridge rectifier that blew up. There is leakage from there.
I have pics of the 2 silicon bridge rectifiers and the resistor that I changed:

I measured this resistor in ohms and only shows open line, other one is ok, about 5 ohms. I will be replacing it for a good one, to me it looks like it leaked.


texts: Photovoltaic/solar power supply for Raspberry Pi

texts:
I want to build a power supply for my Raspberry Pi zero. It needs 5V and 2.5A (2A also working but only if 2.5A is not possible).

I want to use solar cells to get the 5V and 2.5A. I have already searched amazon for solar panels but somehow the ones I've found do only have an output of 80mA - 500mA what's obviously not enough...

Do you have any advice for me about suitable solar/photovoltaic panels...

Please also include some more (technical)details as I'm an noob in electronics.

Thanks in advance!!


texts: I'd like to add one more LED (1->2) but don't know how to keep the same current

texts:
I made a simple LED circuit using a battery, a variable resistor, and a LED.
When the light intensity satisfied my demand (I do not need the full intensity) by changing the resistance, the condition was:
R1 voltage: 0.5V
LED1 voltage: 2.3V
Current: 86 uA

Now, I want to add one more LED in a series to make a dual LED system.
But I don't know how to calculate the appropriate supply voltage and resistor to keep the light intensity the same (= same current of 86 uA through 2 LEDs).
For example, what should be the resistance if I use 4.5 or 6V supply?
Any thoughts or suggestions?

LED: https://www.digikey.com/products/en?keywords=XPEBGR-L1-0000-00E02CT-ND

Okay, now I update a new circuit to supply 5.5V using a voltage regulator.
It is battery powered (6V: 4 x 1.5V AA), so I want to keep the current (or voltage) constant ( ~ 86 uA) during the period of operation.
Do you think this circuit would work as intended?
(Let's ignore the product error between the same LEDs)

https://www.digikey.com/product-detail/en/ablic-u-s-a-inc/S-1133B55-U5T1U/1662-1276-1-ND/6601416

Or what about this design for the parallel arrangement?

I want to supply the constant voltage while the battery voltage goes down. That's why I need to use the voltage regulator.

Voltage regulator: https://www.digikey.com/product-detail/en/texas-instruments/LP3985IM5X-2.5-NOPB/LP3985IM5X-2.5-NOPBCT-ND/3527410


texts: Why would sdi to hdmi work, but not when I convert sdi to hdmi to dvi

texts:
I am transmitting video over sdi and converting from sdi to hdmi with an aja Hi5. This works, but if I convert that hdmi output into dvi, the output is either not detected, or constantly connects and disconnects without getting a display. This was tested on multiple monitors, and multiple adapters that all work independently. I've also run an hdmi signal booster just in case, which seemed to have no effect. Input is 720p 59.94.

I'm kinda out of ideas for why going from hdmi to dvi breaks everything. My final display is DVI only, which is why I'm going to all this trouble.


texts: How to properly clean up a noisy signal with a capacitor

texts:
I'm reading a pulse from a camera back to a raspberry pi and the noisy signal is causing the gpio pin to read too many inputs.

My signal is 3.3v. I'm currently using a 1uf Cap to try to clean up the signal but is that enough? I have the cap soldered to ground and then soldered in the middle of the 3.3v line which leads from the camera to my raspberry pi's gpio pin.

I'm more of a software guy rather than an electrical engineer. I appreciate any help/guidance!

simulate this circuit – Schematic created using CircuitLab


texts: How to carry quadrature encoder data using a single signal?

texts:
A quadrature encoder can be thought of as two switches, usually sharing one of the terminals, i.e. we have COM(mon), A and B.

Is there some simple way of carrying its output on a single wire? How about interfacing that to a single pin on an MCU?


texts: I would like to interpret my ammeter. I don't understand what the point with the numbers 2,20,200 means and what is the exact current I am measuring. Thanks


texts: Generate 1W load on 240V mains to calibrate power meter

texts:
I need to measure the accuracy of a mains power meter at around 1W.
How can I go about it?
Despite being clueless about electronics, I do have some a Tektronix PA1000 Single-Phase Power Analyser that I can use to measure the actual power consumption of whatever circuit I can come up with.
Once I am satisfied with that consistently consuming my 1W, I would then connect the power meter and check what values are read there.
Can anyone advise how to setup such a circuit? I can fall back on electrical engineers to help me build it, but I failed to get the advice to get going.


texts: Easiest way to instantiate a transceiver in Quartus to avoid unused channel degradation

texts:
This answer in the altera knowledge base indicates that the TX channels on the Arria 10 degrade over time if left unused. I have added the recommended assignment to my QSF file, but it has no effect if I don't already use some transceivers:

Warning(18584): There are no transceiver channels used in the design. You must use or instantiate at least 1 transceiver channel to preserve the rest of the unused channels.

I'm just trying out some very simple examples to start with and am trying to find my way around Quartus. How can I instantiate a transceiver with minimum fuss so I don't ruin the boards?


texts: Power 3V EL wire inverter with DC adapter

texts:
For a project I have 20 pieces of EL wire that each have their own 3V (2xAA) inverter. Now I think it's a complete waste and hassle to replace the batteries every so many hours, so I wanted to try and power the inverters from the mains.

What I am worried about with just connecting a 3V adapter is that with dropping the internal resistance of the batteries will result in a too high current that will fry the system (like with LEDs), will this be the case? Is there any way to control the current that will flow?

I have tried different resistances with a 6V power source, but I haven't been able to find one that still powers the circuit with 3V and creates a 70-125mA current (this is what I measured the circuit draws when powered by batteries), and I think I have fried one of the circuits so now I am afraid to do more experiments.

Note: an alternative is to get a 12V driver and a 12V adapter from the shop (I think). However, in this way I lose the different settings that come with the battery pack, which is undesired for my project.

Edit:
I have tried to split the 6V into 3V according to the following diagram:

The R1 and R2 are resistors and the yellow thing is my unknown EL wire circuit that I want to power. I used 220Ohm resistors for both R1 and R2 which results in a nice 3V over the circuit. However, the current over the circuit is not enough because of the resistors. Would it work with lower resistors?


texts: Relays turning on randomly when 24VAC sprinkler solenoid valve is shut off

texts:
tl;dr: I'm having a problem with 8-relay module boards that control sprinkler solenoid valves.  When 24VAC is present, sometimes turning a relay off causes other relays to randomly turn on.
Long version:
My configuration is as follows:

I'm using an ESP32 Pico kit microcontroller.
Three of the 3.3V ESP32 pins are connected are connected to a 3.3V to 5V bi-directional logic level shifter (one level shifter per pin, three total).
The 5V logic level shifter outputs are connected to the RCLK, SRCLK, and SER pins of a SN74HC595 8-bit shift register.
Three shift registers are daisy-chained together, providing 24 outputs total.
Each of the 24 shift register outputs are connected to an input of one of three 8-module relay boards.
The 8-module relay boards are powered by a standalone 5V supply (in other words, not the 5V linear regulator on the Pico board).  The 5V supply is a 1.5A supply, large enough to turn on several relays at once.

When there are no connections to the relay outputs (NC, COM, NO) on the 8-module boards, the relays can be turned on and off in any order or combination, so I believe the shift registers, connections to the relay boards, and software are correct.
I then connect 24VAC sprinkler solenoid valves to the relays like so:

Notice in particular that one leg of the 24VAC transformer is connected to the COM port of multiple relays in the 8-module relay boards.
When I enable just one relay it looks like this:

If 24VAC power is not enabled, I can turn on and off the relay just fine.  When I plug in the 24VAC transformer and then enable the relay, again, everything works ok.  The sprinkler solenoid energizes and all is well.
Most of the time, say 4 out of 5 times, when I turn off the relay the solenoid shuts off and everything is good.  However, 1 out of 5 times, when I turn off the relay, numerous other relays just randomly turn on.  When that happens it looks like this:

I'm wondering if anyone can help me diagnose what might be happening and/or give me some troubleshooting tips.  I've disconnected things down to just one solenoid in the system and it still happens.
Random notes on my setup:
The leftmost relay of the bottom, horizontally oriented 8-module board is where the COM cable comes in from the 24VAC transformer.  It then connects to the COM of the relay to its right, then that COM connects to the COM of the bottom-most relay of the left 8-module relay board, runs up through each COM of the left board, then runs across the top to the COM of the upper right 8-module board, down through each of its 8 relays, and terminates there.
The rightmost 6 relays of the bottom horizontal board do not share the COM channel.  I am using those as dry contactors to operate different (non-sprinkler solenoid) devices.


texts: I have problem with a question. Can someone help me with the solution? Thanks


texts:
So I have a fake "arduino" that I put together (The main components on a breadboard, i.e. ATmega328, capacitors, ocilator, etc) and I am trying to use it to overide a light switch (When the light switch is off, power is off, when it is on, the microprocessor can shut it off manually, or leave it on.)

Anyway, I have everything deesigned and working, but now I want to figure out a way that I can power the ATMega from the electricity flowing through the lightswitch. It will be inside the the wall, so I can't use a tradition wall AC to 5V converter, and I am having trouble finding what I am looking for on google, so does anybody here have a solution? How can I power an ATMega328 from the electricity flowing through a lightswitch? DO I need to set up a power 'limiter' somehow?


texts: I have a question regarding an overheating lamp switch I just fixed in my living room. Below is a diagram of what it looked like internally. It's not exactly a push switch, but a rotating wheel which is half dielectric, half conductive. Anyways, what is the purpose of the diode connected between the main facing terminal and the piece which the connects the two terminals? It seems superfluous. Why not just have the two terminals and the portion that connects them when turned on?


texts: Question about 50ohm impedance matching circuit

texts: I am implementing rf energy harvesting circuit. The rectenna is working at 915MHz and the impedance is 50Ω. I think L-matching may be the easiest. However, I don't have the vector network analyzer. Is there any way to calculate the parameters without the analyzer? Thanks. Here is the structure.


texts:
The 125kHz RFID scanner / reader device I have, has a coil like this:

NB> Don't have a good camera handy at the moment, so had to share a cropped image from Alibaba, but the pic is very close to the one I have, mine being slightly thicker.

Now the problem is that this RFID reader has seen some abuse, and on opening it up, I figured that the 2 coil ends that were soldered to the PCB have snapped. While soldering them back, I have unfortunately broken the thin copper wires bit more, such that, I have very little free length remaining to solder them to the board.

Question now is -

If I undo one round of the coil (which BTW, seems pretty difficult, as the thin wires are stuck together pretty hard), and solder the leads back on PCB, would the reduced coil turn impact functioning of the RFID reader ?
Alternatively, if I solder 2 offboard wires (26AWG single strand copper) to the remaining tiny lengths of leads, and then solder those offboard wires back to PCBA, can it impact the functioning of the RFID reader ?
Are these thin copper wires insulated from each other by something like transparent lacquer / clear varnish ? If so, while soldering, I believe I might burn-off some of it, so can I use standard clear-varnish available at hardware stores (for woodworking), to restore the insulation layer ?


texts:
After my initial question about switching regulators I had decided on trying to use an LM2678 for an adjustable/variable voltage form 5-24V and 5A max with an input of ~30VDC.

The application will be a stepper motor tester for varying motors, hence the adjustable voltage.

In the datasheet, they mention that the PCB layout is very important for this device:

They also give this layout pattern which I admit to not fully understand:

I made this schematic here with the following PCB layout.

Please note:

The heatsink might change, but the actual Schottky diode and the LM2678 have the tab connected to ground, so I would like to share the heatsink.
J1/J2 pin headers are just for demo, in real design they will get replaced by beefier screw terminals of course.
RV1 will actually be replaced by a front panel potentiometer and not be on the board; it's for reference here only.

And once again, with the zones filled (but harder to see silkscreen):

My questions would be:

The bold traces from the design are all very small and copper pours are used for ground and L1 to C3. Other track widths are 2mm. I tried moving the feedback wiring far from the inductor. Would this layout seem acceptable?
Is there some trace/part (I'm sure!) that could be improved?
They say prototype etc, but I only need to make two or so of those boards so I'd like to get this right and obviously on a breadboard this cannot be much tested layout-wise, so what other guidelines would there be to follow, or is this a bit of a tall order without tinkering on a real PCB?


texts: Is there an amplifier voltage limit for the input signal even if the differential voltage is small?

texts:
I am building a simple current sensor.  The amp says the maximum differential voltage is 5V.  I'm not getting more than 1V in differential voltage at the moment.

Is it safe to test differential voltage on a floating 24V line?  What if the grounds are referenced?

It seems like if the line is floating it would work ok but if it was ground referenced it might kill the amp, seeing as the internals might see a 24V potential difference.

simulate this circuit – Schematic created using CircuitLab


texts:
I'm sorry if this has been asked, as it's a simple question, but I haven't found it.

Is there any reason why capacitors are built in so fixed values? For any other components the manufactured value are round numbers, for example resistors 100 Ohm - 1 kOhm - 10 kOhm - ... but capacitors come in weirder numbers, specifically, why can you find multiples of 4.7? is there anything special about that number? is there any normal circuit that goes on everything that needs a capacitance like that?


texts: Close a circuit with no current load (MOSFET)

texts:
For my project I have to close to contacts.
It's bascially a remote for a Canon camera.

With Canon you can use 3 pins (2.5mm jack) to "remote" controll it, 1 of these 3 is the common pin, 1 is the focus and the last is the shoot contact.

My initial plan was to use 2 NO relays for this, put after a look in the datasheet, I noticed the "minimum contact load" and after some searching I found a post about all of this and "mercury wetted relays".

My problem is that I am pretty sure that there is absolutely no load on this circuit.

Now to my question, could I just use a MOSFET in this case, basically use a MOSFET in a circuit with no current?


texts:
I am using this MAX9278 deserializer.
The inputs to the IN+, IN- pins of the deserializer are twisted pair inputs.
On the IN+ and IN- serial link, I have 2 AC coupling capacitors of 220nF 50V on each link and parallel termination resistors of 49.9K from the IN+,IN- line to GND.
I am just trying to figure out what would be the voltage on the serial link (IN+ and IN-) lines so as to calculate the power dissipation of the 49.9k parallel termination resistors and also find whether the capacitors are properly rated in voltage.
What would be the voltage on the serial link?


texts: Correct way of calculating BLDC torque for a given RPM and Current

texts:
A permanent-magnet 3-phase brushless DC electric motor is attached to a load.
Motor is operated with vESC6.6 inverter, which is software-limited to 140A. Measured efficiency at maximum power is 81%.

Motor specs are:

Kv: 49 RPM\V
Operating voltage: 48V
Max RPM: 48V*49RPM\V=2352
Max Rated Current: 140A
Nominal Current: 70A
Peak load: 10kW
Nominal load: 5kW
Resistance(R): 11 mOhm
Inductance(L): 54uH
Flux linkage(lambda): 0.566mWb

The test results:

U: 43.1V
I: 140A
RPM: 769
P: 6035W

I then use two different formulas for estimating motor torque:
$$
Q_1=8.3*\frac{I}{Kv}=8.3*\frac{140}{49}=24\frac{N}{m}
$$

$$
Q_2=9.549*\frac{P}{RPM}=9.549*\frac{6035}{769}=75\frac{N}{m}
$$

Which value is correct?
How can a 3-fold difference be explained?

*I took the formula for \$Q_1\$ from here. 8.3 is for 3-phases, not one.


texts: What is the easiest (least complicated) way to emulate a "short" button press that pulls a pin low?

texts:
I'm trying out the IP5306 (The datasheet is in Chinese, I used the "document" feature of Google Translate to translate it).

Here is my schematic:

The IP5306 is a cheap boost chip that is normally used for charging mobile phones. Its typical application involves boosting a lipo to 5V. It also charges the lipo via a micro USB port. I'm using it to power a small portable load (~60-200mA @5V).

SW1 turns on and off a PFET that connects or disconnects the lipo from the IP5306.

I have assembled a few boards and am currently in the verification/debugging phase. At first, the board didn't work at all. This was due to my misinterpretation of part 10 of the translated datasheet, which states "The IP5306 recognizes long and short button operations, and the PIN5 pin is left unconnected when no buttons are pressed".

I thought this meant I could leave pin 5 unconnected and the IC would function normally. Unfortunately, pin 5 (the "key" pin) needs to be pulled down by a short button press (longer than 50ms and shorter than 2 seconds) in order for the device to start up and boost the battery voltage to 5V and provide current to a load. I didn't account for this in my design, and left the key pin disconnected.

I've been trying for hours to think of a way to automate the temporary pulldown action immediately after SW1 connects the battery with the IP5306. I'd really like to add something small and simple (I have resistors, capacitors, inductors, transistors, FETS) to the design without redoing the whole thing. The pulldown action must be longer than 50ms and shorter than 2 seconds. Any ideas???

Current progress:

simulate this circuit – Schematic created using CircuitLab


texts: Can I do anything to make this electric piano work?

texts:
I have an electric piano but I don't have the power supply.  It has a barrel connector with a negative tip, and wants 12 VDC, 1.5 A.

I have a power supply that is 12 VDC, 2.67 A, but it has a positive tip.

Is this supply sufficient?  Can I modify my power supply in any way allowing it to meet the specifications? Sorry, I don't know much about circuitry and I'm hoping someone would be able to help.


texts: STM32F469 with AS4C4M32S SDRAM only able to write first byte

texts:
I have made a custom board that features a STM32F469NI MCU coupled with AS4C4M32S SDRAM.
Following are the SDRAM timing and register set information:
hsdram1.Instance = FMC_SDRAM_DEVICE;
  /* hsdram1.Init */
  hsdram1.Init.SDBank = FMC_SDRAM_BANK1;
  hsdram1.Init.ColumnBitsNumber = FMC_SDRAM_COLUMN_BITS_NUM_8;
  hsdram1.Init.RowBitsNumber = FMC_SDRAM_ROW_BITS_NUM_12;
  hsdram1.Init.MemoryDataWidth = FMC_SDRAM_MEM_BUS_WIDTH_32;
  hsdram1.Init.InternalBankNumber = FMC_SDRAM_INTERN_BANKS_NUM_4;
  hsdram1.Init.CASLatency = FMC_SDRAM_CAS_LATENCY_3;
  hsdram1.Init.WriteProtection = FMC_SDRAM_WRITE_PROTECTION_DISABLE;
  hsdram1.Init.SDClockPeriod = FMC_SDRAM_CLOCK_PERIOD_2;
  hsdram1.Init.ReadBurst = FMC_SDRAM_RBURST_DISABLE;
  hsdram1.Init.ReadPipeDelay = FMC_SDRAM_RPIPE_DELAY_0;
  /* SdramTiming */
  SdramTiming.LoadToActiveDelay = 2;
  SdramTiming.ExitSelfRefreshDelay = 7;
  SdramTiming.SelfRefreshTime = 4;
  SdramTiming.RowCycleDelay = 6;
  SdramTiming.WriteRecoveryTime = 2;
  SdramTiming.RPDelay = 2;
  SdramTiming.RCDDelay = 2;

  if (HAL_SDRAM_Init(&hsdram1, &SdramTiming) != HAL_OK)
  {
    Error_Handler( );
  }

  /* USER CODE BEGIN FMC_Init 2 */

    FMC_SDRAM_CommandTypeDef cmd = { 0 };

    cmd.CommandMode = FMC_SDRAM_CMD_CLK_ENABLE;
    cmd.CommandTarget = FMC_SDRAM_CMD_TARGET_BANK1;
    cmd.AutoRefreshNumber = 1;
    cmd.ModeRegisterDefinition = 0;
    HAL_SDRAM_SendCommand(&hsdram1, &cmd, 0xFFFF);

    HAL_Delay(100);

    cmd.CommandMode = FMC_SDRAM_CMD_PALL;
    cmd.CommandTarget = FMC_SDRAM_CMD_TARGET_BANK1;
    cmd.AutoRefreshNumber = 1;
    cmd.ModeRegisterDefinition = 0;
    HAL_SDRAM_SendCommand(&hsdram1, &cmd, 0xFFFF);

    cmd.CommandMode = FMC_SDRAM_CMD_AUTOREFRESH_MODE;
    cmd.CommandTarget = FMC_SDRAM_CMD_TARGET_BANK1;
    cmd.AutoRefreshNumber = 8;
    cmd.ModeRegisterDefinition = 0;
    HAL_SDRAM_SendCommand(&hsdram1, &cmd, 0xFFFF);

    cmd.CommandMode = FMC_SDRAM_CMD_LOAD_MODE;
    cmd.CommandTarget = FMC_SDRAM_CMD_TARGET_BANK1;
    cmd.AutoRefreshNumber = 1;
    cmd.ModeRegisterDefinition = (uint32_t) 0x230; //also tried 0x231
    HAL_SDRAM_SendCommand(&hsdram1, &cmd, 0xFFFF);

    //Setup SDRAM Refresh Timer Register with the delay between refresh cycles of the SDRAM, this is SDRAM specific.
    HAL_SDRAM_ProgramRefreshRate(&hsdram1, 1404); //Tried 1386

This same code works when running on a STM32F469-I DISCOVERY Board but fails when It is run on my custom carrier board.
On my board, whenever I write to any SDRAM address, only the first byte is READ/WRITTEN to, for example when I write 0x00 to address 0xC0000000, the data at that address when monitored under debugging contains 0x48129100 i.e first 3 BYTES are random garbage and only the last byte is written correctly(0x00), and suppose If i write 0xAA to the same address the data there when monitored contains the value 0x481291AA.
This is true to every address that I read/write to/from the external SDRAM.
Only the last byte is written/read.
The custom board schematic and PCB layout is identical to the STM32F469-I DISCO board.
Only difference is the RAM chip which instead of being MICRON one is Alliance Memory's AS4C4M32S .
What can be the issue of such a problem?


texts: What it means when adjustment area is: 10±5 s-10min? I cannot find a solution from Google.


texts: Bad on output of Constant-Current source

texts:
What I'm trying to do?
I'm making a constant-current source based off an existing design. The specs of the existing design are:
Existing Design
The design is of a constant current source capable of outputting 4-20mA output current from an input voltage of 0-2V.

The Problem
The problem is when physically making the circuit, the output of this circuit is stuck at 56mA irrespective of input.
I cannot find/contact the original author of the schematics to discuss the problem and its up to me to figure this out.
The simulations also show the same results as in reality:

Simulation Findings
Input: Sinusoidal Wave of 0-2V peaks of frequency 1 per second
Output Current: Constant current of 56 mA
Output Voltage: 13.6474V with small ripples with amplitude in microvolts.

PMOSFET Info

V(Gate)   : 23V
V(Source) : 14V
V(GS)     : 8V

Question
1) Where should I start looking for issues?
2) What is the name of the op-amp configuration being used in the second stage? I do know that the
   first stage is a voltage follower.

EDIT 1: Resolving whether PMOSFET Symbol is correct
I have inverted the MOSFET just in case and the result is a little better but still not close to expected. Don't know whether inverted helped or made it worse.


texts: RLC simulation with initial condition - what is wrong?

texts:
I measure the currents in the RLC system, I gave the initial condition to the LTspice program.
The schematic in LTspice looks like below:

However, the current comes out in kiloamperes:

For comparison, the characteristic of the I3 current in Matlab

obw2.m file:
function [yp] = obw2(t,y)
R1=5000; R3=3000; L1=1*10^-3; L3=4*10^-3; C=0.2*10^-6; alfa=100;
A=[1, 0, 0, 0, 0, 0;
   0, 1, 0, 0, 0, 0;
   0, 0, 1, 0, 0, 0;
   0, 0, 0, L1, 0, 0;
   0, 0, 0, 0, 0, L3;
   0, 0, 0, 1, 1, 1];
B=[y(4);
    y(5);
    y(6);
    e_zr(t)-R1*y(4)+y(2)/C;
    -R3*y(6)+ y(2)/C;
    -alfa*(y(4)+y(5)+y(6))];
yp=A\B;

e_zr.m file:
function [e] = e_zr(t)
freq=5000;
e=10*sin(2*pi*freq*t);

run.mlx
 [t,y]=ode23s('obw2', [0,0.01], [0;0;0;4*10^(-3);0;10*10^(-3)]);
plot(t, y(:,1));
title('Q');
plot(t, y(:,4));
title('I1');
plot(t, y(:,5));
title('I2');
plot(t, y(:,6));
title('I3');

Please help, what am i doing wrong here! Thank you for your help and advices!


texts:
The standard motherboard USB 3.0 connection looks like a standard 20 pin IDC male with 1 pin missing, however IDC pin pitch is 2.54 mm but this image shows it as a 2.0 mm pitch.  Is there a name for this connection?

Also, a bonus question, does anyone manufacture a lockable variant of this connection?  Thanks


texts: How to get date and time of uploaded firmware?

texts:
I have some kind of smart home on multiple esp8266, and I periodically update code of their firmwares via Arduino OTA. And sometimes I forget to upload actual code on them. For example, I don't remember, if I uploaded a new version of firmware to esp8266, that serves in toilet :) .
Each of Arduino esp8266 firmware is *.bin file, if I understood it correctly. Each of file has time of creation. And question is - does esp8266 store date and time of firmware, uploaded via OTA (or update) and is there any Arduino program method to get that date and time?


texts: How do you create a spice model of a lm234? This model would need to be used with both LTspice and Labcentre's Proteus software

texts: How do you create a spice model of a LM234? This model would need to be used with both LTspice and Labcentre's Proteus software.  Please note that I have never created a spice model.


texts: What is the best way to acquire voltage information of a battery powered microcontroller project?

texts:
I would like to track the battery that supplies my microcontroller.

I was thinking at a simple voltage divider bridge wired to an ADC input.

As my divider bridge will be permanently connected, I suppose the resistors will consume current all the time.

I wonder if there is not a more energy-efficient way to measure it.

EDIT 1 :

My microcontroller is an STM32L422. I know I could use the ADC of the VBAT pin of the uC to measure this voltage (p38 of the datasheet) but I read p73 of the datasheet that the VBAT max was of 4V. Problem, my battery can go high as 4.2V, so I can't use it directly.
I will probably run my uC at 8MHz for HSE and at 32KHz for LSE.
I'm using standard li-ion battery like this one for instance (4.2V max)
My charge management IC is the MCP73831, here is the datasheet
My LDO voltage regulator is the XC6220

EDIT 2 :

There is the the power section schematic :

Where :

Vbat being the battery voltage, the one that I'm trying to monitor
+5VDC_(24V) = a possible 5V input from a 24VDC to 5V regulator.
+5VDC_(USB) = a possible 5V input from an USB power source.
+3VDC = The voltage used for the uC and all the other components.


texts: Turning on PC PSU with current or bridging PS_ON and COM/GND?

texts:
I really hope title is specific enough.

What I am trying to achieve is that using a SATA Extension Cable to PS4 you can plug in a 15mm 2.5" Laptop Drive or 3.5" Desktop Drive and the issue is that the internal SATA connection provides no 12v for 3.5" HDDs so 3.5" HDDs that require the 12V will not spin up due to inadequate power.
I have a 430W PSU lying around and have it set up so that it provides SATA power of 12V and 5V DC to the HDD and just have the SATA III data connected to PS4. But for this I ALWAYS need to make sure I turn on the HDD power before the PS4 or the PS4 will spend a minute trying to boot and then warn of "Cannot Connect to Storage".
Is there a way to connect the 5V from PS4 to PS_ON so that when the PS4 boots and attempts to power on the internal drive it switches on the PSU via the PS_ON + GND bridge causing the HDD to be adequately powered and everything flows nicely. During PS4 shutdown, the last thing to lose power is the HDD, thus turning off the PSU.

Is this possible?


texts: Isochronous endpoint descriptor service interval choice

texts:
Here's the isochronous endpoint descriptor:

0x07,                           /* Descriptor size */
CY_U3P_USB_ENDPNT_DESCR,        /* Endpoint descriptor type */
CONSUMER_ENDPOINT,              /* Endpoint address and description */
CY_U3P_USB_EP_ISO,              /* Iso endpoint type */
0x00,0x04,                      /* Max packet size = 1024 bytes */
0x04,                           /* Servicing interval for data transfers: 1ms*/

The last argument is the servicing interval. Currently, it is 0x04 meaning that the polling period is 8, that is, every eights bus interval. I know I can set such interval with values 0x01,0x02,0x03,0x04 meaning every microFrame, every second, every fourth, and every eights microframe respectively. Would it be possible to have a 0x8 interval to have polling on every 16th microframe (every second frame)?


texts: Freescale MCP8260, don't understand pins

texts:
I am looking at the Freescale MCP8260 processor.

For programming PINS you set values to some registers. I would like to use MII interface for Fast Ethernet for example. I can see the Dedicated PINS table and everything is fine. But TX_CLK and RX_CLK aren't at the table. Why are they missing? All other PINS exist (except from 2 that manual explains but says nothing why the clock pins aren't there).
However there is a register that can be used to change the clock but why are they missing?

Is it possible A TDMA device to use the same clock for receiving and transmitting?


texts:
I know that if you have two transformers connected in parallel that are of slightly different turns ratios, then there will be a circulating flow of VARs.

I also know that if you have two transformers that are mutually phase-shifted, you will have a circulating flow of watts.

My question is: what is a circulating flow of watts?  To my knowledge, having more VARs implies more current implies more losses.  But, having a circulating flow of watts seems like the exact same thing to me.

So what is a circulating flow of watts?

Thanks!


texts: Stopping criterion of lead-acid battery charging operation with SMPS

texts:
I'm trying to charge a lead-acid battery. The input DC voltage is too high, so I used a 400W SMPS to drop it down to a more convenient (currently not decided) voltage level. Battery capacity is not fixed (i.e.; different batteries will be connected).

Generalized circuit diagram is as below:

The charge controller unit of my circuit is supposed to take a voltage feedback from the battery, and decide whether to go on charging or to stop. I'm puzzled at this point. Is this a good method for stopping the charging operation?

Suppose that, the output of SMPS is 15V under no load; and the battery voltage will be 13.8V when it is fully charged. It looks like it will be a clash between output impedance of the SMPS and internal resistance of the battery. The voltage level which the charge controller will read is ambiguous. I'm not sure if it is a good way to check battery voltage level or not.

Is this a correct way of controlling the charging operation? If not, what modifications should I make on this circuit?


texts: Headphones with 3 wires: blue, green, and copper

texts: I'm trying to replace the male connector on my headphones. After cutting off the broken connector, there are three little wires sticking out, colored green, blue, and copper. What does each color correspond to? As far as I can tell, nobody else seems to have had this issue.


texts: inline pull up/down resistor decrease resistance when encapsulated

texts:
I am working with a 500 MΩ resistor, assembled in the fiberglass tube with both ends closed.  There is dielectric-silicon filled in between the resistor and fiberglass tube, which gets cured in 24 hours.

When I measure the resistance of the resistor itself, it's showing 500 MΩ. However after assembly into the fiberglass tube, it was showing in 450 MΩ range. Then after cutting the top half of fiberglass tube (horizontally cutting) the resistor was again showing 500 MΩ.

I think the silicon expands during the curing process and it puts pressure on the resistor to make it read low resistance. Can this happen? What would be the impact of pressure on resistor and what is the easy and best way to measure the impact?

Thank you.


texts:
I'm writing a bit of code for a keyboard. I've written this before, but it was inefficient and I figured as I was learning bare metal, I'd rewrite the code again. However, the said code wasn't working, so I've written the main in C to see what went wrong. My output pins (columns) are connected to pins PC0 - PC8 and input pins (rows) are connected to PD0 - PD6.
Initialization code:
    RCC->AHB1ENR |= RCC_AHB1ENR_GPIOCEN | RCC_AHB1ENR_GPIODEN;

    GPIOC->MODER |= GPIO_MODER_MODER0_0 | GPIO_MODER_MODER1_0 | GPIO_MODER_MODER2_0
                 |  GPIO_MODER_MODER3_0 | GPIO_MODER_MODER4_0 | GPIO_MODER_MODER5_0
                 |  GPIO_MODER_MODER6_0 | GPIO_MODER_MODER7_0 | GPIO_MODER_MODER8_0;

    GPIOD->PUPDR |= GPIO_PUPDR_PUPDR0_1 | GPIO_PUPDR_PUPDR1_1 | GPIO_PUPDR_PUPDR2_1
                 |  GPIO_PUPDR_PUPDR3_1 | GPIO_PUPDR_PUPDR4_1 | GPIO_PUPDR_PUPDR5_1
                 |  GPIO_PUPDR_PUPDR6_1;

Definitions, structures, typedefs, variables
typedef enum {
                KEY_UP,
                KEY_DOWN
} keystate_t;

#define NUM_COLS 9
#define NUM_ROWS 7
#define NUM_KEYS (NUM_COLS * NUM_ROWS)

keystate_t key_state [NUM_KEYS] = {KEY_UP};

static const struct
{
    GPIO_TypeDef* port ;
    uint16_t pin ;
} keyscan_col_io[NUM_COLS] = { {GPIOC, 0},
                               {GPIOC, 1},
                               {GPIOC, 2},
                               {GPIOC, 3},
                               {GPIOC, 4},
                               {GPIOC, 5},
                               {GPIOC, 6},
                               {GPIOC, 7},
                               {GPIOC, 8} };

static const struct
{
    GPIO_TypeDef* port ;
    uint16_t pin ;
} keyscan_row_io[NUM_ROWS] = { {GPIOD, 0},
                               {GPIOD, 1},
                               {GPIOD, 2},
                               {GPIOD, 3},
                               {GPIOD, 4},
                               {GPIOD, 5},
                               {GPIOD, 6} };

While Loop
  while (1)
  {
    /* USER CODE END WHILE */

    /* USER CODE BEGIN 3 */
      for (int cols = 0; cols < NUM_COLS; cols++)
      {
          for (int c = 0; c < NUM_COLS; c++)
          {
              if (c == cols)
                  HAL_GPIO_WritePin(GPIOC, keyscan_col_io[c].pin, GPIO_PIN_SET);
              else
                  HAL_GPIO_WritePin(GPIOC, keyscan_col_io[c].pin, GPIO_PIN_RESET);
          }

          for (int rows = 0; rows < NUM_ROWS; rows++)
          {
              if (HAL_GPIO_ReadPin(GPIOD, keyscan_row_io[rows].pin))
                  key_state [rows * NUM_ROWS + cols] = KEY_DOWN;
              else
                  key_state [rows * NUM_ROWS + cols] = KEY_UP;
          }

      }
  }

Like I said, I initially tried writing the while loop section in bare metal but the code didn't work as expected, so I wrote it in HAL to see if it would.
On checking the status registers, all the bits are set as expected. I set key_state as a live expression, so that I could view the states of all the keys. However, the keys won't trigger the right variables. I checked the connections and can confirm they're connected properly. Also, on checking with the previous, program I wrote, the keys trigger the right variables and I cannot see any difference between the code.
Where am I going wrong?


texts:
How does the Arduino IDE/build system work?

I noticed that they use the avr-gcc in the background,
but what do they do on top?

They seem to have their own "kind of C" language that transforms into something that then compiles by avr-gcc.

Would someone like to spread some light on how it really works?

What language are they using?
Are they using something like Make in the background?
What intermediate files do they create? Can you listcompile a arduino file, or have a look at the generated AVR assambler?


texts: Change in duty cycle of a transistor (BJT)

texts:
simulate this circuit – Schematic created using CircuitLab

I have recently been working on a project in which my requirement is to transmit the data through a transistor, at a typical speed of 100KHz to 200KHz.

While performing the experiment, I observed that the square wave with 50% duty cycle, which I generated from Arduino, at a frequency of 158KHz, changed the duty cycle to 42%.

The transistor I used was 2N2222, whose dynamic characteristics according to the datasheet is in the range of hundreds of megahertz.

Does anyone have a idea about the cause of the anomaly?


texts: Problem connecting to Arduino with USB and audio

texts:
I have a project which uses an Arduino to detect tones generated by a laptop. The Tone Detector (TD) circuit is a very simple LM567 implementation designed to detect 10kHz. The circuit is powered by the Arduino, connected to the laptop headphone socket via a standard 3.5mm stereo audio cable. In testing, with Arduino externally powered, the circuit works fine - the laptop generates tones, which the TD detects and raises a signal to the Arduino.

The problem is that it doesn't work if a USB cable is connected between the Arduino and the laptop. I have tried all configuration variations I can think of, but the common factor is when the USB cable AND the audio cable are connected it doesn't work, and it seems the audio is simply not generated in this configuration. The target Arduino is a Leonardo, but the same problem occurs with a Uno.
All suggestions very welcome!
In response to questions, yes there is a common ground. The audio input for the TD is connected to 0v.
Tone Detector circuit:

Audio input is connected to Input and 0v; Arduino to 5v, 0v & Output.
It is clear from the comments that the issue is around connecting the audio and digital grounds together, the question now is, how can I solve this?


texts:
I was reading a manual of an oscilloscope, and I noticed in working environment section it mentions something about altitude. What does altitude have to do with oscilloscopes?

It says operating less than 3km and non operating less than 15km

The oscilloscope is Rigol DS1000Z.


texts:
I need to control 8 12V automotive relays with an arduino. I have two PS2502-4 optoisolators. The relays are 12V with a coil current of 75mA.  The transistor side of the optoisolator can handle 160mA/ch and 160mW/ch and has a Vce(sat) of 1V so the power dissipation through each channel of the optoisolator should be 75mW. This is well within the 160mW rated value. Pretty much every example circuit on the Internet uses an optoisolator to drive a separate transistor for the actual switching though.

Is there a reason to use a second transistor if the optoisolator can handle the power dissipation directly? Are these second transistors serving another purpose?  The only thing I can think of is a lower Vce(sat) which means more voltage across the relay.

Thanks


texts: How to connect WiFi module and Miсrocontroller via MII interface

texts:
WiFi module:     WIZ610WI
Microcontroller: LPC1788
Purpose:         Connect it via MII on PCB

I have the following scheme:

Do I need a signal delay on TX_CLK?
On what line and what the value of the resistor to set?
Are there guidelines for the design of such boards?

The image from:
enter link description here


texts: Proper clock generation for VHDL testbenches

texts:
In many test benches I see the following pattern for clock generation:

process
begin
    clk <= '0';
    wait for 10 NS;
    clk <= '1';
    wait for 10 NS;
end process;

On other cases I see:

clk <= not clk after 10 ns;

The later is said to be better, because it is scheduled before any process is executed, and thus signals that are changed synchronously to the clk edge are handled properly.
The following sections from the LRM may seem to support this theory:

Page 169: 12.6.4 The simulation cycle
  A simulation cycle consists of the following steps:

b) Each active explicit signal in the model is updated. (Events may
occur on signals as a result.)

This should be the signals with a new projected value such as signals delayed by the after.

d) For each process P, if P is currently sensitive to a signal S and if
an event has occurred on S in this simulation cycle, then P resumes.

That would be most of the logic to be simulated

e) Each nonpostponed process that has resumed in the current simulation
cycle is executed until it suspends.

And now all processes that are suspended by a wait for are executed.

TL;DR:

Is the after method always superior to the wait for method?
Does it help to prevent the problems synchronously set input signals?


texts:
I need a VGA socket for my project (preferably PCB mounted but that's not reevent probably). But I can't find such a thing at any of my usual suppliers.

I presume they have some other name I need to look for? Searching through the many thousand types of connector hasn't helped me so far...

So, my question is, what do I need to look for for a vga socket connector?


texts:
I'd like to use a mobile phone together with a barcode scanner as a poor-man's version of a computerised barcode scanner, something like this: http://www.thebarcodewarehouse.co.uk/pdas-and-handheld-computers/handheld-computers/motorola-MC9190-G/

My phone is capable of USB OTG, and that works well but it uses the same micro USB port for charging the phone and I'd like to avoid unplugging the barcode scanner to charge the phone.

I'd essentially like to combine the phone and scanner into a single device with a a socket that I can use to charge it.

I know that there are Y cables available, but these seem to provide power to the peripheral (scanner) rather than the phone. I have also seen various micro hubs but these again seem to provide power to the peripheral devices only.

I have seen various suggestions for a scheme similar to the one below but with the addition of a resistor to pull the ID line in the phone's connector low with specific values. I have been unable to find an easily digestible list of these, and there are suggestions that it is against the standard. I also don't know how it would handle the connection and disconnection of the charger.

In the OTG cable that I use to connect the phone and scanner, I believe there is a short between ID and GND. This tells the phone that it should be in host mode and provide power. When I plug the charger in, the phone needs to stop powering the 5v line and accept power instead.

I considered a simple switch to open circuit the ID pin, thus taking the phone out of OTG mode, and allowing it to charge. But, I believe it takes a short while for the phone to realise that the OTG device has been unplugged and to stop providing power, during that time the phone and the charger will be trying to supply power at the same time which doesn't sound good.

I also had a look for a chip that will handle this switching for me. They seem either to want to switch the data lines only which I don't think I need (unless the charger signals its presence this way), or be a charge controller for a battery (I don't need this since the phone will handle charging of its own battery).

The barcode scanner doesn't have to work while it's charging but that would be a nice-to-have feature.


texts: I am just getting into this software. I construct my circuit, and it tells me to choose a ground. I only have experience with "ideal" circuits and circuit elements, and have only seen "ground" in the context of the node-voltage method for solving circuits. My question is: What does this term "choose a ground" mean, and where should I put it in a simple circuit with a voltage source, a resistor and an LED all in series?


texts:
Is this a valid circuit for high current 12 to 5 volt regulator? I need approx 10 amps. The TIP's will have a massive heat sink.

The source is a car battery mounted on this huge R2D2 thingy robot.


texts: A low bandwidth mesh network for RC planes

texts:
I am looking for suggestions of a low bandwidth (<1 kbps) mesh network which can be implemented between RC model planes. It should be able to communicate over distances of 500m or more, preferably 1km+, and it should gracefully handle the loss of nodes in the network.

It should be legal worldwide to operate; at least Europe and the USA if that is not possible. And, it must be relatively cheap to implement.

This is for an RC plane game I am developing. Real world model aircraft in dogfights. Or racing each other. It will be part of Super OSD.


texts: Help needed to design a suitable energy harvester for TENG

texts:
I am in the process of desgining a scalable triboelectric nanogenerator (TENG) through which I can easily harvest and store electricity in a battery or a capacitor.
A TENG can be modelled as voltage source and a capacitor as illustrated as below.

simulate this circuit – Schematic created using CircuitLab
The problem with this model is that it has a very high impedance and for maximum power transfer we need impedance matching. One idea that I had is using coupling inductors (transformer action) to bring down the voltage and upscale the current so that the impedance on the load side is reflected as Z/n^2.
I am not sure that this technique will work.
After rectifying this low frequency AC generated I have found some energy harvesters by Linear Technology but they are pretty expensive and keeping the costs low is the main goal as for now.
Here are the links of the two that I found:
LTC3588 evaluation board.
ADP5091 evaluation board.
What factors beside the costs should I need to keep in mind in order to decide which of these devices would better suit my need?
Also what would be the modular breakdown of such a nano energy harvester so that I can design it for myself?


texts: Why does a pure resistance have an imaginary current and voltage?

texts:
While solving the below circuit:

The solution is as shown below:

I noticed the following while analyzing it:

Why does the voltage across a pure resistance and the current through it have imaginary parts?

What do these imaginary parts represent?
Similarly for a pure reactive load (inductive) what does the real part of the voltage Vx mean?


texts: How to convert from binary to hex display in verilog?

texts:
The question needs some explanation:

Suppose I have an 8 bit value, say 8'b00000001 (1)

Suppose I have the module as follows:

module hex_decoder(hex_digit, segments);
    input [3:0] hex_digit;
    output reg [6:0] segments;

    always @(*)
        case (hex_digit)
            4'h0: segments = 7'b100_0000;
            4'h1: segments = 7'b111_1001;
            4'h2: segments = 7'b010_0100;
            4'h3: segments = 7'b011_0000;
            4'h4: segments = 7'b001_1001;
            4'h5: segments = 7'b001_0010;
            4'h6: segments = 7'b000_0010;
            4'h7: segments = 7'b111_1000;
            4'h8: segments = 7'b000_0000;
            4'h9: segments = 7'b001_1000;
            4'hA: segments = 7'b000_1000;
            4'hB: segments = 7'b000_0011;
            4'hC: segments = 7'b100_0110;
            4'hD: segments = 7'b010_0001;
            4'hE: segments = 7'b000_0110;
            4'hF: segments = 7'b000_1110;
            default: segments = 7'h7f;
        endcase
endmodule

to output on HEX0 and HEX1, I can do something like this:

hex_decoder h0(.hex_digit(value[3:0]), HEX0);
hex_decoder h1(.hex_digit(value[7:4]), HEX1);

and this will display 01 on HEX1, HEX0.

The only problem is that after 9, the values will become in hex letters. I want it so that if I pass in binary 10, (8'b00001010), then HEX1 HEX0 should be 1 0, not 0 A (as hex works)

How can I convert it like this?


texts: Controlling 5V Pushbutton switch fails with Triac

texts:
I have an external consumer product what I try to automate by connecting my Arduino to its push buttons. This device uses internally 5V, I can get this voltage on the switch buttons as well.

My goal would be to automate this without relays to keep my circuit small and quiet.

I have tried 2 methods so far:

http://www.instructables.com/id/Small-Triac-Switch/

-Connecting the buttons to the triac

-Connecting the buttons to the MOC directly

The results were the same. For the first time the switch works (device turns on) but any other attempts are ignored. I would like to understand why and how to modify my circuit to work possibly with the components I have on hand (TIC206 or MOC3041).

I got the triac in high power switching in mind because I didnt know what the device uses internally until I disassembled it but I would say the MOC should be good enough for switching 5V.

If I use a relay or just sort the wires by hand that works 100%.


texts:
In many books I've seen the generalized transfer function expressed using:

\$\displaystyle G(s) = K \frac{(s + z_1)(s + z_2)\ldots}{s^n (s + p_1) (s + p_2)\ldots} \$

What I don't understand is where the lonely \$s^n\$ term in the denominator comes from? I've searched high and low but I've not found any explanation for this term.


texts: For the need of more accuracy in my adc value, I have to average the adc value for particular time, what are the types of techniques handled in the averaging Can anyone help me with the example C programs for different types of averaging techniques PIC 16f877A.


texts: Requirement for more ADC inputs than micrcontroller has available

texts:
I have a requirement to read an analogue value from 20 sources. I am using a PIC microcontroller that has 11 available ADC inputs. I have a number spare IO ports, I am thinking of using an analogue multiplexer/demultiplexer 74HC4051; 74HCT4051 they cost 55p each. What are people experiences with these devices? Would you just add an additional PIC and not bother with the additional logic?

edited to make it a little more clear.
I am trying to read the values from a large group of potentiometers inside rc servos.
I will take readings from all of the pots maybe once a second.


texts: How can remove the spikes in common mode rail?

texts:
Following is the circuit I am working with.

Intended output across R7 is (60  Ohm resistor) is:

More than 2 mA current for logic high (5 V) input V1
Less than 0.1 mA for logic low (0 V) input V1

Another key point is, output should have a common mode voltage of 2.5 V

Following is the characteristics of input and output waveform

Color code: Green (Input), Blue (Output)

Output voltage is taken with respect to ground. Ideally there should be output voltage around the 2.5V common mode voltage and there should be no such spikes as I have highlighted in the brown circles.

Questions:

1) Why there is spikes in the output?

2) How this spikes can be removed?


texts: How can I determine if this computer fan is dead?

texts:
Desktop computer fan started making noise then stopped.

We noticed it requires 12V and will run at 200mA.
I wasn't sure about that at first.  Does that mean it has an internal resistance of :
12V / 200mA = 60 Ohms?

If so that means I could supply it with 12V and it would consume 200mA and spin.

Question: Is that what I should assume from reading those details on the fan?

I decided to try it out with a bench power supply, but first I decided to measure how much resistance I could read.

Check Fan Resistance

When I hooked up my meter to read resistance I read 20 KOhms of resistance.  Hmmm...??  Well, wasn't sure about that because if it were true then 12V would only supply it with only 0.6mA (600uA) and I knew that wouldn't work properly.

Applied 12V

I applied 12V to it figuring nothing lost here since it wasn't working.  The the fan just barely moved then stopped.

I'm assuming the fan is dead, but I have a couple of questions.

What are the "normal" reasons these fans die?
Dirt?

What generally makes these fans die?  There really aren't any parts touching anything to wear out are there?

Is there any way to bring it back? (extreme cleaning of some sort? - blowing out dust or is it carbon build-up or something?)

Does the high resistance (20 KOhms) indicate that the fan is dead or would a working fan read that amount also?

One Last Interesting Point

After I was done testing it I put it back in the desktop case and hooked the computer's power to it again and it started spinning slowly 20-30 rpm or so (guessing).  Why would it do that?


texts: why do the large industrial lathes, 1 HP upwards still use induction motor and not BLDC?

texts: I'm trying to find an answer as to why exactly larger more powerful lathes still have 3 phase AC induction motor. All the benefits of a BLDC seem to far outweigh the use of an induction and they seem to be relatively cheap if bought separately.


texts: Simple and compact Over-Voltage protection with fuse and resistor

texts:
I know there are many techniques to protect over-voltage on the power supply. However, it does not apply to my case as it only provides single polarity voltage protection. Additionally, I want to achieve that with as little amount of components with small size as possible. In the other words, I want to design hardware to protect against a kind of harmful device called USB killer in a compact size with a little cost.
The schematic is shown below to demonstrate my idea:

simulate this circuit – Schematic created using CircuitLab
Here HOST is known to provide constant 5V. Device may charge via the 5V power line and discharge to provide a short high voltage pulse: V_u (aka Unknown Voltage) could be 110V or -110V or higher. This is to protect HOST against the high voltage from Device.
Let's assume that HOST can tolerate the maximum voltage from -5V to 15V for a short period of time. I use 1 Ohm resistor to get the current and protect the circuit from the over-current with a 10A fuse.
Will this circuit protect against such a device? How effective is this protection?


texts: Frequency changing element in an FM transmitter

texts:
In a simple FM transmitter such as this

What element does the frequency modulation? I don't mean the oscillation itself, since it's clearly created by tuned tank circuit, but the modulation. There is no VCO or anything so what exactly changes the frequency of the wave?


texts: Negative Charge Pump with Ring Oscillator

texts:
I was told it was possible to get a negative voltage from a ring oscillator (that doesnt go negative), I was wondering how is that possible?

Thank you in advance.


texts: Measure voltage of the panel light bulb inside a vintage radio

texts:
I'm new to Electronics. I have recently received a vintage radio Pioneer TR-305. I am trying to replace the panel light bulb inside this radio. I opened the radio panel and found the bulb soldered into the wires. I turned on the radio and tried to measure the voltage using the multimeter from the 2 wires soldered to the bulb. It reads very intermittent and small voltage. I then measured 2 ends of a 1.5V battery and it reads 1.3V - which indicates the multimeter is working fine with the same settings.

Do you know how to measure voltage points inside a radio board? I thought I was the same as on the breadboard but definitely something else is going on here...


texts:
I am an Electrical Engineering student, and when we were taught about inverters (at a power electronics course) we studied inverters using Sinusoidal Pulse Width Modulation.

My question is do the so-called "true sinewave" inverters use the same technology, or a different one?

Isn't it possible instead of using SPWM to directly create a sinusoidal waveform (stepped like a DDS signal generator does) and then use that waveform to drive some power semiconductors?


texts: Charging 3 cell LiPo with TP4056 (Protection included)

texts:
I am trying to charge my three LiPo cells with these TP4056 modules.

My Idea:

simulate this circuit – Schematic created using CircuitLab


texts: Two BJT transistor vs driver for PWM MOSFET

texts: In some books and articles they say that to protect the MOSFET from overheating when working in PWM mode two BJT transistors are used as in the image, others recommend the use of a driver for MOSFETs such as MCP 1404. What is the difference between using one or another?


texts: How to limit voltage charge of supercapacitor

texts:
For a DIY project, I plan to charge an 100F 2.7V Supercapacitor using a 3.7V Lithium-ion 18650 battery. However, I need it to charge only until 2.25V.

Is there a simple circuit that I can build to limit the voltage\charge?

I basically need the stored energy to be ~250J.


texts: Relationship between reset pins and SWD functions (ARM Cortex M0)

texts:
On many microcontrollers or other devices without JTAG/SWD functionality, there is a reset pin which when low unconditionally and asynchronously forces everything into a known state.  On devices with JTAG or SWD functionality, however, things seem to be more complicated since it's possible to perform some JTAG/SWD functions while the reset pin is asserted.

I have some Freescale KL15Z-based boards which include the SWD pins on a connector with the reset line and some other diagnostic I/O pins.  Occasionally when connecting or disconnecting a cable, the parts seem to get into a weird state such that even reset won't kick them out.  I'm wondering if some stray pulses on the SWD pins might be putting the device into an "ignore the reset pin" state.  I have found that when using the debugger, I seem to have frequent difficulties getting the devices to reset reliably; I don't know if the issues may be related.

What is the relationship between the reset pin and the SWD functionality?  Conceptually it would seem most helpful to have a design where any falling edge on reset would be guaranteed to actually reset everything, and SWD communications which were supposed to happen before user code startup could be performed with reset held low, but I don't think that's how the Freescale KL15Z chips actually work.  What's the best way to solve such reset-related problems with the Freescale or similar parts?


texts: Get wattage (electrical power) from applicances and devices plugged in around the house

texts:
Firstly, I'm not really an electrician or an electrical guy with lots of knowledge about electronics but I'm always interested learning to it.

Yesterday, I asked my wife to help me out determining the wattage (electrical power) of an electrical device such as TV, Reff, PC, Laptop, Tablet, etc, etc anything around the house that uses electricity and I plotted each one of them and log at least 3 wattage and average it.

I have this:

that's 95% of our electrical devices here around the house. I can play with values and see how much it costs if this device is turned on for this hours. But doing it is pretty tough job because we had to turn off everything and turn on and off each device to check its wattage.

But I wonder if an multimeter can do this? Can I check the wattage of an electrical device such as TV, Laptop , etc even if they are plugged in?

I only have this cheap small digital multimeter I carry around the house.

Here in Philippines, meters are exposed and some are digital, like ours. That's the way I check the wattage of the device - sort of like this one:


texts:
I am working on a problem for which I need to know how much power will be consumed on a given CPU as the parameter sizes are increased. The following properties/attributes of the CPU are available:

    Version: Intel(R) Xeon(R) CPU E5-2670 0 @ 2.60GHz
    Voltage: 0.8 V
    External Clock: 100 MHz
    Max Speed: 2600 MHz

It is not possible to install any special tool as far as I know from the admins of the system. I am looking for a suggestion for some kind of formula/method to map a given executable running on this CPU and the power that the CPU will consume. Do I need to know any more about the CPU to obtain a more accurate power profile? About the executable: is there a way to accurately figure out its CPU profile?


texts: Matlab: Solving homogenous set of linear equations based on Kirchhoff's circuit laws

texts:
I have got the following equivalent circuit of a common source amplifier from which I want to determine the expression for the voltage gain A = VD/VG.

Because I have pretty much more difficult circuits to solve, I want to use a systematic approach instead of calculating the result manually. So, with the definitions

I thought the easiest way is to define the Kirchhoff's loop equations

and the Kirchhoff's junction equations

Together with the equations from Ohm's law

and the input impedance

I stated the coefficient matrix C in Matlab:

However, because it is a homogenous set of equations Matlab only shows the trivial result (V = 0).

Am I doing anything wrong?
Thanks for your help!


texts: MSP430F5438A: How can I see the flash memory content in CCS?

texts:
I have to establish a file transfer mode between C# and CCS.
To make sure the text files has transferred properly, after sending a file I read it from C# to compare with the origin.

I need to look at the flash memory content all the time for these reasons:

I get different results of writing to specific memory segments, for instance: if I start writing at 0x20000, some characters distord, but if I start at 0x20008, everything works OK then, 0x20016 half OK half garbage, etc..
Even with the Non-problems mode (0x20008) just the transferring the first file works fine, if I send another file and try to read it then, all I get is just garbage.

This photo if anyone would like to see the writing/reading procedure code:


texts:
I have two ICs with STM8S005C6 MCUs.

Is it possible to read flash from MCU of the first IC and write it to the other one?

I checked the STMZ website for tools to read/write to MCU but they seem to use JTAG and my IC doesn't have JTAG.

What should I look for?
What pins of the MCU are used for reading/writing operations? So I can follow those pins and maybe find myself a tag to read from it on the IC.


texts:
Have I obtained the correct transfer functions for the following RCL circuit?
Please note that my Maths is a little rusty!

$$\dfrac{Eo(s)}{Ei(s)}=\dfrac{1}{(R_1C_1L_1)s^2+(R_1R_2C_1)s+R_1} \tag{1}$$
Defining $$Z_1 = R_1 $$
Defining the series impendance between \$R_2\$ and \$C_1\$
$$Z_s=\dfrac{1}{sC_1} + R_2 = \dfrac{1+sR_2C_1}{sC_1} $$
Defining the parallel impendance between \$R_2\$, \$C_1\$  and \$L1\$
$$Z_p = \dfrac{Z_sZ_L1}{Z_s+Z_L1}=\dfrac{\dfrac{1+sR_2C_1}{sC_1}sL_1}{\dfrac{1+sR_2C_1}{sC_1}+sL_1} =\dfrac{\dfrac{s^2R_2C_1L_1+sL_1}{sC_1}}{\dfrac{1+sR_2C_1}{sC_1}+sL_1}$$
Multiplying numerator and deniminator through by sC
$$Z_p=Z_2=\dfrac{s^2R_2C_1L_1+sL_1}{s^2C_1L_1+sR_2C_1+1} \tag{2}$$
Therefore, we have that
$$\dfrac{Eo(s)}{Ei(s)}=\dfrac{Z_2}{Z_1+Z_2}= \dfrac{\dfrac{s^2R_2C_1L_1+sL_1}{s^2C_1L_1+sR2C+1}}{{R1}+\dfrac{s^2R_2C_1L_1+sL}{s^2C_1L_1+sR2C+1}}$$
Simplifying
$$\dfrac{Eo(s)}{Ei(s)}=\dfrac{s^2R_2C_1L_1+sL_1}{{R_1(s^2C_1L_1+sR_2C_1+1)}+{s^2R_2C_1L_1+sL}}\tag{3}$$
The $$ s^2R_2CL+sL $$ terms cancels out with the one in the denominator and we're left with the following
$$\dfrac{Eo(s)}{Ei(s)}=\dfrac{1}{(R_1C_1L_1)s^2+(R_1R_2C_1)s+R_1} \tag{4}$$


texts:
I have a small board that stores some static and dynamic data: cc 80bytes of serial number, manufacturing date and a counter.
The board has two SOT-23-5 components: one is with CBOCX and one is with EC0d0 (?) mark on it.

On the board, the wires as as follows (from left to right): SDA, SCL, GND, PWR.
I have hooked a logic sniffer to the wires and checked the communication. The board communicates with I2C protocol. It seems these two components are slaves, with addresses 83 and 96.
I was assuming these components are EEPROM-s, and looked up many datasheets. I compared the command descriptions from the datasheets with the sniffed data, but the sniffed data is different.
For example the communication starts with this I2C commands when I plug in the board to the master unit:

START
10100110 (write request for the 83 device) - ACK
01000001 - ACK
11100111 - ACK
00000000 - ACK
00000000 - ACK
STOP

The response from the board for these sequence is 32 bytes of data.
If I hook the board on my arduino and send out the sequence above, the board responds the same 32 bytes also for me.

I'd like to read and manipulate the data, but I have no idea right now, how could I do it. What other could be these components, that stores data in SOT-23-5 package other then an EEPROM?

Your ideas are welcomed!

Thanks!


texts: How to interface 3 serial devices to AT89S52 microcontroller?

texts: I have to interface GSM, GPS and RFID to one microcontroller (Atmel AT89S52). The GSM and GPS can be switched using relay but I can't find a solution about RFID.


texts: Increasing the resolution of a sensor by using an amplifier

texts:
I'm new to electronics and I'm trying to design some circuits and blocks on my own.

I'm making a block to measure temperature in a range between 2ºC and 50ºC, by using the sensor LM35. I have set the circuit (which is pretty basic) in a Protoboard and it works. However, I'm wondering if there is any way to maximize the resolution (currently, I obtain a resolution of 0.1mV). I am using a ISO TECH IDM 203 multimeter (which is 3 3/4 digits).

I thought that this could be done with an amplifier. But my knowledge of amplifiers is not very good.

Is this feasible? And any idea on how to start to do it (or what OpAmp block should I use)?


texts: I have a stepper motor that is controlled by PWM.  I am trying to analyze the signal coming out of the controller on an oscilloscope.  Ideally, I would like to capture, maybe 2 seconds of wave form so that I can see the exact signal being used to control the signal.  I am using a Rigol DS1102E oscilloscope but and I am able to capture screen shots of the waveform, but not enough for me determine exactly how the controller is operating over an entire cycle.  Does anyone know of a way to capture several waveforms so that I can see the entire signal over when it runs the stepper motor?