texts: Is there an easier alternative for finding the gain of this operational amplifier?

texts:
My question is:
Is there an easier method than what I've tried, that I can use in order to find the parametric gain in the following circuit? If so, what is it?
The circuit:

Where the parametric gain I had to find was defined as: $$G_v=\frac {Vout}{Vin_1}$$
Additionally,
$$Vin_2=Z\cdot Vin_1$$
Where Z is a constant unknown parameter.
It's also given that $$R_{in}=\infty, R_{out}=0, Vout=\mu(V^+-V^-)$$
The method I've used (my own efforts):
Firstly, I found the relation between Vy, Vout and V-, using several currents:

After that, I found the relation between V-, Vin1 and Vy, then plugged in Vy from the previous step:

And then, a whole lot of Algebra for simplification purposes:

Finally, I arrived at this answer:

As you can see, the method I used was very complicated, and it also took a long time to think of and actually carry out.
Is there a method I could have used that would have made calculations simpler, easier or even more intuitive? If so, what is it?


texts: Insights required to repair my Agilent YIG oscillator

texts:
I know, it's probably no chance. But let me try.

The model is HP-Agilent 0955-0520, Y088-4258, that can be bought for 600-900$.
Here is a picture.

When I bought the oscillator, I performed multiple tests and everything worked fine. Recently, the oscillator is no more able to deliver its 15dmb, but deliver only -15dmb (and there are resonances at intervals of 3GHz). The delivered power is still (surprisingly) flat, and the frequency is still tunable as previously. I've checked everything possible regarding the supply current, heater etc., and everything works as in the original tests. I suspect two possible things:

