texts:
I came across a moving average code for my ADS1115 ADC to smooth out the noise.
When I do voltage scaling I getting zeros at my serial monitor.
I'm giving input to my ADC from an LMC6001 op-amp.
Although I'm able to read ADC values, when I do voltage scaling (voltage = (adc2 * 0.1875)/1000; which I have included in my code) I'm reading zeros on my serial monitor.
Please point out the mistake.
#include <Wire.h>
#include <Adafruit_ADS1015.h>
Adafruit_ADS1115 ads(0x48);
const int numReadings = 10;
int readings[numReadings];

//int readings;
int readIndex = 0;
long int total = 0;
float average = 0.0;
float Voltage2 = 0.0;

void setup(void)
{
  Serial.begin(9600);
  ads.setGain(GAIN_TWOTHIRDS);
  ads.begin();
  for (int thisReading = 0; thisReading < numReadings; thisReading++) {
    readings[thisReading] = 0;
  }
}

void loop(void)
{
  int16_t adc2;
  adc2 = ads.readADC_SingleEnded(2);
//  readings = analogRead(inputPin);
  Voltage2 = (adc2 * 0.1875)/1000;
  total = total - readings[readIndex];
  readings[readIndex] = Voltage2;
  total = total + readings[readIndex];
  readIndex = readIndex + 1;
  if (readIndex >= numReadings) {
    readIndex = 0;
  }

  average = total / numReadings;
  Serial.print("AIN2: "); Serial.println(adc2);
  Serial.print("Average: "); Serial.println(average);
  Serial.println(" ");
  delay(1000);
}
```


texts: What is the purpose of grounding rectifiers?

texts:
In the centre tapped rectifier:

It seems as if the highlighted ground line would provide a short circuit for any current developed between the top/bottom wires and the centre tap, eliminating any output voltage.

Additionally, in the bridge rectifier:

The current is supposed to flow through D1/D2 or D3/D4, but the presence of the ground makes it seem like the current would get through the resistor and then short to ground. This wouldn't affect the output voltage but it still seems strange to me.

I'm guessing I'm not grasping how grounding actually works, so a simple explanation for these circuits would be appreciated. Thanks.


texts: Is there any advantage to biasing a transistor with a zener diode rather than a (resistor-based) voltage divider?

texts:
In the figures below, we see two methods of biasing a bipolar transistor: the first uses a voltage divider, and the second employs a zener diode regulator.

Since the voltage regulator appears far more frequently, I'm wondering if there exists some scenario or reason that would compel me to use a zener diode regulator instead.


texts: Atmega328 Clock Freq. via Divider vs. Power

texts:
I have a question that the power section in the Atmega328p datasheet does not seem to cover. I was planning on running my system at 1MHZ with a 2.8V VCC for a good trade off of power vs performance. As it turns out 1MHz crystals and resonators do not seem to exist, Digikey has none.

If I run a divide by 8 (set with the fuse bits) attached to an 8MHz crystal, from a power standpoint will that be the same as a 1MHz clock? Obviously there will be some small additional losses from the 8MHz in-front of the clock divider but since the CPU and assorted other clock domains are slower, I'm assuming it will have a power draw close to 1MHz.

Is this correct?

EDIT
I can not use the internal oscillator as I require accurate timing across a large temperature range. Also I have reviewed the datasheet and the question is asking if I feed a 8MHz clock and scale it by 8 to 1MHz is the approximately the same power use as a raw 1MHz clock.


texts: Have microcontrollers replaced simpler ICs?

texts:
Is it still worthwhile to learn, for example, how to tune a 555 timer with resistors and capacitors, when you can write a timer program for a microcontroller in a human-readable programming language?

Or, to put it another way, are there problems that ICs are good for that microcontrollers are not?


texts: What is the difference between a PLL and a frequency-synthesizer？

texts: It seems that a LPF is contained in PLL and not in frequency-synthesizer. Maybe I had made a wrong judgement.


texts: VME64 vs PCI Bus for vibrating environment

texts:
I have to select between VME64 bus and PCI bus and one of the important decision metric is concerned with the connector types used in these buses. My application is in a vibrating environment. I cannot find any information or data for these buses if one of them will work in vibrating environment better than the other.

How can I do this evaluation?
Will it be pure judgmental or should it be decided on some specification?

I will be connecting some cameras, displays and discrete I/Os on the bus. It's a 1-shot work for a custom application.


texts: What are the address input pins used for in ds1621?

texts:
I just bought a ds1621 temperature sensor and started reading its datasheet.
I found out that it have 3 pins (A0,A1,A2) which as specified in the datasheet are chip address input.

Can somebody explain to me  further the interest of having those pins ?


texts: I'm just beginning to understand a bit about transistors and wanted to build my own NOT gate with what i thought was an NPN Transistor. When it didn't work I thought maybe i had the pins mixed up and tried every configuration possible to no avail, so I thought maybe it's a PNP transistor. When i was trying to create it, I had an input led to make sure i was getting good contact through my switch when I realized it was actually functioning as a NOT gate. So here's my schematic, if someone can tell me how this thing is actually working, I would appreciate it. Thanks in advanced.


texts: What's the correct method to find the Thevenin Impedance in this circuit?

texts:
I cannot find the Zth in the circuit i uploaded; i calculated the correct value of Vth with the following steps:

LKC @ N1:
5 + (0.2)Vo = -Vo/(8+4j)

LKV @ the outer loop:
Vth + Vo - (4-2j)*0.2 - Vo = 0

And the Thevenin Voltage is exactly 7.35 L(72.9°).

At this point I usually connect the two terminals (a, b) and try to find the short circuit current (i put a visual reference in the picture) using the node method (or the loop method) and use the formula Vth/Isc = Zth,
but nothing seems to work! Also adding the SC makes the circuit look really weird, as all the "block" on the right can be seen as a single node.
Any ideas to find the Zth? The solutions are in the picture.
Thank you :)


texts: Why does my LPC812 require PIO0_1 to be tied to ground?

texts:
I am using an LPC812 (specifically the 20 pin SOIC version LPC812M101JD20). This is currently soldered to an adapter and being tested in a breadboard. To program this PIO0_5 (RESET) and PIO0_12 (ISP enable) are pulled up to the 3V3 rail with pushbuttons to short them to ground to enable programming. There are also LEDs on PIO0_16 and PIO0_17.

The device is programmed using mBed code over a serial connection but I have found that PIO0_1 (pin 12) seems to be required to be tied directly to ground or the device remains in reset. Once it is running, if I disconnect the ground wire from this pin the device stops. If I use a 10K pull-down resistor it remains in reset and a 470R pulldown seems to put it into some confused state where the LEDs flicker a lot, possibly continuously resetting.

The datasheet does not seem to suggest there is anything special about this pin:

  By default, the GPIO function is selected except on pins PIO0_2, PIO0_3, and PIO0_5. JTAG functions are available in boundary scan mode only.

Later, in table 6 on page 12 it is pointed out that on some earlier revisions this pin was used to enter ISP mode but on versions marked 4C (mine is marked 4C) this was moved to PIO0_12.

I've also checked the errata sheet and nothing is listed for this revision.

So this pin should be in GPIO mode and should not need to be tied to ground as I understand it. Is this common to these devices? It appears to work fine but only if this pin is tied directly to ground.


texts: LM2678 Switching Regulator Voltage Dropout Under Load and extreme Input Distortion

texts:
I recently had a question about the layout for an LM2678-ADJ switching regulator.
Since, I have built the circuit and layout as follows:

So far, I have only had moderate success with the circuit.
With an input voltage of 30V and up to 6A available, everything works well (at least, output voltage constant), up to a current draw of up to about 2.5A.
Above that, the voltage drops dramatically and the diode starts getting hot(ter).

The following waveforms were taken at different current draws, with the rheostat set to produce 12V out:
Yellow is measured across diode D1, and blue across capacitor C3 at the output on the right.

Current Draw: 0.1A

Current Draw: 2.4A

Current Draw: 2.5A

Current Draw: 3.0A

Aside from the slight ringing at 0.1A, it seems to normalize out to a square waveform by about 0.15A and everything looks well to about 2.4A.

However, at around 2.5A, where the voltage drop occurs, there seem to be "misses" in the waveform, and going further in 0.1A increments to 3.0A, the waveform only shows "misses".

I have read on other threads that the inductor needs to be large and have low resistance.

L1 is a torodial  47 µH with a DCR max = 13.5 mΩ and rated 10A.

D1 is an STPSC10H065D 10A Schottky Diode

I have tried a small ceramic across D1's terminals without success.
Also, this thread says ringing should be checked, but there doesn't seem to be any in the above output (except under low/no load conditions).

So finally, my question is very basic: What is causing this, and how can it be fixed?

The datasheets for the components are here:

L1 Datasheet

D1 Datasheet

Regulator Datasheet

EDIT 2020-05-22

I have measured the input voltage, and am seeing some nasty feedback/ringing that I think is causing my issue:
The blue is the input measured across Input and GND pins on the regulator (AC coupling), and yellow measured on Switch_Output pin (DC coupling)

0.2A load

2.0A load; distortion worse

3.0A load; everything is crazy

I have tried:

Adding more input capacitance (to lower RMS)
Adding more output capacitance (to lower RMS)
Trying different Schottky diode
Different inductors as suggested and accepted as answer at first, one 3A 47uH for 255kHz switching regulators, and a 68uH stolen from a DC-DC boost converter. There was no measurable effect.
Resoldering on another prototype board with different layout in case ground plane or whatever on the board is causing this. Effect was about 0.3A more load before breakdown.


texts: What is the difference between a magnetized nail and a coil?

texts:
When I was a child, I brought a nail (metal bar) and I made some turns around the nail. It was something like a coil and the nail was the core of that coil. When I applied DC on the coil using  1.5 V battery, the nail had become a magnet. It was attracting other nails and metals.

Now, I've learned that the magnetic field is generated due to change of current in a wire, and that's why we apply AC to transformers and coils.

I have two questions:

Why the nail is magnetized although there is no changes in current (DC) ?

Why we don't apply DC to transformers and coils ?


texts: Convert fan-in-2 fan-out-3 NAND gates to FO4

texts:
This question is about gate delay in VLSI (microchips). (Yes, it is a CMOS)

Every digital chip consists of 2 kinds of elements, Register Logic (trigger or latch stations) and combination logic (between the registers, does the actual computation). Most chips can be expressed as http://en.wikipedia.org/wiki/Register_transfer_level which describes logic and registers.

The maximal clock frequency of microchip is determined (limited) by the delay of the slowest combination path. This delay depends from kind of elements, used in it.

The most popular metric of this critical delay is FO4 http://en.wikipedia.org/wiki/FO4 or Fan-out of 4:

  process independent delay metric used in digital CMOS technologies.

It is counted as chain of length N of NOT gates. Each gate have output power enough to drive 4-fold more powerful inverter (according to wiki). I get this metric as tree of inverters with N levels, where each inverter drives 4 same inverters. Tree looks like http://www.mathworks.com/help/toolbox/wavelet/ug/wptreed2.gif but with NOT gates (transistors) at nodes. (better description is at http://www.realworldtech.com/page.cfm?ArticleID=RWT081502231107 )

So, the any modern processor have a metric FO4, which can be equal to 14, or 20 or 40. If the processor have small FO4, it can have more frequency, than a processor with large FO4 at the same silicon technology.

I have a metric for critical path of some chip, expressed in terms of fan-in-2 and fan-out-3:

18 fan-in-2 fan-out-3 NAND gates

How can I convert this to FO4? (Fan-out of 4)

I want to compare this chip with modern CPUs. FO4 will give me a clear way to check, how fast the chip can be on technology of modern CPU.

Update: There is a book which says:

  This fan-out-of-four (FO4) inverter delay, t_4, is a good estimate of the delay of typical logic gate (fan-in=2) driving a typical load (fan-out=2) over relatively short wires.

So, Fan-in=2 and Fan-out=3 is close to 2/2 or to FO4. For the first estimation I will use this 18 fi2/fo3 as equal to 18 FO4.


texts: Why does Arduino get damaged when used in this relay circuit?

texts:
I am controlling a heating element using microcontroller development board (https://store.arduino.cc/arduino-nano?queryID=a777b4d5d5a1040ab95d2450172b4ef2) using the following circuit. It worked fine until I changed the pinMode(PIN#,OUTPUT) command in the code to turn the digital IO on which resulted in fumes from the microcontroller. Initially an internal pull up resistance is set in order to avoid short circuit. when pinMode() command is used to set the pin to output mode, the resistance is removed. So, I wonder if my following circuit has caused this?
The resistance of the heating element is very low, 15.8ohm, is this ok to attach the element in the following manner?

simulate this circuit – Schematic created using CircuitLab


texts: Why isn't the solar panel charging the battery?

texts:
I have a solar panel, a battery and a charge controller. I didn't pay for any of it so I thought I would just wire them up and see how it goes.

The battery won't charge. The charge controller has a battery level indicator and it has stayed at middle for over a week. The solar panel doesn't have a high wattage so I wasn't expecting it to charge quickly but I think It would have charged by now. Could somebody tell me if there is anything wrong with the setup?

I believe I need 2x 12V solar panels to give 24V to actually start charging the battery. Is this correct?

All of the parts are definitely working. I also would like to know how long it would take to charge the battery fully with no load. I have worn Google out searching for how to do that but I need it to be put simply and into context. If someone could briefly demonstrate, that would be great. Anyway, the info on the different parts:

Solar Panel

12V
5W

Battery

12V
4.5AH

Charge Controller

12/24V (auto)
5A

Thanks!


texts: Temperature limit on Soldering iron\heating element

texts:
I am trying to design a soldering iron type of tool that will not heat-up past, lets just say 400 degrees F.
I know I can get a PID controller and manipulate the temp, but I'd JUST like the unit to never heat above 400 F, no need to turn it up or down.
The reason being is i need the modification to be as SMALL as possible...I cant have an external housing.
Any ideas?


texts: Step-down converter input and output capacitors

texts:
In the below pictured circuit for the MC33063 by TI, how important is the capacitance of the inpu-output caps? I understand why they're there, I don't know what the recommended capacitance is derived from. I am using the QFN package.
The reason I ask is that I have very little space left on my board and the caps tend to get relatively large, even at 16V, not to mention more.
I think I might be able to cram a 100uF/6.3V on the output in a B case, and a 100uF/16V C case on the input, both tantalum, but I doubt they'll be low ESR.
Possibly if the capacitance was slightly lower, I could either use a smaller case or lower ESR. Real input voltage will be 12-14V.
Would that be possible?
Also, what is the smallest package available for the diode?

Update: This is what I've come up with so far. If I can find all three in B case, given that the output will be a pair of 220uF/6.3V, than I can fit them.
Please don't mind the dirty schematic with incorrect values for 4.1 output etc.


texts:
I have an AT90USB162, have it set up like this:

I'm trying to program the chip using Atmel FLIP, but I can't because it's not detected.
What could be the problem and how can I fix it?


texts: How do I calculate the efficiency of a linear constant current LED driver?

texts:
I'm trying to select a driver design for a LiPo battery powered 3W LED light. I'm looking at switching options, but see that there are discrete linear options such as this one. How do I determine efficiency vs a switching design from the data sheet?

If I'm only looking to power a single LED (implying a Vf that's slightly below that of a LiPo battery), does a Linear CCR become an effective option?


texts: Is this circuit correctly protecting my Arduino I/O pin?

texts:
I'm quite new to electronics. I thought of this circuit to prevent more than 5V from going into the Arduino I/O pin. Should it do the trick or is there something wrong?

simulate this circuit – Schematic created using CircuitLab

The resistance values is merely for show.


texts: Does half stepping produce less torque than full stepping in a stepper motor?

texts: Would running a bipolar stepper motor at half step produce less torque but smoother movement than running it at full step?


texts:
These two figures(below) are from book Microelectronics circuits by Sedra/Smith.
I have two doubt regarding notation used in this book (or may be in general also)

1.in this figure(1) why there are two arrows ( most of the times only one arrow is there) pointing towards 10v and in general what  arrows indicate (or its significance)

2.in this figure (2)
how to judge  (method?) whether  emmiter terimnal  Re2  of Q2 transistor is connected to 15v terminal of Rc1 (Q1 transistor)
 or

grounded collector terminal Rc2 (Q2 transistor)?


texts: Do PMOS Reverse Input protect on ORed power rail

texts:
As the title says, I have a power mux IC and two power inputs. I need them to be protected from reverse voltage input. The power mux I have already comes with a reverse voltage input protection but I need the second input voltage for another IC and its not always the second input is selected by the PMIC. So I must protect it beforehand.
Typically a PMOS does the trick but I do not know if it will work when there are two inputs that share the same ground. If one of the inputs is powered and if one of the other is wired correctly, what would happen?


texts:
Pins = 16x2
Space between pins = around 2mm

What i really need is the name of a female adaptor to connect to it in order to have cables like this. Thanks!


texts: clock period, throughput and efficiency of I2C bus

texts: If a I2C bus is runs at 400kHz what is the clock period ,data throughput in data-bits/seconds and bus efficiency? i am very new to those buses and is the clock period is 2.5 micro seconds ? any help will be appereciated.


texts: installing a DIP package with broken legs

texts:
I'm attempting to modify my NES (Nintendo entertainment system) for RGB output. This involves removing the PPU from the board and soldering it onto a board supplied in the mod kit. This installation is rather notorious for giving people trouble. In particular, desoldering the PPU seems to cause many people to pull traces and break legs off of the PPU, as the motherboard is rather thick and tends to soak up heat.

I was no exception to this. I spent a few hours slowly trying to work the PPU off the board, but I still managed to break a few of the legs and pull a trace. However, I believe this is still salvageable, with the proper methods. I think I've fixed the trace by installing this wire (picture #1), however I'm a little afraid the wire may be too thick (also I'm sure the wire layout isn't ideal; if you can't tell I'm a novice at this). My last obstacle is to do something about the broken legs on the PPU (pictures #2 and #3). I was thinking of two things:

(1) I can solder a small piece of wire to the shorter legs then solder that as usual, but I may run into a problem where the heat from soldering the PPU onto the board may desolder the piece of wire and leave me with little bits of wire in the through-holes, which I am deathly afraid of.

(2) I can solder the PPU onto the board as usual (as if the PPU did not have a few broken legs), just making sure to add extra solder to the broken legs so that the little stubs can make a proper connection.

I'm leaning towards (2), but it seems a little crude and naive, so I come to you all for advice on how to proceed. Any help is greatly appreciated. Thanks


texts: Hold Pushbutton for soft latch after X seconds

texts:
What I'm trying to achieve is have a momentary push button that must be held for say 5 seconds before latching on permanently.

But the button must be held for entire duration or else timer will reset.

I'm looking at 555 timers but struggling to figure out how to auto reset on button release before timer finished.


texts:
I bought a cheap LED strip and a 12V 5A power supply unit on Aliexpress. After testing it I realised that the LEDs closer to the PSU end get quite hot (around 55°C) while the ones at the other end of the strip don't get hot at all. I'm a bit worried that continuous exposure to this kind of temperatures might change the colour of the paint on the wall over time.
I measured the open circut voltage output of the PSU and it turned out to be slightly higher than it should be (12.2V), so I thought I could lower the voltage a bit by adding a couple of diodes in series with the strip.
I went to the local electronic parts shop and they sold me FR302 diodes which are rated at 100V 3A. I added 2 in series and indeed all the LEDs now are now cold to touch without noticeably losing in brightness. I measured the voltage drop and it turned out to be 0.8V across each diode, and the current drawn by the strip dropped from 1.1A to 0.9A, but here comes a new problem: the diodes get really hot (79°C according to my multimeter).
I can't find much in the diode's datasheet about how hot it should get in these conditions. I can see that it can operate in the -65..+150 range, but my question is: is it normal for the diodes to get this hot in these conditions? Can I avoid it by using a different type of diode? Should I use a different method of lowering the voltage altogether?
I'm also worried that some of my measurements might be wrong, because according to the description on Aliexpress:

Power Consumption (W/m): 7.36W/m

Which I thought should mean that the strip draws 7.36 W/m / 12V * 5m = 3A, whereas I can only see 1.1A on my mulitmeter. Am I wrong in my calculations?


texts:
I'm trying to power a SoC with a battery as in the figure below. The SoC in question is the WeMos, based on the ESP-8226.

simulate this circuit – Schematic created using CircuitLab

When the WeMos is restarted, the following voltage is observed on VM1:

This poses a problem because the rest of the circuit depended on the voltage being a stable 3.7v. What is the correct approach for making the Vcc as independent as possible from the WeMos behavior?

Tried solutions:

I've tried putting different capacitors (10, 47, 220, 2200, 4700 microFarads) in parallel to the battery but they didn't fix the issue.

edit: The x axis in the diagram is in fact 3V and not 0V. The question is how to stop the power from the battery dropping below 3V.

Our board does have power and ground planes, and we were using an oscilloscope to measure the voltage at VM1. I checked the probe on the battery and recalibrated it to show 3.7V across the unconnected battery.


texts: Correct DC Adapter type to use for Arduino

texts: What's the correct DC adapter to use with an Arduino?  Voltage, etc.?


texts: Verilog assigning wire by iterating over array

texts:
How to assign a wire with a AND operation of a wire array?

    parameter row = 4;
    parameter col = 8;
    wire ready [row-1:0][col-1:0];
    output wire allready;

logically i want to do

allready=AND ready[i][j] for all i,j


texts:
I've been trying to understand this exercise proposed by my teacher.
He asked us to find a combination of 2 ideal filters to generate a filter within the conditions of the image below. (That means, band-stop,band-pass,low band and high band)
That means, I need to reject 100-200 Hz and (here comes what I don't understand) reject with 50% of attenuation 300-400Hz.
Afterwards he asked to generate them with a Butterworth first order, which is not a problem, except that I don't know what kind of combination I should use.
Thank you all for your patience.


texts: What serial signalling format is this? (RS-485?)

texts:
This is a mystery signaling standard that I'm trying to sort out.  It looks more or less like RS-485 to me, but I don't recognize the long looking start bit, and the "idle" state of the line looks a little strange to me. Using an RS-485 to RS-232 converter, I can't seem to get it to translate to anything intelligible.  Note the different offsets for CH1 and CH2.  When in the "idle" state (at the beginning) the two lines are at essentially the same potential, and when transmitting, they differ by the amounts show.

I guess in particular, I'm more curious about the framing than I am about the physical layer itself, since my rs-485 converter seems to interpret it OK (even if the data appears to be nonesense to me)

Edit:

Here's the character of the data over a longer time span, note the timebase (same vertical settings)

Here's the close-up trace, but with infinite persistence turned on.  I'm triggering on the long start pulse, which seems to be present for all messages:


texts: Where can I find a fast (1KHz) LCD plate?

texts:
I'm not looking for a graphic or text LCD display here, just essentially a single, large pixel, capable of going from dark-light-dark in under 1ms. The faster, the better.

The idea is to create a secondary shutter for a still camera, increasing the flash sync speed of the camera. Here's a video of a similar idea, but on a CMOS video camera. Seems like they're using a pane from a pair of 3d shutter glasses, which operate at video speeds (60 or 120 hz, not fast enough.)

Something like the panel in an auto-darkening welding helmet would be along the lines of what I need, providing they can also transition from dark-light at high speeds.

What are these called? What can I search for (LCD panel obviously doesn't help)? Where might I be able to find one? (Aside from hacking apart a welding helmet.)


texts: Get clean line-level audio signal from a sound generator chip that is designed to drive a transistor as amplifier

texts:
(I removed both of the two old questions since they are going wild and off-topic, but the main concept is the same, just as title states. Also some details are clarified and informations are appended.)
I need to record the output of two sound generator chips with a Sony PCM recorder.
The recorder does not specify the maximum input level, the only technical specification on manual is

Microphone/External input jack (minijack, stereo)Input for plug in power, minimum input level 1.0 mV

To make sure the recorded audio does not become distorted, I need to keep the input below 0dB. After many trying, it seems like when the VU meter shows 0dB, the input voltage is about 0.5V. I am not sure how to measure the exact voltage for 0dB, which seems like has many definitions (0.6V, 0.775V, 1V, etc).
Both chip are designed to simply drive an NPN transistor as amplifier, and drive a speaker with it:

And the datasheet both have this entry about output current, but not voltage (I am not sure what does the VOH and VDS mean), and when I measured the voltage of the output pin when the chip is working (a song being played), the voltage is about the same as VCC:

So I tried various ways to capture the highest quality of audio from them. I have found that I will need a resistor from AUD (the output pin) to ground, to provide the chip a load and make sure that the output voltage is correct. But how do I determine the value of that resistor? For example, I used a potentiometer to try many times on the HT3894, and seems like the optimal value which I am getting max audio level without peaking (which from the measurement above, should be around 0.5V maximum) is ~390Ω. But I assume there will be some mathematical way to get this value from the specs the datasheets provide, since it won't be random?

Also when I used the method stated above to capture the output, it sounds nothing wrong when played back and heard by ear, but when I examine the waveform in DAW, I saw something unusual:

The waveform has a downward peak, which I assume it's some DC thing in the output. To prove this, I tried to connect a low voltage DC source to the audio input and record it, and sure enough:

So the second question is, is it possible to eliminate this DC signal mixed in the output of the chip? How to? I tried to connect a capacitor in between, but the sound just becomes hoarse, and the downward "bulges" in the waveform are still there.
Also I have found a recording sample of the same song done by others (bottom image), which does not have the "bulges". After comparing the two, I found out that my recording (top image) is more of a square wave variation, looks like some sort of PWM signal.

Here are the datasheets if you ever need other information:
HT3894
M994A


texts:
I have a custom STM32F103C8T6 board. Long story short, the MCU works fine, I can connect to it, program it, read sensors, toggle GPIO etc. The problem is that, one of the crucial pins seems to be shorted to VDD. The pin is PA9, which I wanted use for USART_TX1. I have no control over this pin. I can not digitally toggle it, can not use uart, nothing. I checked the pin via a multimeter ,with the board powered on and off, and both times I noticed a short between VDD and the pin. The length of the track out of this pin is about 7 inches. I visually inspected the route to see if short was on the board but I didn't notice anything, route is neat and isolated. Thus, I believe the pin is internally tied to VDD somehow?

I also performed a full chip erase, still tied to VDD. I also think it is worth noting that sometimes there exists an amount of resistance that the multimeter measures when checking for shorts. I read values ranging from 2 to 190 ohms.

What is going on here?

Edit: schematic and layout of the relevant parts. Top layer being ground, and the bottom being VDD. Let me know if more info is needed.


texts: What happens to a high power inductive motor if you decrease the RPM to half the rated in terms of current, torque and heating?

texts: and what is minimum possible RPM ratio for a high power motor


texts:
Up grading a ATD 9030 mig welder. What does a choke look like?
I lost the photos of the wiring before I took it apart.
The one wire on the wire feed motor goes to a choke.


texts: How can I increase the range of an infrared emitter?

texts: I'm currently using this set of infrared emitters and detectors. It appears that I only get about 10 cm of signal before the detector doesn't pick it up. It's on +5v power with a 10k pull-down resistor connected to ground. Without the resistor, the emitter burns up. With a 150 ohm resistor (I calculated this to be around the minimum resistor), there does not appear to be a change in distance. Is there any way to increase the range without damaging the emitter?


texts: In ADS, what are the differences between the lumped components and the lumped component models?

texts:
I'm trying to put in some ideal inductors and capacitors into my schematic, but there are two options: "Inductor" and "Inductor Model".

What are the differences between the two?


texts: Board layout help: 64-output Mux! (for possible use in 8x8x8 LED Cube)

texts:
So just for practice I decided to design a 64-output mux in Eagle, I figured if its good it could be useful in the future. I did not use auto-router.

Here is the PCB:

(Click to zoom in)

To the lower left are the interface pins: power, gnd, selectors.
It consists of 2 levels of 8-output muxes (9 total).
Datasheet for analog muxes used (CD4051): http://www.datasheetcatalog.org/datasheets/120/109150_DS.pdf

Here is the schematic it's based on:

(Click to zoom in)

The size of the layout is 4.4" x 2.4" which would get really expensive to get printed for an amateur. I kind of get the feeling this whole idea is impractical, but I don't know what to think. Does it even make sense to do this?

Is this a good design?
I'm planning on using this to make an 8x8x8 LED Cube. Would this design cause too much propagation delay since the traces weave in out through vias a lot?
Is there any way I can make this even more compact or efficient? Or just any general improvement?

Any input is appreciated! Thanks!


texts: Exceeding voltage ratings on microcontroller pins using series resistor

texts:
I've been designing a circuit which requires a microcontroller to read a voltage above its current VDD or below its current VSS. I've done this once or twice before by putting a large-ish resistor in series between the high voltage source and the microcontroller pin. My understanding is that this works by limiting the current through some protection diodes on the input pins.

I could use a voltage divider, but it looks ugly and prone to mishaps with the way my circuit works (the ground reference of the microcontroller shifts around...I really don't like it, but that's how things are wired...I'm kinda stuffing this microcontroller in where another part used to go). I'm also trying to reduce my part count.

The voltage that would be read is either high or low and could go as high as 0.7V above VDD or 0.7V below VSS. Does anyone know a way to calculate a size for a series resistor for this situation? I'd like to avoid relying on the guess and check since I have a limited supply of microcontrollers.


texts: Unified struct in C to represent multiple sensor data

texts:
Working on desginging APIs for sensor events. I was wondering if there is a way to represent different type of sensor readings into a unified struct in C ?

For example a accelerometer'e reading represents 3-axial data(x,yz), a temperature has float data type and a proximity sensor has reading in integer.
Is it possible to represent different sensor events into a same struct?

Found an example of the Adafruit sensor library which uses combination of union inside the sensor_event_t struct. Is it possible to define a struct without using the union technique?
Not that anything is wrong with it.

Is it possible to implement it with the void pointer concept?


texts:
I'm trying to build my own quadcopter and I plan to design my own flight controller / mother board. Now my question is, how do drones, such as the DJI phantom, reduce a high voltage with high current, like 11.1V 5000mah, to a more usable voltage, such as 3V, for the controller, yet still distribute the a maximum number of power.

Is the power pin of the ESC connected directly to the main supply?
Do they use a step-down converter to lower the main voltage to a more usable voltage for the microcontroller?
How do I calculate how big does my traces on the PCB needs to be?


texts:
I want to drive a LED seven-segment display multiplexed.
For the high-side switch I have a UDN2981(TD62783APG).
It's running on about 80Hz @ 5V.
When I hook it up to a scope I can see that when its Input goes low,
the output has a capacitor-like discharge curve of about 1ms starting
from that point.

Why does it do that?
How can I remove it?


texts: Does anyone know what this outlet is for and why it would be sparking with nothing in it.


texts: DC BJT Circuit Allowable collecter swing discepency

texts:
Im working through tutorials of BJTs from sedra smith in which the lecturer has video solutions that you can follow as you go if you get stuck.

The issue is i don't agree with some assumptions that have been made and i have checked chegg for the solution, in which there none of them obtain the solution provided via video.

The first assumption is that the BJT is in the active region. I am fine with this are working through the question will result in an answer that tells you if it is in active or not.

Now the assumption made that i don't agree with is that the lecture says that the +-1V swing at Vc (Stated in question) is equal to Vcb=-+1V. This confuses me because the question is saying that it is an allowable swing. Its not saying that the voltage difference between Vc and Vb is always going to be -+1V. Next point because active is assumed Vbe=0.7v. I agree with this. and can then conclude that Vb=0.7V which is also true. Now to solve Vc the statement Vc=Vb-+1v=0.7+1(only uses the positive swing value) is made. which i disagree with due to my initial Vcb=-+1V discrepancy. From this point on i continued through with the provided video solution to see were it went but believe that it is incorrect.

I have attached my working which is a copy of the video working

Note i did not bother with that very last part of the question regarding beta=150. Because im at the conclusion that  everything is wrong.

Im going to review chegg answers to see if i can get an understanding also

Thanks.


texts: Arduino to CPLD to toggle an LEDs using I2C

texts:
I have a a CPLD (Lattice MachXO2) that echos a signal from an Arduino to turn on an LED.

Arduino:

//send out .1s pulse on output pin 2 when a 'q' is recieved
void loop () {
  USBinByte = Serial.read();
   if (USBinByte == 'q') {
     digitalWrite(ledPin, HIGH);
     delay (100);
     digitalWrite(ledPin, LOW);
   }
}

CPLD:

//When LEDin goes high toggle LED
module toggleLED (
 LED,
 LEDin);
    output LED;
    input LEDin;
    reg LED;

    assign led_next = ~LED;
    always @(posedge LEDin) begin
        LED = led_next;
    end
endmodule

How do I setup I2C on both chips to be able to load an 8 bit register on the CPLD and also read the register, so I can set up multiple LEDs? I've done I2C between three Arduinos before using the WIre library. I2C is required for a project I'm working on.


texts: What is input to the RF power amplfiier (gate of the MOSFET)?

texts:
I have read that the RF PA is a block just before the antenna. So, the input to the RF PA (voltage signal at the gate of trasistor in the PA) should be a modulated signal and thus the PA just does the job to amplify it. Is this correct? If yes, why do most of the books show a pure sine wave input and output while discussing RF PAs?

Also, in the class - E PA, the input (gate of the transistor) is a digital signal. Is that the data signal? If yes, in that case, does the PA itself do the job to modulate and output the amplified modulated wave?

I am confused as to what is the input to the RF PA.


texts: Edge-triggered flipflops - keep CP high or low, most of the time?

texts:
I'm using 74HCT574 Octal D-type flipflops in a homebrew-cpu project. http://assets.nexperia.com/documents/data-sheet/74HC_HCT574.pdf

These flip-flops latch their input on a +ve edge on CP.

I could either:

keep CP high, then pull it down for the clock cycle before I want it to latch.
keep CP low, then pull it up for the clock cycle after I want it to latch.

Option 1 looks easier to write microcode for, as CP is pulled down in the same cycle as the input is set-up for the flip-flop.

Are there issues with using option 1?

How do professionals use the CP input on flipflops?  (If any still do, since we have $2 CPLDs and MCUs.)


texts: What does a resistor value of NP mean on a schematic?

texts: I'm trying to design a schematic based off a certain schematic I've seen online. In the image theres two resistors and a capacitor all with a value of 'NP'. What does this mean?  I'm guessing it means there is no component but I want to make sure. Should VS be connected to ADCIN at all if this means no component? Also why put a resistor and capacitor symbol in at all then?


texts:
Newbie here,
I am working on a project with a panel of 12 - 15 LEDs(std 5mm through hole LEDs) in paralell.
I am currently using a 5V 1A SMPS. I used 330 Ohm resistors for current limiting.
It works great! (Schematic in first figure).
[]

I know using resistors for current limiting is not efficient, moreover I have no control over the brightness of the LEDs.

Now, I want to make upgrades to the panel:

Use a driver IC to save power
Use a POT to control intensity of LEDs1
Do the above 2 points without a Micro controller or a timer IC (Tomake it as simple and cost effective as possible).

Is there any such driver IC(powered by a 5V 1A SMPS) that can take input resistance from a POT and drive 15 RED leds by controlling the intensity of brightness..


texts:
I am trying to learn about a buck converter, and so far I think I have grasp the main idea of the basic topology

simulate this circuit – Schematic created using CircuitLab

From what I read and based from examples, the SW is driven with PWM signal from MCU, so the output is based on the signal duty cycle.

Now I am trying to reverse-engineering a power module using buck converter, I found out that the MCU does not provide any PWM signal, but using DAC features. Is it possible to create an adjustable buck regulator using DAC signal as control instead of PMW? If so, how does it work?

If there are missing point from this question, please ask and I will try to improve this question.


texts:
I'm looking for an IC that can convert an analog signal to a PWM signal, i.e.:

Ui = 0V --> DC = 0%
Ui = 6V --> DC = 50%
Ui = 12V--> DC = 100%

Anyone who knows an IC for this?

Thank you


texts: Arduino's analog input pulling down voltage when off

texts:
I'm got a PCB manufactured, where a Arduino (Mega2560) is (via a 5V Buck converter) supplied by a 4S LiFePo4 battery which is secured by a custom BMS system. The system is measuring the voltage of the battery via a 1:3 voltage divider, which is also providing the information to the arduino.
What happens now is, that when the BMS is switching the system off, the voltage from the divider is dropping to approx. one third causing the BMS to misbehave. Once the BMS is active again, the Arduino starts and the voltage is back to normal.
My guess is, that since tha arduino is powered off when the BMS is not on, the voltage from the voltage divider gets kind of "sunken" on the analog input, trying to power the arduino from it or so.

One solution would clearly be, to solder in a second voltage divider, so that the BMS hardware measurement is independent from the one for the Arduino.

My questions are:

Why exactly is this happening within the Arduino? How can the sinking of the voltage be explained? To my knowledge the input impedance of the Atmega Processor is 100MOhm, so how is it able to pull down the voltage so much?
Is there another way to avoid this, without a separate voltage divider?


texts: What happens to current in a RC-battery circuit when you move plates with a square signal?

texts:
I use an RC circuit connected in series with a battery. I change the gap between plates of my air capacitor (2 paralleles plates, one fixe, the other one moving with an actuator) so as to change my capacitance with a square signal. I measure the tension at the resistor to know the current in my circuit. I do not understand the type of signal that I could expect ? what is happening ? What is the power harvested ?

details: Actually I am chemist working on composites for energy harvesting (converting motion into power). i would like to develop a circuit to easily quantify the power harvestable with my material under motion. These materials can actually change their permitivity under motion.
To develop this circuit, my first step was to work with an air gap, to try to quantify the power harvestable and not harvested (we imagine that the material keeps its polarization). but i do not see how measure this value with these curves.. Do we have to integrate the signal ?


texts: How can I save a floating point value to a Microcontroller data Flash

texts:
I'm trying to save some floating values to the Data flash of my Nuc220(ARM-M0 32 bit) Microcontroller using ISP procedure.

FMC->ISPCMD = FMC_ISPCMD_PROGRAM;   /* Set ISP Command Code */
FMC->ISPADR = 0x10000;              /* Set Target ROM Address. The address must be word alignment. */
FMC->ISPDAT = 22.5;                 /* Set Data to Program */
FMC->ISPTRG = 0x1;                  /* Trigger to start ISP procedure */
__ISB();                            /* To make sure ISP/CPU be Synchronized */
while(FMC->ISPTRG);                 /* Waiting for ISP Done */

FMC->ISPCMD = FMC_ISPCMD_READ; /* Set ISP Command Code */
FMC->ISPADR = 0x10000;         /* Set Target ROM Address. The address must be word alignment. */
FMC->ISPTRG = 0x1;             /* Trigger to start ISP procedure */
__ISB();                       /* To make sure ISP/CPU be Synchronized */
while(FMC->ISPTRG);            /* Waiting for ISP Done */
dataFloat = (float)(FMC->ISPDAT);

But the value read is 22.0 instead of 22.5 , I also get a warning of, 'implicit conversion to integer' while compilation. How can I do this without error?


texts:
I'm trying to decide if the internal programmable output termination (UNTUNED_50) of the spartan XC6SLX45-2CSG324I if sufficient for our design, or an external termination is needed.

The traces from the fpga pin (driver) to the IC (receiver) are relative long ~30cm, so reflections will occur and be a problem without source termination.

I have looked at the IBIS model spartan6 IBIS for the driver LVCMOS18_S_8_LR_33 the output termination resistance is calculated to: min=41, typ=50, max=64.
Which I would consider good.

But looking in the datasheet ds162 on page 5, the UNTUNED_50 has very wide range 21 to 96 ohm, which would give significant ringing.

So two questions:

Why is there so big difference between the IBIS model, and the datasheet ?
When should I generally not use the internal output termination ?


texts: Method for sensing fault currents with microcontroller

texts:
How do I choose a proper approach for detecting ground fault currents (20 mA through 30A, 60Hz)? Let's say I have a zero sequence CT and calculate a burden resistor. I have a 12-bit ADC in the micro. I have seen different methods:

A peak detector, like this one
DC biasing like this
Doing some FFT in the micro?

I want to avoid as much hardware as I can and leverage the microcontroller, even for filtering. Also, I don't think a fixed gain amplifier or burden resistor would cover this wide range of current with good resolution?

I'd appreciate your suggestions.


texts: What opamp configuration to choose to measure 1kHz square wave with 1MHz signal modulated on it

texts:
I have 1kHz square wave I would like to measure the max and min voltage of. But, it is asymmetrical in both amplitude and duty cycle and it has a 1MHz 1V signal on it. The input impedance should be > 100kOhm and the output goes into an ADC without a load.

I went through some theory of opamps. Understand the half wave rectifier, the peak detector and the first order low pass filter. It all seems useful. But I was wondering what best way to do this. I know the duty cycle. Those are fixed values of either 4%, 50% and 96%. The amplitude is either around -5 or -10 at the negative side and around 5 or 10V on the positive side. Any change in voltage I would like to detect within 10 periods (10ms). I would like to measure at better than 100mV accurately.

The only thing I know that works is making a buffer with gain 1, a diode, and R and C that settle at the average of the positive duty. And then divide that voltage by the (known) duty cycle. But the voltage drop of the diode was less constant than expected. For the negative value I could do something similar.

But I am quite sure there is a more elegant way. Before you know it, getting rid of the 1MHz in negative feedback RC combined with the diode of the peak detector works. Thanks!


texts: Using a plug-in timer to extend the lifespan of a laptop battery

texts:
My 3.5 year old laptop is suffering from a swollen battery despite having completed only 100 cycles. It's been plugged in for at least 18 months, which I read likely contributed to its degradation.
I'm going to get it repaired but would like to take steps to prevent / delay this from happening again.
According to this article the 'optimum' charge for a Li-ion battery is 40%-80%, but more generally the advice seems to be to avoid leaving your laptop permanently plugged in.
One approach could to be plug the laptop into the mains through a simple timer, which could cut the power from 00:00 - 12:00, so that each day from when I switch the laptop on at 09:00 to 12:00 the battery would drain and then be recharged.
Aside from any performance issues of the laptop running on battery v.s. mains power, are there any drawbacks to this approach, and could I reasonably expect an improvement in the lifespan of the battery? Any advice on timing schedules - I could set the timer weekly rather than daily, for example - also appreciated.


texts: Can I use Bill of Materials to order components online?

texts:
I am working on a project in which I am designing a circuit board with a lot of components (resistors, capacitors, ICs etc) using AutoCAD Eagle. I am done with the schematic part and currently I am ordering components online. I have found this process very time consuming and tedious. I have to order each individual components with the correct values, which requires a lot of searching.

Recently, I came across a feature in Eagle - Bill of Materials, which generates a list of all the components and their values and details. Is it possible to upload Bill Of Materials on electronic vendor websites to speed up ordering process?


texts: Extract part of a PCB to make a new footprint in KiCad

texts:
I have an old PCB KiCad file that I want to modify but I don't have the libraries and footprints any more

Can I extract a part of the existing PCB to make a new footprint for one of the components?


texts:
For a project, I want to charge a lipo battery (3.7V  @2000mah) with a 5V USB charger.
I'm not into electronics, so I don't know if is viable to do that.

So, can I charger a 3.7 battery with a 5V charger with no problems?

Thanks!


texts:
I am using a Raspberry Pi 3B to output music to an audio amplifier board. Without the Pi connected, there is no noise from the amplifier. Once the Pi is connected (but not outputing any music yet), there is loud crackling and humming which is associated with the activity on the Pi.
BTW I am a (retired) digital engineer and my analogue experience goes back to university.
I am using a "brick" power supply (J1) which outputs 20V. This feeds the amplifier directly. There is a separate buck/boost DC-DC converter (J2) which generates 5V from the 20V for the Pi. Here is a diagram of the wiring:

The amplifier board uses a TPA3116D2 audio amplifier IC.
The (partial) schematic for the Pi can be seen here. The audio output is generated on the Pi by a PWM which is buffered using a separate 3V3 supply, then filtered before output to the 3.5mm jack socket. Unfortunately the Pi schematic doesn't show how the 3V3 supply is derived from the 5V input.
If I power the Pi directly from a standard USB charger (with the amplifier still supplied by the power supply), there is no such noise and it sounds pretty good.
I can think of three potential problem areas with my design:

The noise is being generated by the power supply. The amplifier has a good PSRR so can cope with this noise but the DC-DC converter is essentially passing it through. The Pi then passes the noise onto the 3V3 supply.
The noise is being generated by the DC-DC converter which the Pi is passing through.
All the wiring is generating ground noise.

Is there a more likely source of my issue?
Which is the most likely area for me to investigate further?
Any suggestions on what I can do to remove this noise?
All help gratefully received.


texts: 5 Pins soldered from a USB 2.0 type A cable

texts:
I have just recived a new product and I want to replace the permanent USB cable that is soldered to the board with a shorter female end USB. The problem is that when I disassembled the item I saw that the cable is soldered to 5 points to the board using 5 cables that come out of it. Now as far as I know USB 2.0 Type A has only 4 pins (Voltage, Data-, Data+ & GND).
How can I then connect it (The 4 pin female end USB) and why does it have 5 pins when on the other end were it connects to the computer it is a type A connector.


texts:
I have an application where I would like to derive a secondary square wave from a primary one but with a continuously variable phase shift. I would like to know if this is possible to achieve in a relatively simple manner, ideally without an FPGA or Arduino etc. I'm open to the idea of a PLL chip if these are approximately as inexpensive as, say, 741s or 555s and that the implementation does not imply a long settling time. However, if there is absolutely no other way of doing it then I'm open to more complicated suggestions.
The specifications for the primary square wave are not yet set in stone but the following can be taken as guidance:

fixed frequency at some convenient rate (say 1MHz)
50% duty cycle
0-5V or 0-3.3V p-p or similar to suit any logic requirements

Specifications of the secondary derived square wave:

phase shift from primary of 0-360 degrees
not discrete steps but continuously variable (analogue control eg potentiometer, voltage input or similar)
ideally an instantaneous phase shift (minimal settling time)

The other question (Phase Shift Square Wave) with the same title as this one is different in that the OP wanted to produce 6 x 60 degree fixed sub-multiples of his original frequency. I want to be able to vary my shift continuously over one full cycle.


texts: Verilog - A line stays high, I need it to go low after a while

texts:
I'm working on a circuit in Verilog to be implemented on a CPLD.  The output of the circuit will drive a stepper motor.  The input is a stream of pulses from a machine.

I generate a stepper pulse every X spindle pulses.  No problem, works great.

While simulating, however, I noticed that if the stepper signal is high when the spindle pulses stop (say, someone turns off the machine), the stepper signal stays high. This is because I set it back to low on the leading edge of the spindle pulse, and there are no more.

This means that (with a poor implementation) the stepper could be run at full speed which would cause a machine crash.  Now, I would hope the stepper controller would operate only on the leading edge, but you never know.

Finally, the question - since I can't depend upon my 'clock' (the spindle pulses) to continue ad infinitum, what's a good way to make the stepper pulse go low after 'a while.'

As you see, I can't even describe it properly so I can't Google it, lol.  If someone could supply me with some words to search on (or better yet, describe a standard technique) I'll be off to the races.

Thanks!

EDIT -

I'm experimenting with the following (typed from memory...)  Is this sadness, or a good idea?

always @(posedge Stepper) begin
     #50 // or whatever, this is a low Hz system...
     Stepper = 0;
     end

Or does the delay only work in the simulator?


texts: How do you write the system of equations that solve the nodal voltages for this circuit?

texts:
I have the circuit below drawn on a piece of paper.  I am trying to figure out the unknown nodal voltages x1-x9.  Actually, from the circuit we already know x8=9 and x9=0.

Here is my thought process: first draw out the direction of current through each resistor.  Then use KCL (Kirchoff's Current Law) to write out current equations.  Then Ohm's law to convert unknown currents to unknown nodal voltages.

Suppose:

i1 moves from x1->x4
i3 moves from x4->x7
i6 moves from x5->x4

Then my first equation becomes

i1+i6-i3=0 for node x4.

By similar analysis, I get 4 more equations:

-i1-i8+i2=0 for node x2.
-i6+i8-i7+i5=0 for node x5
i3-i4+i7=0 for node x8
-i2-i5+i4=0 for node x6

By using Ohm's Law, I can convert all the currents i1-i8 to nodal voltages x1-x9 using the equations:

i1=(x2-x1)/.5
i2=(x3-x2)/.2

and so on.

Then I get a linear system of equations with unknown nodal voltages.

My linear system is:

A=  -2     2     0   -10    10     0    -5     0     0
     2    -9     5     0     2     0     0     0     0
     0     2     0    10   -22     2     0     0     0
     0     0     0     0    10     5     5     0     0
     0     5    -5     0     2    -7     0     0     0

b=

   -45
     0
   -90
   135
     0

The last step is to do A\b in MATLAB, which gives me the wrong answer for nodal voltages.  I know it's the wrong answer because when I create this circuit in a circuit simulator online I'm getting different nodal voltage values.

Would appreciate if somebody could point out what is wrong with my thought process here. All I'm doing is using KCL, then transforming unknown currents into unknown nodal voltages.  Then solving the linear system.

simulate this circuit – Schematic created using CircuitLab


texts: What is an auxillary winding in a flyback transformer?

texts:
I am researching about SMPS, specifically AC/DC flyback converters.

In the datasheet for the switching controller (Fairchild FSCQ0765), it refers to an auxiliary winding. What is that? All the current transformers I've looked at only have a primary and secondary winding.


texts: Buck regulator maximum supply voltage VS. voltage spikes at input where we have a TVS diode

texts:
Currently I'm using a buck switching regulator AOZ1284PI of Alpha & Omega Semiconductor to generate a 5V supply from a 12V input of a lead-acid sealed battery, and I plan to use AOZ1284PI again on the project below.

I plan to design some vehicle tracker that can be used in cars and bus/truck, so my input voltage range to be considered is from 10 to 30V (maybe 32?) steady. Of course I will use a schottky diode at the input to prevent reverse connection of the supply input (battery power of the vehicle). And I plan to use a TVS diode SMAJ30CA right at the supply input (it is bidirectional TVS diode), before the protection diode.

According to the datasheet of AOZ1284PI, the maximum supply voltage recommended is 36V, and absolute maximum is 40V.
According to specs of TVS diode SMAJ30CA, Voltage Clamping (Max) @ Ipp = 48.4V.

Then, considerer voltage spikes are occuring at the battery and the TVS diode is clamping them at the input of my circuit. Clamping voltage would be 48.4V, and this is greater than the maximum of 40V of AOZ1284PI. Of course such voltage peaks will probably have a very short time duration in practice.

I would like to know what are your observations for that situation.

Would the AOZ1284PI be prone to be easily damaged in such situations? In a vehicle environment? That's my main question.

Or in this case we have to consider the ESD rating of the IC?

Datasheet of AOZ1284PI: http://aosmd.com/res/data_sheets/AOZ1284PI.pdf
SMAJ30CA specs on Digikey: https://www.digikey.com/product-detail/en/littelfuse-inc/SMAJ30CA/SMAJ30CALFCT-ND/762507

Regards.


texts: Microcontroller Oscillator Layout for ESD immunity

texts:
I have a small portable USB device failing ESD immunity.  It's a two layer board with a solid ground plane on the bottom. I have diode protected inputs, and there's a TVS on the USB connector, and I'm wondering if I need to think about discharges to the ground plane and how that would affect the oscillator.

I've seen recommendations for a ground island for the oscillator, but I'm not
entirely sure if I've implemented them correctly.  I was hoping some wiser individuals might be able to give me some feedback.

Some Questions that Come to Mind

Should the decoupling capacitor be connected to the crystal?
Should the island extend upward to cover the oscillator signal
traces?
Is the island big enough?
Is making the island going to make any difference at all?

I would love to hear any feedback that would help me produce more robust designs.  Thanks in advance.


texts:
I want to use a power regulator PCB I designed to switch down 60V to 12V and 12V to 5V in order to power a USB plug and use it as a phone charger. My only worry is that the switching regulators I am using (TI TPS54560) can provide up to 5A of current whereas the plug is rated for 1A. Do phones cap their charging current at 1 or 2A on their own or is this something I need to implement in my system in order to avoid damaging them?
Thank you for your help!


texts: thickest pcb track before hitting ridiculousness in digital circuits

texts:
Ok, you can call me ridiculous.

But, When I make PCB's, I learned myself to get into a habit into making thick PCB traces for every wire including those that others would use maybe a 5 - 8mil width.

I also noticed that thicker traces allow me to use a junky printer to print the artwork to create decent PCB's with the photoresist method. With thin tracks, the printer sometimes prints a hole the size of the trace itself (5-8 mils). and No, I don't always have the time to use the office store for printouts.

Currently my minimums I set for my boards are 12mil width for traces with 12mil clearance. For power (except ground), I aim for at least 40 or 50mils to cover the width of a standard IC pad. For ground, I use 24mil max so it fits in-between pins.

Most of my circuits are powered with 5VDC but I have some powered with 3VDC and I also have part of my circuit that outputs loud audio as well as a radio module.

I used a 7805 voltage regulator without issues, so I can conclude my entire circuit uses less than 1.5A current total.

So my question then is, am I going overkill with my large trace widths? If so, what should I use as absolute maximums for trace widths and why?

and yes, I will use a ground plane, and all my PCB's are single-sided.

Added note

I should mention that the maximum speed passing through the majorit of my board at any one time is 24Mhz courtesy of a crystal, however those two traces (where crystal connects to micro) are less than 1/2 inch long and roughly 40 mils wide with a max of two 45 degree bends.


texts:
I'm trying to get the CubeMX generated sample CDC application working on STM32l475VG IoT board.

By following a document from ST Community, I was able to get the clock configuration right and the CDC application without VBus Sensing works perfectly fine. I used MSE trimmed by LSE as suggested by the document.

However I would like to get the same application with the same clock configuration on the same dev board running with VBus Sensing ON and it doesn't work at all. This time the device is even not seen by the PC at all.

When VBus Sensing is ON even the HAL_PCD_IRQHandler doesn't get triggered upon connection.

I need VBus Sensing since in my real application we're using the uC in a self-powered device.

I am trying out all these experiments under the assumption that HW on dev board readily supports VBus Sensing, since with the datasheets I can't read that HW changes are required.

Is it really safe to assume that sample USB CDC app should work with VBus sensing ON without modifying the dev board HW ?

With the description mentioned in the document, I have a feeling that VBus Sensing is Disabled intentionally for a very specific reason. Is it that the clock configurations have to done differently when it is On ?

Can someone please shed some light on this ?


texts: Switch between power supplies with a MOSFET

texts:
I'm new here and my knowledge in electronics is basic, so what I'm trying to do is to switch between two power sources, one at 5V an other at 12V, I already made a circuit that kinda works, but I have to use a diode on the 5V source to lower the real voltage and I don't want that. Is there any way to do that without draining the 5V source?

It would be no problem if the draining would be on the 12V source.

L.E Looks like that I was wrong, the 3V source does nothing there, I've tried other configurations and I've got nothing, seems that the easiest way to do it is with a relay.

Also I'll try using a Schottky diode as @gbulmer told me in the comment.


texts: Clearance requirements from EGND to SGND on ethernet transformer

texts:
I have previously been instructed to have a ~70mil clearance between DGND and EGND and to bridge using a 1.5kV 0.47u cap.

Application notes also show a 2kV 1000pF cap to EGND off of the center tap of an ethernet transformer. I can't find anywhere that says i need that same kind of clearances but I assume I do based on the cap rating. Any knowledge? I found an app note from Renesas that said a 1/16W 75 ohm resistor can be used in series with the 2kV cap. So that implies i am fine with an 0402 cap but then i will get hammered on my design rule check. Something has to give here.

Can anyone explain what is correct and provide supporting documentation?

R4 and R5 are 75 Ohms, C25 is 1000pF 2kV, R55 is a 0 ohm jumper, and C2 is the 1.5kV 0.047u that allows transients on GND to get to EGND.

Screenshot below: 1st image is ground plane layer. 2nd image is top layer. light blue is the SGND net (pours on both layers) and green in the EGND net on the SGND layer and red is the EGND net on the Top layer.


texts: Can I draw brief large bursts of current from a shift register, above output pin current rating (i.e. cap or IR sensor on the register output pin)?

texts:
I am tinkering around with shift registers and I want to power an IR sensor from one of the output pins on the shift register. The register can push or pull 8mA/pin(recommended) or 20mA/pin(max) with a max of 50mA through the entire register. The IR sensor draws 5mA on average and 70mA during short bursts. I am going to add a 10uF cap across the power and ground of the IR sensor. Will this work, or will it destroy my register in the long run?

Would having capacitors on the shift register output pins destroy the shift register, since they would require brief bursts of current to charge up every time?


texts: Buffer, amplify, filter, sample - In which order?

texts:
I'm trying get an audio signal from a high impedance source (guitar or mic) to an ADC.

Some casual research suggested that I should filter my signal before amplifying it.

My current mental design is: Source -> Buffer (optional depending on impedance) -> Butterworth filter -> Boost -> ADC.

Is this the "correct" way to design this circuit?
Does it make sense to throw in an RC filter (or a second active filter), e.g. before the ADC?


texts: How can I interpret the circuit of the voltage probe with cable between the probe body and the compensation box?

texts:
Let's take a look at the voltage probe circuit without the cable between the probe body and the compensation box.

This circuit is a typical RC voltage divider and the following relation holds; $${R_P} = \beta {R_{OSC}},{\rm{ }}{{\rm{C}}_P} = \frac{1}{\beta }C'
% MathType!MTEF!2!1!+-
% feaagKart1ev2aaatCvAUfeBSjuyZL2yd9gzLbvyNv2CaerbuLwBLn
% hiov2DGi1BTfMBaeXatLxBI9gBaerbd9wDYLwzYbItLDharqqtubsr
% 4rNCHbWexLMBbXgBd9gzLbvyNv2CaeHb5MDXbpmVaibaieYlf9irVe
% eu0dXdh9vqqj-hEeeu0xXdbba9frFj0-OqFfea0dXdd9vqaq-JfrVk
% FHe9pgea0dXdar-Jb9hs0dXdbPYxe9vr0-vr0-vqpWqaaeaabiGaci
% aacaqabeaadaqaaqaafaGcbaGaamOuamaaBaaaleaacaWGqbaabeaa
% kiabg2da9iabek7aIjaadkfadaWgaaWcbaGaam4taiaadofacaWGdb
% aabeaakiaacYcacaqGGaGaae4qamaaBaaaleaacaWGqbaabeaakiab
% g2da9maalaaabaGaaGymaaqaaiabek7aIbaacaWGdbGaai4jaaaa!5081!
$$ where $$C' = \left( {{C_C} + {C_{OSC}}} \right)
% MathType!MTEF!2!1!+-
% feaagKart1ev2aaatCvAUfeBSjuyZL2yd9gzLbvyNv2CaerbuLwBLn
% hiov2DGi1BTfMBaeXatLxBI9gBaerbd9wDYLwzYbItLDharqqtubsr
% 4rNCHbWexLMBbXgBd9gzLbvyNv2CaeHb5MDXbpmVaibaieYlf9irVe
% eu0dXdh9vqqj-hEeeu0xXdbba9frFj0-OqFfea0dXdd9vqaq-JfrVk
% FHe9pgea0dXdar-Jb9hs0dXdbPYxe9vr0-vr0-vqpWqaaeaabiGaci
% aacaqabeaadaqaaqaafaGcbaGaam4qaiaacEcacqGH9aqpdaqadaqa
% aiaadoeadaWgaaWcbaGaam4qaaqabaGccqGHRaWkcaWGdbWaaSbaaS
% qaaiaad+eacaWGtbGaam4qaaqabaaakiaawIcacaGLPaaaaaa!4A8A!
$$ is the equivalent capacitance of the compensation box and the oscilloscope and $$\beta  = \frac{{1 - \alpha }}{\alpha },{\rm{ }}\frac{{{V_{out}}}}{{{V_{in}}}} = \alpha
% MathType!MTEF!2!1!+-
% feaagKart1ev2aaatCvAUfeBSjuyZL2yd9gzLbvyNv2CaerbuLwBLn
% hiov2DGi1BTfMBaeXatLxBI9gBaerbd9wDYLwzYbItLDharqqtubsr
% 4rNCHbWexLMBbXgBd9gzLbvyNv2CaeHb5MDXbpmVaibaieYlf9irVe
% eu0dXdh9vqqj-hEeeu0xXdbba9frFj0-OqFfea0dXdd9vqaq-JfrVk
% FHe9pgea0dXdar-Jb9hs0dXdbPYxe9vr0-vr0-vqpWqaaeaabiGaci
% aacaqabeaadaqaaqaafaGcbaGaeqOSdiMaeyypa0ZaaSaaaeaacaaI
% XaGaeyOeI0IaeqySdegabaGaeqySdegaaiaacYcacaqGGaWaaSaaae
% aacaWGwbWaaSbaaSqaaiaad+gacaWG1bGaamiDaaqabaaakeaacaWG
% wbWaaSbaaSqaaiaadMgacaWGUbaabeaaaaGccqGH9aqpcqaHXoqyca
% GGUaaaaa!53AF!
$$

So far so good. However, what about the voltage probe with the cable?

In this case, there is the cable between the probe body and the compensation box and the cable should be treated as a transmission line in general case. So, Zin, the equivalent impedance from the cable, through the compensation box, to the oscilloscope is such that $${R_P} = \beta {R_{in}},{\rm{ }}{{\rm{C}}_P} = \frac{1}{\beta }{C_{in}}
% MathType!MTEF!2!1!+-
% feaagKart1ev2aaatCvAUfeBSjuyZL2yd9gzLbvyNv2CaerbuLwBLn
% hiov2DGi1BTfMBaeXatLxBI9gBaerbd9wDYLwzYbItLDharqqtubsr
% 4rNCHbWexLMBbXgBd9gzLbvyNv2CaeHb5MDXbpmVaibaieYlf9irVe
% eu0dXdh9vqqj-hEeeu0xXdbba9frFj0-OqFfea0dXdd9vqaq-JfrVk
% FHe9pgea0dXdar-Jb9hs0dXdbPYxe9vr0-vr0-vqpWqaaeaabiGaci
% aacaqabeaadaqaaqaafaGcbaGaamOuamaaBaaaleaacaWGqbaabeaa
% kiabg2da9iabek7aIjaadkfadaWgaaWcbaGaamyAaiaad6gaaeqaaO
% GaaiilaiaabccacaqGdbWaaSbaaSqaaiaadcfaaeqaaOGaeyypa0Za
% aSaaaeaacaaIXaaabaGaeqOSdigaaiaadoeadaWgaaWcbaGaamyAai
% aad6gaaeqaaaaa!5150!
$$ where Rin and Cin in parellel connection which equivalent impedance is Zin?


texts: What AC-to-DC adapter would I need to power two of these battery (3V) powered door contacts at once?

texts:
I'm new to electrical wiring.  I understand circuits, soldering, and basic wiring in parallel / series but calculating and understanding draw, resistance, etc. is new to me.

That being said,  I have two of these http://www.lowes.com/pd_690400-41277-3320-L___?productId=999925302&pl=1&Ntt=iris in my garage...

Here is a photo of what they look like:

I have tons of varying output AC-to-DC adapters that are not being used for anything and was wondering if I could somehow solder wires to the battery terminals of these two sensors and wire them to a single AC-to-DC and plug it into my garage wall outlet so I don't have to worry about batteries.

The battery that comes with them is a single CR2 3V lithium battery.

I suppose my question is, what rough estimate voltage output would I need to power two of these in parallel I guess? or would I wire them in series?

Any advice you can offer is very helpful!


texts: Is there any limit of how many commands it can be sent to modbus controller relay?

texts:
I have modbus controlled relay hooked to raspberry pi (using node-red) which depending on the condition sends "on" or "off" command every 5 seconds (24h/365d). I know that relays in general have its life cycle and have to be changed after frequent use, especially on heavy load - that's not what I am referring to.

I'm referring to relay having a limit on commands it can receive. The question comes after reading manuals of Daikin HVAC modbus modules that state max 50,000 commands (If I remember well). Is this a limitation imposed by the manufacturer in order to well buy more from them or communication becomes unreliable after passing that number or is it something else?


texts: Tesla coil, where do the sparks from the secondary coil ground to?

texts: This might be an obvious question, but I was wondering how a Tesla coil emits sparks that's seem to complete a circuit in thin air, and how one end of the secondary completes a circuit with the other side of the secondary. Is this circuit simply being completed by the electromagnetic radiation in the air reaching the ground and completing this circuit or is there more to it?


texts: Connect PC to CAN bus using MCP2210 + MCP2515 + MCP2551

texts: I would like to connect my PC to a CAN bus to send and receive messages. Is it possible to use MCP2210 as an USB-to-SPI converter and connect it to MCP2515 and then use SocketCAN to open a channel from the PC to the CAN bus? Will it work?


texts: Which NTP server should I use for my product to update time?

texts:
I am developing a GPRS enabled embedded device.To synchronize time with the network I have to use NTP protocol.
The nature of the product is such that I have to Hardcode the NTP server address inside the firmware and I cannot change it in future by any means. The estimated quantity of the devices to be sold is in thousand and location is India.

After googling about NTP servers I am not able to figure out which server should I use.
The given link mentions about some incidents caused due to wrong NTP client configurations.

NTP Server misuse and abuse

I don't want fall into such trouble please help me choosing correct NTP server Address.


texts:
I found a pile of these resistors, and I didn't know how to decode them using 4-band logic.

How do you know if it's to be read:

Brown(1), Black(0), Black(0), Black(0), Red(2) = 100Ohm

or:

Red(2), Black(0), Black(0), Black(0), Brown(1) = 200Ohm

Now before you get carried away, I hooked up a multimeter and I know that it is a 200Ohm resistor.

My question is, how would I be able to guarantee it is a 200Ohm resistor and not a 100Ohm resistor, using only the bands?

While looking for a picture to put with this post, it appears "grouping" plays a role on some 5-band resistors, but in this case there appears to be no grouping, but the red band is slightly thicker than the brown band. Is there a standard, or is this some form of tribal knowledge?


texts:
I have the following PCB datasheet, but I am very uncertain as to what it is saying. Some of the dimensions each have 3 numbers, which I took as nominal, minimum and maximum values, however, the sides do not add up.

The datasheet says that each side should be 4mm in length, however, adding up each of the individual components of a side does not add up to 4.

Am I reading this wrong? How would I go about designing a PCB for this?


texts:
A friend and I are working on building a smartwatch on a budget, so it’s a (very) low power project, but we are currently having a problem with the power supplying.
We already chose this board, because of its size and the BLE chip: RFduino BLE SMT
For now on, we are planning to use this battery 500 mAh LiPo battery (approx. 4V at full charge) with this voltage regulator Micrel MIC5209-3.6YS (the board supports 3.6V max.).

But the problem is that the Voltage Regulator will apparently drain by itself too much energy from the battery (by heating), reducing drastically the autonomy.

What (type of) regulator would be the best or do we need to find another battery?


texts:
I have an interest in writing a scheduler/RTOS project in XC8 using an enhanced MCU with access to the hardware stack.

I am trying to figure out how to control the creation of the software stacks so each tasks software stack will get a certain range in the general purpose ram.
Conceptually this is all easy to program in ASM but I want to be able to write C programs and have the software stacks for each task be put into the right address space.

There doesn't appear to be an option to create a separate software stack for a certain section of code or even create multiple software stacks - how do I do it?

Thanks


texts: How to auotmatically reverse a 12v motor on successive activations

texts: I am a novice looking for as simple a device / circuit as possible to automatically reverse a small gearmotor ( stall torque max .5 A, 12 V DC) powered by a 2A 12V source, wherein the motor is to come on and runs 2 minutes (based on a timer that powers the AC to 12 DC converter) in one direction. After a period of several hours the timer powers up the DC and motor for another 2 minute run. What do I put between the +,- DC supply wires and the 2 wires to the motor, such that with no intervention by a person, the direction of the motor reverses on each next activation? Pretend you are talking to someone educated to High school physics. I have been told a Finder 20.23 relay would do this. No idea at all how to connect the 4 wires described above to make that relay do what I said. Thanks in advance for suggestions or a solution. This answer could be useful for many applications where someone wants to run a motor for x amount of time to do something, and the next activation run the same amount of time in the other direction to undo the previous run.


texts: Programmatically determine what is on the i2c line

texts:
I'm working on a project that uses a simple microcontroller (I2C) master, and a component (I2C slave). When the microcontroller receives power the first thing it has to do is determine which device is on the I2C line. Only one device on the line is expected.

How would one go about determining which device is on the I2C line?

I've thought of a few ways:

Try all possible addresses for items, then search for the device ID in each item. (I've found the location of the device ID register is different on most chips).
Send out a Device ID request - but the spec says this is optional. And I couldn't find anyone relying on this.
Uniquely address each component, create a map. (i.e. This address means it must be this component.) Try each address.

For additional context, once the device is determined, capabilities are mapped in the firmware and the firmware executes.

Solution 1 sounds like a brute force approach. I'd like this to be fast, and this doesn't seem fast.

Solution 2 sounds unreliable- but maybe that's only because of my lack of experience.

Solution 3 seems possible, but then I'm limited to the number of I2C devices the address space can support.


texts: Multiple independent antennas on same PCB

texts:
Is it feasible to use multiple (e.g. 2) independently transmitting antennas on the same PCB (e.g. 5cm x 5cm) operating in the same band (e.g. 2.4GHz), though on different "frequency channels"?

I'm not sure what the radiation pattern looks like for typical PCB or modular 2.4GHz antennas, but I am wanting to have a device receive a data stream on one antenna via a (fast) proprietary protocol, and interact with another device via BLE on the other antenna.  Unfortunately the throughout needs are too high to use a single antenna with modern SoCs (e.g. from Nordic).

I was hoping if I was able to space the antennas out by about 5cm and orient them in opposite directions, then there would be minimal interference assuming different frequency channels were used.

Any explanation on why or why not this would work would be much appreciated. Thanks


texts:
So I've been learning AVR assembly in my own time, I rather like it and I understand registers/counters and such.

But the problem is...most of the websites I read online/tutorials don't really talk about actually using them with stuff like Servo's/Motors/LEDs/etc

They more talk about just doing I guess math/logic, but I'm actually wanting to control LEDs/MOTORS/Servos (especially servo's/motors...haven't seen an example yet)

Any ideas of where I could find this info?


texts: Where do I adjust forward voltage on LED

texts:
I am learning basic electronics with iCircuit. I have build a very simple circuit with just a 5V battery and a LED connected in series, as seen in the image attached.

There is an option called "Fwd Voltage @ 1A" which I do not understand.  The normal forward voltage drop for LED is 1.7V - then what does it mean if I enter "1.7V" in this field? Do I automatically add enough resistance in the circuit to limit the voltage across the LED to be 1.7V?

How do I adjust the "Fwd Voltage @ 1A" in real circuitry, or is that something rated/fixed on the LED?


texts: How to create a touch switch to use with a Raspberry Pi

texts:
I'm trying to make my own wakeup lamp. I have a lamp with a large metal base to hide all the components in. I also have a Velleman K8064 DC Controlled Dimmer Kit which I have put together and is working. I have a Raspberry pi to control it all (I also plan to use the Pi as an Android Dock)

I would like the base of the lamp to work as a touch switch to turn the lamp on and off. I've tried breadboarding a touch switch I found on www.talkingelectronics.com however when testing it the lamp is always on.

Can anyone point me in the direction of a wiring diagram of a simpler touch switch that will work with a raspberry pi?


texts: Is this gate driver circuit sufficient to drive a parallel FET spot welder?

texts:
I am building a spot welder for attaching nickel strips to Li-Ion cells to make custom battery packs.  There are plenty on the market but I wanted to use up some components and learn something.
The idea is I'll use a foot pedal to trigger an MCU to pulse a large array of FETs for a configurable amount of time, and then enforce a 1 sec cooldown period. The FETs effectively short the battery across the welder probes for this brief period of time, probably a few milliseconds but I'll have to experiment there.
The lab is here:  https://www.circuitlab.com/circuit/sfms963nw44y/gate-drive-lab-for-spot-welder/
The driver schematic:

The FET array:

I am not an electrical engineer so I am asking for help figuring out if my circuit is sound.  It's pieced together from many different online sources covering the various concerns that go into the project.  I am not providing the full KiCad for the PCB because it's not done yet, I will come back and edit to add it here.
Design Goals:

Use a hobbyist MCU (going to try out the new RPi Pico)
Minimize pulse times to avoid injecting heat into the cell

Big discharge current, shorter pulse times
Slam the FETs open and closed as quickly as possible to try to avoid the magic smoke

Other project goals:

Build the gate driver out of discrete components for educational purposes

My questions:

Is R7 sized appropriately?  Not sure what the considerations are here.
Any sizing considerations for the push-pull BJTs?  The lab seems to think that the current will be measured in microamps--but I found that quite surprising, as the point is to pull the gates high and low as quickly as possible.
Is there something I should do to isolate the controller from the rest of the circuit?
Are the gate resistors sized appropriately?  I couldn't seem to find a straight answer on how to size these things, and they appear to be necessary to make the FETs all work in unison.

Misc Notes:

D1 will be 82CNQ030 (Schottky, 30V, 80A), I didnt see a comparable diode in Circuitlab
The I haven't figured out how to size the F1 fuse yet
Vsig represents a 3.3 GPIO pin
Rtest will not be in the final circuit
I am software developer by trade, with only hobbyist level knowledge of circuit design


texts: dc machine with brushes covering more than one commutator segment

texts:
i'm a bit confused with the current that flows in a wave armature winding of a dc machine. In a wave winding, there are two current paths, right? what happens when the brush covers more than one commutator segment, let say two and a half segment.
will the current be divided between the segments?

for example, if the total current is 250A, will the armature current be 125A or 125/2.5?


texts: What type of wire should i use to make a jumper on the PCB control board from my dryer?

texts:
Sorry for my ignorance on this topic.
The relay (part G8P-1A4P 12VDC by Omron) on the PCB control board of my clothes dryer went bad. As a result, one of the pins and circle around the pin (sorry dont know the name of that ring) were destroyed.
I want to buy a new relay, take off the old one and solder the new one on. The problem is the ring around the one pin is not there. So I'd like to make a jumper between the bad pin area and the one that it connects to.
My question is, what type of wire (please be specific) is needed for the jumper? The relay has the numbers 30A and 250 VAC on it - is this the current/voltage that runs on the board itself?


texts: Compensating the forward voltage drop of a diode signal rectifier

texts:
I am reading Arts of Electronics and they are showing this circuit:

It says that D1 compensates for D2's forward drop by providing 0.6V of bias. I don't understand this circuit at all. Is the +5V an external 5v source? How does it compensate?


texts: Error (10028): Can't resolve multiple constant drivers for net "rf[7][XX]" at registerfile8x32.v

texts:
Hello Im making a register file 8x32 in verilog, the sim looks good but when I compile on quartus it makes

Error (10028): Can't resolve multiple constant drivers for net "rf[7][31]" at registerfile8x32.v(21)
Error (10029): Constant driver at registerfile8x32.v(32)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][30]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][29]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][28]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][27]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][26]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][25]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][24]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][23]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][22]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][21]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][20]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][19]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][18]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][17]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][16]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][15]" at registerfile8x32.v(21)
Error (10028): Can't resolve multiple constant drivers for net "rf[7][14]" at registerfile8x32.v(21)
Error: Can't elaborate top-level user hierarchy
Error: Quartus II Analysis & Synthesis was unsuccessful. 21 errors, 4 warnings
    Error: Peak virtual memory: 300 megabytes
    Error: Processing ended: Sat Oct 27 19:20:08 2018
    Error: Elapsed time: 00:00:01
    Error: Total CPU time (on all processors): 00:00:01
Error: Quartus II Full Compilation was unsuccessful. 23 errors, 4 warnings

// Defino todos los parametros, entradas, salidas, regs,etc.
module registerfile8x32(addrsrc1_i,addrsrc2_i,addrdest_i,dest_i,
                        src1_o,src2_o,clk_i,rst_n_i,wr_i);

  input [2:0] addrsrc1_i;
  input [2:0] addrsrc2_i;
  input [2:0] addrdest_i;
  input [31:0] dest_i;
  input clk_i,rst_n_i,wr_i;

  output [31:0]src1_o;
  output [31:0]src2_o;

  reg [31:0] rf[7:0];
  reg [31:0]src1_o;
  reg [31:0]src2_o;
  integer i; //Necesito este iterador para el bucle for, con el que lleno todos los reg de 0s.

  // Esta parte de codigo es ASINCRONA, lo primero que miro es el reset, si esta a 0 reseteo todos
  // los registros.
  always@(negedge rst_n_i)
    begin
      if (rst_n_i == 0) // Miro si el reset esta a 0
        begin
          for(i=0; i<8; i=i+1) // Si lo está, lleno los registros de 0s.
          rf[i]<= 32'b0;
        end
    end

  // Positive edge clock y write enable.
  // Esta parte del codigo es nuestra parte SINCRONA, con el reloj y el write enable.
  always@(posedge clk_i or wr_i)
    begin
      if (wr_i) // Si write enable esta a 1
        begin
        rf[addrdest_i] <= dest_i; // Escribo en el registro de destino.
      end
      else if (!wr_i) // Si WE no esta activo, el registo mantiene el valor que ya tenia.
        begin
          rf[addrdest_i] <= rf[addrdest_i];
        end
    end
  // Esta parte del codigo vuelve a ser ASINCRONA mira las direcciones de lectura

  always@(addrsrc2_i or addrsrc1_i)
    begin
      src1_o <= rf[addrsrc1_i];
      src2_o <= rf[addrsrc2_i];
    end
  endmodule


texts:
The attached circuit works fine. The LED turns ON when SENSE PROBE and GROUND PROBE are NOT attached. The circuit is fed by a 5V battery. Somehow, the LED is not bright enough to begin with, but I could live with that. Now I am trying to add a small buzzer that also goes off whenever the LED is ON.
Adding that buzzer directly with the LED does not work. I measured the voltage across the LED and it was about 1.84V. That is not enough to trigger the buzzer. Connecting the buzzer to 5V and ground works fine. Is there a way to add a low current relay so that it turns ON the buzzer with the LED?


texts:
Exploring some fab houses and I came across this statement from https://www.viapart.com/PCB/Explain

"Minimum slot aperture
Mechanical drill 0.6mm The tolerance of groove aperture is±0.1mm"

Does this mean that the smallest hole they can make is ~24mils with an annular ring of ~4mils ? If not, what does Minimum Slot Aperature mean ?

How could one extract annular ring size from their description ?


texts: Planning to make a pen-like device which has a roller rolling on a surface and measured its linear distance travelled

texts:
I am planning to use a microcontroller to do the brain works of receiving pulses from the encoder and  compute it to output linear distance and at the same time indicating the measured distance as short, medium or long (of course that means I'll write a simple program for classifications/ranges of distances).

The encoder I chose is of reflective type.

My idea is similar to the case of a digital vernier caliper where the distance measured are constantly displayed on the lcd screen.

I suppose the way to do it will be something like to count the number of pulses over the entire length of signal? How to make the microcontroller to do that? will the microcontroller reads a binary number of 10101010... as the signal? if so, all I have to do is to translate these binary number to decimal then subsequently extract the angular displacement?

please tell me whether am i right lol


texts: How can I improve USB EMI insensitivity?

texts:
I have several devices and some long cables on my PC's USB buses and every now and then I get a message like hub 6-0:1.0: port 2 disabled by hub (EMI?), re-enabling... on my Linux machine. Especially the devices on my desk (keyboard, mouse, 2 Arduino's) are being disconnected and reconnected. These devices respond to electric shutters for the windows, but also from passing motorbikes.

What can I do to improve immunity to EMI?

Tried ferrite cores on the mains cable of the shutters and some other equipment, but doesn't really improve much.

Bus 006 Device 025: ID 1a40:0101 Terminus Technology Inc. 4-Port HUB
Bus 006 Device 026: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC
Bus 006 Device 027: ID 03f0:0324 Hewlett-Packard SK-2885 keyboard
Bus 006 Device 028: ID 046d:c046 Logitech, Inc. RX1000 Laser Mouse

Moved the keyboard off the hub, errors still appear.
Moved the mouse off the hub, errors still appear.
Moved the Arduino off the hub, errors still appear.

Eventually replaced the long extension cable with a shorter one and haven't had any errors for over a day. The longer cable is required to reach my desk though without cables dangling halfway in the air.


texts: 4x4 keyboard matrix not generating unique keycodes

texts:
I have a 4x4 keybord matrix fsm scanner but it generates only high keycode setting all last 4 bits to 1 and second and fourth digits to high.
Is there anything wrong in my code here?

module keyboardScanner (input clk, input [3:0] col,output reg [3:0] row, output reg [7:0] keyCode);
reg [1:0]state=2'b00;
reg [1:0]nextState=2'b00;

//state register
always@(posedge clk) begin
    state <= nextState;
end

//output CL
always@(posedge clk) begin
    case (state)
    2'b00: row <= 4'b0001;
    2'b01: row <= 4'b0010;
    2'b10: row <= 4'b0100;
    2'b11: row <= 4'b1000;
    default: row <= 4'b0001;
  endcase
    if (col != 4'b0000) begin
    keyCode <= {row[0],row[1],row[2],row[3], col[0],col[1],col[2],col[3]};
    end
end

//next state CL
always @(posedge clk) begin
        case (state)
            2'b00: nextState <= 2'b01;
            2'b01: nextState <= 2'b10;
            2'b10: nextState <= 2'b11;
            2'b11: nextState <= 2'b00;
            default: nextState <= 2'b00;
        endcase
end

endmodule

Please help me. It used to work 2 days ago, but now... :/


texts:
I am trying to build a suitable pull-switch for my invention. Inside the switch, there is a tiny metal plate. When the user pulls the switch, this metal plate gets close to and makes contact with two metal structures and forms a closed circuit which is connected to a digital pin on an Arduino.

The problem is that I need this to function for up to 10 million cycles or more, and I'm neither a eletrical nor a mechanical engineer so I have no idea if it will hold that long. I have designed the two metal structures so that there should still be plenty of area in proximity to the metal plate (less than 1 millimeter away) after expected bending, wear and tear, but apart from that I have no idea what other problems I might encounter.

My three questions:

Are there any other issues I need to consider for 10 million cycles?

Can the Arduino handle that many cycles?

Suggestions on suitable material for the metal plate and structures?


texts: I need help to solve my melting switch problem

texts:
I have used a 20A 12VDC switch which by-passes my air-conditioning climate switch in the car which is not functioning, and yes... The 20A melted. My car battery is 12V. I have a glass fuse installed before the switch which is 20A.

I can't get a spare AC climate control switch, as in my country there are none. This is my second purchase of a 20A switch.

I seriously need help.


texts:
I have a question regarding impedances. While it is intuitive that \$ R \$-element has impedance \$ R \$, it's not so easy for me to figure out impedances of \$ L \$ and \$ C \$.
Here is my, probably incorrect, reasoning. For element \$ C \$ following differential equation is satisfied: \$ i(t) = C \frac{\mbox{d} u}{\mbox{d} t}\$. Our input is \$u\$, and utput is \$i\$. By transforming this equation we have
$$ \frac{U(s)}{I(s)} = G(s) = \frac{1}{sC} $$
Since we cosider only sinusoidal inputs we know, that output will also be sinusoidal of the same frequency, but different magnitude and phase, so it's fine to use Fourier instead of Laplace, then let \$s:=j \omega\$, then
$$G(s)=\frac{1}{j \omega C} = -j \frac{1}{\omega C} $$, which is indeed equal to impedance of element \$C\$.

Now - is that a coincidence, or the actual reasoning behind impedances and whole method of solving circuits based on them? If so, why take \$u\$ as an input, and \$i\$ as an output? Is it to make analogy to well known \$R=\frac{U}{I} \$?

If I tried to use not necessarily sinusoidal voltage and current, would I use the more general form: \$\frac{1}{sC}\$? Would it work?


texts: What are the LE (latch enable) and the CLK (serial Clock) pins on the TQM8M9077?

texts: I'm new here, so bear with me. I'm working on a sdr board for a raspberry pi and I have selected the TQM8M9077 as my DVGA. While looking at its datasheet and I came upon a few questions. What are the LE and CLK pins on the IC?


texts: Power dissipation versus power consumption

texts:
I'm currently running some power dissipation analysis or thermal calculation on a system and the way I do it is by looking at each part's data sheet and see if they list its power dissipation.
Now some part's data sheet list power consumption and some other show the power dissipation.

My questions are:

How can I estimate the power dissipation if the only power listed is the power consumption? I think that power consumption is different from power dissipation, isn't that right?
Is the power consumption the power at the input of the electrical part? For example: how would I calculate the power consumption of a 30 watts power supply (120VAC input and 24V/1.25A output)?


texts:
I need to use this stabilizer for a sensitive electronics equipment. The equipment is at outdoors so this was recommended by some before me to possible suppress spikes urges ect. Aside from an isolation transformer I have never encountered such device before even the name. It has mains input(I guess the grey plug) and output(I guess the black socket) and a rocker switch on it. And in the data sheet not much is written.

Did anyone have encountered such device? It seems like an isolation transformer with extra filters embedded?

I'm also stuck with another point that whether I need an RCD before this device. I have been told that there is no RCD where the equipment will be placed. Or since this unit has isolation transformer RCD would be redundant?


texts: I have an existing OMRON Temperature Controller with a temperature input requirement of Pt100. Is there other way to maximize my Pt1000 in order to used it as Pt100?