somehow, the sma connector has been damaged
the transistor has been damaged by some electrostatic discharge (I've very stupidly forgotten to protect it with a Zenner)

Unfortunately, I was unable to find anything technical regarding this model (and more generally, about most YIG oscillators). It seems my only chance is that a charitable person well acquainted with those models will give me some information...

Anyway, any insight will be appreciated before I try to open it.


texts: Power Supply for xl6001 12V Switching LED Driver

texts:
I have 2 nos 7W LED Modules, each of which are fed from a separate XL6001 based LED Driver. The DC power input to the drivers is from a 12V, 7.5AH SLA Battery. The LED driver takes 12V DC from the battery and boosts it to 22V DC for the LED module. The current consumption at the lamp side is 636mA (for both lamps), while on the battery side is upwards of 1.2A (for both lamps). All this works fine.

Now, in a separate mode of operation, I would like these lamps to light up from AC power. The design of the operating unit (the overall box) is such that power must go through the LED drivers to reach the lamps. So, for the AC power mode, I have been trying to use an LM317 voltage regulator outputting 12V DC which is then fed to the above LED drivers. I am observing that after a few minutes the output of the LM317 drops to 4.5V DC and current falls down to 300mA (for both lamps) on the input of LED driver. This results in "abysmal" brightness from the lamps. I have also tried using an LM350 (3A rated) and found the same sudden voltage drop.

What am I missing? Is it heatsinking...though I am using a regular heatsink which is used with TO-220 packages. Ambient is around 28 C.

Should I configure LM317 as a constant current source and then feed its output to the LED driver ?

Should I configure the output voltage from LM317 to be 22V and then feed it to the LED driver ?

The input to voltage regulator is from the bridge rectified output of a 230V:24V single phase, 50VA transformer.

Thanks and best regards,

Vishal


texts: How do I connect 24v NPN/PNP device to a Raspberry Pi GPIO without cooking the Pi?

texts:
As part of my "detecting the presence of an item on a conveyor" I'm looking at industrial through beam connectors. A lot of them are 3 wire NPN or PNP devices like this (highlighted):

I'm wondering how to use the output of either of these to signal to the Pi; the devices themselves are fairly configurable in that you can buy NPN/PNP that will output either when something is in the beam or when something is not in the beam, and I was thinking to detect a transition anyway so it probably doesn't matter which I choose in terms of beam on/off. In my reading around about NPN and PNP I've determined that PNP would output the supply voltage (24v in my case) when outputting and some floating(?) voltage when not. I think I could use two series resistors of high value and suitable 7:1 ratio to divide the 24v output voltage down to ~3v to register as high for the GPIO - but would I need to connect the 0v to the pi's GND also ? Is that safe?

Alternatively is it better/possible to use an NPN, 3.3v from the Pi through a pullup resistor and the output of the NPN takes the place of the switch in this diagram?:

The specific product I'm looking at is a Panasonic CY-100 series - that link has a few resources including datasheet but it appears that a lot of these photo sensor devices seem to have similar workings


texts: A question about length vs electromagnetic interference relation

texts:
How can we explain the reason for why EM induced noise increases with the cable or wire length in analog voltage transmission?

My way of thinking is that same current is induced on the wire regardless of its length, but because the longer cable has longer resistance it causes more voltage noise. Is that correct? If not how can this be explained illustratively?

EDIT:

If the reason is the larger area hence d(A*B)/dt; then why people need to use diff ended inputs since they can zero the area by twisted wires?


texts: How will the proper termination at one end while the other end is kept open avoids reflections in transmission line?

texts:
Consider a transmission line which is terminated with characteristic impedance at one end but other end is kept open, the reflections are not observed. I don't understand the mechanism behind. Please explain how it is happening?

What I think is that, since other end is kept open, the signal will get reflected and reaches the other end where there is proper termination so no reflection occurs but the reflected signal from the open end is going to the load so it should see that reflection, but it is not seen. Why?

I don't understand the flaw in my explanation, please help me understand the mechanism.


texts: BJT small signal analysis, ignoring current sources

texts:
Question for you. Currently 'm in the middle of studying for an analog II exam. I've got the following midband small signal model:

When analyzing for midband gain, more specifically VB2/VPi1, the solution just considers the one current source (GmVpi1) to be running across the resistance RC1//Ri2.

$$\large\frac{V_{b2}}{V_{\pi1}} = -g_m \left[R_{C1} \| \left(r_{e2} + R_{E2} \| R_L \right)\left(1 + \beta_2\right) \right]$$

In reality there are two current sources! What gives? Is it because we know that the current being supplied by Gm2Vpi2 is much much smaller than Gm1Vpi1 that we ignore it?


texts: Why is my voltage regulator get warm while my car is not running "68 corvette" battery is also going dead, is it the regulator or another problem?


texts: Connecting the secondary side of ignition coil to earth

texts:
I have an ignition system used for some application.
During the testing I found that spark plug is producing EMI due to spark occurrence and high voltage is traveling through the wire.
So to suppress the noise signals, I connected the secondary end connection to the earth (through electrical junction box.)  But when I turned on the setup, the equipment (RPS) which connected on the same line (connected on the same junction box) is disturbed (glitches in display,) within few seconds RPS is blown off (something is burned inside the RPS).
I am not able find the exact problem but during the testing I tried moving the earth connection near to the secondary end, suddenly an arc is jumped from secondary end to earth connection.


texts:
I'm working on a flexible LED screen persisting of 20 meters of digital RGB LED strip with WS2811 IC for each LED.

I want to control this using Arduino, which isn't a problem using FastSPI. My problem is, that I want to create different LED programs (for instance using LedEdit 2013) which can then be exported to *.led files.

This in itself isn't a problem, as I have already generated these files. The problem is how to read and decode the *.led file? From what I have been able to read around the internet (searching around for couple hours now) the files consist of some sort of header followed by base64 encoded information about the x and y position of LEDs that should be turned on and which color they should be (RGB 0-255 value I suppose). I am not entirely sure how exactly I am going to decode this signal and get something actually useful out of it?

If I can just get some useful information out, I can surely program my way out if implementing it with the FastSPI library for Arduino.

EDIT:

I have made two simple example files that could perhaps be easier to look at for you guys.

Both are made up op a simple 10 x 10 led setup, both only one scene; one all black and one all white.

Black: http://www.codesmith.dk/black.led and White: http://www.codesmith.dk/white.led


texts: What is the delay incurred by ternary content-addressable memory (TCAM)?

texts:
What is the cost (in terms of delay) of using TCAM? How do they compare with SRAM and DRAM?

I understand their use cases are different. But assume, for an application, I can do an operation using TCAM and can also do the operation using RAM. Now in RAM I can access data with memory index. But in TCAM I can do 3 wat matching. But if that specific operation is not so much frequent I can use the RAM. But for that I need to understand the performance difference (in terms of time) between SRAM, DRAM and TCAM. Any reference is most welcome.


texts:
I need help with an LED matrix I am building for my son, running from an atmega 32 and a BC818 transistor. I have the schematic from
http://dhassel.de/projects/cool/led-matrix-display/
In the schematic there is no resistor value from BC818 pin to LED anode. I'm afraid that I will burn the atmel 32
http://dhassel.de/images/projects/2012-11-15-led-matrix-display/led-matrix-display8.png


texts: How do I build a DC time out circuit that stays off until power is toggled?

texts:
My girlfriend bought an LED faucet that is actuated when you turn the water on and is powered by a battery pack of 4 AA batteries (2 wire out).

However, when the water is turned off, the slope of the faucet is rarely sufficient to overcome the surface tension and the faucet remains on.   How can I build a timeout circuit such that the faucet turns off after being lit for 5-10 minutes and stays off unless water is fully cleared from the faucet and then the faucet is turned on again?

A friend of mine recommended a 555 chip, but after looking into it it seem the faucet would just turn off after 5 min, then turn back on 5 min later and keep cycling indefinitely.

I tried searching this site and came across this question that seem similar, but can't figure out how to deal with the fact that the activation of the circuit would work more like a toggle switch than a push button.

Thanks!


texts: Solution to detect bad vias in production process

texts:
I face the problem of damaged (cracked) vias in a rigid/flex assembly.

It is very difficult to detect those defects before mounting the assembly. Products with cracked vias may fail during lifetime while early detection seems difficult.

The manufacturer of the PCBA is testing all tracks according to A 600 class 3, which means, any track with less than 10 Ω is considered ok. However nominal values for tracks are only mΩs. Which means, testing acc. A 600 cannot detect moderate resistance deviations.

Current interim solution is to connect all tracks of the assembly in series by connecting it to a test adapter and to measure the series resistance. It is then compared to an arbitrary threshold for good/bad decision. This causes a high scrap rate of PCBAs which probably don't bear a defect. I.e. it is a test with a very bad specificity.

Is there a testing method for PCBA manufacturers to find defect vias within PCBAs? Is X-ray a way?


texts:
I am looking to measure an incoming V vs ground with an ADC (MCP3424 or equal). The Vin vs Gnd can be anywhere from -1.5V to +2.0VDC. I looked at using an op amp with level shift, when I came across the attached schematic in the manual of the ADC.

So I put an Excel together and if I take R2 and R3 extremely high (k/MOhm) and R1 and R4 lower then it converts the incoming signal while not directly tying Ch- to GND.

But could it be this simple, or am I overlooking something obvious? If so it's back to the op amp with level shift.

FYI I am looking for abt +/- 2 mV accuracy. As it is digital, it's no problem to have a conversion formula in the program if the measurement is not fully 1:1. I intend to use multiple channels all with the same ground.


texts: Interfacing an RCA audio output to a microcontroller ADC

texts: I'd like to connect the audio output from a set-top box (and similar) to a microcontroller's ADC. They all have an RCA connector so I was wondering what sort of circuit may be required to interface the RCA audio output to the ADC on a microcontroller?


texts: Can i directly connect a gsm shield to a computer without using arduino?

texts:
Ok, i've bought a gsm900 in alexan, and what i bought was a gsm shield thinking that it is really just the same only that shield can be placed directly in an arduino.
The problem is that, im trying to do a computer system that utilizes gsm module to automatically send sms notifs, but the gsm shield does not have rs 232 port like some of the gsm module available in the internet. And Im thinking would it be possible to connect my gsm shield to an arduino then connect the arduino to the pc, would the at commands coming from my computer system be able to pass through the arduino and send it to the gsm? Or if it is possible how should i do the programming? Im using visual studio 2012 and c# as my language.

Ps. My gsm shield have small male pins namely rx tx gnd and i cant remember the other one, (my gsm shield was with my friend at this time). And i have read that rs 232 are composed of that pins. Correct me if im wrong, can i just buy/creata/modify an rs 232 cable so it can be connected through those pins? I still have very limited knowloedge bout gsm.

Thanks!


texts: Unsuccessful when testing a power entry module model in simulation

texts:
I'm trying to understand how this power entry module suppresses common mode interference. Here is the diagram:

I want to sort of make a simplistic EMC test in simulation just to see how the common mode is suppressed by this filter. In simulation I set the mains to zero and applied common mode voltage to see the effects better. The first circuit below is without module and the second one is with the module. I provided the correct values for the filter components in the diagram.

Is my model for this purpose correct? Why is there no difference between with and without module/filter cases at the output a, b,c and d?
How to model the test in simulation so we can see the difference between with and without module cases? It would be great if someone could make a simplistic test model just to see the idea for this module to see the effects of the module in simulation.


texts:
Background
I'm doing a DIY project of bulding a 1kW Induction heater.
in the process I have built a poormans PSU out of a MOT ( and a 50V 25A brigde rectifier. with not even nearly enough of a smoothing cap (2,500 uF from a broken switched psu for my old comp).. but anyway:
Method
I am going to build a Volt/Amp-meter with a Aurdino tiny and as I am testing my prototype something is a bit of..
I'm just wondering what I'm doing wrong..
According to the internet copper has a resistivity coefficient (q) of \$1.72\cdot 10^{-8} =  q\$.
Resistance (R) in a conductor is given by \$(q L)/A =  R\$
where L is length in meter and A is Surface area in \$m^2\$.
The resistance I'm using for a shunt is a 2.5mm^2 copper cable (European way. I don't know gauge)
now, I decided I want 2mV/A in drop and that, witch all other variables now given gives me a Length (L) of 0.727 m for a

simulate this circuit – Schematic created using CircuitLab
Issue
When I hook it up to a known circuit that handles 20A+ and go to calibrate it in reference to my multimeter I end up at 5.7mV/A drop instead of 2.0mV/A witch was calculated.
It's quite a difference and since this stuff is pretty straightforward \$U=RI\$ I wonder what I'm missing?


texts:
I have a high power 12V rail that I would like to keep separate from the logic supply, and so would like to optocouple the N-MOSFET drive for an external high power LED light. Does this seem like a reasonable schematic?

The optocouple used is a Vishay VO618A (datasheet) (CTR 100% to 200%). The N-MOSFET's datasheet is here.

I have a few questions:

Do I need a gate resistor?
How unecessary is the is the switching MOSFET on the photodiode side?
Should I lower the forward current through the diode?


texts: Can I choose a heatsink based on its thermal design power (TDP) for cooling LED chips?

texts:
I am confused about TDP ratings and what they refer to actually.
The reason I am confused is because most modern CPUs and GPUs, although not ideal, are able to sustain very high temperatures (80 C or even above).
In my projects, I need to cool bunch of high power LEDs.
I'd like to keep the LEDs under 70 degrees celcius but 60 or less would be even better.
My application areas have very constant (known) ambient temperatures (between 20 to 36 C, basically indoors).
My questions is:
If I have a 100w rated LED that I drive at 32 volts x 2 amps (64 watts total), could I use a CPU cooler with 75 watt TDP to keep it under 70 degrees celcius in ambient conditions?
I have done my research but could not get the answer I need.
Your helps is much appreciated.
Many thanks!


texts:
I'm trying to build a simple low voltage 0-12 adjustable PSU and the simplest way i could think of was using a LM2596T ADJ.

In page 16 of the Datasheet there's a inductor selection selection guide, in my case figure 7:

Can someone please explain this graph for me? how can i choose the required inductor value using this graph?


texts: Building a Huge 18650 Battery Powerbank DIY

texts:
I know there are a lot of threads about this topic already, but I still have some questions about it. Anyways, I am thinking about making a 50-80 thousand mAh power bank depending on the batteries and how many of them I get to build them up. I will need a protection board if my batteries do not have built in protection. Then I would also need a charging board. If I do not have a protection board or built in protection, then the power bank could catch on fire, a safety hazard. I obviously don't want this power bank to be a safety hazard. So I am just wondering if this will work. So I am thinking I could use this board to charge the batteries:

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

However, I don't know if it can handle the current. If it can't, where is a link that would have all the nice features that this board has like led indications with at least 1 usb for my phone/devices?

I know the batteries here seem legit and has built in protection, so wouldn't need a protection board:

https://www.18650batterystore.com/Protected-p/panasonic-18650-protected.htm

With these batteries, I would probably buy like 16 of them, so 16x3400 mAh=54400 mah and wire these in parallel. So these batteries I am like 90% sure they're not fake.

Anyways, thanks in advance.


texts: EV Car's battery voltage and charging with solar panel

texts:
How much is the voltage of electric car's batteries?
I was thinking about a DIY electric van (Mercedes Sprinter) with 3x200 watts solar panels on the roof. I'm not sure but let's say the EV batteries are 460 volts and solar panels are are there any inverters or battery charges that can charge 460 volts battery with 18-20 volts?


texts: USB Type-C split to fast charge PD and use with car Android Auto

texts:
OK here is the image of the device and it is working, like users posted. There is one problem though, I cannot buy it anywhere.

I want to make it out of cables directly, without using the board. I need a help for this to work. I already tried it and I have a problem recognizing a phone connected to PC, there is no connection because VBUS is not connected to USB A side of the connector. I cannot connect it because PD Fast charging is supplying greater voltage on VBUS than 5V while charging.

There is also a PD Buddy Wye adapter available on the internet but it is using all 3 Type C cables. The trick there is to use pull down 5.1kom resistors from CC1 and CC2 lines without using VBUS lines. But I need to use USB 2.0 A connector which doesn't have CC1 and CC2.

I also tried to add resistors on the A side from this schematic below, but with no luck. When the phone is not connected to cable I get PC to recognize that something is plugged into it, and device is malfunctioning because no phone is connected. When I connect phone, the PC doesn't recognize anything at all.
D+ voltage with phone connected is around 1V, and without phone connected is around 3.6V.
Can you help me assemble this cable to work?


texts: help identify USB-like charging cable/connector (used in headphones)

texts:
I need help in identifying the type/name for this cable and input pair.
I've been able to rule out existing cables that I already own and that I could determine online.
I used several sites that list USB cables for different types/revisions such as this


texts: Help with supplying 3.3v to ESP and temperature/humidity sensor

texts:
I'm new to electronics. I've built this:

It's an ESP-01 Wifi chip and a DHT22 temperature/humidity sensor. Now I'd like to power it with batteries instead of an Arduino. The ESP-01 requires 215 mA, the DHT22 requires max 1.5 mA.

This post shows powering such a set-up with a 3.7v battery regulated with a HT7333 voltage regulator.

However, as AA batteries are more available in my neighbourhood, I thought maybe I should use a "step-up"/boost chip to boost 2 AAs to 3.3 volts.

Is this a good idea? And which particular chip would be easyish to use on a breadboard and hopefully eventually solder?


texts: Inverting buck-boost vs. positive buck-boost

texts:
Should I use an inverting buck-boost or a positive buck-boost topology?

Input voltage range = 19-22VDC,
Output voltage range = 10-56VDC,
Application = LED driver

The app not I have says the inverting topology fits applications with an input voltage range that overlaps the output voltage, and that the positive buck-boost supports applications where the input voltage range crosses the output voltage.

I feel like with those descriptions either topology would work. Although, the input voltage doesn't exceed the output voltage. Which one would be better?

Thanks!


texts: How to double the amplitude of an AC Signal

texts:
If I have an input signal, \$v_{in} = A\sin(2 \pi ft)\$ where 1 < A < 4V and 20 < f < 20 kHz, and I am wanting to double the signal's amplitude so that my output then becomes \$v_{out} = 2A\sin(2 \pi ft + \theta)\$, where I desire to keep the phase shift (theta) as low as possible, how might one achieve this using eletrical circuit components?

Any help would be greatly appreciated!


texts: Mystery RGB LED ring from defunct Hello Sense device. Trying to make it work

texts:
I can't seem to figure out how to get this LED ring to work.
It's got 4 labeled pads: GND, VCC, VIN, DO.
I tried wiring DO to an Arduino and running FastLed on it but it won't light up. I tried using multiple clockless LED models in the FastLed setup but nothing seemed to work.

Could this 4th pin be required to make it work?
Is a resistor required between the DO pin and the Arduino data pin?


texts: Is Arduino a good platform for monitoring 24VAC thermostat circuits?

texts: Our house has 4 heat/cool zones, controlling two separate furnace units.   I'd like to build a system to log on/off times for each of the zones and the burners/compressors.   This makes a total of 10 inputs.    Is arduino a good platform for this type of application?  I have plenty of software experience, but limited hardware design knowledge (but I am comfortable with a soldering iron if I know the required design).    I would probably ship the data (input#, new state) to a nearby server using TCP or UDP to be logged.


texts:
The datasheet of a chip describes the circuitry of the reset pin the following way:

The reset pin is described as a pull-down.
The chip is powered at 1.8V - the recommended/acceptable values are between 1.7V and 3.0V.
The reset pin belongs to another domain and toggles between 0 and 2.5V.
What is the risk for the chip to be powered at 1.8V and receive a signal at 2.5V?


texts:
I am seeking to build a small drum pad that can trigger short mp3 files. Here there are a lot of specifications and I don't expect to have everything explained, but any tips on how to go about making this, what IC's to use especially, or any general help and explanation would be greatly appreciated,Thank You.  -Kevin

Basically the goal is to have eight buttons that will each play a short mp3 clip when pressed.
More things that would be good are:

Press more than one at the same time

A bank selector switch that lets you chose between different sets of mp3's that will be played when each pad is pressed.

The ability to download mp3s to each pad and change what each pad will play.

A Looper to let you record short loops, play them back, and overdub (record over the last recording)

Rechargeable battery (via USB) with low battery LED indicator.

Again, I realize that these are ideals, and also that it might be easier to create a custom IC to fit the needs (If anyone knows about where and how I could do that please point me in that direction by the way). But please give me some general direction or outline of how I should go about this, and any tips that might be helpful. Here is my best attempt at a general schematic of my idea. Feel free to dismiss if it is incorrect or unfeasible. Thanks again!

Update: I found a great chip that I think might work for my purposes,the ATTINY861-20pu. I found a project that Plays WAV files off of an SD card. Any Ideas on how to better integrate this chip with the features above?  Heres the Project: http://elm-chan.org/works/sd20p/report.html

Update 2: Drew out a block diagram for a circuit with the Atiny 861, I'm just encoding each pad to binary to control the triggers on the Atiny, whitch plays .wav files from the SD card to the Headphone Amp(LM4910). The bank switch just shifts the binary number up to where I will place a different set of samples on the SD card to be accessed. ----- Problems: Can't press more than one pad at once? How do I load the firmware to the AVR? Will the higher powered PWM output ruin the Headphone amp? Haven't gotten to the looper part yet. Any help or criticism greatly appreciated!

simulate this circuit – Schematic created using CircuitLab


texts: How to avoid Johnson noise in high input impedance amplifier

texts:
I don't have a circuit I'm working on, this is more of a theoretical question - I am trying to remedy a flaw in my understanding.

Imagine I want to build a high input impedance amplifier to work in the low mV range, with a few nV/√Hz noise. I want to amplify a 1-100KHz differential signal. Initially, I would start with a good quality instrumentation amplifier (e.g. AD8421) and just put capacitors in series with both inputs.

But that has a problem.  There is no DC path to ground on the input, so it's probably going to slowly drift away and rail the output.  So I need to add a resistor to ground on each input. See the first circuit in the diagram below. That resistor will set the input impedance of my amplifier, which I want to be about 100MΩ.  But if I calculate the Johnson noise I expect from two 100MΩ resistors I get\$\sqrt{2} \times \sqrt{4k_BTR}\$ ≈ 1.7 μV/√Hz

So I came to the conclusion that I could have low noise or high impedance, but not both.  I then found a commercial input preamplifier which is specified at 3.6 nV/√Hz input noise and 100MΩ input impedance.  I had a look inside, and it seems that they use the circuit on the right.

simulate this circuit – Schematic created using CircuitLab

The two FETs at the right hand side are a matched pair (datasheet from google), and form the first stage of the amplifer.  I didn't reverse engineer any more of the circuit, but I can if necessary.

So my question is: What is wrong with my understanding? Why does the second circuit not have about 1-2μV/√Hz white noise from the resistors?


texts: ATMega32 vs. ATMega32A - one works, that other one not

texts:
I've got a setup with an ATMega32 running perfectly. When replacing the ATMega32 with a ATMega32A, nothing happens any more, not even the crystal oscilator swings. According to the changenote from Atmel, the reset pull-up resistor has a good value and the pull capacitors next to the crystal are also in place.
I tried with many different parts (all from one shipment) of the ATMega32A, always the same behaviour. Changing back to the ATMega32 everything is fine again.

Finally I setup a circuit only with the AVR, reset pull-up, crystal and pull-capacitors. ATMega32 works (crystal swings), ATMega32A does not work (crystal swings not).

Could you think of anything but all ATMega32A I have in the lab are broken?


texts: Other than cost, is there a reason to not use higher rated components than called for by design?

texts:
(Apologies upfront if this question seems too vague, I'm trying to formulate the problem statement as I ask this)

I'm thinking about circuit assembly in a high component variability / low MOQ environment, from the standpoint of passive components. Assuming identical footprints, I'd like to be able to substitute:

Resistors

tighter % tolerance for looser
higher wattage for lower

Capacitors

Higher voltage for lower

What I'm getting at is - if I'm prototyping lots of different designs, parts inventory management becomes a substantial issue. If I could aggregate by component value, and use the same parts where possible, inventory requirements go down, likely enough to offset the potentially higher cost of the individual items.

Does an approach like this work, or would I break designs by doing this? If this works, what other components can I try to standardize?


texts: conversion of single ended audio input to differential

texts:
I am working on a bluetooth module for streaming audio signals. Audio signals coming from audio jacks are single ended,but datasheet of module has mentioned that differential audio signals are recommended.
is there any way to convert single ended audio signal to differential one.
Through internet search, I found this schematic:

Is this method valid for conversion?


texts: Is it possible to monitor analog multiplexer inputs without changing the selector signal?

texts:
If you have 8 analog input sensors (or 2 or 9 or 738479) is there a chip / is it possible with microprocessor programming to actively monitor all of the channels? Say you had 8 rotary potentiometers attached to each i/o pin on the mux, would you have to change the selection inputs every time you wanted to use a different potentiometer? It seems like this would make a mux much less useful than I thought it was. So if I wanted to use the pot on i/o pin 1 and then the pot on i/o pin 8 immediately following the first, I would have to tell the microcontroller / processor to change to reading pin 8 before I could use the peripheral attached to it? Or is there a way to make it monitor all of the i/o pins at once so that I could use the peripheral on pin 1 then on pin 7 then on pin 2 without having to do anything at all regarding changing the io pin being read, so long as I only use one at a time?

CD74HC4051MM96EP is the mux I already have tons of, and I'm using teensyduino (arduino code library) / teensy 3.1 to send midi messages. I'd like to read all kinds of different input sensors.


texts:
I have a question about my EEPROM Project recently started. why there is a maximum of 16-byte is Writing into EEPROM in below code. when we able to writing 64byte into the single page using page write according to the datasheet.  there is any limitation of i2c buffer or page buffer
. For example, the comment said /Theoretically, the 24LC256 has a 64-byte page write buffer but
we'll write 16 at a time to be safe/
what is mean by theoretically? is mean that we can not write the 64 bytes of data at once.
I share code with you. which I take reference from Sparkfun Reading and Writing guide
https://learn.sparkfun.com/tutorials/reading-and-writing-serial-eeproms/all
EEPROM IC -  24lc256
Microcontroller ic - Atmega 32u4 ic
Library - Wire library
//Include the Wire I2C Library
#include <Wire.h>

/*This address is determined by the way your address pins are wired.
In the diagram from earlier, we connected A0 and A1 to Ground and
A2 to 5V. To get the address, we start with the control code from
the datasheet (1010) and add the logic state for each address pin
in the order A2, A1, A0 (100) which gives us 0b1010100, or in
Hexadecimal, 0x54*/

#define EEPROM_ADR 0x50

/*Theoretically, the 24LC256 has a 64-byte page write buffer but
we'll write 16 at a time to be safe*/

#define MAX_I2C_WRITE 16

byte tempStore[MAX_I2C_WRITE];

void setup()
{

//Start the I2C Library
  Wire.begin();
  Wire.setClock(400000);

//Start the serial port
  Serial.begin(19200);

//Here is where we'll keep track of where in the memory we're writing
  long currentSpot = 0;
  long timerReset = 0;
  byte counter = 0;

  //Here we listen for bytes on the serial port and increment
  //the counter as we store them in our tempStore variable
  while (1)
  {
    while (Serial.available())
    {
      tempStore[counter++] = Serial.read(); //Read this byte into the array

      if (counter == MAX_I2C_WRITE)
      {
      //Once we've collected a page worth, go ahead and do
      //a page write operation
        writeEEPROMPage(currentSpot);
        counter = 0; //Reset
        currentSpot += MAX_I2C_WRITE;
      }

      timerReset = millis();
    }

    if (millis() - timerReset > 2000)
    {
      Serial.println(currentSpot);
      timerReset = millis();
    }
  }

}

void loop()
{
    // Don't do anything here
}

/* This is the 3 step memory writing procedure that
we talked about. First, we send the MSB of the address.
Then we send the LSB of the address. Then we send the data that we want to store. */

void writeEEPROMPage(long eeAddress)
{

  Wire.beginTransmission(EEPROM_ADR);

  Wire.write((int)(eeAddress >> 8)); // MSB
  Wire.write((int)(eeAddress & 0xFF)); // LSB

  //Write bytes to EEPROM
  for (byte x = 0 ; x < MAX_I2C_WRITE ; x++)
    Wire.write(tempStore[x]); //Write the data

  Wire.endTransmission(); //Send stop condition
}


texts: Bode is plot despite of high quality factor

texts:
I'm trying to simulate the following circuit in LTSpice:

As can be seen, the Gain
$$ G = 1 + \dfrac{R_3}{R_4} = 1 + 1.6 = 2.6 \Rightarrow Q = 2.5$$
Which should give a peak, but I'm getting following plot:

I've tried changing the value of capacitance and found that if it is higher than 30-40pF, there is a peak.
How this behaviour can be explained?
I've checked this question but as per the answer I should get a peak, since the damping ratio is lower than 0.707.


texts:
I have an IR LED which is switched at a rate of 32.768kHz from an oscillator circuit (relevant portion shown below). I have 10 prototype PCBs. 30% of them work while the others don't. The problem is not the oscillator itself but the output stage.

On the boards that don't work, the waveform at TP7 (base) is a very nice square wave. So, the oscillator is working just fine. Measuring across R5 (TP1 to TP6) I can see that the bad boards conduct but don't switch. In other words, the LED output does not oscillate with the input at the transistor base.

Any thoughts to what the problem might be? I am well under the maximum switching frequency for that particular BJT. Also, my base resistor should put me well into saturation.

One thing you can't tell from the information below is that this is a battery driven circuit (CR2032). Due to its relatively high internal resistance the current through the LED with a fresh battery never exceeds ~ 100mA. So, R5 really isn't necessary. It's simply there so that I can test from a power supply. The battery is also 'switched in' as noted in the second image.

Any thoughts?

EDIT:

Here is a waveform at the base of the transistor Q2:

Here is a waveform across R5 on a good board:

Here is a waveform across R5 on a bad board:

Here is the battery voltage on a good board:


texts: AT28C256 Page Mode Write Waveforms in datasheet

texts:
I read the datasheet for the AT28C256 EEPROM and in the page mode write section there is the following diagram.

Where \$ \overline{OE} \$ line is always in the HIGH state during operations whereas in the note (2) it says that it should be HIGH only when \$ \overline{WE} \$ and \$ \overline{CE} \$ are both LOW.
So I'm a bit confused, what am I missing?


texts: Why do microcontrollers have so little RAM?

texts:
Maybe this is more of a perceptional problem, but it seems like microcontrollers have advanced by leaps and bounds in the last 20 years, in almost all regards, higher clock speed, more peripherals, easier debugging, 32-bit cores, etc...

It is still common to see RAM in the 10's of KB (16/32 KB).

It doesn't seem like it could be an issue of cost or size directly. Is it an issue of complexity with the RAM controller above some threshold?

Or is it just that it isn't generally required?

Looking over a parts matrix at a popular Internet supplier, I see one Cortex M4 with 256 KB for less than US$8, and then for a few dollars more you can find a few more that are ROMless, but it seems pretty sparse...

I don't exactly have a need for a microcontroller with a MB of volatile storage, but it seems like somebody might...


texts: How to efficiently power and arrange 100 multi chip LEDs in 6 different colors each color runnig off their own transistors

texts:
First time on here hope I have given sufficient information. I am trying to power 100x 5W high power multi chip LEDs and 8x 3W high power LEDs. I would like to do so off of 120v Ac house plug. The thing is that there is 6 colors and each color group has its own NPN transistor so it can be control with a microprocessor to dim or turn off/on. There is two heat sinks each with 50x 5W LEDs and 4x 3W LEDs.

On each heat sink there is:

  24x red1
  6x red2
  4x red3
  10x blue1
  5x blue2
  5x white

The led specs.

  red1 650-660nm
    4-6v 700mA
    225-270Lm

  red2 620-625nm
    4-6v 700mA
    225-270Lm

  red3 730-740nm
    3.5-3.8v 700mA
    20-30Lm

  blue1 450-455nm
    6-8v 700mA
    90-135Lm

  blue2 460-465nm
    6-8v 700mA
    90-135Lm

  white 15,000-20,000k
    6-8v 700mA
    500-550Lm

I know that I need to wire the individual color groups in a parallel and series configuration to raise or lower the forward voltage and/or current so I can have a practical power supply. The thing is I don't know how to figure the best configuration to gain the most optimal power. It's not that I do not get the math calculations. It's that the complexity of compounding factors is throwing me for a loop. The factors being:

it pulls more power then the wall plug can give so then do i use a step up converter after the transformer and bridge rectifier?
or what power supply should i use?
or  will i have to use more then one power supply to get the right power rating for each color group?
or can I group all the color groups so that i can give all the transistors the same power?
all with keeping low cost and energy efficiency and keeping the power supply small as possible.


texts:
I wrote a simple C program for STM32:
main.c
  while (1)
  {
      HAL_GPIO_WritePin(GPIOD, GPIO_PIN_15, GPIO_PIN_SET);
      HAL_Delay(400);
      HAL_GPIO_WritePin(GPIOD, GPIO_PIN_15, GPIO_PIN_RESET);
      HAL_Delay(400);
  }

it.c
void EXTI0_IRQHandler(void)
{
      HAL_GPIO_WritePin(GPIOD, GPIO_PIN_14, GPIO_PIN_SET);
      HAL_Delay(1000);
      HAL_GPIO_WritePin(GPIOD, GPIO_PIN_14, GPIO_PIN_RESET);
      HAL_Delay(1000);

  HAL_GPIO_EXTI_IRQHandler(GPIO_PIN_0);
}

There is no problem when there is no delay interrupt; it enters ISR and exits.
But when delay interrupts,
the program gets stuck at delay ().
My RCC settings are correct.


texts: How to calculate the bandwidth of a synchronous bus with overlap in bus transfer and reading next data?

texts:
I am working through problems in Saylor Academy's computer architecture course. I can't understand how this kind of problem is solved:

Consider a 32-bit synchronous bus with f = 125 Mhz, an 8 nsec clock cycle (CK), send address/data takes 1CK each, 2CKs between bus operations, a memory access time of 200 nsec, bus transfer and reading next data overlap, block size 8 words. What is the bandwidth for 256 4-byte words to be transferred across the bus?

The given solution:

The BW calculation is as follows: 256/8 blocks gives 32 total transactions. Each memory access takes 200/8 = 25 clock cycles. Send data/address + idle time is 8 clock cycles for a total of 34 clock cycles including 1 clock cycle for the initial memory read.....

I could not understand this:

Send data/address + idle time is 8 clock cycles

I expect that it would be 1 cycle for send data, 1 cycle for send address and 2 cycles idle time, for a total of 4 cycles. Why is one cycle required for the initial memory read?


texts: Is it possible to sink and source from one output pin using a darlington driver

texts:
Sinking and sourcing with a darlington driver

I asked a question about sinking and sourcing LEDs while using a darlington driver. The images were slightly unclear so i have redrawn it. I had too many LEDs in my circuit so i needed to create a relay. I am going to use a darlington driver and when i was testing it, i was fine with all other 7 outputs. However, I am unsure how to be able to sink and source LEDs from 1 output pin while using a Darlington driver

My project is a traffic light. I have 8 available outputs. I have 9 groups of LEDs. Currently there is 5v availible for the LEDs. The maximum number of leds per group is 8. I also have a loudspeaker and a motor in there. Please see comments for LEDs data sheet

ww.picaxe.com/Circuit-Creator/General-Outputs/Darlington-Driver-ULN2803A/

That is the link for the Darlington Driver i am using which is represented by the 18 - DIL

Is it possible to sink and source at the same time with the driver?

I only have 8 outputs and i realised that either the green man or the red man can be on at the same time. So to maximise outputs i sunk the red LEDs and sourced the green LEDs. However, I realised i had too many LEDs to work with a 5v PIC, so i needed to create a relay


texts: How do I charge this odd 4S Li-ion circuit?

texts:
I am trying to make a battery pack that will power my electronics.
I need to make +7V and -7V. The +7V needs to have a decent amount of capacity.
I have proposed a 2S6P circuit for the +7V supply with a 1-Ohm STAR resistor network to balance the midpoints.
To make the -7V I just tacked a 2S circuit below ground.
To make things complicated each cell has a Battery protection IC BQ2970 to prevent reverse polarity insertion, short circuit protection any many other things.
So each cell in the schematic is actually representing Pack+ and Pack- in the second picture
I am designing my PCB to include a charger option. How do I go about charging this?
Is there an IC or circuit anyone can recommend?


texts: 3V3 uC input protection from higher voltage?

texts:
I wanted to confirm some of my suspicion on this particular matter.
This is a part of a switching circuitry with a button.
I derived this circuit from a circuit divider to make this part of the switch work under lower voltages (button tolerates <20V across). So the button enables the MOSFET switch. Yet I need to monitor the state of the button and thus have protected a uC inpt from the gate with a schottky diode.

simulate this circuit – Schematic created using CircuitLab

I can measure gate voltage from the voltage divider on the planned uC input pin node. The idea of the shottky diode was to protect the input from those 'high' voltages but ofcrs could be measured on that node (currently floating).

Should I consider input protection (such as a zener) to limit the voltage on that pin ? Although there's potentially low currents there (due to reverse current of the diode).


texts: STM32 TIM2 changing prescaler in IRQ handler works strangely

texts:
I am trying to change a prescaler in the timer interrupt handler, and I expected the new value would become active for the very next timer delay. I mean that after the handler exits, the timer will immediately run using the new prescaler value.
But what happens is that the next delay is the same as previous, then the updated prescaler is first used for delay after that. So, it looks like if I set prescaler value not for the next delay, but for the second one.
I would like to understand this strange behaviour and how can I change it.
I have tried with both 1 and 0 ARPE bit values in TIMx_CR1 with no difference.
Thanks in advance for your help!
P.S. I am using STM32F103C8T6 (black pill board).
General-purpose timer TIM2, and I use STM32F1 RM0008 Reference manual as a main resource.

Update: June 28, 2020
OK, I found it. I don't understand why and how it is working now, but I have found a way it works.
Here is a pseudocode of IRQ handler that did not work (works strangely):
reset UIF bit of TIMx_SR        (clear IRQ flag)
set UIDS bit of TIMx_CR1    (disable update)
write new prescaler value to TIMx_PSC
set the UG (Update generation) bit of the TIMx_EGR
reset UIDS bit of TIMx_CR1  (enable update)

and here the handler that works correctly (as I want it to):
reset CEN bit of the TIMx_CR1 (disable counter)
write new prescaler value to TIMx_PSC
set the UG (Update generation) bit of the TIMx_EGR
reset UIF bit of TIMx_SR        (clear IRQ flag)
set CEN bit of the TIMx_CR1 (enable counter)

If someone could explain what is the principal difference, and why the wrong one is wrong, it would be great. I am still standing on the hose.


texts:
I am looking for a component, with the main criteria being very low to no power consumption when it is not detecting anything touching it.

It should be able to pick up something as light as 10 grams simply brushing it.

If there is something like this what is it called?


texts: Why does my router have a power on/off switch?

texts:
I have to develop a consumer product for home automation. We initially wrote a requirement to have a on/off switch, but after a second thought we realized that hard-reset can be done by simply unplugging the device.

This lead to another question. Why customer products such as routers or Hi-Fi products usually have a useless on/off switch?

Is there a standard behind that?


texts: How can a time limited signal be of infinite bandwidth and a finite bandwidth signal be of infinite duration?


texts: High Voltage Surge From CNC Router Spindle

texts:
I am thinking about building a cnc router with an ebay 400w spindle and the motor of choice.
My question is, will any significant high voltage surge be created by the motor that could possibly fry a regulated power supply such as a psu? If so, is there a way to prevent this from happening?


texts: How to pick a capacitor to adjust loop compensation caused by reactive load?

texts:
I do wish to add a voltage regulator between a Li-Ion battery pack and a 36V 220W rated mid drive pedalling assist motor with integrated controller. The caps of that controller have a 63V rating.
That pedal-assist motor has an unloaded current draw of 0.823A. The motor is (or at least seems to be) a reactive load. Such loads may cause instability at Vout of the switching buck-boost DC converter.
In this (LM5176) case, 1 out of 12 parallel ceramic 100V 4.7 uF input capacitors, the capacitor closest to the MOSFET/inductor was shorted (desoldered Cin10 in the image) the instant I did start pedalling. In several hours of resistive e-load testing the circuit ran fine. For this instability reason I do wish to compensate the loop.
I was told that a large capacitor with proper ESR at the output rail can serve as a damping factor to cope with the reactive load.
How to pick a good large reactive-load-damping capacitor and where to place it in the schematic (close to Vout, or close to the MOSFETs)?

BOM

Rvisns 1.98kΩ ERJ-6ENF1961V
Cboot1,Cboot2 100nF ESR=1mΩ C0603C104M3VACTU
Cbulk 68uF ESR=320mΩ EEV-FK1K680Q
Ccomp 39nF C0603C393K5RACTU
Ccomp2 750pF C0603C751J5GACTU
Ccs 47pF ESR=147mΩ 06035A470JAT2A
Cf 100nF 06035D104KAT2A
Cin1, Cin2 15uF ESR=40mΩ 100V 100SXV15M
Cin3…Cin14, Cout1…Cout15 4.7uF ESR=4.236mΩ 100V CGA6M3X7S2A475K200AB
Cout16…Cout18 33uF ESR=25mΩ 63V 63SXV33M
Cslope 1.2nF CL10C122JB8NNNC
Css 22nF C0G GCM21B5C1H223JA16L
Cvcc 1uF GRM188R61C105KA93D
Dboot1 10A 0.91V MBRD10200CT-13
Dboot2 20A 100V 0.455V STPS20M100SG-TR
Df 100V 1.0A 1.05V STPS1H100A
L1 10uH SER2915H-103KL
M1,M3 80V  BSC037N08NS5ATMA1
M2 150V 50A BSC190N15NS3GATMA1
M4 100V 5.3mΩ CSD19531Q5A
Rcomp 4.64kΩ ERJP03F4641V
Rcsg,Rcsp 100Ω
Rf 10Ω
Rfbb 20kΩ
Rfbt 1.1MΩ
Rpg 10kΩ
Rt 86.6kΩ
Ruvb 9.31kΩ
Ruvt 249kΩ
Rmode 93.1kΩ
Rsense1 62mΩ // Rsense2 5.1mΩ -> Rsense 4.7112mΩ

Schematic


texts:
I've an electronic drum machine - which involves electronic drum pads with piezoelectric transducers in them (which pick up you hitting the pads with your drum sticks) which feed into a magic drum machine brain that senses when your cranking out some beats!

I want to feed two of these pads into a single input, which I have tried by simply linking the cables that come out of the transducers in parallel. The sensitivity of the drum pads seems to plummet and they don't work half the time if this is done.

I was wondering it there's something about piezo transducers I need to do to stop them interfering with each other's output. I wondered if one was acting as a resistor to the signal produced by the other (almost acting as a speaker) and damping things down, or are they acting as capacitors to each other? Do I need to stick a diode between each of them or something! I'm not sure and the info I've read hasn't helped much.

Hoping you have some advice, thanks :)


texts: How to lower the RPM of a motor without using PWM or gears?

texts:
I need to lower the RPM of a simple DC motor to almost 20 - 30 RPM for some reasons. I cannot use PWM signals or gears to lower the RPM of the motor (I know how to use them but I want a simple solution.)
Is there any other way that I could slow down this motor? I tried to lower the voltage going to the motor using resistors but it didn't work (for me at least, I connected the resistor between the motor's one wire and the positive terminal of the battery supplying 3 volts. Let me know if I did something wrong.)
I don't care about torque that much so it's not a problem if I lose some torque in the process.
Hoping for a trick that could slow down this motor without using PWM or gears.


texts: How to tell how sensitive a photodiode is?

texts:
I am looking to buy some new photodiodes for a project. Currently, I have been using expensive photodiodes with a picosecond level rise and fall time and a very small area to pick up light. The problem is that I am not getting much light into the photodiode so the readings are quite low and need to have more of a range.

I was just wondering what the measurement for how sensitive a photodiode is and if anyone has any good ideas for near-infrared (800-850 nm) photodiodes which are extremely sensitive so have a large range from not much light which is what I need.

This is the type of photodiode I am looking for

Any ideas?


texts: Can I use a 5% tolerance resistor instead of a 10% tolerance resistor?

texts: can I use a 5% tolerance resistor instead of a 10% tolerance resistor? It is for an organ from the 60's. All resistors stated in Schematics are 10% 1/2 watt. But I can't find a 6.8k 1/2watt 10% tolerance resistor anywhere. All the resistors in the organ are carbon based.


texts: Why the phase response of a series RLC circuit plotted against frequency goes from 100 to -100 degree?

texts:
simulate this circuit – Schematic created using CircuitLab

The transfer function which is $$\frac{Vo}{Vi}=\frac{R}{R+j(\omega L-\frac{1}{\omega C})}$$

The phase is $$-arctan(\frac{\omega L-\frac{1}{\omega C}}{R})$$

My question is why is the phase going to 100 degree when $$\omega<<\frac{1}{\sqrt{LC}}$$? How can you see it from the phase equation?

The phase equation can re-writtened as $$\frac{\omega^2LC-1}{\omega RC}$$. When omega^2LC<<1. the phase is basically $$-arctan(-\frac{1}{\omega RC})$$. Why is this equal to 100 degree?


texts: Discharging all energy of one battery into another

texts:
I was wondering how discharging all the energy from one 18650 Lithium-Ion battery into another 18650 Lithium-Ion battery would be achieved.  So far I’ve consulted using MOSFETs, DC to DC Converters and current sources/sinks without avail.

The whole circuit I’m attempting to achieve is a circuit that can fully charge battery 1, and then transfer all of the energy (less any losses) from battery 1 into battery 2.

Any direction or reference papers would be appreciated.  Thank you.

Edit: Will update with more details shortly.
The end goal is to have a battery testing circuit that does not entirely dependent on the energy from a wall adapter.  The circuit will also be testing for battery voltage, charging current and temperature among other things.

So far I have a discharging circuit to discharge both batteries and a charging circuit to charge one of the two the two batteries. The transferring of energy from battery 1 to battery 2 is the essential step I’m currently working on.

Thanks again for all the insight it’s has been a huge help.


texts: Whats the justification to determine the phase sequence?

texts:
I have been told many times that one way to determinate the phase sequence of a three phase system is to use two resistances and one capacitor (or inductor) in star (wye) connection, then connect two voltmeters across the resistances and watch the one gives more voltage like:
\$V_{R1}>V_{R2}\$\$=ABC\$
\$V_{R1}<V_{R2}\$\$=ACB\$

simulate this circuit – Schematic created using CircuitLab
But I was never told why is so? So someone could give me a reference?
Thanks


texts: Two DC DC converter with different output - In series or parallel?

texts:
Source: LiPo Battery (13V - 16.8V)
Consumer #1: 5V (RaspPi) ~1A
Consumer #2: 12V (variouse) 0-3A (plus ~1A if series)
DC/DC step down: two LM2596

Which would be the better solution:

LM2596 #1 on LiPo (16.8V to 12V out)
LM2596 #2 on LiPo (16.8V to 5V out)

LM2596 #1 on LiPo      (16.8V to 12V out)
LM2596 #2 on LM2596 #1 (12V to 5V out)

What are the pros and cons in term of efficiency, and voltage stability?

Datasheet of the dc/dc converter,

Max output current is 3A .
The battery can provide a discharge rate of 35c at 10Ah
Efficiency diagram is on page 6.

Note:
The 12V output might be used to supply 12V/3A to a battery charger (Yeah, charging a liPo with a liPo,.. thinks that happen in RC-hobby).
So the drawn current on the 12V out could raise by 3A instantly.
So yeah, right now I see the issue with the serial concept, I'd limit my charging current to 2A instead of 3A.
But are there other pros and cons?


texts: Is there any difference in effectivity between the following two layout examples of an RC Filter? The first has the signal passing directly through the capacitor, while the second has the capacitor offset below the resistor.


texts:
I have a power outlet without a ground, but I have an electronic device which requires a real ground (can't use a GFCI protected outlet). Would it be okay to run an extension cable from an outlet which is grounded, and use the ground off that circuit with the hot & neutral wires from this outlet without a ground.

Is this unsafe?


texts: How can I get a loud noise out of a 15mm piezo disc?

texts:
I need to get an as loud as possible noise out of a 15mm piezo disc, using only the 3V from Arduino.

I know I will have to make some sort of amplifier circuit, and I have attempted to make a basic one but I don't really know what I'm doing as I'm new to electronics.


texts: Atmel AVR XMEGA-A USART MPCM (Multiprocessor communication mode) configuration with ASF 3.33

texts:
I'm using two XMEGA256-A3BU's on XMEGA-A3BU Xplained boards. My goal is to make MPCM (Multiprocessor communication mode) possible between the two using their USART in synchronous mode.
They are physically connected so that the master's PC1 (SCL), PC2 (RXD) and PC3 (TXD) are connected to the slave's PC1 (SCL), PC3 (TXD) and PC2 (RXD) respectively.
I use ASF 3.33's "USART - serial service" to make the communication work.

Master's initialization code:

static usart_serial_options_t usart_options = {
    .baudrate = 1200;
    .charlength = USART_CHSIZE_8BIT_gc,
    .paritytype = USART_PMODE_ODD_gc,
    .stopbits = false
};

sysclk_enable_module(SYSCLK_PORT_C, PR_USART0_bm);
usart_serial_init(&USARTC0, &usart_options);

usart_set_mode(&USARTC0, USART_CMODE_SYNCHRONOUS_gc);

// Pin to set as output for clock signal.
ioport_configure_pin(IOPORT_CREATE_PIN(PORTC, 1), IOPORT_DIR_OUTPUT);
// Port to output clock signal on.
PORTCFG.CLKEVOUT = PORTCFG_CLKOUT_PC1_gc;

usart_set_rx_interrupt_level(&USARTC0, USART_RXCINTLVL_OFF_gc);
usart_set_tx_interrupt_level(&USARTC0, USART_TXCINTLVL_OFF_gc);

Slave's initialization code:

static usart_serial_options_t usart_options = {
    .baudrate = 1200;
    .charlength = USART_CHSIZE_8BIT_gc,
    .paritytype = USART_PMODE_ODD_gc,
    .stopbits = false
};

sysclk_enable_module(SYSCLK_PORT_C, PR_USART0_bm);
usart_serial_init(&USARTC0, &usart_options);

usart_set_mode(&USARTC0, USART_CMODE_SYNCHRONOUS_gc);

// Pin to set as input for clock signal.
ioport_configure_pin(IOPORT_CREATE_PIN(PORTC, 1), IOPORT_DIR_INPUT);
// Do not output the clock signal.
PORTCFG.CLKEVOUT = PORTCFG_CLKOUT_OFF_gc;

usart_set_rx_interrupt_level(&USARTC0, USART_RXCINTLVL_OFF_gc);
usart_set_tx_interrupt_level(&USARTC0, USART_TXCINTLVL_OFF_gc);

I use usart_serial_putchar(&USARTC0, buffer[i]) and usart_serial_getchar(&USARTC0, &buffer[i]) to send and receive data for testing, the final design will use DMA.

In order to make MPCM work (and make it possible to add more slaves to the bus), I know that I need to switch to the 1 start bit + 9 data bits + parity + 1 stop bit format, and I also know that somehow I should use these constants I found in iox256a3bu.h file:

#define USART_MPCM_bm  0x02  /* Multi-processor Communication Mode bit mask. */
#define USART_MPCM_bp  1  /* Multi-processor Communication Mode bit position. */

Could someone help me out with some ASF sample code? What should I add to set the slave's own address, and where should I define on the master who I'm intending to send the message to?


texts: How to imagine the mathematical expression in the waveguide

texts:
bellow we see an example expression for the E-field.it has three components:
1.polarization of the field
2.propogation direction
3.standing wave pattern.
In the phot bellow of the field "L" has standing wave pattern ,"H" is polarisation.
So "W" is the direction of propogation of the wave?
Thanks.


texts: Updating all components from a schematic library to schematic sheets with Altium instead of individually?

texts:
As title suggests just wondering if there's a way to do this, like specially in case if I ever import this library to another project and want to update all my schematic components rather than having to update them 1 by 1 through the SCHLIB tab.

My Altium version is 19.1.6, and am looking to use the Update Schematic sheets function when you right click a SCH Library component, but to do more than one at once.


texts: Why does the output voltage of an alternator increases when it is connected to Capacitive load?

texts:
Why does an alternator output voltage gets higher when it is connected to capacitive load than it was with a inductive or resistive load?

I understand that when a capacitive load is connected it improves the power factor. But how does power factor increases output voltage?

Is there any resonance effect when a capacitive load is connected? And if so how does that affect the output voltage?


texts: How does resistance, voltage and current work in a circuit with a small load

texts:
If I intend to run an LED with a 5V source voltage and an LED forward voltage of 2V at 20ma it is my understanding that a 150 ohm resistor is suited.

I get this from using the formula V = IR rearranged to R = V/I.
R = 3/0.02
A 3V voltage difference at 20ma.

This works in practice as well, the LED is well lit and I get the forward voltage and current I expect when measured.

How exactly are these concepts related? It is my understanding that at at V voltage with R resistance, a maximum of I current will be allowed through. Is my understanding of these concepts over simplified or valid?


texts: When analyzing an electrical circuit, and in the occurrence of an impedance mismatch between the supply voltage and the load (connected through a cable) + a high switching frequency, reflection phenomena take place and surges are noticed. What is the frequency of the surge voltage?


texts:
I have a 0-16 bar pressure probe connected to a module called Adca UD-720. The probe works on a 4-20 mA loop and the readings are ok. This module also has a 4-20 mA output and I need to connect this output to a data acquisition module in order to get the readings remotely. But when I connect the output to the module, the module goes into protection mode. When I measured the output I couldn’t read any current, but I got a 14.7 voltage, which is way too high. The module can only support an input up to 10 V.

So, how can I reduce the voltage below 10 V, and still be able to read the current?
i was thinking to use resistors, but i do not know what resistors to use.

thanks.


texts: Would a 100k ohm resistor or motor emit more heat

texts:
Would a 100k ohm resistor produce more heat than a motor that had the same resistance?

+|---------(100k ohms)---------|-

+|---------(100k motor)--------|-

Both circuits have the same amount of current running. Which produces more heat?

Note

One of these circuits is converting electrical energy to mechanical energy as well as heat.

The exact same amout of current is running in either circuit.

The motor is designed to maximize mechanical output.


texts:
a. Is it possible to run a 230v three phase motor with a 115v input VFD?  Where does the other 115 volts come from in this case?

b. How would I size the VDF for this case.  I know my VFD will need to rated higher than the the FLA of my motor but by how much?

Thanks


texts: Why is the the uart_rx _interrupt is not triggering on a PIC32MX775F256H?

texts:
void __ISR(_UART1_VECTOR, ipl6) IntUart1Handler(void)
{
    if(!INTGetFlag(INT_U1RX))
    {
        g_intraised++;
    }
    IFS0bits.U1RXIF=0;
}

uart initialization  code

    U1BRG  = 0x0A;                                // baud rate 115200
    U1MODE = 0x8080;                              // set the ON bit and
    U1STA  = 0x5400;                             // set the transmit bit and
    IEC0   = 0x08000010;//0x18000038;           // interrupt receive bit
    IFS0   = 0x18000010;//0x18000038;           // interrupt receive flag
    IPC6   = 0x0000001F;


texts: Reading multiple RFID tags at the same time

texts:
Hi I've been working on a personal project for which i need to read multiple RFID tags in close proximity, something like 10-20 tags at once, I know RIFD tags can't be actually be read at the same time, fast reading still works for me tho. However I'm having an hard time figuring out if what I want to do is feasible or not.
I've read about ISO14443A tags and that they should work with the RC522 RFID Arduino reader, however it's reading speed is slow.
I have no need for a long reading range, quite small actually, all my tags are disposed separated from each other and in contact with the reader, never stacked.


texts: Voltage regulator STBY & OFF - whats the difference?

texts:
I am looking at MAX883 voltage regulator and from the documentation is not very clear whats the difference.

It says this about pin OFF:

  In this mode, the pass transistor, control circuit, reference, and all biases  are turned off

And this is writen about STBY:

  feature that disconnectsthe input from the output when STBY is
  brought low, but keeps all other circuitry awake. In this mode,
  V_OUT drops to 0, and the internal biasing circuitry
  (including the low-battery comparator) remains on.

I understand that there are different elements of the regulator shut down, but I don't understand if the OFF would actualy turn "too much things off" in my usecase:

Using battery (4xAAA for testing for now) for power supply for membrane which is strictly operating on 3V +-0.1V. Therefore I need to hold the voltage at about 3V and when the egulator starts to drop under 2.9V it needs to be shut down to prevent any damage.


texts:
is it possible to change Circuit Diagram for the following example: http://www.redcircuits.com/Page146.htm or https://www.youtube.com/watch?v=mrxdiO1b29A

Original: 4 short flashes stay on light

Modified: 1 short flashes stay off light

If it's impossible to change Circuit diagram for my needs, do you have any Circuit diagram for the specified change?

I'm sure there's a scheme for my question, but my electronics knowledge is low. Therefore, I do not know what should be used in search for my answer.

Thanks.


texts:
I'm currently stuck on my project as I'm not sure what to do with PWMing my pump as I want to adjust the pressure.

I will be using an Arduino for PWM. The pump  is 60W @ 230V 50Hz mains and is a vibratory pump, it has a built in diode so it only sees half of AC signal.

My question is would this circuit work? Do I need to add additional passive components? I think I do, but I don't know what or where should I add them.

Thanks in advance!


texts: What is meant by VCES in a transistor electrical specification?

texts:
I am studying the STMicroelectronic BUL216 NPN power transistor. Electrical specification like VCES is given by the Specification Sheet BUL216 Datasheet. Also, the VCEO spec. Both spec has to do with how much high voltage the transistor can withstand before breakdown. Specifications are marked as follow:

Symbol     -   Parameter  -   Value   -   Unit
VCES    -  Collector-Emitter Voltage (VBE = 0) 1600 Volts
VCEO    - Collector-Emitter Voltage (IB = 0) 800 Volts

Technically speaking, what exactly is the difference between VCEO and VCES ?
And what are the exact definitions ?
I also found on the WEB an old Fairchild 1973 Data Book which states that VCES would stand for "Collector to Emitter Saturation Voltage", typically 0.2volt.
Obviously, these two specifications are totally different.
Can anyone clarify those information ? Appreciate your help :)


texts:
I am currently using an STM32F4xx and extracting an already compressed JPEG from a camera module OV5645 as that particular sensor has an internal JPEG codec. I want to starting using a new sensor, OV8865, that does not come with the internal codec and I wonder if it is feasible to use a STM32 MCU in order to extract the RAW RGB and encode it into a JPEG getting at least 2 frames per second. I can't use the Digital camera interface (DCMI) for STM32 MCUs built into the STM32F4 as the maximum input size is 2048 × 2048 pixels and I'd like to use at least the resolution of 2816 x 1584 pixels the sensor offers (although 3264 x 2448 would be better).
Is there any estimation on how long it would take to a Cortex M4 such as STM32F4xx to encode a 2816 x 1584 or a full 8MP image (3264 x 2448).
I wonder if a MCU is enough for 2 fps.
Do you know any comercial IC that encodes RAW RGB into JPEG? I guess I could design an FPGA but it will be out of the scope of the scale of the project.


texts: Exact meaning of the issue mentioned on Errata document

texts:
I am using PIC18F67K40. When I went through the Errata datasheet I found out that I am using A3 revision Device.
There is an item number 5.1

Can somebody explain to me what is the exact meaning of this?

I have added snap below


texts: Conversion of a signal to digital pulses

texts:
The following signal is presented to me, and will vary in freq, but not amplitude from 10Hz up to around 25 KHz.

Any ideas for a simple circuit that will convert this into a clean 3V3 square wave for feeding into an MCU? Ideally, avoiding phase shift as freq increases (though not as important.)

I am thinking of some sort of schmitt trigger with a large hyst and 1v/3v cross over points, but open to suggestions!

It should also have some noise immunity being an automotive environment.


texts:
I have an interest in "alternative" logic gates, as in not silicon transistors. I have built RAM in a little game called "Powder Game", constructed "one-off" logic gates out of exploding lattices of popsicle sticks, and used electromechanical devices such as motors and relays. Right now, I'm intensely interested in magnetic cores. I would like to somehow experiment with these myself, but short of purchasing the equipment to do so, I haven't found a way. I am hoping that there is, perhaps, a free piece of software that would let me experiment with trying to make logic with magnetic cores. Can anybody help me find one?

Here is a PDF to describe what I am talking about:
http://ieeexplore.ieee.org/stamp/stamp.jsp?arnumber=04051986


texts: Leaving Arduino Kit in the car, in summer (40+~), do i need to tell the customers?

texts:
Arduino kits containing the following, stored in a plastic box:

Sensors
Male to male wires
The actual arduino board
other usual components such as resistors etc...

Leaving it in the sun for a day or two in a car, where temperature outside is 40c~, would it do any damage? is it necessarily to tell customers that the kits were stored or forgotten in such an environment?


texts: RFI protection for a stepper motor controller

texts:
I'm building a remote tuning device for a magnetic loop antenna. It will use a stepper motor to turn the shaft on the mag loop's variable capacitor. The electronics will consist primarily of a microcontroller and a stepper motor controller. Control and power will be provided through a shielded twisted pair cable. One twisted pair will carry a half-duplex RS-485 signal at a low baud rate. The others will carry DC power and ground, somewhere around 7 – 12 volts depending on which motor I choose. I have a draft schematic here.

The transmitter must be on during tuning, so this device will be next to a source of around 5 – 10 watts of RF at 7 – 30 MHz. There is no RF circuitry inside the box and I would like to keep out stray RF as much as possible. I have never done a project like this before so I have a number of questions about making it robust to RFI.

Should I build this inside a metal box? And what connections should exist between the chassis, the control cable shield and the DC supply ground inside that cable? Should I ground the shield at one end or both?
What kind of protection do I need on the power and control lines? I have TVSes on the power supply, as well as both RS-485 lines (using a SM712, designed specifically for this purpose). I put a ferrite bead on the power line as well (but I'm unsure how to choose a specific part) and I have plenty of bypass capacitors. There are also 10 ohm resistors in series with the RS-485 lines to prevent damage due to overcurrent for whatever reason. (I realize this creates a RC low-pass filter with the line capacitance, but I believe this won't be a problem with the low data rates I'm using.) Is there anything else I'm missing?
I'm using a very basic RS-485 transceiver chip; should I switch to an optically or galvanically isolated part? Am I correct in thinking this would be pointless without an isolated power supply? In my current design the sender and receiver share a power supply and will not have a ground offset.
What PCB layout rules do I need to follow, besides "use a ground plane" and "keep traces short"?

Any other advice on making this work well would be greatly appreciated! Thank you.


texts:
I'm in the process of sizing some toroidal ferrites. My problem is that I am seeing the AL value on the datasheets shown two different ways as nH/N² or nH/T².

Are these two units identical? I believe they are, being that N and T both stand for "turn".


texts: Re{ } component of a phase defined function

texts:
I'm attempting to evaluate $$f(t)  = 2Re\left[(e^{j\omega t}) + \left(2e^{-j2\omega t}\right)\right] - 2$$

Would $$f(t) =  2\cos(\omega t) + 4\cos(2\omega t) - 2$$?

What would the Im[] of the same function be? When will I resolve to using \$\sin(\omega t)\$ instead of cosine? Is the \$e^{-j\omega t}\$ not \$\sin(\omega t)\$?


texts:
I'm trying to solve a problem below.
I've already solved (1), but not (2) yet.
The term 'lowpass equivalent' means 'complex envelop' in this textbook.

And this is solution of problem(2)

Where does the expression

come from?
I think the correct expression is


texts: Is there a shorter or L-shaped version of PowerPole connector? if not, is there an engineering reason why not?

texts: I've not worked with this connector in many years.  I'm working with a robotics team and these connectors are very long and bulky and take up [more, think] space [than they need to ].  I'm trying to find a shorter or L-shaped version. Have found none, wondering if I missed it or if there is an engineering reason why they can't be made that way.


texts:
I intend to serialise two DC power supplies (12V/16A and 36V/1A) to achieve 48V.
Q1: how much current can I draw from such a combination? 1A, 16A, 17A...?
Q2: I understand that grounds must be isolated on the DC side, does this apply to the AC side of the PSUs? (Earth/ground or neutral?)


texts: Why is the range on my IR emitter extremely low

texts:
I have built a simple prototype for a circuit attached to a Wemos D1MINI for a DIY thermostat application. I've confirmed that it works (I can turn it on and off from my software), when I hold the breadboard (and thus the LED) very close to my a/c (less than 1 m) but any further and it fails to register.
Unfortunately I'm very new to this but will try to describe my situation as best I can.
The IR led being used is this, I have had no luck finding a datasheet https://www.amazon.co.jp/-/en/gp/product/B07W4JP1YR/ref=ppx_od_dt_b_asin_title_s00?ie=UTF8&psc=1.
Could a different wavelength LED result in a significantly different range? Or do I just need to fashion up some kind of reflector box? As is it's extremely sensitive to direction. Is this all a problem with the LEDs I have or is there something else I can improve? The radiation distance was supposed to be 7 m but I'm getting a meter at best. I'm not really sure what I should be considering when selecting an LED for this application
The other components are an S8050 NPN resistor with the base connected(via 10 kohm resistor) to the D1MINI D2 pin and the collector going to the LED (and 220 ohm resistor which I've added back since taking the photo), the DHT11 in the photo is working fine and not really relevant to the question. Everything is powered(temporarily) off a 9 V battery through a HW-131 power supply set to 5 V.
I have also recreated the circuit without the d1mini, just the npn, resistors and led and I'm getting 1.26v and 22mA over the LED, which should be the correct amounts.
lolin sells an IR shield(which I wanted to avoid using due to size) for the d1mini, which includes https://www.onsemi.com/pdf/datasheet/bss138-d.pdf . This advertises itself as minimizing on-state resistance. A comment has mentioned how the large resistor could cause lag. Would it be reasonable that this lag would be made worse by distance, thus something like this could fix it?
By combining several suggestions from comments this now works.

The transistor base resistor was reduced to 1Kohm and had a 1K pull-down resistor added to ground.
The LED resistor was removed entirely, resulting in a higher voltage passing through. This however isn't damaging since the IR signal is very short and is also pulsed at a 50% load.

I still don't entirely understand why this works but I presume it's a combination of higher voltage-> stronger signal and the pulldown resistor cutting it off faster, is this reasonable? Are there any resources I can review to better understand this?


texts:
I am using the MCP3248 4 input ADC with built in PGA and reference in a design and have determined that it has a small gain error versus a precision volt meter.  The error is within the tolerance from the datasheet.  The strange part is that the gain errors are different for the 4 channels.  My design is such that gain errors cancel out if they are consistent across all channels, so the non-matched gains are an issue.  I would like to avoid having to do calibration.

Is different gains on different channels standard for all MUX/PGA type ADCs or is it just the way that this part is designed?  I would have thought that the chip would be designed with a 4:1 MUX followed by a PGA and ADC, but it seems with the different gains that it might actually have 4 PGAs followed by a 4:1 MUX to the ADC.  Is there some reason why it would have been designed that way?

In order to give you an idea of the scale of the difference, 1.0029 and 1.0075  are the correction multipliers required for two different channels to match the value read by a precision volt meter.


texts: Designing single fault safety into class I device

texts:
I'm trying to wrap my head around safety standards for electrical equipment. My device is medical, so for me section 8 of IEC60601-1 is what really matters to me, but it's kind of my understanding that all of the safety standards (e.g. IEC60950) use approximately the same language and logic, however 60601 has the most stringent thresholds for acceptable safety during testing.

The general concept behind the entire thing seems to be that your device must remain safe under all single fault conditions. 'Safe' is whenever leakage currents don't exceed the thresholds given in the standard. And besides describing the tests, Section 8 seems to be entirely dedicated to defining exactly what constitutes a 'single fault'. There are a list of external single faults listed in the standard (e.g. open protective earth conductor), but it is also your responsibility to consider every possibly internal fault and ensure that the leakage currents are never exceeded.

These internal failures can be shorts and opens of any single component on the circuit board, and could be shorts across any single insulation less than 2 means of protection (as defined in the standard by creepage, clearance or solid thickness). Additionally, any and all insulation not adequate to be considered 1 means of protection can be shorted out in addition to the external and internal single fault conditions. This notion of 'two means of protection' is introduced and I believe (and I could be wrong here) that what this is getting at is that IF any given single fault produces a leakage current that exceeds the threshold, then an additional means of protection is necessary. Is that correct idea?

I have a million+1 questions about this, but where I am really stuck here is specifically regarding what you need to do on the secondary side of an isolation transformer to make it single fault safe. For the purposes of this question, let's assume the circuit inside the device is dead simple.

Powered from AC mains through isolation transformer
Secondary is just a 2 resistors
Enclosure is protectively earthed.
Everything is contained in the enclosure
Secondary voltage $V_s$ could be anything, really.
one side of secondary winding is connected to the enclosure at a single point.

For the fault conditions I am showing here, when I trace through where the fault currents should flow, I can't see where the hazard is to person in the leakage current tests(represented by MD). I think the only test that matters for this situation is the earth leakage test, but it seems like it would never fail as long as your primary side passes the test.

It's too simple, What the heck am I missing? Is it not the leakage test the matters? Is it a touch current test? But isn't everything protectively earthed and you can't do a touch test? I can imagine that a large fault current flowing through the finite impedance enclosure could present a hazard, but oddly, only when the protective earth conductor is intact (bottom left).


texts:
So, I am trying to build an 8 bit multiplier in verilog. I am using an add/shift method to do it that uses a register. Whenever I run the code, it produces a result that isn't right. My verilog is:

`timescale 1ns / 1ps

module Mul8bit(
input [7:0] Multiplier,
input [7:0] Multiplicand,
input Clock,
output [15:0] led
);
reg M;
reg [16:0] ACC = 0;
reg start=1;
reg state = 0;
reg [15:0] led;

always @(posedge Clock)
      begin
           led <= ACC[15:0];
      end

always @(posedge Clock)
    begin
                M = ACC[0];

                case (state)
                    0:
                        if(start)
                        begin
                            begin
                             state = 1;
                             ACC[7:0]<=Multiplier[7:0];
                        end

                    end
                    1,3,5,7,9,11,13,15:
                        begin
                            if(M)
                                begin
                                    ACC[16:8] <= ACC[15:8] + Multiplicand[7:0];   // Add
                                    state <= (state+1); // increase the state
                                end
                            else
                                begin
                                    ACC <= (ACC) >> 1;
                                    state <= (state+2);
                                end
                        end

                    2,4,6,8,10,12,14,16:
                        begin
                            ACC <= (ACC) >> 1;
                            state <= (state+1);
                        end

                    17:
                        begin
                            led <= ACC[15:0];
                            start <= ~start;
                            state <= 0;
                        end
                endcase

Additionally, this is my testbench:

`timescale 1ns / 1ps
//////////////////////////////////////////////////////////////////////////////////
// Company:
// Engineer:
//
// Create Date: 11/16/2016 08:12:51 PM
// Design Name:
// Module Name: 8bitMultiplier
// Project Name:
// Target Devices:
// Tool Versions:
// Description:
//
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Additional Comments:
//
//////////////////////////////////////////////////////////////////////////////////

module Mul8bit_tb(
    );
    reg [7:0] Multiplier = 8'b10101010;
    reg [7:0] Multiplicand = 8'b00001111;
    reg Clock = 1'b0;

    wire [15:0] led;

    Mul8bit Multi(Multiplier, Multiplicand, Clock, led);
    initial
    begin
    end
    always
    #5
    Clock = ~Clock;
endmodule

So, regardless of whehter the clock keeps going, the program should stop once it enters state 17. However, it continues going and the output is:

Is there any clear reason the program doesn't stop once it gets to state 17?


texts: Control door with RS232 or Ethernet relay

texts:
Our company use a fail safe electric bolt with a remote control for the entry door. It closes when the power is ON and vice versa.

It does work normally but I want to make a hot button for the receptionist to open/close it using her keyboard.

I'm a newbie in electrical and after spending a half day for googling I have found 2 way that I feel it may work:

Connect the receptionist's PC directly with the door controller through computer port (USB/Serial).
Use an ethernet relay.

Honestly, I have searched a lot but still found nothing fit my need. I want to solder the circuit myself so buying a complete controller is not in the category.

Btw, I intend to make the application using .NET framework (C#).

Any help would be appreciated!

P/S: Sorry for my English if you do not understand.


texts:
I derive the formula for energy stored in an inductor as follows:

$$\text{power} = P = v(t)i(t)$$

$$\text{energy} = E(t) = \int \limits_{t_0}^{t} P(\tau)~ d\tau$$

$$\text{energy} = E(t) = \int \limits_{t_0}^{t} v(\tau)~i(\tau) d\tau$$

substituting voltage law for inductor:

$$v(t) = L \frac{di}{dt}$$

I get:

$$E(t) = \int \limits_{t_0}^{t} L \frac{di}{d\tau}~i(\tau) d\tau$$

$$E(t) = L \int \limits_{i(t_0)}^{i(t)} I ~dI$$

$$E(t) = \frac{L}{2} \bigg[I^2\bigg]^{i(t)}_{i(t_0)}$$

$$\boxed{E(t) = \frac{L}{2} \bigg[i^2(t) - i^2(t_0)\bigg]}$$

However the book that i'm using defines inductor energy as just:

$$E = \frac{1}{2}~L~i^2~~[\text{joule}]$$

then they go onto to calculate the energy of a 2 Henry inductor with current flow of :

$$i(t) = 2e^{-t}$$

as:

$$E = \frac{1}{2}(2)(2e^{-t}) = 4 e^{-2t}~~[\text{joule}]$$

Strictly speaking, is this right??

If I consider the current flow at time zero t=0, it has an initial current of 2 amps... and I don't see that factored into their energy equation.   Or did I do something wrong in my derivation of the inductor energy equation and it shouldn't have the i(t_0) term?

I suppose i could play a trick like this by defining current like this:

$$i(t) = \begin{cases}2e^{-t} & t\ge 0\\0 & t \lt 0\end{cases}$$

but, it doesn't really help since the initial current is still 2 amps. and you really can't jump an inductor current instantaneously...


texts: What is the functional difference between an in-circuit-debugger and an in-circuit emulator?

texts:
In-circuit emulators (abbreviated ICE) boast about their awesome debugging features, and also boast high price tags.

In-circuit debuggers (abbreviated ICD) can do most of the stuff that an ICE can do, but often cost much less.

I know that way back in the day, ICEs would actually remove the problem chip from the socket and replace it with an emulator cable, but with modern QFN, BGA, and fragile TQFP packages, it seems that most products calling themselves "ICE" debuggers are connected to a debug header in much the same way that an ICD would be.

Here are some examples of products which use "ICE" in the name:

Atmel AVR JTAGICE
Microchip MPLAB RealICE

There are also JTAG 'ICE" products from several vendors.  Note that I'm not discounting these because they're not physically in-circuit, but I would discount them if they don't function as a true ICE.

In what sort of development tasks do I need an ICE, and when should I be content with an ICD?  Let's assume that I want to step through my code, and not use LEDs and printf() statements.

What are some examples of problems which you've solved with an ICE but could not (realistically) have solved without it?


texts: Difference between these two op amp circuits

texts:
I came across this circuit for a non inverting op amp which is biased Vs/2. I'm wondering what the difference bettween these two circuits are? What is the purpose of R3 in the first circuit and how is it different to the second circuit?

Thank you


texts:
I am a mentor on a US First FTC team.  We have had some motors start to smoke a couple of times.  How can I test the motors we have to find out if they are good?

I have the data sheet for the motors here:

http://www.tetrixrobotics.com/Building_System/Downloads/default.aspx?moid=721


texts: Charging 4 x 12V lead acid battery with solar in series or parallel?

texts:
I have a small electric vehicle that currently uses 4 x 12V 8Ah SLA batteries wired in series as its 48V battery packs. I have 2 of these packs.

In order to charge the batteries, I unplug all of them, plug them into a parallel wiring harness and use a 12V battery charger, either AC powered or solar panel with 12V charge controller. Then once charged, I have to re-wire them in series (the batteries have F2 terminals and the series/parallel wiring harnesses have female spade connectors)

This works but is obviously annoying.

I'm wondering what my options are. I currently see two possibilities:

Continue this series/parallel song and dance, but use DPDT relays to easily switch between "charge" (parallel) and "run" (series) modes. Do you see any pitfalls with this idea? I really like the ubiquity of 12V chargers. I could have each of the two battery packs switched independently so one is charging while the other is being used.
Use 48V chargers. I'm not even sure I can get a compact enough solar panel system to get 48V? I'd like to mount the panels on the vehicle itself, so probably not more than 150 or 200 watts of panels. Are there inexpensive charge controllers that can boost the voltage?


texts:
My 2 year-old nephew likes nothing more than to plug/unplug RCA jacks. Whenever he's around, tv inputs get switched, audio plugs are swapped, etc.

So... For his birthday, I decided to build him a little box with a panel full of RCA jacks and some buttons and nice blinky leds and beepy noises.  The idea is to have an array of about 12 RCA jacks, into which he can plug cables to his heart's content. To give him some feedback, an arduino will generate different blinky led patterns and wacky noises (using the Mozzi library) depending on which pairs of RCA jacks are connected.

My question is... What's an efficient way to detect which pairs of RCA jacks are shorted via a cable?  Ideally, for 12 RCA jacks, I would want to uniquely detect up to 6 connected pairs.

I have a few ideas (below), but I can't help but think there must be a more elegant solution to the problem.

Possible combinations
Some combinatorics tells me that the number of ways I can choose p pairs out of n jacks is:

C(n,p) =  n!/((n-2p)!*p!*2^p)

That's basically the number of permutations of 2p jacks out of n (=n!/((n-2p)! ), divided by number of pair reversal combinations 2^p (i.e. reversing a cable), and divided by the number of pair permutations p! (i.e. the order of plugging in the cables)

So, for 12 jacks and using anywhere from 0 to 6 cables, there are:
sum(C(12,p) for p=0..6) = 140152 possible pairings (I think...)

Some ideas I came up with:

1)  connect each of 12 jacks to an arduino digital IO pin with a pullup resistor. Scan for pairings by setting one pin to OUTPUT LOW and checking for a low signal on the other eleven (configured as INPUT pins).  Repeat 11x (each time, setting another one of the twelve to OUTPUT LOW)

Advantage: uniquely detect any of the 140152 possible pairings

Disadvantage: Lots of pins in use

2) Create a string of resistors from 5V to ground, via the 12 jacks, like this:
GND - R - p1 - R - p2 - R - p3 - R - p4 - R - ...  - p12 - 5V

Connect pin p1 to an analog input as well.  When a cable is plugged in to two jacks, some of the resistors are bypassed, changing the voltage at pin p1.  For equal values of R, we can determine only the total number of resistors bypassed.  For sequentially doubling values of R  (1,2,4,8,...), we can deduce from the voltage at p1 exactly which resistors have been bypassed (sort of...  we'll be limited by noise and the arduino's 10 bit ADC)

Advantage: Simple, only 1 analog pin used

Disadvantage:  This method can't uniquely identify all 140152 pairings (notably when plugging in multiple cables), but I don't think my 2-year old nephew will notice the shortcoming.

3)
Something something RLC filter... I have no idea what I'm talking about.


texts:
In Figure 1, I designed a synchronous buck converter using the IR2110S half bridge gate driver integration. However, when I look at the source-GND measurements of the high side MOSFETs in Figure 2, I see that the voltages don’t reach zero. Why could such a situation occur?
Thanks.
Figure 1

Figure 2

Edit
Output voltage 35V and 105W.
MOSFET = IXTP90N15T
Input voltage = 60V
Full schematic


texts: Why does the underside of this flip-chip BGA have small notches in it?

texts:
I am reverse engineering an embedded system which has an ARM SoC on it. I have no datasheets at all, so I am going fairly deep with the investigation.

It is packaged in a lidless flip-chip BGA. The carrier substrate that the die is mounted on provides clues to the function of pins, so I was investigating the SoC under the microscope.

I have noticed that there are a number of notches cut through the solder mask and outer layer of copper. They cut traces between the balls.

Overview of the underside of the BGA:

View of some of the notches:

Oblique view showing depth:

Traces being cut by notches:

My initial thought was that these were used to configure the device after they had been binned. There seem to be too many though - well over 50 on a 452 pin BGA package. What are they used for?

I'm also intrigued as to how they are made. They have very square sides and no undercut given that they are only 0.25mm long, pretty much ruling out etching and laser. I can't see how a mechanical method would get such a uniform bottom.


texts: Oscilloscope: How are Bandwidth specification and Sampling Rate related?

texts: I had thought that a (digital) Oscilloscope with higher Sampling Rate,  would automatically have higher Bandwidth. That seems intuitive because of Nyquist Sampling Theorem. But I've read in several places that in an Oscilloscope "sampling rate is not directly related to the bandwidth specification" (see here for example). That doesn't make any sense to me. Could you explain the logic?


texts:
I have an Input which provides DDR data, I need to capture it and output it from the FPGA in one register (12bit).

How can I do it?

What I did for now is to capture the input data with always block in the rising edge and store in reg1.
capture the input data with another always block on the falling edge and store in reg2.

Now i have data of the rising edge on reg1[12bit] and falling edge on reg2[12bit],  how can I send this data now to another output register of 12 bit?

my code:

module ADC(
    input rstn,
    input clk,
    input [11:0] data_in,
    output [11:0] data_out
    );

    reg rst;
    reg [11:0] posedge_data;
    reg [11:0] negedge_data;

    always @(posedge clk or negedge rstn)
    begin
        rst <= ~rstn;
    end

    always @(posedge clk, posedge rst)
    begin
        if (rst) begin
            posedge_data   <= 12'b100000000000;
        end else begin
            posedge_data   <= data_in;
        end
    end

    always @(negedge clk, posedge rst)
    begin
        if (rst) begin
            negedge_data   <= 12'b100000000000;
        end else begin
            negedge_data   <= data_in;
        end
    end

endmodule

assuming that doubling the clk frequency with PLL is not an option.
Im using Lattice ECP3 FPGA.
If you can help me with Lattice IPs and how to connect them that also would help.. but I think there is possible way without IPs no?

thanks.

Edit:

after Oldfart comment

if I change data_out to 24 bits and add this line of code:

assign data_out = {posedge_data,negedge_data};

does it make it good DDR design? or there is a better way?


texts: How come decimal to BCD encoder has 10 input lines

texts: Came across to study about decimal to BCD encoder and noticed it has 10 input lines, and four output lines but encoder   should have 2 pow n input lines, so I doubt 10 cannot be in the form of 2 pow n!


texts: Which electric components could make a high pitch sound when defected?

texts: My PC's ATX power supply stopped working. I opened it and noticed that it makes a high pitch sound when turned on. I can't figure out which component in the power supply makes that sound, so that I can replace it.


texts:
home automation is driven by a PC running Ubuntu.  It currently has a 1-wire network of thermometers for managing our geysers and solar water heaters.  I would like to extend it to manage our water pumps. The first problem I would like to solve is to measure the volume of water in the overhead tank. I couldn't see any 1-wire compatible distance sensor.  I am ok with using a different setup to measure the water level, but would prefer if the sensors (say HC-SR04 or others) could be connected to my USB through some adapters/read made hardware.

Instead of setting up an Arduino or raspberry pi, etc.  Any USB to general IO board adapter, that can be used to drive the sensors?
Any other recommended approach?


texts: BNC connectors and EMC - plastic or metal?

texts: This is an example of the right angle board mounted BNC connector I am using. It has a plastic body. It is mounted in a grounded metal box with only the barrel protruding. From an EMC perspective, does it matter whether the body is plastic or metal?


texts: Are Data Cards simply L1 (Physical Layer) Devices?

texts:
I was just wondering, how many levels of the TCP/IP (OSI) Stack reside within a modem or a 3G data card and other similar networking devices?

These devices do have a physical (MAC) address, which indicates that they have a Data Link MAC sub-layer, but what about LLC? What about the rest?


texts: Is there a convention for the polarity of voltage specified as \$V_{XY}\$?

texts:
Inspired by this answer, which includes the image:

Which solicited the comment:

  No, you have the polarity of Vce shown backwards in the diagram [...]

The diagram seems consistent to me: the arrows go from the thing in the 2nd letter of the subscript, to the 1st letter of the subscript, in each case.

We might see similarly subscripted voltages in contexts besides BJTs: we also see them in FETs, or things that might not be transistors. Thus, given an arbitrary \$V_{XY}\$ to measure, the procedure is:

place positive lead of voltmeter on X
place negative lead of voltmeter on Y
read measurement

Is this always the convention? Is it a more explicit definition? Or does it change, based on the thing in question, or even which part of the thing being discussed?