source
stringlengths
620
29.3k
target
stringlengths
12
1.24k
Step down transformer without coil? Isn't it possible today to make a down-transformer without coils, without the idea of induction? After all, the AC reaches every voltage in-between, so all we have to do is keep cutting the power flow and only letting current pass when the wave is at the desired voltage. Of course, this will be a series of pulses but it can be smoothed out with capacitors. <Q> Is it possible to make a step-down CIRCUIT without coils? <S> Sure, we typically call them "lamp dimmers" or "motor speed controls", etc. <S> etc. <S> There are millions of examples all over the globe. <S> There may be one within a few meters of where you are right now. <S> Is it possible to make a (whatever) <S> TRANSFORMER without coils? <S> No. <S> By definition a transformer (in the ordinary sense) is made with one or more windings ("coils" if you will). <A> There are 2 kinds of reactive transformers. <S> Inductive and Capacitive. <S> But an R divider is Not a transformer. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> This is the most common high voltage transformer for low power. <S> simulate this circuit <S> Then we have R1/R2 dividers and PWM open close switches where the shunt R2 n series with PWM toggle between R2 and open cct thus R2'=R2/%d.c. <S> ... <S> or Triac Phase controlled switches which are similar to PWM but at line rate. <S> ---- <S> then there are motor / generators which can transform both voltage and frequency in ratios. <S> However the most popular practice today is to step up AC to higher DC with active PFC then DC-DC to step down with inductors in stead of use heavy bulky expensive cold-rolled grain oriented laminated steel core transformers for step down DC converters. <S> This method has become mandatory in the EU for PSU"s >100W due to the THD overload of distribution transformers neutral wire harmonic currents from too many poor power factor rectified line caps. <A> Sure is possible. <S> What you want is a cycloconverter. <S> Overview of cycloconverters <A> Yes, it's possible to do that with an electronic switch that opens once the input AC voltage exceeds the desired output voltage, on each cycle or half-cycle depending on whether the input is half-wave or full-wave rectified. <S> This Design Ideas article illustrates a method using only discrete components. <S> No coils needed, but the input does have to be something like a sinusoid (no square waves). <S> With square wave input the pass device would have similar losses to a linear regulator, while causing a lot more EMI. <S> It does not have very widely useful applications because it puts a lot of harmonics into the input power, but it does work nicely and losses are not necessarily high (the peak current is higher than that of an equivalent rectifier-capacitor filter because the input voltage is higher so the dv/dt is higher) . <A> All of the methods involving motor/generators or cycloconverters are still going to have coils and induction, so do not fit the OPs desired solution. <S> But as alluded to, it can be done electronically with high speed solid state switches, as long as you only want to REDUCE the AC voltage. <S> Do a search on "Phase Angle Voltage Control" for details that are too long to post here. <S> But in a nutshell, that's exactly what it does, delays the firing of a thyristor (SCR) so that only a portion of each sine wave gets through and results in a lowering of the RMS voltage. <S> The main difference however is this; in an electronic voltage controller, the CURRENT on the output will be the SAME as the current on the input, just at a lower voltage, so the POWER is LOWER . <S> With a transformer, the current on one side <S> it <S> DIFFERENT from the current on the other side by the ratio of the windings <S> (inverse of the voltage change), so the POWER is the SAME . <S> There are losses involved in both methods, so for simplicity, call them the same. <S> The capacitor method, also called a "voltage doubler" circuit works too, but only if the desired output is DC, plus becomes incredibly cost prohibitive compared to transformers in higher power levels. <A> (You can make a current changer with (switched) capacitors.)
The only way to make a voltage changer that can (in therory) be lossless (100% efficient) is with inductance(s).
Am I having an impedance issue in a cable between two devices? And if so, How can I resolve the issue? I have two devices, device 1 and Device 2. The devices are approximately 60 feet apart connected to each other through a long cable. They communicate with each other at 2400bps synchronous serial using the single clock source. Device A needs a clock for input and output clocking. The current design has an "In Cable" loopback of the clock as shown below to provide both needed clocks. Sometimes it was noticed that Data In of device A would not receive data. When this situation occurred, device 1 could check the incoming RX clock (Which should be at 2400bps) and it would be at a value that was not 2400bps. It would usually be a multiple or more of the original 2400bps clock. Values such as 4800, 7200 and other values have been seen at Device 1. Th obvious reason that data was was not coming into device 1 is that the clock was invalid for the Data (which was clocked at 2400bps). If I try to put an O-Scope up to the clock signal into deice 1 to see what it looks like, it immediately clears up and is seen as 2400bps. We have 20+ data paths with this configuration. Some work and some do not. Swapping cables may make bad paths work, or might make them not work. Using cables known to work between two different device might cause the path not to work. All cables are professionally made and I do not think it is a cable issue. It is unpredictable what device/cable set will work or not. I am not an EE but have been researching this issue and I think there could be some impedance issue at device 2. The clock signal could be reflected back and forth between device 1 and 2, ultimately the RX clock IN on Device A giving improper clock signaling, and thus no Data in at Device 1. I have read that some resistor or capacitor added in the path can cut back this issue, but I am not an EE so I am not sure if a) this is an impedance issue and b)where would I put a circuit to fix it. Someone has mentioned an inline 22.5ohm resistor to start. Someone else has mentioned anything <100ohms. At this point, I can not tell you the output impedance of device A. it is an old component and is currently undocumented. <Q> Your suspicion is likely correct, you have impedance mismatch somewhere, including unbuffered clock loopback at device 2. <S> You also omitted any information what kind of cable is in use, what impedance it has. <S> But you already have mentioned the solution. <S> Put a 10pF cap at the Rx end, same place where you did connect your scope. <A> What is the input impedance of your scope set to when you check and it gets better? <S> Typical options are 1 megohm or 50 ohms (the latter usually switchable if it's an option), possibly some other options depending on scope and probes. <S> A capacitance value is also usually listed (mine is 1 MΩ & 20 pF) <S> Try a resistor of that value at device 1 where you were connecting the scope probe (presumably between clock in and ground.) <S> You might also want to replicate the capacitance to fully replicate the impedance. <S> If you were using X10 probes that will affect the values that you were actually applying to the circuit under test. <A> There are several concerns with this; Signal quality, ESD protection , immunity on cable connection, crosstalk, Noise nearby radiated and coupled to cable. <S> ground currents causing injected noise, RF ingress etc. <S> Perhaps you can define the driver, receiver chips, cable type ( UTP bundled or TP shielded etc 120 Ohm or CAT5 or whatever) and scope signals. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> Signal integrity is a common issue, although 2400 baud is easy to send asynchronously by RS-232, logic levels can be very unreliable unless terminated with some impedance near the threshold, usually Vcc/2 and often in the range < 300 Ohms or even 600 or less Pull up and 600 pull down. <S> using R terminator SIP or DIP packages for ease of connection on board. <S> There is also a standard driver used for controlled impedance called RS-485 which controls the signal using twisted pairs. <S> YOu may not need this <S> but you may need to attenuate stray noise that is on the signal and ground as well as the signal between signal and ground. <S> This is call Common Mode and Differential noise. <S> Generally it is best to use Schmitt Trigger gates for receivers or something with controlled Hysteresis <S> > <S> the expect noise level. <S> or filtered with an RC low pass filter or add Ferrite choke around cable. <S> or.... <A> It sounds as if you are sending data differentially end-end <S> (is it twisted pair wiring?), but you do still need a good ground/Earth reference for the system. <S> I wonder if you are having a ground/Earth problem between devices. <S> The hint is that when you connect your Oscilloscope the problem disappears. <A> I know it is a little late, but after successful testing, we redesigned the cables with 100 Ohm resistors in the clock lines. <S> This solved the clocking issue and our first systems worked perfectly. <S> Thanks again.
It is likely that signal/clock edges have excessive ringing, which confuses the receiver, either double-clocking occurs, or else.
Powering MCU with capacitor during short power off when MCU VCC comes from LDO? I'm trying to create a solution to power an ATtiny85v MCU for maybe two seconds after a power loss to perform some power down tasks, but I don't have much knowledge with electronics. I did some searching but couldn't find an answer to my specific scenario. The MCU's power is coming from the output of a LDO (Microchip MCP1703T or similar). With my limited knowledge, my idea is to use a capacitor across VCC and GND of the MCU to keep it running for up to two seconds. Powering the MCU with a capacitor has been covered in other questions here, but in my case the capacitor to power the MCU has to be much larger than the specified largest output capacitor of the LDO. Without any components between the MCU's "power off" capacitor and the output capacitor of the LDO, these two capacitors will be parallel connected. Wouldn't that just be the same thing as a single larger capacitor as LDO output capacitor? It would be much larger than the allowed largest output capacitor for the LDO, possibly causing stability issues. How would I go about solving this? A few notes:I will be doing this on a 17mm board already populated with components for other things and have very limited space. Also, how to detect power loss and how to run the MCU in low power mode is not of interest for this question unless it is of importance to the solution. <Q> Yes, regulator stability could be affected by the added capacitance. <A> I've been doing some testing so I can now add an answer myself for future reference. <S> I got the best results by putting the cap after the LDO. <S> To prevent reverse current draining the cap during power off I used a LDO that does not let any reverse current through. <S> The one I'm using is the LT1761. <S> On detected power loss I put the MCU to sleep (sleep mode power down) and set a watchdog timer to wake up the MCU every 120ms to check the voltage with ADC (prescaler division factor 8 to save power), then go back to sleep if the power has not returned. <S> With a 47uF capacitor I was able to measure just over 2 seconds of power off before the capacitor was drained, which is enough for my purposes. <A> The above answer is a solution, however, if you need to power MCU for 2 seconds after power is cut, you need a big capacitor. <S> Even if the current consumption is very less. <S> You can make a isolated power source which is bypassed when the power is live, but comes into play when the power is cut. <S> (read Schmitt Triggered - Clean Op -Amp Circuit). <S> I could post a working circuit, but i would refrain from doing so. <A> As Lundin says in "comments", the storage capacitor from LDO input to ground keeps the regulator operating - that's the simple solution. <S> Its size will depend on current draw through the regulator. <S> Start by measuring this current with an ammeter between your power source and regulator. <S> Perhaps you know under what condition your microcontroller consumes most current - use this to size the storage capacitance. <S> When your LDO has a higher input voltage (than output voltage), you can get by with a smaller capacitor. <S> Your more difficult problem is detecting a loss-of-power. <S> To be done before the regulator and the storage capacitor. <S> A logical signal to your microcontroller is required, one logic state says "power good", the other logic state says "pending loss-of-power". <S> Perhaps you can use one of many power-on-reset (POR) chips to generate "power good". <S> Read this note about the theory of supply start-up. <S> It also discusses power-down detection and the risks involved. <S> Your battery voltage monitor might be useful for detecting the pending-loss-of-power condition. <S> LDO data sheet specifies a slow start-up time of 1000uS (to prevent output voltage overshoot). <S> It does not specify how output voltage falls, but it is safe to assume that output voltage is always equal to or lower than input voltage. <S> To use voltage monitor as a pending-loss-of-power detector, it will have to be polled often. <S> Possibly a job for the microcontroller watchdog function. <S> An on-off SPST switch that kills battery power makes the power-loss-pending circuit simple - monitor battery voltage after the switch. <S> simulate this circuit – <S> Schematic created using CircuitLab
Assuming your required current is relatively low, simply adding a series resistor to the much larger capacitor (or using an electrolytic type with high ESR) should ensure stability without causing too much voltage drop when the added cap is sourcing current.
LED Flickering on Mains I've just bought 10m of 220VAC LED Strip yesterday just to found out that it flicker so bad on mains. My country is using the 220V 50Hz as their mains.Anyone can help me on a way to reduce the flicker? What I'm thinking is adding a 0.47uF 400V caps before the LED.. Is it a good idea? Or are there any way to lessen the effect of flicker? I don't need it to be completely gone (as it is pretty much impossible) I don't want to throw this strip and buy 12v or 24v ones because I've already bought 10m of em and the store doesn't have a return policy. EDIT: Since many people asked for a schematics.. I don't have any, but I forgot to say that it is indeed an SMD 5050 LED, will try to find any schematics for that. And here's a pic to it http://imgur.com/16Yg96a For anyone who's wondering what is written on the R, it is 391. Sorry for my camera. <Q> Rev x <S> ** <S> From reviewing your Photo, I misread 60-D-16R as 16Ω but in fact 391 is correct and \$16E\$ is upside down was my misteak <S> ----------- <S> Plan C <S> Assuming 33 mA, 390Ω, Vtot <S> = 2.8V*4 + <S> 390Ω*0.033A = 24.07V ... <S> *0.033A= <S> =0.8W <S> With 60mm pitch 10m yields ~165 in parallel or 165*0.8W/string = <S> 132W max. <S> or 13W/m or 24V@5.5A using a Laptop universal charger ( if you can find... usually all are 19.5 V now) <S> Old info from insufficient data and poor description for historical ruminance <S> Plan B ( based on poor specs)- <S> Measuring the Photo the 4LED + 16R , pitch is 60mm and total power @14V= 2.367W <S> /m - <S> Thus 24W per 10 m minimum. <S> cooler. <S> - Suggested Supply Tolerance 14V+/-0.2V @ <S> 2A min pref 3A <S> - 12V will work but dimmer. <S> In order to smoothen the flicker let's do some calculations. <S> First you need a bridge rectifier to make rectified AC into DC. <S> Second , the decay time between 10ms pulses needs to attenuate 100Hz by at least 20dB or 10:1 in current to be significantly attenuate flicker. <S> if they did something like use 2 diodes to run 1 string in + and another on - then the flicker rate would be really bad at 50Hz. <S> So what value C is needed and at what cost? <S> I know that 10% ripple uses RC=8 t and R=10~15 Ohms (approx) per 65mW~100mW white LED. <S> For an RMS voltage of 220V , let's assume there are 330 LED's split into 5 strings of 66 in series or 5P66S with a Vf of 66 <S> *3V=198Vdc the stripleds resistance when above 198V becomes 166 <S> *15R/5 <S> ~500 Ohms thus C=80ms/500 Ohms=160uF !! <S> at >400V rating with a series drop resistor of 20V/(20mA*5P)=200 Ohms @ <S> 2W <S> You can substitute your values and see if you want to retire it or rewire it with a bridge , **cap , power resistor . <S> have fun and get extra R in case it is too bright or too hot. <S> The resistor must be flame proof and rated for line voltage. <A> A detailed circuit diagram is needed for a more definitive answer, but here goes my best guess. <S> LEDs require "pure" DC to not flicker. <S> Most likely there is a diode rectifying the mains voltage. <S> This only provides pulsed DC, thus causing the flicker. <S> What you need is to filter the pulsed DC and get it closer to pure DC. <S> The size of the cap will depend on the amount of current needed for the LEDs. <S> However, the voltage should be at least 600 AC <S> and you need to connect it to the node formed by the diode and the start of the LEDs string. <S> You should also add a 1 megohm across the cap to bleed it off, when not in use. <S> Based on the additional information, it appears that you have one resistor limiting the current to four LEDs. <S> Each set of resistor and 4 LEDs, drop approximately 12v, so there are probably 20 "sets" (80 LEDs) connected in series (20 x 12v = 240v). <S> If there is no rectifier, it means the LEDs are the rectifier. <A> From the picture that you've posted it looks a like a regular 5050 led strip that is powered from a 12V supply. <S> It also looks like parallel connections of 3 leds in series. <S> Each of these leds take about 30mA. <S> If you have a full 5m strip on a reel which has 300 leds in it, that's 100 parallel strips each with 3 leds in series. <S> Which means you'll need a supply that can supply 100 x 30mA which is 3A. <S> Note that you won't be able to power them directly from the mains supply. <S> You will need to step it down to 12V. Look for simple rectifier bridge followed by a regulator circuits online. <S> There are plenty of them. <S> In case you don't want I build one on your own <S> there are plenty of 12V, 3A supplies available online . <S> These supplies usually operate from 100-240V mains AC.
If all this is correct, you can reduce the flicker by using a full wave rectifier, a 200uf cap, and a 10 megohm resistor, to rectify and smooth out the DC.If you need more detailed information to build it your self, let me know, but if this sounds unfamiliar to you, I recommend you get a 220v DC, 100ma supply .
What is the difference between electrical engineering and electrical engineering technology? I have recently found that someone can get a BS. in Electrical Engineering and a BS. in Electrical Engineering Technology. I'm trying to find the fundamental difference between the two, but the only thing I can find is that EE deals more with AC currents and power, while EET is more focused in device-controlling circuits. What are the fundamental differences between the two? are there an parts of EET that shouldn't be discussed on EE.SE? <Q> It isn't a complete distinction between theory and application since there is always some overlap <S> but this was the main distinction when I attended ITT Technical institute's Electronics Engineering Technology program. <S> This is also one of the main differences cited by ABET which accredits some of these programs: Engineering and engineering technology are separate but closely related professional areas that differ in: Curricular Focus – <S> Engineering programs often focus on theory and conceptual design, while engineering technology programs usually focus on application and implementation. <S> Engineering programs typically require additional, higher-level mathematics, including multiple semesters of calculus and calculus-based theoretical science courses, while engineering technology programs typically focus on algebra, trigonometry, applied calculus, and other courses that are more practical than theoretical in nature. <S> Another area that can differ is career path. <S> EET questions are appropriate here. <S> See this answer about how the name was chosen and the history of the site. <S> Keep in mind that, there are some things that you may get better answers to in different places like physics.se or mathematics.se <A> Leaving the BA, BS or BE degree for what the are. <S> The fundamental differences could be explained as follows: <S> The primary role of an electrical engineering technologist is to aid the electrical engineers with electrical power distribution, process control, and instrumentation design. <S> Duties of this position include conducting statistical studies and analyzing costs of production for non-sustainable and sustainable designs. <S> Electrical engineering technologists analyze the performance of assemblies and electrical components, as well as assist scientists and engineers with electrical engineering research. <S> -- Payscale description of EET Electrical engineers are responsible for implementing and designing components for any device that uses electricity, as well as the devices themselves. <S> Engineers have to focus on the generation of power to the device or product. <S> These devices can include anything that runs on electricity. <S> Electrical engineers also focus on researching, creating, and improving products and devices. <S> -- Payscale description of EE <A> The "official" descriptions are essentially meaningless outside of academia. <S> In the working world, there is little difference paid to it once you get out there and get experience. <S> But a BIG difference in terms of your career path is that in many states, you cannot apply for an Electrical PE (Professional Engineer) license with just an EET degree, it must be an EE degree. <S> In states where you can use another "lesser" degree, you typically need a lot more years of experience. <S> That means if you want to work on your OWN as a licensed PE, you can't with an EET degree, you will have to work for someone else. <S> I have a BS EET and discovered that after the fact. <S> So I have to worked for someone else, I cannot be the principal of an engineering firm. <S> Ultimately, that has had little effect on my 30+ years of a successful career and to be quite honest, I don't really want the stress of owning my own company any more (I owned a Systems Integration company for a number of years). <S> Money is important, but it's not everything.
My understanding is that engineering degrees are more theory based and engineering technology degrees are more application based.
Amp Draw On Battery Over Time & Battery Run Time Can someone post a formula / help me figure out how to figure out the battery run time for the following scenario? I have a single 12v led light bulb with a draw of 510mA @ 12v and 1400mA @ 8v. If I start with a AGM 12v 80Ah battery and let it run for say 10 hours how do I figure out the run time given that the amp draw will rise as the battery is discharged? I know battery discharge is non-linear so I am not sure how to calculate. Also it is worth noting that I plan on using 4 of the these light bulbs so ultimately I need to also calculate that in as well. Battery Specs: Product ID: 24M-XHDCranking Amps: 1000Cold Cranking Amps: 800Voltage: 12Termination: Common Code MWeight (lbs): 44.6Width (in): 6.88Length (in): 11.00Height (in): 9.50ReserveCapacity-25: 135.00WET/DRY: W <Q> Your LED is clearly operating as a switching regulator. <S> The current draw is almost certainly not steady, unlike an incandescent lamp. <S> How do you know your current meter was reacting properly? <S> If you used a true RMS voltmeter to measure the voltage across a known small series resistance, and calculated RMS current thereby, how would it compare to your meter's reading? <S> It is highly possible that your current meter was, effectively, lying. <S> In which case you know nothing useful for calculating battery life. <S> You have to know your tools, and their strengths and weaknesses, in order to use them effectively. <S> Cheap meters often read PEAK values, and the less steady (and/or sinusoidal) <S> the waveforms, <S> the worse they lie. <S> Your LED wants to suck more current as the battery exhausts, in order to maintain brightness, at which point the battery is also least able to provide current. <S> Also, drawing a 12V battery down to 10V will seriously damage its longevity. <S> A lose-lose proposition if there ever was one, so don't do this! <A> What you need is the battery capacity, usually expressed in Amp-hours. <S> If you want to run something that takes 510 mA for 10 hours, then it will drain 5.1 Ah from the battery. <S> Any 12 V car battery will handily exceed that minimum rating. <S> Car batteries don't like to be deep discharged, so plan to use only half the rated capacity. <S> At that level, the voltage will be fairly close to 12 V the whole time, so you shouldn't have to worry about the 10 V draw. <S> In any case, are you really sure about this light taking 1.4 A at 10 V, but only 510 mA at 12 V? <S> That sounds really odd and implausible, like maybe you read something wrong. <S> This implies it uses 6.1 W at 12 V but 14 W at 10 V. <S> Where do the extra 7.9 W go? <S> If it has a switching power supply I could believe a little less efficiency at 10 V compared to 12 V, but not such a whopping change with just a little less input voltage. <S> Something isn't right in what you're telling us. <A> As noted the current drawn by your LED bulbs seems to indicate something active inside. <S> But your battery (as far as I see) is rated at 75 Ah. <S> Fully charged it will have a terminal voltage around 13.4 V and fully discharged you should not go below about 10V.Assuming the 0.5 <S> A discharge rate is correct then to consume 75 <S> Ah would take 150 hours. <S> If you run 4 bulbs you'd expect 37.5 hours. <S> The discharge curve for the battery is non-linear, but if you plot the bulb current from 10 V to 13.4 and take an middle point, you should not be far off. <S> I'd measure your lamps on your power supply again, you should measure a sharp knee below which the current (and light output) drops dramatically. <S> If from the knee the current goes up linearly with applied voltage then you don't have active components in the bulb. <S> If the current goes down as you increase the voltage then you may have some type of buck/boost regulator circuit in the bulb. <S> ... <S> though it seems a rare beast indeed.
You need the RMS current of your LED lamp, at its operating voltage, divided into the Ah rating of your battery in order to know your system's operating time.
What would an inductor be doing here, and can I replace it with a jumper? I have a small board camera to fly first person view on a quadcopter. The camera outputs a PAL/NTSC analog video and is powered off of 12-17 volts (I'm assuming this is regulated) During a crash, what appears to be a surface mount inductor came off of the board, and the camera doesn't work anymore. The inductor is close to a surface mount SO-23 component marked A7 (a high speed two diode package) and a bunch of discrete resistors/capacitors. My research turns up surface mount inductors have very, very small values (in the tens of nH). It would be too small for a switching regulator, and there isn't any other reason I can think of for there to be an inductor on an analog camera. Since the loss of the inductor, the camera does not output anything. Since this inductor is likely of a small value, can I replace it with a short loop of wire? Or is it a serious risk to assume that the exact value of the inductor is unimportant? Update: jumping the pins did as expected, the camera turns on but is very prone to interference. Since it's right next to a 5.8g receiver, four brushless motors modulated at 24khz and a bunch of other stuff, it picks up a lot.So that means that it was a ferrite bead. Can I replace this with a loop of wire wrapped around a ferrite ring, or is that long bit of wire still going to pick up garbage? Update 2: I dismantled a CD-ROM drive and took the ferrite bead. The camera still turns on, but if anything the interference is worse than just with a jumper. I'll try a proper inductor next and see what that does. <Q> This is likely a component called "ferrite bead". <S> It is used for filtering high-frequency noise on power rails. <S> The beads are rated by current carrying capacity, DC impedance, and impedance at 100MHz or something like that. <S> It looks like a 0805 size. <A> You cannot tell by looking what a SMD is. <S> It could be an inductor or a resistor or a capacitor or even something else. <S> Was loss of the mystery component the ONLY casualty of the crash? <S> Do you know for certain that no other parts were damaged? <S> If the inductor is simply part of a filter circuit, yes, you might get away with shorting across the pads. <S> However, if the inductor is part of a buck regulator circuit (or some other active circuit) then it is possible that you could destroy the board by such an uninformed substitution. <S> Of course, if the board doesn't work anyway, maybe it is worth the risk to you????? <A> I would expect it to be 1~10uH 0.1~0.5A <S> for a DC-DC converter 500kHz to 2MHz from the best suppliers such as Taiyo Yuden or TDK <S> The input 12~17Vdc needs to be regulated for video processor probably <S> 5V. <A> The interference tells the story - it is a ferrite bead.
It can be replaced by a jumper, but a better way is to get any ferrite bead from Digi-Key, or "borrow" similar bead from some scrap board (old hard drive, CD-rom drive, etc.)
Phase shifting DC+AC audio signal without affecting its DC content I have a strongly and asymmetrically clipped audio signal (green signal on attached picture), with DC bias content (blue signal). In order to obtain the exact DC bias level of this composite signal later, first I would like to phase shift the signal with 180 degrees, without affecting its DC content (red signal on the following picture). The inverting op-amp configuration change the polarity of the DC content too, it can not be used in this case. Is there any possible solution in the analog signal domain? For the time being I don't want to switch to digital domain. <Q> to obtain the exact DC bias level of this composite signal <S> Use a low pass filter - it will average the signal and give you the DC level. <S> Of course, you will need to take into account that a low pass filter will take time to settle to the average value and that there will still be some rippley artefacts left from the AC content of your signal but by choosing the correct number of stages you will get a small ripple that will likely be acceptable to use. <S> Following a discussion it appears that the op wants the dc level representative of the on-off periods being equal <S> so: - The comparator turns the analogue signal into a square wave. <S> If the duty cycle isn't 50:50, the integrator raises or lowers the comparator threshold until it is. <S> Bingo, there's the output. <A> It will delay the signal without changing the frequency content. <S> They are described here; <S> All pass filters <S> No, the all pass filter will not average the signal. <S> That is what all pass means. <S> Here is a simple second order all pass; <S> Here is the output at 100Hz; <S> The loss in gain can be made up in a following gain stage. <S> Here is the output at 1kHz; <S> This is starting to show errors at 3kHz; <S> So, it can be done. <S> Now you need to generate the specitication for the all pass you need and design that. <A> Your method of extracting the bias voltage will only work if you know the nature of the original AC signal and can infer the zero crossing point from its shape. <S> It will not work for an arbitrary waveform which has been distorted by your circuit. <S> For example, imagine the output is a square wave going from 0 to 1V. <S> How much (if any) of the bottom half of the original wave has been cut off? <S> You don't know! <S> What shape was the cut off part? <S> You don't know! <S> Since that information has been lost there is no way to reconstruct the original AC waveform, and no way to determine its average value (DC bias point).
What you need is an all pass filter.
Figuring out how much torque dc motor will need to run at a certain speed. (E-skateboard project) Suppose I want to purchase a DC motor online, how can i determine how much torque my motor will need to run at a certain speed? I.e. 15mph This is for my electric skateboard project and the load on top of the board will be 140 lbs. Really having a hard time figuring this out and was hoping someone can share their knowledge. <Q> Get a friend to tow you behind a car while you ride a conventional skateboard. <S> Use some type of spring scale to measure how hard the tow rope is pulling you. <S> That force, multiplied by the radius of the skateboard wheel, is the required wheel torque. <S> If your skateboard uses a drive-belt, then the motor torque will be different than the wheel torque. <S> The rope should be long enough that you are not in the slipstream of the car. <S> I suggest you take measurements at several speeds and also while going up and down a few hills. <S> Make sure you record both speed and force. <S> The speed component will allow you to calculate power as well as torque. <A> I don't know if the same is true for skate boards but for bicycles you can find online calculators like these; Cycling calculator . <S> I would think at 15mph the rolling friction and wind resistance would be similar. <S> For me this calculator says 160lbs of me and 20lbs of bicycle take 110 Watts. <S> In this case, I'm the motor and putting out about 100rpm at the crank. <S> Your motor will turn a lot faster. <S> It turns out on the mechanical side the power a motor puts out is equal to the motor speed in rad/sec times the torque in Nm. <S> Now if you search for small motors like this you might come up with these; Maxon 150W Motors <S> You need to know your battery voltage. <S> If you pick one of the 48V motors and run it on the fast side, to get good efficiency, say 7000rpm. <S> This is about 700rad/s. <S> So this motor would be at 110W/700rad <S> /s <S> = 0.15Nm. <S> If you picked a different motor that was most efficient at 3500 rpm your torque would double to put out the 110 Watts needed. <S> See? <A> Torque is about acceleration, not about speed. <S> To calculate the actual acceleration, you need the impulse required, which is governed by the load to accelerate. <S> In contrary , the top speed is limited by the driving power your whole arrangement needs and has. <S> The motor torque goes into that equation but not the impulse and thus, not the load on top of the board (because it isn't accelerated any more). <S> Instead, losses get important. <S> Most influencing losses come from the wheels on the ground (but then: more loss there leads to higher possible acceleration – no slippage) the loss of the gear (but then: a worm gear may be much smaller) and head wind (don't laugh <S> : wear a cape and see the difference, plus: wind losses go up with \$v^2\$) <S> You have to find out these losses first to calculate the top speed possible. <S> That's what mopeds have. <A> What makes you think you can build one cheaper than buying one engineered with over 10 man years of R&D and low cost materials in China? <S> I say this, not to discourage your thinking, but to encourage you to learn how write a better list of requirements. <S> Cost, performance, functions accessories. <S> Not just weight and speed. <S> There is a lot more to Engineering than Grade 12 Physics. <S> This picture is worth about $850 with charger and remote control. <S> Rated at 3300W with 35 kph but not sure for how long as this would get very hot.
The higher the torque, the faster you speed up. To make a rough guess, for the wind shape of a single person riding a vehicle at 15mph, you need about 1kW mechanical power.
Picking correct level of resistance for a voltage divider I want to measure my DC voltage source (aka batteries), vs my known Dc voltage from my DC-DC regulator. To do this I'll need a voltage divider. I can calculate the resistances I need - but what I'm not sure about is the over all level of resistance I should go for. If the voltage divider resistance is to low, I'll be burning current for no effect. If it's excessively high.... is there any downside if the current is near zero? Should I just got for 100K ohms and leave it there? The math is easy. But picking the right target? That's hard. <Q> When you factor in the input impedance of the measurement device, your options will reduce <S> but yes, there will be a range of values that can be chosen and you will tend to choose the option with the highest impedance that still produces acceptably low errors in measurement. <S> For instance, the ADC inbuilt in such devices as a PIC micro will not want to see a signal impedance more than a few kohm. <S> As you go to greater values than a few kohm, the measurement error will increase and this can be alleviated, to some extent, by adding a capacitor from input to 0V. <S> Sometimes you find that there is no overlap and, in cases like this you would use a spare IO line to activate a MOSFET to connect your battery to a potential divider. <S> Then you can use quite low values and get good measurement accuracy and the battery energy spent is only for a short period of time in the bigger picture of things: - Taken from this stack exchange answer (by me). <A> The impedance of a voltage divider depends critically on a) what's driving it and <S> b) what's loading it <S> Given your driver is either batteries or a PSU, then you can go down to very low values successfully. <S> You don't say what your load is, but I will assume it's a DVM. <S> Now most of these have a 10M input impedance, but I did buy a cheap one recently <S> that was 1Mohm input. <S> If you drove that from a 100k divider, you would have up to 10% voltage error, not very good. <S> Be warned that some ADCs have lower input impedances than that. <S> Keep your divider impedance <S> If we assume you have a worst case 1Mohm DVM, and want the loading effects to be negligible compared to the DVM error and the resistor tolerances, so 0.1% from loading, then you would want 1kohm impedance divider. <S> That won't embarrass your PSU, and is probably OK for your batteries. <S> If we assume a 10Mohm DVM, and a 1% error, then your 100k is OK. <A> The answer also depends on your local EMI environment. <S> Say you have a bunch of 12V car batteries for some electric car conversion project. <S> Then you’re probably gonna have some heavy switching noise from your power electronics. <S> Even the short distance (10 cm) between battery poles to a battery-mounted voltage-measurement chip can attract a lot of EMI. <S> So your best bet then is to draw some measurement current, say 50mA (240 ohm resistor in this case) into your shielded measurement circuit which could be based on the other peoples suggestions here. <S> To decrease your used energy, you can draw current only when measuring, say during 100 us per second (implying power loss of 60uW in my example, excluding circuit losses). <A> Consider just using a slidewire. <S> All it takes is a meter stick and a length of wire to make a divider with 1:1000 resolution. <S> Typical voltage-measuring bridges used a zero-center meter and momentary key so the source (or reference battery) only need be connected for a few milliseconds. <S> Nowadays, of course, a 1M to 10M voltmeter is inexpensive and convenient. <S> The slidewire has an advantage if you want to measure microvolts, I suppose.
So, read the data sheet for your measurement device, restrict your range of impedances and choose the highest set of resistors that give you an acceptable measurement error.
Industry Values for Beta (β) in BJT current amplification I recently completed a lab involving the use of BJT's and as part of my post-lab analysis I was curious at looking in to the max/min values of β in current amplification (Using formula would obviously yield infinite possibilities) \$β = {I_{C} \over I_{B}} \$ I was having trouble finding a source on what values are common. <Q> As a general answer to what values of B are common out of all the BJTs commonly available right now; One quick way to find out what's common would be to search for what's in stock at the major distributors, (Mouser, Digikey, Avnet, Arrow, etc). <S> A search on Digikey for all currently stocked BJTs in active production gives 3723 unique manufacturer part numbers. <S> Given B for each of those part numbers <S> we have the following statistics. <S> Minimum B = 3 (lowest value) <S> Average B = 559 (arithmetic mean) <S> Median B = 100 (center of the list) <S> Mode B = 100 (most common value) <S> 90% of the B values fall within the range 25 to 750. <S> 80% of the B value fall within the range 40 to 270. <S> I used the values of B in the Digikey database to generate the above statistics. <S> The value of B is usually given for a specific operating point that the manufacturer thought was relevant. <S> So my answer should only be taken as a rough estimate of what's out there. <A> Check the datasheet, but don't expect any particular value from any given transistor either! <S> The answer to this question is RTFDS -- <S> Read The Friendly DataSheet. <S> Most transistor datasheets will provide minimum betas for selected operating points, as well as a typical or maximum beta value for one or two of them. <S> Some datasheets may also provide a curve of typical beta vs collector current, but this isn't guaranteed. <S> For your transistor, the ubiquitous 2N3904, Fairchild's datasheet quotes a minimum beta of 100 and a typical of 300 at 10mA collector current and 1V from collector to emitter. <S> So, I'd use a beta of 100 for calculations for the forward-active region, while designing the circuit to be as beta-independent as possible -- transistor beta is not a tightly controlled parameter! <A> These will usually specify the minimum gain at a few operating points. <S> Sometimes they also give typical values, but there is little useful you can do with these. <S> The upper bound on gain is rarely specified, and can be 10x or more the minimum. <S> Good circuits work with the transistor gain from the minimum guaranteed to infinite. <S> That's actually not as hard to design to as it may sound. <A> As @dim pointed out, \$\beta\$ is the same as hFE, and it will be listed as the latter on a datasheet at a few currents and at some substantial Vce. <S> Here is an example from the Fairchild data sheet: <S> So at 10mA and 1V Vce and 25 degrees <S> C the DC current gain will measure between 100 and 300, guaranteed. <S> If you hold it in your fingers during the measurement it will increase from the heating! <S> To see how it varies with temperature and current, typically, you can refer to the graph: (Pulsed gain is specified because they want to neglect the effects of self-heating) <S> You can use the guaranteed numbers and extrapolate what the effects of temperature will be or interpolate for different currents. <S> If you are using the transistor as a simple switch you may not care about hFE (directly) at all, only the current required to saturate the transistor, which will be much higher than hFE for a Vce of 1V would predict. <S> You may care about the maximum gain if there can be a bit of base current <S> but usually you can say that if Vbe is less than (say 300mV) that the collector current resulting will be negligible over a normal temperature range (that voltage will be less if you have to operate at very high temperatures because hFE increases and the Vbe for a given base current decreases- <S> a double whammy). <S> If you are just driving a base with a CMOS gate or MCU the voltage is usually < 100mV and the resulting current can be ignored. <S> It also helps that hFE is typically drops at very low currents so <S> battery drain etc is not impacted as badly as you might expect. <S> Transistors aimed at analog applications often have hFE bins that at are relatively narrow (typically about a 2:1 range) - <S> for example an SS8050C has hFE between 120 and 200 under specific conditions. <S> Often used in cost-sensitive applications. <S> You'll want to pay particular attention to the hFE changes with temperature if you want to do low distortion amplifiers because the hFE changes with temperature can cause large thermal 'tails' on the open-loop response. <S> It's best to design so that your circuit will work over all possible variations of hFE (with your specified part) without any manual adjustments.
The values of B in the Digikey database usually match the typical value given in the table in the manufacturer datasheet for each transistor. Maximum B = 1000 (highest value) Generally B is different for each unit manufactured and can also change if the operating conditions change(temperature, collector current, collector emitter voltage, etc). To get value of gain for a transistor, look in something called its datasheet .
Why Op-Amp Saturation voltage drop with increasing frequency? i was Implementation of square and triangular wave generator using op-amps LF353 . I observed that when I choose different values of Resistor and Capacitor for different frequencies, with increasing frequency the amplitude of Square wave decreases and amplitude of triangular wave increases. If I extrapolate a trend line in the graph of Amplitude Vs frequency they join a common point where both amplitudes become the same. Why the saturation voltage(square wave amplitude) is decreasing and triangular amplitude increasing? Note: There are two points at 45Khz. The lowest amplitude point of square wave are taken when I selected a greater value of capacitor and smaller value of resistor to form the same combination for 45KHz. Circuit Diagram: R1 and R2 are capt constant: R1=1kΩ & R1=2KΩ <Q> Your left operation amplifier with its RC components are an active low-pass filter - that's their purpose, if you think about it! <S> So what it mathematically is is a "integrator". <S> And that's the whole reason the amplitude of the triangles decrease with shorter period time (=higher frequency). <S> When you integrate a constant (high input) for a long time, your integral will have a higher value than when you integrate the same constant for a short time. <S> Atop of that, real-world amplifiers also have finite bandwidths, and the gain of the semiconductor circuitry inside an opamp goes down with frequency, and at some point the idea that an opamp has "very very high gain" just breaks down. <S> However, at your cute 45 kHz, that's probably not the situation here, unless you're using something extrodinarily slow (and then, you'd probably know – that opamp would've been labeled as "only for audio applications" or "vintage" or so). <A> I obseved that When i choose different values of Resistor and Capacitor for different frequencies, with increasing frequency <S> the amplitude of Square wave decreases <S> It will because a lower value of "R" loads the output of the op-amp more and its saturation voltage increases. <S> Remember the integrator input resistor feeds a virtual ground so it acts just like a load resistor to ground on the output of the comparator. <S> and amplitude of triangular wave increases As you raise the operating frequency, the time it takes for the comparator to switch becomes more dominant in the period of the signal frequency being generated. <S> This "extra time" allows the triangle wave (formed by the integrator) to rise to slightly higher peak values. <S> When using an op-amp as a comparator, the output transistors enter saturation and it can take several micro-seconds to recover from saturation. <S> I don't think the the two other answers understand what is happening in this circuit <S> - the whole point is that the triangle p-p amplitude is dictated by the hysteresis of the comparator; theorestically, with perfect op-amps, the triangle wave p-p amplitude is constant. <A> The triangle waveform and the square wave amplitude ideally (as in using an ideal op-amp/comparator) will not vary with frequency- <S> it would be constant for a given supply voltage. <S> That is because the amplitude of both is determined by the output saturation voltage of the right-hand op-amp (used as a comparator), which (ideally) depends on the supply voltage only (once it gets there). <S> To put it succinctly, the left hand op-amp is responsible for the frequency,and the right-hand op-amp for the amplitude. <S> The problem with an aggregate measurement of a complex waveform is that you may be missing something. <S> In this case, I believe you are missing the fact that the square wave is not really square (and as a result, the triangle wave is not really triangular). <S> The op-amp (used as a comparator with hysteresis proportional to the supply voltage as determined by the R1/R2 ratio) has a finite slew rate and thus the edges of the square wave are really ramps. <S> Thus the square wave spends less time at the limits. <S> Similarly the triangle wave is created by integrating the square wave, so the slopes of the triangle wave will not be straight lines, but will curve upward or downward on rising/falling slopes. <S> A secondary effect is that some op-amps take a long time to recover from saturation so the output of the comparator op-amp will be delayed by a (more-or-less) fixed amount on each edge. <S> However that would tend to make the output triangle waveform amplitude increase with frequency and would not affect the square wave, so I don't think that's a factor here. <S> Edit: Andy is also correct that loading of the op-amp/comparator output may be a factor. <S> The limiting output voltage of the op-amp will change with loading. <S> You can avoid this problem by using a proper comparator instead of the right-hand op-amp with hard output limiting using a pair of zeners, say, so the square wave amplitude is controlled. <S> It will transition in nanoseconds <S> (maybe a couple hundred for a really slow comparator) and <S> your variation with frequency will (mostly) go away until you run into the slew rate limit of the left-hand op-amp on the triangle wave slopes. <S> TL;DR <S> It's the comparator op-amp slew rate limitation <S> and/or loading making crummy square waves of non-fixed shape and amplitude. <A> There are several things going on here. <S> This is because the triangle wave generator is a integrator. <S> The integral of a fixed level is a fixed slope. <S> The longer that level is held, the longer the slope continues, and therefore the greater its end-to-end amplitude. <S> The second affect is less predictable due to how the second opamp threshold-detects the triangle wave. <S> If all components were ideal, the second opamp would flip immediately at each zero crossing of the triangle wave. <S> That would stop that half-triangle and reverse it. <S> That would immediately cause the opposite zero-crossing, which would flip the triangle slope again, which causes another zero-crossing, etc. <S> The result would be infinite frequency with ideal components. <S> The frequency you actually get is therefore dependent on the non-ideal nature of the components, which is not going to be specified. <S> Basically, this is a bad circuit if you're looking for a predictable frequency. <S> They way to fix this is to add some hysteresis to the second opamp. <S> Then even with ideal parts, the square wave will flip at known thresholds of the triangle way. <S> The frequency is then deterministic as long as you're not pushing the limits of what the parts can do.
The propagation delay, rise time, parasitic capacitance, and particularly the slew rate of the second opamap all matter. First, the amplitude of the triangle wave is inversely proportional to the frequency of the square wave it is derived from.
Is it safe to frequently restart an ATX power supply I'm powering five Arduinos and four LED strips (600 LEDs total) from an ATX power supply (CoolerMaster B2 Series 700W). Four Arduinos drive the four LED strips, and the fifth Arduino periodically cycles the power supply to keep the LED strip animations in sync. The restart interval is approximately 2 minutes and will be running for about three hours per night over December (i.e. around 2700 restarts for the month). Is it safe to be cycling the power supply this frequently? I'm a bit uneasy about leaving this to run whilst I'm not at home. I imagine my alternative would be to use relays or MOSFETs to cycle the Arduinos. <Q> If you have your mind set on power cycling the Arduinos, why not do the following? <S> This way you don't have to restart the whole PSU. <S> Make sure you get a FET that can handle all the Arduinos <S> (or you can use one FET for each Arduino). <S> simulate this circuit – <S> Schematic created using CircuitLab <S> Another solution that ocurred to me is.. why not control the ATX PSU the same way computers motherboards do? <S> Put a FET/relay (or even control it directly as per this tutorial) between the Pwr_On and GND pins (on which I believe you must have some jumper if you are using ATX PSUs). <S> So.. not many external components, the problem with inrush current in the input caps is gone, and.. you got the power cycle you wanted. <A> Some power supplies use an NTC thermistor for inrush current limiting. <S> This works by initially presenting a large resistance while cool, so that the input capacitors charge slowly, then reducing in resistance as it heats up, allowing larger currents. <S> This is not all that likely to actually happen (especially since many power supplies uses other inrush limiting approaches), but it is theoretically a problem. <S> Everyone telling you that it's a bad idea to cycle the power just to synchronize animations is correct. <A> Addressing the question at hand, I do not see a problem with reseting an ATX power at that frequency. <S> The only moving parts in there are the cooling fans if I'm not mistaken. <S> *** <S> Not sure what I was thinking, clearly the cooling fans aren't the only non-resistive load. <S> My mistake. <S> ****
The problem is that if you cycle power quickly, the thermistor may not have a chance to cool down, and you would get a huge inrush current, potentially blowing a fuse or overheating the capacitors. Since this is the only non-resistive load, I think it should be fine.
Omp Amp Design for shifting a voltage range My DAC can only output voltages between 0-5 V and I want to linearly shift the range to -2.5 to 2.5 V. For example, a 2.5 input would (ideally) lead to a zero volt output. Likewise, a 5 V input would lead to a 2.5 V output. What circuit would be ideal for this? Thanks in advance! <Q> The simplest way is to reverse your 0V-5V to 5V-0V in firmware and use a subtracting circuit: simulate this circuit – <S> Schematic created using CircuitLab <S> Optionally, add another inverting amplifier afterward to get -2.5V to +2.5V for 0-5V in. <S> The reference and resistor accuracy, and op-amp type will depend on your required precision. <S> The op-amps will require a dual supply such as +/-5V, of course. <A> If you have a -5V supply that can be relied on, you can use two resistors (such as 10k and 20k) for changing the 0 to 5V signal into a -1.667 to +1.667 signal. <S> The two resistors just form a potential divider. <S> That gives you a bipolar signal and all that remains is to amplify this by 1.5 using a non-inverting op-amp configuration: - <S> So R1 will be (say) 10k and R2 <S> will be 20k. <S> I've chosen resistor values that match the original uni to bipolar potential divider. <A> I think this answer is simpler: Do the inversion and scaling with a single-opamp by using a differential amplifier configuration. <S> See the LTSpice sim below. <S> I picked R = 100k randomly. <S> Use a lower value if your opamp has significant input bias current to reduce any error. <S> The gain of a diff amp is simply the feedback resistor / the input resistor. <S> In your case you want GAIN = <S> (-2.5V - 2.5V) / (0 - 5V <S> ) = 1, so feedback and input resistors need to be the same value. <S> Because you're only driving the + side of the diff amp, the - side needs to be referenced to 1/2 of the input voltage swing. <S> Your DAC outputs 0 to 5V <S> so halfway is 2.5 Volts. <S> So basically you drive the + input with the DAC <S> and you tie the - input to 2.5V through a 100k resistor. <S> But instead of a separate 2.5V reference, you can simply use the Thevenin equivalent: two 200k resistors as a voltage divider to 5V. Thus the negative input sees this as 100k at 2.5 Volts. <S> On the output side of the diff amp, you would bias R4 to a voltage that is halfway of your output swing. <S> Your output range is -2.5V to 2.5V and the halfway point is 0 Volts, so R4 gets tied to GND. <S> There's a nice writeup of how a diff amp configuration works at: <S> http://www.electronics-tutorials.ws/opamp/opamp_5.html
The diff amp is a nice configuration for doing just this: converting one input range to a different output range with whatever gain, offset and polarity you want.
Decoupling capacitors values in mixed-signal circuit I know theory about decoupling capacitors (ESR, ESl, parallel capcitors etc.)I have read Electromagnetic Compatibility Engineering, H.W. Ott.My question is about practical design. How shall i choose appropriate capacitors to achieve the best results ? I have to design mixed signal pcb. It is measurement system with analog front-end, ADC, DAC, FPGA. There will be a few chips which will be working with different frequencies (shall I take into consideration each freq?). Do engineers in this type of design calculate capacitors carefully (taking into considerations for example impedance peaks in resonance frequency) or put a few different range capacitors ? I would like to solve this problem in correct way not only for the best system accuracy but also for knowledge for the future deign :) Could I kindly ask more experienced people for an advises and answers ? Cheers,e2p <Q> It depends upon the application. <S> For very sensitive applications you could do all of that. <S> Most of the time checking the datasheet for the manufacturers recommendations is good enough. <S> If in doubt 1x 100nF per power pin plus a single 10uF near any larger parts/processors and you'll be good for most designs. <S> There is a very good reason for sticking to a simple rule like that, when it comes to manufacturing you pay for the setup time on the pick and place machine. <S> It's a lot quicker and simpler to load 1 or 2 reels of capacitors than to load 20 different reels because each IC needs different value caps. <A> No deep analysis is usually involved. <S> In cases where I am doing something more custom <S> I use a great web based tool called K-SIM. <S> http://ksim.kemet.com/ <S> In its simplest use, it can calculate the impedance, and ESR of a capacitor across frequency. <S> Given a set of real ceramic capacitor part numbers, and the quantity of each part, it can calculate the impedance of the set of capacitors in parallel across frequency. <S> It takes into account the non-ideal properties of the capacitor when doing the calculation. <S> It can also do other calculations such as ripple current, temperature rise, S-parameters, etc. <A> For mixed signal designs, layout and placement is generally far more critical than the specific decouplers used, although manufacturers will often state a decoupling scheme if they believe it to be critical. <S> The rule of thumb (as already noted) is 100nF per power pin and a bulk decoupler for larger components (such as processors, microcontrollers, large FPGAs). <S> Xilinx goes into quite some detail on this subject. <A> Capacitors in parallel WILL RESONATE. <S> You need to identify those peaks (and valleys) and intentionally pick lossy dielectrics or insert dampening Rs. <S> The first screenshot shows the valleys and peaks for 100uF and 0.01uF <S> and 1uF. <S> The final capacitor[20 pF] uses SkinEffect for dampening. <S> Use the free tool Signal Chain Explorer, in the "Gargoyles" mode. <S> And click on ONLY the PSI {power supply interference} button. <S> Then examine that PSI database (table of interferers) to ensure the 60Hz and 120Hz and SwitchReg and FPGA interferers are enabled. <S> SCE is downloadable from robustcircuitdesign.com <S> The default topology is just a sensor and ADC. <S> Click on Sensor, then go to left margin, select "amps" and select the amplifier stage closest matching your needs. <S> Double click to insert. <S> Double click again, for a 2nd gain stage. <S> Edit the opamp specs (Unity Gain BandWidth & Rout in particular). <S> Edit the Rg and Rf to set gain. <S> Click "Update" on top right, and you'll see the SNR and ENOB predicted by the tool at specific FOI frequency-of-interest. <S> Edit the "Sensor Stage" for voltage. <S> And edit the Power Supply Rejection params {corner freq and Max Atten} <S> This is what you will see, for "filtering" <S> and this is the PSI database (you can edit or add your own interferers) <S> and here is how to edit the Power Supply Rejection params for any OpAmp stage. <S> Click "analysis details" for text window analysis of the many contributors to Code Spread. <A> Low inductance is desirable for HF decoupling. <S> However, Inductance does not depend on cap value, only on package and mounting. <S> Value determines price <S> Let's consider a 4-layer <S> (or more) board with a ground plane in one of the top layers, usually layer 2. <S> Now, the power supply you want to decouple can either be: a local supply with a local regulator for one sensitive analog chip with one or a few power pins Unless it is BGA, the inductance of your chip's VCC pin and the track leading to it will usually be higher than the ESL of a properly mounted MLCC. <S> Therefore, paralleling MLCCs will usually not improve inductance, but it will worsen resonance. <S> Use the highest value MLCC in X7R that will fit in say, 0603 or 0805. <S> Add bulk capacitance if needed to make regulator happy. <S> If regulator datasheet boasts "stable with 1µF MLCC"... check output impedance with network analyzer, if it looks ugly then add some bulk capacitance... <S> A 10nF 0805 cap will have the same inductance as a 1µF 0805 cap. <S> But the 0805 cap will store 100x more energy. <S> Therefore, I'd use 1µF... and no 10nF in parallel! <S> Note: <S> a precision opamp will not meet its settling time specs if its power supplies are polluted with large HF spikes due to caps resonating. <S> HF PSRR of opamps isn't good. <S> traces feeding many chips <S> You will need one cap per chip at least, but those traces add inductance, and worsen resonance. <S> Paralleling MLCCs with tracks is a bad idea. <S> This will also inject noise into your GND as the caps resonate. <S> Think about 0R1 chip resistors. <S> Simulate the network. <S> If you use ferrite beads, remember they are inductors, you are making a LC network. <S> Check the bead spice model, and adjust bulk cap ESR for damping. <S> (1) a power plane which feeds many chips <S> A plane will allow you to parallel many caps without (too much) resonance problems, provided they are properly mounted, values properly selected, etc. <S> Decoupling a plane is where you use those 10nF capacitors, in numbers, to reduce inductance. <S> Note about fancy low-ESR polymer caps. <S> If you parallel one of those with a MLCC without proper care they'll resonate...
Normally when I do a design I use the decoupling capacitor recommended by the manufacturer datasheet. Depending on circumstances, adding ESR can be beneficial. We like small MLCCs for low inductance and low price.
What is the UART TX interrupt for? I know that the RX interrupt is obviously used to save polling, but why the TX one too? <Q> The TX interrupt is mainly for longer datagrams. <S> You can initiate the transfer for a buffer of known length (bytecount). <S> Now you can push your buffer pointer as often as there are bytes to send, when the TX interrupt occurs. <S> This ensures the "as quick as possible" transfer of your buffer, without the need to poll any "TransferComplete"-Flag/Statusbit. <A> When implemented in a proper way: Enable the TX interrupt. <S> The user code starts transmission by sending only the first byte in the buffer. <S> At the end of TX (of the first byte), an interrupt will be generated. <S> In the TX ISR (Interrupt Service Routine), the code must send the next byte in the buffer and update the buffer index. <S> At the end of this transmission, a new interrupt occurs, and so on, until the entire content of buffer is sent "automatically". <S> Disable the TX interrupt. <S> The exact behavior depends on the microcontroller. <S> That is a general description. <A> Some UARTS have an internal buffer that is larger than one, the 16xxx series for one. <S> The procedure here was Set a transmit window mask, for example to 4 remaining. <S> fill buffer positions until the UART said full or no more data need to be send do other stuff <S> when only 4 buffer positions are left unsend, set TX interrupt <S> wait for the interrupt to be serviced if more data needs to be send go to 2. <S> This decreases the CPU load by offloading some processing to the UART thus enabling slower CPU's to keep up and service other task instead of getting interrupted all the time. <A> The TX interrupt fires when there is space in the transmit buffer. <S> For devices that don't have a transmit buffer (i.e. where you write one byte, which is transferred immediately), the interrupt is asserted when the transmit register can be written with the next byte. <S> For devices with a buffer, the interrupt is asserted at an implementation-defined time. <S> For some, it is when the buffer is half empty, for some it is when transmission of the last byte has started and the buffer is completely empty. <A> Another use case is when you connect the UART to another communication interface like RS485. <S> The controller has to release the bus driver as soon as the last bit has been shifted out of the TX buffer. <S> This is easy to handle in the TX interrupt, but would be cumbersome to implement without, since you would have to wait an exact time after writing the last byte to the output buffer which would also vary with baud rate.
The main goal of the TX interrupt (really an END OF TX) is to send the content of a buffer (multiple bytes) automatically.
Will my wires have current stability issues? first post here. I'm currently making a set custom sleeved/crimped cables for my computer's modular power supply, and my crimper isn't very good, so for extra security, I've soldered all the crimps, using flux so that they flow properly. They are male-and-female type connectors, and carry high current (~5A) 12V DC, as well as some slightly lower current 3.3V and 5V DC. After soldering, I proceeded to clean them in ethanol/alcohol, however I'm pretty sure they still have a thin layer of flux in them since it's hard to clean inside the female connectors. I've done testing with a multimeter by first inserting a male connector, then measuring resistance and diode checks from the inserted male connector to the other end of the wire, and they check out (~0.003 ohms, the same as an un-crimped wire, the resistance is probably caused by the multimeter probes anyways, I've checked the probe-to-probe resistance to be the same). Now for my question: If my resistances check out, and Diode check passes, will I experience unstable current under high loads? (e.g 8 Wires for a 150W graphics card) Thanks! <Q> There are two problems from the flux (see <S> Why do we need to remove flux from circuit boards? ) <S> Electical conductivity -- this does not apply in your case. <S> A couple of megaohms, or even a couple of kiloohms, will not affect PC PSU in any visible way. <S> Flux reactivity -- this may apply in your case, but it is unlikely. <S> Again, the PC wires are usually very thick, so it will be many years before corrosion becomes a problem. <S> A proper crimp holds the wire by insulation, and soldering most likely has destroyed this. <S> Make sure not to bend wires too much once you have installed them. <A> Your application of the soldered connections raises a number of concerns. <S> 1) <S> When you solder crimps the wire will easily break at the boundary of where the stranded wire has soaked up the solder between the strands. <S> This can happen up into under the insulation and into the portion of the wire that had the insulation crimp. <S> Use great care with handling your cable and do not bend the wires at the connectors. <S> 2) <S> One hopes that you used a proper electrical soldering flux (rosin or organic type) instead of acid based flux. <S> If you used acid <S> I suggest you start over and build cables with the proper crimping tool and avoid the need to solder all together. <S> 3) <S> Use of flux that possibly got down inside the connector contacts could very well lead to intermittent connections when the cables are mated to the circuit boards. <S> You will need to clean out the inside of each contact. <S> These cans come with a short plastic spray tube that can get inside female contacts and clean out all the residual flux. <A> If you can see a nice shiny, smooth fillet of solder inside the joint, then there is no chance of residual flux causing any problem with the soldered connection.
What you should be worried, however, is that if the connectors that were designed for crimping were soldered, the wires can break off much easier. The best way to do this is to use a spray can of flux remover.
VHDL case with different outputs Is it a valid and synthesizeable VHDL code? case IR(10 downto 7) is -- RD when "0000" => R0 <= RTA; when "0001" => R1 <= RTA; when "0010" => R2 <= RTA; when "0011" => R3 <= RTA; when "0100" => R4 <= RTA; when "0101" => R5 <= RTA; when "0110" => R6 <= RTA; when "0111" => R7 <= RTA; when "1000" => R8 <= RTA; when "1001" => R9 <= RTA; when "1010" => R10 <= RTA; when "1011" => R11 <= RTA; when "1100" => R12 <= RTA; when "1101" => R13 <= RTA; when "1110" => R14 <= RTA; when "1111" => R15 <= RTA; when others => null ;end case; As you see in each case the output signal is different: R0, R1, R2, etc. I thought maybe I have to put all the outputs in each case; Something like this: case IR(10 downto 7) is -- RD when "0000" => R0 <= RTA; R1 <= 0; -- The problem here is that I don't want R1 to be 0 -- but to retain its previous value R2 <= 0; R3 <= 0; R4 <= 0; R5 <= 0; R6 <= 0; R7 <= 0; R8 <= 0; R9 <= 0; R10 <= 0; R11 <= 0; R12 <= 0; R13 <= 0; R14 <= 0; R15 <= 0; when "0001" => R0 <= 0; R1 <= RTA; R2 <= 0; R3 <= 0; R4 <= 0; R5 <= 0; R6 <= 0; R7 <= 0; R8 <= 0; R9 <= 0; R10 <= 0; R11 <= 0; R12 <= 0; R13 <= 0; R14 <= 0; R15 <= 0; . . . when others => null ;end case; If I don't have all the outputs (R0 to R15) into each case the VHDL compiler gives me a warning: "Found 1-bit latch for signal . Latches may be generated from incomplete case or if statements. We do not recommend the use of latches in FPGA/CPLD designs, as they may lead to timing problems." I need to get rid of this warning. <Q> The case itself adheres to VHDL syntax, and in general synthesis tools handles case . <S> The warning is related to general coding style. <S> If a process is used to make combinatorial logic, then all the signals driven from a process must always be assigned in order to avoid latches, but my guess without seeing the rest of your code, is that it is not the case. <S> A good coding style (when feasible) is to assign all the signals in the beginning of the process, like: process (IR, RTA, ...) <S> isbegin R0 <= ... <S> ; R1 <= ...; ... case ...end; So to avoid the warning and the latches, ensure that all the signals driven from a combinatorial process are assigned. <S> For example this code will intentionally make a latch, since q is held if en = '0' , and only updated if en = '1' : process (en, d) <S> isbegin if en = '1' then q <= <S> d; end if;end process; For sequential logic there is not the same problem, since flip-flops can just hold they state if they are not updated. <A> Verilog and VHDL are hardware description languages, but they do look similar to procedural programming languages. <S> This can sometimes lead to code that is technically valid but not synthesize-able. <S> In your first example code, each output not explicitly specified with a new value, implicitly retains its previous value (because that's what would happen in a procedural programming language). <S> That is the "implicit latch" that the synthesis tools are warning about. <S> The problem is that the synthesis tool can't do what you want without also synthesizing the actual memory to store the values, and it's not clear that is what you want. <S> Apparently you didn't tell it to create any memory to store those values. <S> Your second example code explicitly determines the value of each output in each case, so the synthesis tool understands exactly what you want. <S> In your second example, only one output gets the RTA value, and the rest of the outputs are 0. <S> This is valid and synthesize-able, however you mention in the comments that this isn't really what you want either, you actually want to update one register while retaining the values of the other registers. <S> To write HDL code that updates the value of a selected register, you need to declare the actual memory elements. <S> I'm not a VHDL guy, but in Verilog I'd maybe write something like this: // <S> declare R0.. <S> R15 as register storage (memory), not <S> just signal wiresreg[7:10] R0;reg[7:10] <S> R1;// etc <S> ...reg[7:10] R15;// could be written more efficiently as a register file instead of individual registers// update a register selected by IR[10:7] with data RTAalways @(posedge clock)begin case(IR[10:7]) <S> 4'b0000: <S> R0 <= <S> RTA; break; <S> 4'b0001: <S> R1 <= <S> RTA; break; // <S> etc. <S> 4'b1111: <S> R15 <= RTA; break; endcase <S> // end <A> This CASE statement is valid VHDL. <S> A normal use of it would be embedded in a if rising_edge(clk) <S> then statement, in which case it won't generate a latch but a clocked register. <S> Then the first form updates one register on a clock edge, preserving the value of all the others. <S> The second form updates one register, clearing all the others (which is rarely what you want to do). <S> It can be greatly simplified by moving a default assignment before the CASE statement... if rising_edge(clk) <S> then R0 <= 0 <S> ; R1 <= 0 <S> ; -- etc case () is when 0 = <S> > R0 <= <S> RTA; -- <S> etc <S> end <S> case;end if; Here the "last assignment wins" rule in synchronous processes takes care of the default actions, overridisng only the one you want. <S> An <S> aside: any time you see large regular CASE statements like this, they are probably ripe for a huge simplification - consider the following, which eliminates the CASE entirely. <S> type Register is natural range 0 to 255;type Register_File <S> is array (0 to 15) of Register;signal R : <S> Register_File;-- optional if you need teh original register names somewhere... <S> alias R0 : <S> Register is R(0); -- etc for each register... if rising_edge(clk) <S> then -- optional second case -- R <= <S> (others => 0); R(to_integer(unsigned(IR(10 downto 7)))) <S> <= <S> RTA; <S> end if <S> ; If the CASE statements are irregular, that simplification isn't so easy.
This HDL code might be technically valid, but may not be synthesize-able (or maybe not in the way that is intended).
Current transformer for current sensing at Low Voltage AC I have 230V/50HZ AC to 12V/5A step down transformer. Is it possible to measure the current at the secondary (Low Voltage AC)side of the transformer?is it possible to use regular CT coil(which is used to measure the current @230V AC) <Q> Measuring the current on the secondary side of the transformer can be accomplished in three possible ways. <S> place a small resistor ( <S> less then 1 ohm) in series with the transformer connection and measure the AC voltage drop across the same. <S> Thereafter it is simply Ohms law <S> (I = V/R). <S> The other way is placing a miniature current transformer (see picture) and measure the voltage across the transformer load resistor ( Do not use such a transformer without a load resistor). <S> Look at the data and application sheet of such transformers for further information. <S> A third way could be to use a hall effect sensor with corresponding electronics such as the NA25 or NAP25 both from FW BELL. <A> The least intrusive method would be to use a current transformer which simply clamps around your secondary cable. <S> Here's one that should work well: http://cdn.sparkfun.com/datasheets/Sensors/Current/ECS1030-L72-SPEC.pdf <S> https://www.sparkfun.com/datasheets/BreakoutBoards/0712.pdf <S> These are readily available on Ebay as breakout boards <A> You want to measure current, not voltage, it is no problem if the voltage is 230 V or only 12 V. <S> But the current transformer should never be used without a load resistor. <S> A CT rated for 5 <S> A should be used for current up to 5 A but not more. <S> But such a CT for use on 230 V wires should not be used for measurement on high voltage like several kV, only up to the rated voltage of the datasheet.
A current transformer may be used to measure current at the primary side of your step down transformer as well as on the secondary side. You can also get Hall effect sensors, and these are particularly easy to interface to a microprocessor:
Considerations when using internal pull-up/down resistors I am working with STM32 micro-controllers. These micro-controllers have the option to set the input pin as pull up or pull down: Earlier I used to give external pull up or pull down resistor wherever required but now I am wondering whether I can do away with external components and use the pull down feature of the micro-controller itself. Will that be a good thing to do? Is there some use case where I should take extra precaution or not use this feature at all? <Q> Yes... <S> You can... <S> It's a proven feature. <S> If you see pin structure in STM32 Reference manual, you can see that it has required components -- <S> If this satisfies your requirements, then, you can do away with external components. <S> Edit Remember that at Power up, Pins will be tristated. <S> If it does not hamper your application, it is good! <S> That's why it's good practise to init IO section first and then go ahead with other peripherals. <A> Disadvantage is that you can forget to enable it from software, that can cause a little headache. <S> The external pull-ups will always be there. <S> So do not forget to enable the internal ones and save a lot of PCB area by reducing component number. <S> The STM32's internal pull-up and pull-down resistors usually have a value between \$ 30\small <S> ~ <S> k\Omega \$ and \$ <S> 50\small <S> ~k\Omega \$. <S> You should always check if your application needs a certain pull-up or pull-down resistor value before using the internal resistors. <S> For example do not use them with I 2 C , as these values will be too high for that. <A> Unless the pullup and pulldown resistors are active during reset (I suspect they aren't, but I'm not familiar with STM32 devices), there is an undefined pin state at reset. <S> This is one major reason to use external pullup or pulldown resistors. <A> As others have said, internal pull-ups and pull-downs are fine as long as: <S> you remember to configure them, they are strong enough, you do not end up fighting them with an external pull, and the voltage at start-up and reset is unimportant. <S> On the last point, remember that CMOS inputs at mid-voltage level can cause significant shoot-through current on their input pair. <S> This can cause a problem in a low power system during start-up. <S> In general, external pull resistors will yeild a more conservative design. <A> In addition to the other fine exceptions listed in all the answers, the internal pull-up resistors are too weak for I²C in many cases.
In general, it is perfectly fine to use the internal pull-up or pull-down resistors.
Is there a way to use constructive interference to create a specific sound in a specific location? With 8 speakers, one in each corner, can a combination of waves be emitted that are silent from the sources but form a coherent emission somewhere between? I mean that even if you walked around the room the sound of something, say a ball bouncing, would stay in the position that it sounds like its bouncing in relative to the walls and not because your position is being tracked and each speaker adjusts its volume accordingly, silencing as you approached and vice versa, but because the pressure changes in each speaker are beyond the 20 to 20k Hz range we hear until a combination of interference creates a wave that is formed at a controllable location and actually emits from there. An opposite to dead spots. We have Phased arrays to steer sound without moving the array if we're not using the parametric array effect to 'beam' the sound but maybe some combination of these. Acoustic phase conjugations which can create a localized vibration or sound wall that could perhaps be enough of a non-linear medium to scatter the ultrasonic propagation? There is Intermodulation, primarily considered a distortion but all combined this could be possible? <Q> Not in any practical sense, no. <S> Constructive/destructive interference can only change the amplitude at a given frequency; it cannot produce a frequency shift. <S> Combining multiple ultrasonic signals will only give you another ultrasonic signal; it will never result in an audible frequency. <S> Audio "dead spots" are the result of multiple audio paths that happen to perfectly cancel out at that spot. <S> They are, in a sense, "unstable", because the balance is only hit at that one exact location (and, in most cases, even then only at specific frequencies). <S> At most other locations, the sound can be heard normally. <S> There's no way to get the opposite effect you're describing, of a set of signals that cancel out everywhere except one location. <S> This is because there's no way to make signals cancel out everywhere, besides making them perfectly equal and opposite, and originating from the same point. <S> (At which point, there's effectively no signal being transmitted at all.) <S> What is possible is to produce a single point of constructive interference, where a sound is perceived louder than it is elsewhere -- this is simply the opposite of the "dead spot" effect I described earlier. <S> However, this doesn't translate to the effect you're describing: the sound is not re-emitted from that location; it can only be heard by a listener in that location, and they will hear it coming from all of its "real" sources. <A> this does not make everywhere else sound silent , it just sounds like its coming from the speaker. <S> Although dead spots can be created by standing waves. <S> -Look up <S> Ricean Fading , the same thing happens to WiFi on fringe signals. <S> This phase property is what defines the quality for those who have a passion for high fidelity audio with the ability to see the orchestra play positions on stage. <S> Unfortunately mixing is such these days that this property is obscured by the needs to be compressed and sound good on radio resulting in some phase distortion. <S> Also speaker linear phase response or maximally flat frequency response is an expen$ive linear property. <A> You should check out this vid on sound wave patterns. <S> The interference here would be similar to what you're trying to achieve. <S> https://www.youtube.com/watch?v=v4ehaGeo6vs <S> However you probably want very directional speakers, the effect of which could be ruined by diffraction depending on the size of your room. <A> I don't know if I should answer my own question but no one has yet put all these together... <S> We have Phased arrays to steer sound without moving the array if we're not using the parametric array effect to 'beam' the sound <S> but maybe some careful combination of these. <S> Acoustic phase conjugations which can create a localized vibration or sound wall that could perhaps make the air enough of a non-linear medium to scatter two converging ultrasonic wave's propagation at a point in mid air via Intermodulation distortion. <S> All combined even with lots of maybes, this seems quite possible to me.
Yes for focusing 1 point, No for silent eleswhere beam forming coherence standing waves can be created to simulate the sound in the middle of your head, like whispering into a large parabolic dish or concave wall centre.
How does a capacitor reduce voltage drop in a DC motor start? I know that a capacitor stores charge:C=Q/V but what i don't understand is how this would reduce the voltage drop caused by high current draw. My theory is that the capacitor would need to be in parallel with a conductor (minimal resistance) and then connected to the motor. simulate this circuit – Schematic created using CircuitLab (Diode is motor) By doing this, current will only be drawn from the capacitor when the power source can't supply enough. If this is true why? and if it this isn't true how is capacitor supposed to be set up then? what would happen if the capacitor is in series? <Q> Your voltage source is assumed to have some resistance. <S> The capacitor would provide some of the current during the start-up surge. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> So, say it takes 0.5 second for the motor to wind up <S> and it draws 0.5A during the surge and 100mA after (of course it will vary more smoothly than that). <S> Then you would like the voltage to drop less than 1V during the surge. <S> Let's assume all the current is supplied by the capacitor. <S> So <S> \$C = <S> \frac{I_{start}\cdot T_{start}}{\Delta <S> V}\$ = 0.25F <S> (250,000uF). <S> As you can see, you'll need a pretty large capacitor for even a small motor. <S> Putting it in series would just cause the motor to jog for a bit and then stop when the switch is closed, assuming the capacitor was discharged to begin with. <S> It could only reduce the current available to the motor (again assuming it was discharged). <S> Once the cap is charged there is no more current and the motor stops. <A> What you show is just a diode in parallel with a voltage source. <S> There is no capacitor here since it's shorted. <S> Removing the capacitor would change nothing. <S> It's not clear what you are really asking, but some types of motors have a "startup capacitor" in them. <S> These types of motors run on AC, and don't have any torque when the rotation speed is 0. <S> The capacitor unbalances the motor to cause some torque at 0 speed. <S> This capacitor would reduce efficiency at normal operating speed, so there is usually a way to switch it out of the circuit. <S> A common means is a centrifugal switch. <S> Added <S> If you really mean a capacitor in parallel with the power supply a DC motor is connected to, then that's just a capacitor holding up a supply. <S> There is nothing special about a motor being connected to that supply. <S> A large capacitor across a supply provides extra charge to the load when the supply voltage drops. <S> This helps the supply look more beefy to the load than it really is, at least in the short term. <S> In effect, the supply/capacitor combination is capable of larger short term current than just the supply alone. <S> A motor draws a surge of current at startup, so a capacitor can help. <S> However, this motor initial current surge is "long", so in most cases a unrealistically large capacitor would be needed to make a significant difference. <S> A small capacitor across a motor can help to reduce emissions. <S> The capacitor keeps the voltage more steady, and keeps the high frequency noise current circulating close to the motor. <S> The time over which such a capacitor can make a meaningful difference in holding up the voltage is so small that this only does anything useful at frequencies that can radiate. <A> In the diagram below, the power supply is represented by an ideal voltage source, an internal power-supply resistance, and an internal power-supply capacitance. <S> When the motor is switched on, the armature is not turning and the back emf is zero. <S> The motor current is then limited only by the armature resistance and the internal resistance of the power supply. <S> Unless the internal power-supply capacitance is quite large, it will discharge through the armature resistance and much of the supply voltage will be dropped across the internal power-supply resistance. <S> Adding more capacitance will "fix" that problem by supplying current for a longer time before discharging to a significantly lower voltage. <S> If the motor accelerates sufficiently in that length of time, the back emf will build up and prevent further discharge. <S> If the power supply has a current-limit or overcurrect-trip circuit the capacitor can prevent the power supply from electronically reducing the voltage or shutting off. <S> Since the power supply may have difficulty charging a large capacitor, a charging circuit may be needed. <S> This scheme is suitable only for small DC motors that have sufficient armature resistance to be started at full voltage without incurring commutator damage. <S> Larger motors require a starting circuit that will limit the current until the motor has reached full speed.
I believe that capacitors are sometimes used to prevent voltage drop when starting a DC motor that is connected to a power supply that is not really suitable.
Switching between +9V and -9V (using 5V logic) I got some linear actuators today and found out that when I give them +9V they extend and -9V makes them contract. This is easy enough to test by hand, simply by wiring the actuator up to the battery backwards for the negative voltage, but when I hook it all up I'm going to be driving all of them from my Atmega1284, which uses 5V logic. In anticipation of this, I got a bunch of relays that run on 5V logic as well so I can control whether or not there's +9V running through with my 5V microcontroller. However, I have no way to programmatically provide -9V. My question here is how can I switch between giving +9V and -9V when all I can do from my microcontroller is either push out 5V or 0V? Will I need more than just my relays? Is there some spiffy EE trick to make this work? Thanks! <Q> You can use two SPDT relays to select +9 or -9 or 0V. <S> Both energized = off, Both de-energized = off, and if one is energized and <S> the other is not it will drive the actuator in one direction or the other. <S> simulate this circuit – <S> Schematic created using CircuitLab <A> You will need to provide a 9V supply to be able to power the linear actuator. <S> Here is a basic schematic of how you would hook it up. <S> If you use relays with very low power 5V coils you could control them directly from the Arduino otherwise use NPN transistor buffers as shown here. <S> The Arduino controls to the two relays can apply 9V in either polarity to the actuator to move it in or out. <S> To stop the actuator motion switch both relays to apply either 9V or GND to both wires of the device. <A> The L293D motor driver/ H-Bridge IC should work nicely for this purpose: http://www.ti.com/lit/ds/symlink/l293.pdf <S> This chip is commonly used for controlling motors and because it's able to reverse the polarity of the motor, you can change the direction in software. <S> For your application this also provides you with the benefit of not having to have a -9V power rail, you just have to provide the chip with 5V and 9V. <S> Here is a connection diagram: a busy cat http://www.electroons.com/electroons/images/ckt_mtr.jpg VCC2 (left bottom corner) should not be hooked up to the 5V, but to the 9V supply. <S> 3,4E should be connected to the 5V supply. <S> Another nice thing: the chip can drive 2 actuators, if you need them. <S> Just hook up RA2 and RA3 to your MCU, and common the ground of the chip and your processor.
You do not need to have a -9V supply as you can achieve that simply with a polarity reversing scheme controlled by two of your relays. To suppress electrical noise, add a bridge rectifier ( W04G , for example) across the actuator (the AC input terminals) and connect the + terminal to +9 and the - terminal to 0V
How to adapt a string of 10 LEDs powered by 3 AA batteries to work off a USB port? I have a string of Christmas lights made up of 10 warm white LEDs. The lights are connected in parallel (not in series). The string works with 3 AA batteries (that is, 4.5 VDC). And all that stands between the power source and the lights is one 200 Ohm resistor (this is a photo of the resistor, in case I read it incorrectly): Now, that's all I know/understand of the string of lights. What I want to do is change the power source: I would like it to work off the 5 VDC that come from a USB output. My basic knowledge of electronics tells me that there's basically 2 things I have to worry about here: 1) How do I drop that 0.5 volt I don't need? (Although, playing around with LEDs, I think they'll have no problem working with half a volt over what they were originally working with); and 2) Is the current coming out of a normal USB outlet (such as from a telephone charger, 0.8-1.2 amps) going to be too much and, if so, how can I drop it to the current needed? (If I'm not very much mistaken, the current will be too much because a normal LED takes 15-20mA, right?) I understand this issue is very basic but so is my knowledge of electronics. I would really appreciate any help you can afford. I think that if I could "fix" this issue, find a way to get it to work, I would be able to understand a little more about how it works. So far, reading theory... well, it's all mixed up in my head; perhaps if I could solve this real-life situation, the little I understand could start falling into place and organising itself. So thanks a lot in advance! <Q> You did read it incorrectly, Red|Black|Black is 20 Ohm, not 200. <S> White LEDs (which are actually blue LEDs with white luminophore) drop about 3V (a multimeter would give you an exact value), leaving about 1.5V to the resistor. <S> This amounts to 75mA of current. <S> To have the same current with a 5V supply, you need a resistor which lets 75mA through at 2V voltage drop, which is around 27 Ohm. <A> The current available from a power supply must be equal or greater to the current required by the load. <S> The supply doesn't attempt to 'push' excess current into the load. <S> Assuming 3v for the LEDs, a 200ohm resistor would limit the current to 10mA, which sounds a bit low. <S> I gave up trying to read colour codes years ago when I couldn't make out unambiguously the difference between warm brown, gold and muddy orange, so it could be 20ohms. <S> If that's the case, then it limits the current to 100mA total, or 10mA per LED, which seems more like a reasonable level. <S> Disconnect the battery, connect the red (+ve) and black (-ve) power wires from the USB, and you should be good. <S> As Dmitry warns, if you want to run at exactly the current you would get from a 4.5v supply, then either increase the 20ohm resistor a bit, or use an extra resistor in series between the USB supply and your battery box terminals. <S> The latter would be preferrable as it avoids altering the stuff in the box, and spreads the dissipation out over two resistors. <S> Try 6.8ohms, or 10, or 4.7, and see what voltage you measure at the battery box terminals. <A> Probably it's a little late to add comment, and there are several previous meritorious solutions. <S> In answer to the original question, I would reason that it is safe to connect a 3 x Battery, 4.5V led string with a Ballast resistor in circuit, directly to a 5v phone or usb charger. <S> The series "Ballast" resistor normally drops the Battery voltage by 1.5V (nominal) to 3V and limits the current to the leds, with fresh batteries this can often be close to 5V. A ballast resistor provides a measure of current limiting and its value suitably calculated. <S> With a 5v constant supply the series "ballast" resistor will drop <S> (absorb) 2.0V instead of 1.5v. <S> A 5V input results in a permanent increase in the current through the Leds, in the ratio of a 2 volts drop <S> compared to the original 1.5 volts drop across the ballast resistor giving 1.33 times the battery current.. <S> A Led current of 7.5mA is well below normal led running conditions. <S> ( value derived from a given 1.5v drop across 20 ohms split between 10 leds) . <S> An increase of 30% in the led's current to about 10mA is acceptable and still relatively low. <S> I would note that led's behave like soggy (Zener Diode) regulators and whilst the voltage across them is considered to be constant, it does rise slightly as current increases, this will marginally compensate for the higher voltage. <S> In real terms the total power would be circa 500mW with the 10 leds consuming just 300mW and the ballast resistor 200mW, which are acceptable values <S> AS mentioned elsewhere, the next simplest circuit correction would be to add a single 1A diode in series, providing a 0.6 to 0.7v drop. <S> Then no calculations would be necessary. <S> any existing balance resistor must be retained . <S> Recently I found a 4.5V V.DC Mains to DC converter for a couple of pounds(new) which is perhaps the easiest solution of all. <A> Wow, everyone is over complicating this. <S> Usb 5V to a 1N400x series <S> diode in series with the led battery pack is all you need. <S> 90% of usb computer ports do not require enumeration for power draw, regardless of the usb standard documentation. <S> 99% of usb wall chargers dont need it either, unless you want a high voltage with some newer fast charging ones. <S> Some usb supplies are at 5.2 to 5.3 volt, making a 0.7V silicon diode forward voltage drop ideal. <S> At 5V, it would be just under ideal. <S> I've done this a hundred times with 2x and 3x led packs. <S> To answer the current question, the load pulls It. <S> The resistor will limit the current already, no need to look into further current limiting.
In your case, totally fresh AAs would have a voltage higher than the nominal 1.5v, 3 together might just produce 5v, so I strongly suspect your LED string will tolerate a 5v supply without problems.
Is it good general practice to avoid powering components from the 5v pin on an arduino? Most examples and tutorials have you power small components by connecting them to the 5v pin on the Arduino. As part of my learning process, I've messed up an arduino or two by not considering the amount of power a component would draw or by expecting that it would be drawing less power than it actually did. Is it - in general - a good idea to be on the safe side and virtually never power any components from the 5v pin, instead using a separate 5v power supply (or at least, a separate line to the same power supply that is powering the arduino)? It seems to me that this way, you'd at least never ruin the arduino itself should you make a mistake, just the power supply (if it's not up to the task), although it might be overcomplicating things. What are people's best practices in this regard? <Q> For one specific use case, the answer is clearly yes. <S> The internal regulator is bypassed via a diode which results in weird voltages appearing at the 5V pin. <S> You will get some unspecified drop across the diode, especially if you're using a Chinese knock off as is common. <S> I measured only 4.72V at the 5V pin whilst the USB voltage <S> was 5.11V. <S> This can confound the unwary and cause unreliable operation of strict 5V kit. <S> It get's worse. <S> When the ADC is used in the normal mode, as in just reading it, you'll get errors. <S> The ADC references itself to Vcc which in this USB case might be 4.7V, not 5V. <S> All your analogue readings will be higher than you expect. <S> You will have to mitigate by using either the internal 1.1V reference (if appropriate) or your own external reference. <S> So in summary, best practice would be independent external power if there is any remote possibility of USB operation. <S> This doesn't mean a wall adaptor, but a power source external to the Arduino PCB itself. <A> The best design practice is to know your devices. <S> Understand the circuits on the Arduino and learn what they are capable of. <S> Then fully understand the requirements of the components and circuits that you intend to interface with the Arduino. <S> This all includes a rigorous reading of the component data sheets. <S> There are likely to be plenty of applications where you can connect directly to the +5V pin of the Arduino. <S> Likewise there are going to be circuits where the connection to separate power supply will be required. <S> There are no real hard and fast design quidelines here that can dictate the way to do it. <S> Use common sense and knowledge to make the right design decisions. <S> Seat of the pants trial and error is not "engineering". <A> Usually it will be fine for low current device. <S> For example, it will be fine to directly power few led directly using arduino 5v with resistor. <S> Usually we power arduino with adaptor 9-12v DC, ~0.5-1A. <S> Thus, it might not be a good idea to directly power a device that will draw large current such as motor or fan to arduino 5v out from the voltage regulator. <S> Some large current draw spike might cause a sudden drop in your voltage also which will impact the microconroller behaviour.
Be very careful using the 5V pin if you power the Arduino from the USB port. You need to know your component's power/current draw and the power supply power.
Powering a MCU from a battery without a regulator I have seen some development boards (for example. BL652 dev kit ) for low power chips have battery power connected directly to the MCU without a regulator. For the example case, the battery used is a 3V CR2032. The datasheet for the MCU defines the following parameters: datasheet page 16.Absolute Maximum Ratings Min MaxVoltage at VDD_nRF pin -0.3 3.9datasheet page 17.Recommended Operating Parameters Min Typ MaxVDD_nRF 1.8 3.3 3.6 I'm interpreting this as "If your battery voltage drops to a value between 0-1.7 it isn't defined what will happen" . Why this worries me is because I've seen regulators having the Power Good pins and have found no explicit statements in the datasheet that the MCU from the example won't be damaged by the undervoltage. How can I decide if a regulator is needed between a battery and a load, to guarantee there are no damages when the battery voltage starts dropping? <Q> If your battery voltage drops to a value between 0-1.7 it isn't defined what will happen <S> This is often true, but it won't, for sure, destroy anything. <S> Because, if it was destructive, the min Vdd in "Absolute Maximum Ratings" would have been given as a positive value (which I have never seen in any datasheet, and I hope I'll never see that in my life - it wouldn't make sense). <S> So at this point, you are guaranteed the MCU won't be destroyed with undervoltage. <S> However, it could still behave erratically (potentially damaging other external circuitry). <S> Now, in this kind of MCU, there is often a feature called " brown-out detection ", or, sometimes, "undervoltage lockout". <S> This is a feature that monitors the supply voltage and guarantees that the chip is held in reset state when the voltage is under a given level (sometimes programmable). <S> Good news <S> : There is such a feature on the specific chip you're using. <S> See chapter 5.1 in the datasheet you linked. <S> Therefore, you don't need to have a regulator with "power good" detection or an additional supply monitor circuit in your specific case. <S> Note that, if the MCU didn't have the brown-out detection included, there are tiny chips that just offer this feature (often combined with a timed power-on reset generator) without being voltage regulators. <A> ...between 0-1.7 it isn't defined what will happen Actually below 1.8 V there is no guarantee what will happen. <S> Don't worry about damage <S> these are the operating parameters . <S> To prevent damage you must not exceed the Maximum ratings , which are not included in the linked sheet. <S> If you know the chip(s) which are used you can look up their datasheets and see the Maximum ratings. <S> I have yet to come across a chip which can suffer damage from a too low supply voltage. <S> You do want your product to "know" and respond when the battery is too low though. <A> There is no guarantee your processor will not run amuck and scramble memory or provide unpleasant and possible damaging waveforms on the GPIO pins. <S> It is guaranteed that the micro will not be damaged physically, but it could cause damage of a soft or, possibly, with bad design, a hard nature. <S> For example, if your battery powered micro is controlling the temperature in a terrarium via a MOSFET- acting as a remote thermostat and the micro runs amuck it could kill the reptiles if the battery ran down. <S> An extreme example, and in reality there should be many safeguards against that happening. <S> It's also rare that a battery powered micro can damage anything outside of itself. <S> A more common example would be scrambling of battery backed RAM or of EEPROM. <S> To make sure that never happens you must inhibit the micro (hold it in reset) for any voltage that is below 1.80V. Since the circuit that does that won't be exact (there is always a tolerance on the threshold) <S> you might pick 2.0V or 1.90V. +/-0.2 <S> or 0.1V. <S> Usually there is also some hysteresis so it might even be reset at 2.2V and out of reset at 1.9V. <S> There is usually also a minimum reset pulse width for a proper reset to occur so that should also be guaranteed. <S> You will get most of the juice out of a CR2032 even at low temperature by cutting off about 2.4 or 2.5V <S> so there is little reason to call it so close.
Add a battery detection circuit (or using the internal one) which will only release the reset when the battery voltage is high enough.
Does RF chip antennas require top/bottom ground plane to operate? I've found a lot of RF chip antennas that in their datasheet provide a reference/test PCB layout with RF results. This PCBs have antenna mounting position and a RF line surrounded by GND plane. Are this GND planes necessary to antenna to operate or they just report test board layout? I ask this becouse my board is smaller than 30mm and top ground is splitted becouse components mounting, most reference board have 50mm lenght and solid ground plane. Here's some examples of what I say: Datasheet link: http://www.johansontechnology.com/datasheets/antennas/2450AT42A100_v2.pdf <Q> Are this GND planes necessary for the antenna to operate or they just report test board layout? <S> Yes and no. <S> In your example, their test fixture shows a connector (probably SMA), surrounded by ground plane, and a feedline leading to the chip antenna, which is outside of the ground plane. <S> This is assuming the PCB is double-sided, and probably 4 layers or more. <S> This is a "standard" test setup, designed to maximize performance. <S> An ideal PCB could be shaped this way. <S> What doesn't matter is the connector and location of the feedline. <S> But changing the position of the antenna relative to the ground plane, and/or changing the size/shape of the ground plane, will all affect the performance. <S> If possible, using a layout similar to the illustration will likely give results similar to theirs. <S> Just be aware that if you start modifying anything, it will change the results, and you'll end up having to perform an impedance compensation requiring very expensive lab equipment. <S> Changing the position of say, the antenna by 1mm could make a significant difference. <S> Dimensions must be exact for high-frequency use (MHz and GHz.) <S> You cannot operate well without a ground plane at all. <S> The many vias stitch both outer layers together <S> (ground of a four-layer PCB) to eliminate any coupled RF energy from penetrating the PCB. <S> For a transmitter, not shown is even more vias, placed less than a tenth of the RF wavelength apart in the middle of the copper, to prevent induced currents from creating gradient voltages in the copper itself. <S> Not an issue for a receiver, but a great concern when dealing with high-impedance signals near a transmitting antenna. <A> The point is that your feedline is labeled 50Ω, which is a property you can only achieve with a PCB line in combination with a ground plane. <S> So, from an antenna point of view, the ground plane is probably insignificant <S> (depends on the antenna, actually), it's important that whatever you use to feed the antenna is impedance-matched. <S> What your diagram shows is typically known as coplanar wave guide, by the way. <A> It's not required in all cases. <S> In principle, there must be a return path for current. <S> In case of microstrip based structure, this return path is through ground plane beneath the feed-line and patch antenna. <S> While in case of co-planar structure ( like CPW line) <S> no ground plane in needed below that chip antenna.
For a receiver, it is possible to do single-side ground plane, and for some circuits this is fine, even with broken ground plane.
Switching between two power sources I am designing a circuit, which can use either 5V from USB, or some higher voltage (7-12V) from a battery. If both power sources are connected at the same time, I want some kind of electrical switch, that would disconnect the battery and power the circuit just from the 5V USB. But the circuit still has to work, when only one of the sources is present. I tried to design a switch using two mosfets, but I was not able to figure out a working circuit. Can such a circuit be build by only using two mosfets? Also, do not worry about the voltage regulation, that is taken care of. <Q> The simplest way that I can think of uses 3 parts. <S> A CPC1117N , a resistor and a diode (eg. <S> 1N5819). <S> simulate this circuit – <S> Schematic created using CircuitLab Operation should be self-evident- <S> the presence of the +5V USB source turns off the 9V battery source and D2 prevents back-feeding the USB +5. <S> If you need that, add a power supervisor chip to switch the SSR. <S> An LM431 and two resistors would work too. <A> There are dedicated chips that you can get which will do this but doing it with discrete parts would look something like this: simulate this circuit – <S> Schematic created using CircuitLab <S> All part numbers are the defaults rather than recommended parts. <S> Without the USB disconnected R1 ensures M3 is off. <S> R5 turns M2 off and R2 turns M1 on. <S> With USB powered M3 turns on. <S> This pulls the gate of M2 down turning it on which in turn pulls the gate of M1 high and turns it off. <S> Power then flows through D1 (which should be a schottky diode) and to the output. <S> D1 also protects the USB from over voltage while the voltage on C1 drops to USB levels. <S> Note, if the battery is under the USB voltage then the body diode of M1 will feed power into the battery. <S> This is outside of your stated operating range <S> but if it is a possibility add a diode to prevent it. <S> C1 should be sufficiently large to prevent the output voltage dipping too far during switch over. <S> And now I wait for everyone else to point out the problems with this circuit (or point out how to do it with half the parts) since I'm sure I've overlooked something... <A> That's the job of power monitors. <S> You can either buy a ready-made circuit that is pretty clever about that, for example the LTC4412, which will ensure low switchover transients etc. <S> Or you can actually build this yourself, as you said, from MOSFETs. <S> simulate this circuit – <S> Schematic created using CircuitLab Downside of this is clearly that operation from battery wastes energy by letting voltage drop over D2 – but that's necessary to ensure that M3's V_GS is always positive when V_G = V_Bat, even when there's a high voltage drop across the load. <S> You can build a more elegant version of this circuit essentially by employing the CMOS ideology – but you'd be, logically, building nothing different than two logic circuits: one that conducts power from the battery if (not USB voltage ), and one that conducts power from USB if (USB voltage).
The end result is that the output is connected to the battery. This circuit has no provisions against brown-out in the USB+5 input (for example, a 3V input could switch off the battery and leave only 2.5V at the output). In principle, yes, one or two might suffice, if you got a few diodes to spare to ensure a few voltage drops and avoid current flowing into the USB port.
4-pin-momentary button replacement with 2N2222A I want to replace the switch with an arduino trigger. this is my attempt with a 2n2222a, but somehow it triggers the switch not with the HIGHs of the PWM but with a completely other frequency I can't track. <Q> The main IC in your Velleman kit is the HT8950, a voice-changer audio effects circuit, from Holtek. <S> I would download the spec sheet and study that. <S> In particular, you want to learn about those 4 control input pins (VIB, TGU, TGD, ROB). <S> What kind of signal do they require? <S> BTW the 2N2222's base threshold is only 0.6 volts (like all BJTs). <S> You need a series resistor to limit the current, like 10,000 ohms (brown-black-orange). <A> It takes very little to trigger this. <S> The transistor is acting as a switch for a logic level input. <S> No significant current is needed for this to happen, so the quickest pulse of the GPIO is enough. <S> It's either on or off, no in between. <S> Additionally, the pin may be floating at some points in the arduino's startup. <S> A simple pull down resistor at the base would help prevent random triggering. <S> otherwise you will see many problems. <A> It looks like you basically have the right idea. <S> 1 kΩ is very low for a base resistor, but won't keep this circuit from working. <S> 10 kΩ would draw less current from the digital output, but should still turn on the transistor to act like a pushbutton plenty well enough. <S> The only possible problem I see in what you show us is that the transistor is being driven by a PWM output. <S> That means the chip must be doing debouncing internally. <S> If you try to toggle the transistor too fast, the results will be unpredictable. <S> Since the chip is meant to respond to pushbuttons on a human scale, it may also take some time to react to whatever it is supposed to do in response to a button press. <S> For both these reasons, try very slow pulses for starters. <S> Most debouncing works in 50 ms or less, since that's about the limit of a human noticing a delay. <S> However, to make sure you aren't pushing any limits, start out with a minimum of 250 ms in both the up and down states before changing any state. <S> Once you get that working, you can experiment on tightening up the time if you really need faster overall response. <S> With 250 ms per state, you won't run into any debouncing problems, so you can debug the rest of your circuit. <S> You show only a single connection between the microcontroller and the transistor switch circuit. <S> You do have the grounds of the two circuits tied together, right? <S> If not, that's definitely a problem.
That means, you only need to send them a short pulse to activate or deactivate the effect. Also you need to connect the grounds of the Arduino and Voice Changer together I think they may be "toggle" inputs. The datasheet of the chip shows just a pushbutton connected to ground without anything more. It is not meant to be used as a PWM trigger.
How to Correctly Implement this Schematic Circuit including two MOSFET? I am trying to steer a 12v motor from my microcontroller's 5V pins (CHIP).I have successfully wired it up to support on and off which included an N-MOSFET, 100kResistor and a diode. Now I want to be able to switch the motor direction also. I found this article: http://www.electronics-tutorials.ws/transistor/tran_7.html which claims that its possible with a N&P MOSFET.It includes this picture: I have wired it up like this on my breadboard (the orange cables connecting to the gates i would manually move for now, later connected to two independent pins of a microcontroller): But it doesn't work, moreover the N-Channel MOSFET gets really hot.1) What's wrong in this setup?2) Do I need to include any resistors or diodes, like i did in my simple example?3) Am I correctly hooking up the 0V of the motor to the Ground of the 5v microcontroller (white cable)? I'm still pretty new to electronics, so hopefully someone can help me out ;) <Q> The cited article assumes that the control signal has the same full swing, from -VDD to +VDD. <S> If VDD is 12V, the control signal of 5V in amplitude will not do the job. <S> At some intermediate point both transistors will be open, and the entire 12V will be shorted by them, and transistors will be fried in no time. <S> To control a 12V motor in both directions, you should be using a H-bridge. <A> The driver for the circuit as shown cannot be a logic gate. <S> To work in this configuration the FET gates would have to be driven by a rail-to-rail op amp such as the LM7322 configured as a comparator. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> While this will certainly work, and you can turn drive the motor with either a positive or negative voltage it has limitations if you only used a Pin output of 1=fwd 0=rev from the microprocessor. <S> To get speed control or to hold the motor stationary you would have to use a PWM signal. <S> If the input is a square wave with equal high and low periods then the motor would be stationary. <S> It will consume some power in this state (depending on the freq used) and if the switching frequency is in the audible range you will hear it (it acts somewhat like a speaker). <S> As you change the duty cycle of the input waveform, the motor will move either fwd or reverse. <S> One last problem you need to think about with this type of drive circuit is that when you power up your microprocessor all the digital ports are likely to be set as inputs (essentially only with a pullup at best). <S> This will mean that until you initialize your ports the motor will be driven. <S> While the micro starts up and comes out of reset <S> and you get to run your code <S> could take mS. <S> This might be enough to give the motor a sudden jolt at least. <S> If this is a concern you really need to have an enable/disable signal designed in. <A> First, you have to use a push-pull configuration such that N-CH MOSFET (or NPN BJT) transistor is on the top side and P-CH MOSFET (or PNP BJT) is at the bottom side. <S> This is very important, else you will fry the transistor. <S> Then you can use a MOSFET gate driver IC, or use a buffer with discrete components, since this app. <S> is not intended for fast switching.
But you will not be able to turn the motor CW/CCW without a positive and negative power source, what you really need is H-Bridge.
Does Op-Amp 741 boost the frequency of an input signal I am trying to design an electronic circuit which does the job of a dog whistle. So basically when a human whistles using the mic of the circuit, the circuit boosts the frequency to at least 50kHz or so. I am thinking to use op-amps in the circuit to boost the frequency but I am not sure if it will boost the frequency. Can anyone help me with this please? <Q> An op-amp will not of itself boost the frequency - it amplifies voltage, not frequency. <S> Two possible approaches are either to use a gated oscillator or to use a phase-locked loop to change the frequency. <S> As dog whistles are effectively a tuned circuit running at an ultrasonic frequency, the gated oscillator is probably a good bet. <S> Try a phase-shift CMOS circuit such as a CD4011 with delays between the gates and feedback from the third to the first gate (you need an odd number of gates to make it oscillate); the fourth gate can be a buffer to drive the output transducer. <S> You do not need a mic for this; a pushbutton will do. <A> No linear element can add frequencies to a signal that aren't in the original. <S> A opamp when used properly is usually a linear element. <S> In any case, the purpose of a opamp is to provide voltage gain, not to introduce frequencies. <S> Then there is the question of what exactly the very vague "boost frequency" means. <S> Does this mean, for example, to shift all input frequencies up by maybe 20 kHz or so, multiply them by some fixed value, or something else? <S> Should the entire input waveform be "boosted" in frequency, or the primary frequency identified, then a higher single frequency produced that is a function of the primary input frequency? <S> There are too many unanswered question to be able to give a reasonable answer about how to proceed. <S> Check out "product modulation" or "heterodyning". <S> These can be used to shift whole ranges of frequencies. <S> A microcontroller looking at zero crossings, after some filtering, can identify the primary input frequency and produce some other frequency as a result. <A> It produces a sound whose frequency depends on the whistle's physical dimensions, like a wind musical instrument. <S> You're not whistling into one end of it and having your whistle frequency boosted. <S> Your role in generating the sound is analogous to that of the power supply for an electronic oscillator. <S> You could make a 23 to 54 kHz (Wikipedia on dog whistles) oscillator embodying a 741, and use it to drive a speaker. <S> Not the best choice: not very loud, among other things. <S> Your reference to using the + input suggests that you know of one of the popular configurations for relaxation oscillators. <S> That configuration wouldn't be a bad starting point for your design. <S> The earlier two answers are not just correct. <S> They have worthwhile points for you to consider and research. <A> There have been interesting frequency doublers that use fullwave rectification of a clipped signal to get the loudest signal component doubled in frequency. <S> With some work you may be able to do this. <S> Use an ALC, suitable band pass filter (say 8 to 14 kHz) an amp and clipper, fullwave, level shift, amp and HiFi tweeter. <S> The other alternative in the modern world is to use a DSP or fast micro-controller and do continuous <S> Fast Fourier Transform on an input signal and adjust gain to keep the calculations sane. <S> EDIT: I forgot to add in the DSP option you would have to shift the spectrum in the frequency domain and then do an inverse FFT. <S> The signal quality does suffer but that is normal for digital time<>frequency convolutions. <S> Also another option was to see if any of the old pitch shifting ICs or gadgets were still to be found. <S> They were popular as voice changes and I seem to remember some could do simple pitch changes. <S> I donot recall what method they used, perhaps a simple DSB or AM modulation and then back again at an ofset frequency. <S> The signals (voice) would be garbled pretty badly as the upper and lower sidebands would overlap badly depending on there the frequency fold occured. <S> A possible analogue domain solution is also to modulate the signal into a SSB at some handy intermediate frequency with high quality sideband reduction filter and then modulate it back down again to an offset frequency and then high pass filtering to clean it up, the quality would be better than the DSB/AM option but still hard on the ears, perhaps the dog will not mind. <S> This would be more involved but is sure to have been done before. <S> This (and the previous) technique woud allow for frequency shifting as opposed to doubling. <S> I just remembered that the fix for the very poor performance of the fullwave rectified solution was to use an analogue squaring /self-multiply circuit as this would preserve the amplitude somewhat. <S> This is sensitive to amplitude and signal noise but a bandpass filter and AGC to preceed <S> might get something out. <S> This would be a frequency doubler like the fullwave rectified system.
A dog whistle doesn't "boost" frequencies.
Heating up water with electrical current Is it possible that (isolated) wires carrying high current, such as 200A, passing through water will heat up that water like a boiler? I have been told by someone that a fuse panel in a building had its bottom immersed in water and apparently this created a lot of heat and steam. Does this make any sense? I know that inductive heating COULD possibly occur, but we are speaking 50Hz and no coils but straight wires. Usually one would expect that with frequencies in the kHz range. Resistor-type heating would probably not have occured either since wires in a fuse panel would be highly conductive. <Q> There is no inductive heating since water is not magnetic (in any working sense). <S> So if only an insulated wire contacted the water there would be no current flow and no heating. <S> So your story (if no wire contacts the water) is incorrect, but since power wiring panels have lots of bare voltage carrying conductors in them, I assume it's just someone got it wrong. <S> Providing the water is impure enough to conduct there will be current flow and therefore heat generated in the water if the wires contact the fluid. <S> Depending on the voltage available there is likely to be lots of heat and steam. <S> There are many (mostly Chinese) shower and water heaters that use this very method, although it is potentially hazardous. <A> Yes, it is Joule's heat (I^2R). <A> Fuse panels are not isolated, there is a lot of metal (conductive) terminals between hot wires and returns and earth ground inside, 0.5 -2 inches apart. <S> More importantly, depending on overall electrical hook-up (two phase or three phase), adjacent hot terminals can have 200-300V RMS of relative voltage. <S> The amperage of wires does not matter much in this case. <S> Now, if the fuse box was immersed into ground waters, it is bad. <S> Ground waters may have high mineral content, and therefore high conductivity. <S> According to this general water chemistry article , ground waters can have conductivity from 50 uS/cm to 50,000 uS/sm. <S> According to conversion from microSiemens to resistance , this range of condictive water can give anywhere from 1k down to 20 Ohms of resistance at terminal distance of 1cm. <S> This is the typical distance we have in a fuse box. <S> Therefore, in the best case we have 200V over 1kOhm resistor, which gives the Joule heat at 40 Watts, and in worst cases one can have a kW of heat over the water conductor. <S> So, it is pretty feasible to have a water boiler out of immersed fuse box.
Electrical energy in the wire is converted into heat (depending on resistance of the material) and the water in contact get heated up.
Running resistors above power rating, but with temperature within spec I am building a circuit to heat a very small area to a relatively high (~100C) temperature. To achieve this, I'm using an SMD resistor controlled by a MOSFET, with an adjacent thermistor for temperature monitoring and control. To achieve faster heating I'm considering running a higher power through the resistors than what they are rated for, at least until they reach the needed temperature. As long as I control the temperature (via PWM control) of the resistors and maintain their temperature within what they are rated for (typically around 125C) are there any issues that would result from doing this? <Q> I'd suggest that small SMD resistors would be questionable, but you certainly could use very small power resistors to achieve your goal. <S> This type of power resistor might suit your need: <S> http://www.vishay.com/docs/51055/d2to20.pdf <S> You have not been specific about your needs in terms of volume, but resistors like this have an SOA out to 140 degC. <S> I've also used two TO-220 power transistors clamped around a crystal to make a crystal oven at 80 <S> degC...worked well. <S> Depending on your application (and since you are already using a FET to drive the resistors) you could simply use the FET as the heat source. <S> By holding VDD constant for an N-Channel FET at some voltage level you can dissipate all the heat required directly in the FET. <S> All the same rules apply in terms of temperature, but most power FETs have an SOA out to at least 125 degC <S> so 100 <S> degC sounds pratical. <S> You could sense the current through the FET using a small value resistor. <S> You could even use a linear power regulator in anything from TO-92 to TO-220 <S> or even SMD D2PAK to provide the heat. <S> Just configure in a constant current circuit and modulate it from the feedback pin divider. <A> Probably not. <S> However keep in mind that the temperature on the surface of the resistor (or at the sensing resistor) may not be an accurate reflection of the core temperature of the resistor. <S> For large, fast increases in voltage or current the resistor temperature gradient (difference between core inner and outer temperature) may be substantial. <S> I suspect that this gradient wouldn't be relevant for an smd part. <A> Lets talk about time constants of components. <S> Ceramic substrates for resistors include silicon atoms. <S> Silicon cubes, 1cm cube, has thermal tau of 1.14 seconds. <S> Silicon cubes, 1mm cube, has thermal tau 100X <S> faster, or 11.4 milliSeconds. <S> Silicon cubes, 100micron cube, has thermal tau again 100X <S> faster, or 114 microseconds. <S> Point being: your thermistor will not report the correct temperature, because there is substantial "thermal distance" between the heat source and monitor. <S> You can model the heat flow between the Thermistor and the Heat Source, using Rth of copper foil {1 ounce/foot^2} as 70 degree C per watt per square --- any size square: 1cm, 1 foot, 1 mm. <S> [ before edit, the numbers were for copper: <S> 0.9sec, 9.0mS, 90uS]
It would seem possible to drive this sort of device with a PWM to provide the temperature increase needed.
How do GPS satellites refresh their clocks How do GPS satellites keep their on board clocks accurate? I assume that they need to get update from a base station. But how do you make sure that after the update all the satellites are synchronized, i.e. there isn't any phase shift. You have your base station on earth, and assume that all the satellites you want to update are in line of sight. You send an update command. But, each satellite is a different distance from the base station. There will also be a delay from receiving the command, to updating the internal clock. Some satellites may have newer hardware, which is faster. If you update the satellites separately, you would need to ensure that your timings of the commands that you send are very accurate. This seems like a difficult thing to get right. Is there a better method that is used in practice? I guess what I am interested in is say you have a clock at location A. How do you synchronize it with a clock at location B, which is far away from A? You have the message flight time delay, processing delay in B etc. <Q> Clock errors are not corrected, they are compensated in two steps. <S> 1. <S> Error determination <S> The reference for position is the WGS84 reference frame , for time it is the international atomic time . <S> Even the smallest effects like continental drift and relativistic time dilatation are taken into account. <S> 2. <S> Error Compensation <S> The onboard clock (in fact, the SV Z-Count, see IS-GPS-200 3.3.4) is not tuned , slewed or reset to compensate for the error. <S> Citing IS-GPS, 20.3.4.2: <S> Each SV operates on its own SV time Instead <S> , the offset between UTC and this spacecraft's clock ("GPS-Time") is broadcast in the navigation message (see IS-GPS 20.3.3.3.1.8). <S> This does not only include the current offset, but also different forecasts ("fit intervals", 20.3.4.4). <S> Normally, only the highly precise short term forecast is relevant, the others would be used if the control segment is inoperable and no uplink is possible. <S> Likewise, the position error (deviation from nominal orbit) is left uncorrected (this would deplete precious fuel), but is broadcast to receivers by uploading ephemeris data (orbital elements) to the spacecraft. <S> Time of flight is no issue for the uplink, as the new fit interval data has already been determined in the previous step. <S> The actual compensation is then done in the receiver (user segment). <S> It applies corrections when relating the observed signal/code phase of different SV. <S> Exceptional situations <S> Sometimes, old spacecraft behave in unexpected ways <S> , for example their clocks begin to drift unpredictably. <S> AGI has a website with performance data of onboard clocks. <S> You can see, that USA-151 s clock (sending PRN28) is a little bit shaky and needs frequent compensations. <S> If a clock goes wild or a powered maneuver makes the SV unusable for navigation the SV sends an "inoperable flag" in its navigation message and is ignored by end users' receivers. <A> say you have a clock at location A. <S> How do you synchronize it with a clock at location B, which is far away from A? <S> You can do what NTP does. <S> Roughly speaking, send a request for current time at the moment \$t_0\$ <S> the server receives your request at \$t_1\$ and sends you a reply at \$t_2\$ receive the reply \$T\$ at the moment <S> \$t_3\$ <S> set your time to \$T+\delta\$: Note that this is not what GPS does because there is no point: satellite second is shorter that Earth's second due to gravity, so it's impossible to keep clocks in sync. <A> The constellation of GPS satellites is constantly monitored by several fixed ground stations positioned around the globe. <S> These ground stations monitor all the satellites and send correction factors if any drift is detected. <S> The GPS control segment consists of a global network of ground facilities that track the GPS satellites, monitor their transmissions, perform analyses, and send commands and data to the constellation. <S> The current operational control segment includes a master control station, an alternate master control station, 11 command and control antennas, and 15 monitoring sites. <S> Ref: http://www.gps.gov/systems/gps/control/
The GPS control segment uses reference receivers in well known locations to determine the actual orbital elements and the clock error of space vehicles.
Latching relay - Remember state after power failure first off this is my second question here so pardon me for any blunders. I am trying to use a relay to control appliances. My arduino will trigger the relay on/off. Additional requirement is in case of power failure the relay should be able to maintain its state so that it is in same state when power comes back. Ex: arduino turned on the lamp (using relay), power failed, power is back, the lamp is in ON state. I read about them quite a bit and found out that I need a Latching relay. I tried to find them online and stores(vetco, radio shack) but all I find is bulky things. Are there any latching relays that are similar in form factor to regular ones? Also any other alternate options to make my requirement possible without a latching relay? <Q> Not sure why you would want to go down the path of latching relays. <S> You have an Arduino that when powered on can turn the power to your devices on and off .... <S> you also have EEPROM in your Arduino, so could save the current state of devices to EEPROM. <S> And when you startup after a power failure...if there are values in the EEPROM....restore them. <S> You might want to consider whether you restore all values or just selected items since you may have power failures when you are not present.... <S> just a thought. <A> Latching relays are available in DIP form-factor. <S> For example there are two different kinds available from All Electronics right now. <S> You did not reveal what is your load (current, power, voltage, etc.) <S> so we don't know what size relay you are looking for?? <S> You could also use non-volatile memory to store the state. <S> You could use an ordinary flip-flop/latch backed up by a coin cell (or a couple of AA cells, etc.) <S> Some microcontrollers have some available NVRAM (non-volatile memory) available for storing status, etc. <A> Using a latching relay means that when power is restored, it is immediately available at the appliance. <S> Each scenario has its pluses and minuses, you need to thoroughly vet those before making a decision as to which way to go. <S> Nobody can answer that for you without full detailed knowledge of what you are trying to accomplish and why. <S> If you want to go with a latching relay, it requires either two coils, a Latch and Unlatch coil, meaning two signals as well, or it requires a relay with a complicated mechanical toggle mechanism that alternates the state of the contacts with each successive pulse of the coil. <S> Either way, it requires real estate to make it happen.
Some auxillary chips like clock/calendar chips have some available non-volatile memory available for you to use. Using a retentive state in the controller energizing a regular relay means there will be a delay on the re-application of power to the appliance.
Filter opto-coupled mains signal for a digital input I need to read an input of 220V and convert it in TTL logic 0-5V for my Arduino. If there's a presence of 220V at the input of my circuit, I read 0V in my Arduino, else I read 5V. In parallel, I have a speed variator for a DC MOTOR 42V/11A with PWM frequency 4Khz. My problem is, I have noises coming from the motor which cause 0V input in the Arduino without presence of 220V. Here are the circuits: I use a soft Pullup resistor. There's two part, the first one is without a RC filter so I can clearly see the noises, and the second one with a filter I tried to make, here are the signals I got from each one. Below the oscilloscope showing the signal with RC filter (2V/DIV 1ms/DIV): Below the oscilloscope showing the signal without RC filter (2V/DIV 1ms/DIV): So what should I add or change to my circuit to get a smooth 5V? <Q> Three things jump out at me. <S> 1) <S> You are clearly seeing magnetic coupling of load current spikes. <S> Your 47 uF cap should be able to filter out "regular" spikes. <S> So connect from the line to your circuit with twisted pair, and keep the circuit as compact as possible. <S> Everything up to your opto input is connected to mains, and you clearly do not have much experience dealing with electronics. <S> This is a bad combination, and you may well wind up shocking yourself. <S> And, yes, you say that you don't have room for a transformer. <S> To this I have 2 responses: a) <S> you can get quite small transformers (1 <S> " x 1" x 1.5"), and b) the universe doesn't care how restricted your space is - if you touch the wrong point you will get zapped regardless. <S> 2) <S> Your use of soft pullup is a very bad idea. <S> The value of the soft pullup is specified as 20k - 50k, which is so high that it takes very little feedthrough in the optoisolator to produce a detectable pulse. <S> Place a 470 ohm pullup resistor at the input to the uP, connected to the processor supply. <S> Depending on the grade of opto you're using, you may need to decrease your optocoupler input resistor some. <S> 3) <S> They are intended as rectifiers, not signal diodes, and are very slow. <S> Instead, use something like the 1N4148. <S> Finally, if you are desperate, you might try connecting opto pin 2 to pin 4 with a 1 Megohm resistor. <S> This should calm down your input some while limiting leakage currents from the mains. <A> Your circuits looks very complicate for generating a simple TTL signal. <S> Try to make the this resistor smaller, ~4.7kOhm should be a suitable value. <S> If there are still problems I can suggest you the following circuit. <S> It's very easy and works perfect for me. <S> Also it has a galvanic isolation. <S> OK1 <S> 4N33 <S> D1 <S> 1N4007 <S> R1A 27k (1W) <S> R1B 27k (1W) <S> R3 <S> 10k <S> The website is Zero crossing detection . <A> Thank you everyone for your advice, i learned a lot . <S> i found the solution, it was very simple <S> i couldn't believe it when it worked, I just add a 15nF capacitor near the microcontroleur INPUT. <S> So it was the electric wire between the microcontroleur and the output of my circuit that was picking up the noise.
The problem might be the wrong filter design and the pull-up resistor. Along this line, you really need to put transformer isolation on your input. In your filter, do not use 1N400X diodes.
Can you get 18V from two 9V batteries Can I get 18V from two 9V batteries if I join two together? How will I join them? <Q> You connect the + end of one battery to the - end of the other. <S> The remaining unconnected battery ends are the ends of the overall 18 V battery. <S> While you get more voltage, you don't get more current. <S> If each battery is capable of 9 V at 300 mA, for example, then the combined battery is capable of 18 V at 300 mA. <A> Yes, they can be connected in series. <S> The voltage is doubled and the Ah life is the same (but twice the voltage, so twice the energy, as you might expect). <S> Or just connect the wires from the snaps as shown below (image from here ). <S> If you choose to clip more than a few together you should take appropriate safety precautions. <S> The 'crazy dude' in the comments who linked 244 together to get ~2kV has an electric chair supply on his hands. <S> The short-circuit current of a fresh alkaline 9V battery is about 3A, meaning that string could supply >1kV at 1.5A. <S> Even if the current didn't go through your heart, the resulting 1.5kW of heat would quickly cause severe tissue damage. <S> Allegedly DC can be more dangerous than AC because it makes it harder to let go. <S> I don't know that there have ever been detailed experiments done on this (perhaps some organization such as Unit 731 did). <S> In any case, avoid getting shocked. <A> Yes, battery ones negative pin goes to battery twos positive pin. <S> Then the positive of battery one is your 18 volts, negative of battery two is your ground.
Yes, two 9 V batteries in series results in one 18 V battery. You can snap them together (female to male snap) and they will be connected correctly.
Is there such a thing as filtered LEDs? I'm trying to "re-engineer" (the original designer doesn't manufacture the board anymore but they were kind enough to provide me with the diagram) a circuit that replaces an incandescent bulb with a LED, and it specifies a white LED "filtered" to 3000K. My question is, does somebody out there make a LED with an integrated filter, or do I have to add an external filter to the LED? EDIT: I should have probably said this in the beginning, but the LED is going into a light meter, which is probably why it's filtered down to 3000K. The meter is this one; http://www.jollinger.com/photo/meters/meters/sei_photometer.html EDIT2:Now I found the site with the exact thing I'm trying to build, there's definitely a filter on top of that LED. http://www.huwswebthing.talktalk.net/seiled.htm <Q> I think this is just a misuse of terminology, and you should read it as merely specifying a white LED with a color temperature of 3000 K. <S> A filter after that would just be wasteful compared to using the right phosphor mix to start with. <S> Just buy an LED whose specified color temperature is 3000 K. Or don't, and choose whatever color temperature you like — this affects the light output, not the electrical behavior, and is purely an aesthetic choice unless the produced light is being is used in some precision application rather than room lighting or as an indicator. <S> The circuit will not care. <A> There are many indicators of light quality which affect the use. <S> Intensity, to the eye in (milli) candela density of light in luminous flux or lumens total, for all directions Beamwidth in <S> degrees to 50% intensity <S> x,y color coordinates referencing CIE 1931 standards for which neutral daylight white is 0.310,0.310 <S> Correlated` Color Temperature (CCT) in degrees <S> Kelvin[K] <S> which is 4500 to 5000'K is preferred daylight and <S> 3000'K is warm with a yellowish tint, while 6000'K is cool with bluish tint color rendering index (CRI), which is a value up to 100, where white LEDs fit between 89 and 92. <S> most LEDs use same mix of phosphor but the delicate balance of thin layer determines if 10 - 20% is converted from narrow Blue to broader orange and red by secondary electron phosphor emission. <S> This consumes some of the blue energy to create the longer wavelengths. <S> However to the critical eye there are many subtle shades of offwhite that all have the same CCT of 3000'K due to the broad tolerance of phosphors. <S> However when I hear a spec that indicates colour filtered, I know the application needs to be reviewed to see if it is an "indicator" or an "illuminator" for some area. <S> So,which is it , and any idea how it is used? <S> I have been in business for 11 years specifiying custom LEDs for Autobaun and Swiss Tunnels in a wide variety of applications for Traffic and Emergency lighting. <S> Added <S> The luminance of the internal lamp is adjusted using the rheostat (N) until the electrical output of the photoelectric cell (H) matches the calibration mark on the microammeter (A). <S> Turning the base of the instrument drives the two neutral density optical wedges to vary the luminance of the upper diffusion screen (F) image reflected by the mirror spot (C). <S> Good luck finding a bulb to match the old one. <S> It must be identical in tungsten filament thickness and length and voltage and current vs radiated light. <A> Specifying a "white LED filtered to 3000K" seems like rather an ignorant suggestion (absent perhaps mitigating facts not in evidence??) <S> It begs the question <S> , why not simply specify a "3000K" LED and get on with it? <S> Or have you left out some important detail that would change the picture? <S> LEDs are so monochromatic that they don't need "filters". <S> In fact rather the opposite. <S> They are so monochromatic that it either takes multiple (Red/Green/Blue) LEDs to simulate "white" or <S> it takes an ultra-violet LED and a white phosphor (rather the "opposite" of a filter). <S> Furthermore what exactly do they mean by "white LED"? <S> You can buy white LEDs in perhaps a dozen different color temperatures (including 3000K).
An incandescent bulb might indeed be filtered to adjust the color of its light, but white LEDs instead use phosphors to produce the desired spectrum starting from monochromatic blue light.
Why can't stepper motors be powered off of 9V batteries? According to Adafruit , "you can't run motors off of a 9V battery so don't waste your time/batteries!" I've been searching around and it seems like most sources do use wall adapters, but without justifying why. What's the explanation for this? <Q> You can run stepper motors on 9V batteries. <S> You just have to respect the batteries limitations: Imgs from this datasheet. <S> Which means, a limited amount of current (typically 300mA max), at a low-ish voltage 4V~9V, during maybe 1~2 hours. <S> So it's not impossible <S> , it just doesn't make much sense, thats all. <A> 9V batteries have a terrible current rating and capacity since they're made of six smaller 1.5V cells. <S> Since stepper motors need to have two coils energized at a time there is very little chance that you can use anything but the smallest of stepper motors for very long with one. <A> It isn't quite accurate to say that you "CAN'T" operate stepper motors from 9V batteries. <S> Quite possibly in a matter of minutes. <S> So it is an incredible waste of batteries to power something that needs that much power from a 9V battery. <S> It has the LOWEST power density of ANY commonly available consumer battery. <S> Even less than a AA cell.
They actually mean that most stepper motors draw so much current that they won't run very long from a 9V battery before draining it completely.
How does the dish size increase reception range of radio signals? For example if you want to transmit a song through FM, does the receiver's dish size actually increase the range in which he can detect these signals? if it does then how? <Q> A 100mm parabolic reflector could light a cigarette from sunlight. <S> But it would take a 3m reflector to boil a liter of water. <S> As Tony Stewart cautioned, however, broadcast FM (down around 100MHz) is rather lower than most practical parabolic reflector dishes can operate at. <S> Although there is a bit of reflection happening in many TV/FM antennas with those multiple rods in a long array, etc. <A> FM has a such a long wavelength that you would need an enormous satellite dish for it to effectively focus the FM signal. <S> Thus gain is lost from the ratio of the undersized dish to half wave. <A> Well it does not. <S> The only thing that changes is the intensity of the received signal. <S> The frequency range remains the same how large the dish be. <S> The length of the antenna has effect on the receivable signal and <S> the calculations for the same can be found in net easily.
A bigger dish is simply able to "catch" more of the power being sent through the air.
Deriving 5 V and 3.3 V from 12 V using single IC I am making a college project which requires me to use a 5 V LCD display and a 3.3 V microcontroller. I am using a 12 V power adapter to power to complete circuit. I am using LM7805 and LM3940 to generate 5 V, and 3.3V, respectively. Is there any IC that takes in 12 V and spits out 2 or more voltage levels like 3.3 V, 5 V, 9 V etc? If such ICs exist then what is the IC classified as? (like 7805 is a linear voltage regulator). The IC I require should do something like this:- <Q> Using a linear regulator of any kind to get 5V from 12V is very inefficient. <S> 3.3V is even worse. <S> To get 0.15A <S> at 5V (0.75W) will waste more than 1W in the regulator and will likely require at least a small heatsink. <S> You could consider using a switching regulator. <S> This works best if the current from the 5V is relatively high (for example for an LCD with backlight which might require 100mA) and the current from the 3.3V supply is relatively low (for example a typical 8-bit micro which might only require 10mA). <S> In that case, an SOT-23 regulator could probably be used. <A> Is there any IC that takes in 12 V and spits out 2 or more voltage levels like 3.3 V, 5 V, 9 V etc? <S> Yes, certainly – but they won't get easier than using two linear regulators – the amount of external components (in this case, only in- and output capacitors) cannot be reduced. <S> If such ICs exist then what is the IC classified as (like 7805 is a linear voltage regulator). <S> " <S> Voltage Regulators with multiple outputs" <S> Now, what you ask is basically a shopping recommendation, and thus, would be off-topic here, so let's rater conclude a list of things you need to decide: <S> Ranges of input voltage Nominal output voltages, acceptable deviations from those Currents on each of these outputs that your supply needs offer <S> With those information, go to the website of semiconductor manufacturers, and use their "power supply design" tools. <S> Typical companies are Texas Instruments Maxim <S> Linear Technology <S> ST <S> Micro <S> ... <S> All of them have tables of their voltage regulator products, and many of them also have tools where you just type in the data that you've compiled, and they spit out possible components and propose circuit designs. <S> As said, in your scenario, having two separate regulators, one for 5 V, and one for 3.3 V, is definitely the easiest solution. <S> It's common to see a cascade of power supplies – i.e. the first stage would convert 12 V -> 5 V, and the second stage just 5 V -> 3.3 V, to avoid "burning" (12-3.3) V = 8.7 V in a single supply IC. <A> There are many dual rail regulators on the market, but they tend to be for specialized applications and mass produced itmes. <S> There is this from OnSemi: http://www.onsemi.com/pub_link/Collateral/ENA1982-D.PDF ...and this: http://www.onsemi.com/pub_link/Collateral/MC33762-D.PDF ...which might just work for you. <A> sure!you can do this: use reverse biased zener diode in output pin of ic regulator. <S> now you have 5v voltage before diode and 3v after it.use this devices: ic:7805, zener diode <S> 1n4615 or 1n4370.for better performance add capacitor. <A> By doing a quick research on DigiKey, I was able to come up with a few devices but that will be up to you to find which one is better since shopping recommendation is off-topic. <S> A simple LDO will typically have one input and one output voltages but it can be designed for multiple outputs. <S> Thus, the die in the chip is bigger and other noises <S> considerations must be taken but I won't get in more details here. <S> Some parameters to consider would be voltage input, voltage output, number of regulators, voltage dropout, and the package.
One method that is sometimes useful is to derive 5V from the 12V with a switching regulator (or use a 5V source to begin with) and then derive the 3.3 from the 5V with a linear regulator. Instead of 2 chips for different voltages, an electrical design engineer would converge both chips into a single one. To answer your question, Yes there are such devices with a single input voltage and multiple output voltages.
What is the Best Way to Reduce High Power Three Phase Rectifier Ripple? If a three-phase 220V AC @ 50Hz(three lines having 127V RMS voltage if measured to neutral each) mains supply is rectified with a standard 6-diode rectifier looks like this: I believe if 25 amps is drawn from output of rectifiers with a rectified voltage of roughly 310V DC, then it can deliver about 7.7kW of power. I know in single-phase full bridge rectification the following formula is used to calculate voltage ripple: Vripple = Iload / (2 * f * C) QUESTIONS: Now the challenge I'm facing is how can I reduce the ripple to less than 1%, so I could deliver a steady DC power? Am I right to assume in three-phase full bridge rectification the following formula can be used? Vripple = Iload / (6 * f * C) Can I get away with a bunch of capacitors or is it better practice to use either a buck, boost, or buck boost converter? <Q> A choke would not do it all, you still need caps, but you can make a choke cheaper than you can buy caps. <S> With the caps however, you must be careful about inrush current, so generally that is dealt with by using a "pre-charge" circuit of either a current limiting resistor that is shorted with a relay / contactor in line with the DC circuit ahead of the caps, or using an NTC thermistor (up to a certain power rating). <S> The multi-phase transformer method requires more diode bridges and is generally used to reduce the harmonics created on the line side, not the DC bus ripple. <A> You may use special transformers for a twelve-pulse-bridge, see here https://en.wikipedia.org/wiki/Rectifier#Three-phase_rectifiers . <S> Your circuit is a six-pulse-bridge, but even 18 and 24-pulse-bridges are possible. <S> The additional phases are generated by using two sets of secondary windings, one in star (wye) connection and one in delta connection or by adding the voltages of additional secondary windings of the transformer. <S> You don't need capacitors to smooth the DC voltage, but you need the special three phase transformer and additonal recitifiers. <S> The twelve-pulse-bridge is often used for high-voltage, direct current (HVDC) electric power transmission systems, see here https://en.wikipedia.org/wiki/HVDC_converter <A> Perhaps consider a multi-phase transformer (e.g. 3 to 9), this will decrease ripple significantly with low-losses. <S> This Paper claims 0.8% ripple using multiphase transformer <S> You can augment the transformers with high-power capacitors.
Capacitors are the simple way to do it, but you can decrease the amount of capacitance needed by putting a DC link choke in the circuit after the rectifier.
Fixing electrical controller (with joystick) on Pride Quantum 600 power wheelchair The momentary switch is bad on a Pride Quantum 600 power wheelchair. The picture is below. It turns on, but you have to hold the rubber button/switch in the correct spot with the right temperature before it will turn on. What could be the problem or cheapest way to fix this? The part to replace the entire controller (what you see in the picture is $1750). The part number says J6, but the Jazzy and Quantum use the same controller. Pride J6 Joystick Controller with Flying Leads (Part #: ELEASMB5009) <Q> After a lot of investigation and internet searching, I came across this YouTube video, which was very helpful in understanding what was inside. <S> https://www.youtube.com/watch?v=5UYn138cKCI <S> This did not solve the issue, but it helped me understand what to look for. <S> In the video, he mentions you need a T10 security torx screwdriver. <S> It actually requires a T10 torx (normal) screwdriver before removing the shell of the controller. <S> MAKE <S> SURE <S> TO UNPLUG <S> THE WIRES IN THE BACK OF THE WHEELCHAIR <S> BEFORE REPLACING. <S> Pride part # RECPART1061Merits part <S> # P75736Shoprider part <S> # P75736 Keypad for 6 Key Button VSI Joystick Controller Pride, Merits, Shoprider. <S> NEW As you can see, the on/off switch was worn down to the nub! <S> See top switch/button in the first image. <S> Finished product! <S> If you need to buy a new controller, purchase a used one with the following name, not the part number shown in the question, as suggested by my durable medical provider. <S> The serial number of the chair did not give them the correct part number, so never trust that. <S> Always look at the number on the actual component! <S> Correct part name: 6 <S> Key 50 <S> Amp VSI Joystick Controller with Flying Leads <S> Here's some detail if the keypad is bad, and you need to replace the entire controller. <S> Pride Mobility: <S> CTLDC1419PG Drives Technology: <S> D50693.01Compatible Models :Jazzy <S> 600Jazzy <S> 610Jazzy 1103Jazzy 1103 <S> UltraJazzy 1143 UltraJazzy J6Pride J6 <A> This isn't an answer to guide your repair, but it is an answer for how to deal with it, if you live in the US. <S> The Wheelchair is a medical device. <S> The maker is required to do post market surveillance for adverse events. <S> This crappy switch preventing you from using your medical device is an adverse event. <S> Call the company that made the chair, and tell them that your plan is to report this as an adverse event to the MAUDE system through Medwatch ( https://www.accessdata.fda.gov/scripts/medwatch/index.cfm?action=reporting.home ), and ask if they can offer you service before you do that. <S> This system can actually trigger FDA recalls, and I believe manufacturers are required to respond to such reports. <A> The joystick looks fairly new (<3yrs old) . <S> Unless there was excessive force, I would suggest it is a defective component and that you request an RMA for free repair. <S> LIFETIME LIMITED WARRANTY <S> For the lifetime of your power chair from the date of purchase, Pride will repair or replace at our option to the original purchaser, free of charge, any of the following parts found upon examination by an authorized representative of Pride to be defective in material and/or workmanship: <S> Structural frame components, including: <S> Main Frame <S> TWO-YEAR LIMITED WARRANTY <S> For two (2) years from the date of purchase, Pride will repair or replace at our option to the original purchaser, free of charge, any of the following parts found upon examination by an authorized representative of Pride to be defective in material and/or workmanship: <S> Electronic components, including: Main frame assemblies, including: Charger Assembly Caster forks Metal seat framing <S> Controller Caster beam <S> Joystick <S> If they refuse to assist, then make a You Tube video exposing the quality defects of the part and send it for refurbishment to a 3rd party. <A> I misunderstood the problem to be the joystick rather than the ON/ON tactile button. <S> These Carbon membrane contact switches are notorious for excess force degradation and surface oxidation with dust and smoke acting as insulation. <S> Cotton Q tips with pure alcohol usually resolve cleaning the carbon surface. <S> The contacts on the PCB must be gold (Au) plated and not any other method (Sn-Pb-Ni-Ag-Cu etc). <S> In Fact ALL metal contacts must be Au gold plated for any contact rating <= <S> 2A, which is true for mechanical switches and relays. <S> If not, premature failures will occur. <S> In the 70's Hewlett Packard made all their circuit boards dip gold-plated 20~30u" thick (not flash e-plated 1~2u") and the card edge fingers needed servicing from time to time from regular use. <S> In every maintenance manual, HP specified the exact part number of the PINK PEARL ©®™ eraser to clean the gold plated finger contacts. <S> In the 80's our factory in Flemington NJ, designed a robot for testing the quality of their keyboards for the B21 computers to simulate 10 years of daily use. <S> Attention to quality reliability with accelerated life testing is something I find lacking in our field of Design and Test Engineering and those who are in volume production need to educate themselves on HALT/HASS/ORT life testing to fix reliability issues.
To solve the issue, I ended up buying a new controller keypad on Ebay for $33.90. Pride (manufacturer) will not let you ask questions unless you have an account with them, so you have to trust the staff at a distributer, who in my case were wrong, and would have charged me for the copay of a $1750 controller, which was the wrong part number. However I have seen escalation of failures in carwash kiosks where the (ab)users found their car key tips would make the membrane button work, until it was totally destroyed.
What are the voltage & current ratings of output contacts of optocouplers ? whether they can withstand ac voltage or not? Currently I'm designing Voltage Stabilizer and I'm using three DC relays at the output of my AVR Controller, at the output of relays I have connected ac sources which is in the range of 190V to 280V and current ranges from 0.9A to 2A, whether I can use opto-coupler (opto-isolator) instead of relays or not ? <Q> Devices sold as optocouplers generally have a an output that approximates a current source, with high output impedance, which is very different than a relay. <S> Also they generally only pass current in one direction. <S> Depending on what you're actually trying to do, you might want to investigate solid state relays or SSRs. <A> What you most likely need is an SSR. <S> Do you really need 280 VAC rating? .. <S> or do you just need to operate on 230-240 VAC? <S> If you only need 230 VAC, then look for "Arduino SSR" on Amazon or Ebay. <S> There are lots ranging from single through to 8 channel that will likely support what you need. <S> Be aware that some are not using zero-crossing SSR's. <S> However if you need to you can detect the mains zero crossing in your microprocessor and switch them on at the right times. <S> Some variants seem to use the Omron G3MB-202P ( http://www.mouser.com/ds/2/307/g3mb_0609-298620.pdf ) which is zero-crossing, but some product images show the G3MB-202PL which is not zero-crossing. <A> Your description of the requirements are exactly what solid-state relays (SSR) are made for. <S> They are available in a wide range of ratings from small units the size of a large capacitor (as shown in Jack Creasey's photograph) up to larger "hockey-puck" style which are quite popular for microcontroller switching of mains power up to 20-30A, and even larger ones capable of handling rather large loads. <S> There are many SSRs for sale on Ebay at all times. <S> Your circuit description is sufficiently obscure and unusual to warrant additional caution to select appropriate SSR products as it doesn't sound like your typical mains AC control situation.
Devices we call "optical couplers" or "opto-isolators" are typically low-power, logic-level devices which are NOT SUITABLE for switching mains power.
Is there a name for this kind of comparator? I have two analog signals, and I need to generate digital signal (to use as an interrupt for an MCU) when the voltages differ more than a certain amount. It's going to be some sort of comparator arrangement, but does this have a name? Window comparators are in the right kind of area, but aren't differential. <Q> does this have a name? <S> Yes, it is a window comparator even though you think it isn't. <S> Regular window comparators have one "variable" input <S> but there's nothing wrong with the "fixed" input being variable too. <S> Consider this "regular" circuit: - If the middle of the three resistors were, in fact, two resistors in series (with the new input feeding the centre-point) <S> then you get a window (magnitude) comparator. <S> Depending on precisely how you want this to work you can make the two outer resistors into a current source and a current sink and you could even use something like a TL431 across the full width of the middle resistor to define precise thresholds above and below the new reference input. <S> It's still a window comparator. <A> Usually these compare a voltage to a fixed min/max range. <S> In your case, you want to compare one voltage to a range that depends on another voltage. <S> One way to think of this is a window comparator with some additional circuitry that creates the window levels on the fly. <S> Another way is to create abs(A - B) using a diff amp and precision rectifier, then compare that result to a fixed threshold. <S> Another way, of course, is to do all this digitally. <S> If the highest bandwidth of interest is only up to a few 10s of kHz or so, then this can be done in a microcontroller. <S> You sample the two signals with A/Ds, then the rest is firmware. <A> A single chip that would be enough to do this would be a multi-opamp IC; no matter what you'd do, you'd need external components to set the threshold difference, so there's nothing you can do about that. <S> If there was the perfect component for your use case, you'd still need to components – your super-funky specialized IC and some external resistor or so to set the threshold voltage, plus a decoupling capacitor for the power supply. <S> I propose the following, naive, circuit, which does what the others recommend, and only uses five discrete components (instead of the 2 you'd need with your specialized IC): <S> simulate this circuit – <S> Schematic created using CircuitLab <S> Now, you'll say, you count four opamps, ten resistors, two diodes and 1 decoupling capacitor. <S> Let me address this later. <S> First a bit of functionality: <S> U1-A, R1–R4: <S> Classical Difference Amplifier, unity gain; output hence IN_B-IN_A <S> U1-B, R5, R6, D1, D2: classical "precision rectifier" U1-C, R7, R_adj: Comparator; voltage divider sets the threshold U1-D, R8-R10: Constant Voltage source for the virtual ground; R8--R9 sets the virtual ground / reference voltage to V_supply/2; R10 is used to load the output slightly, as to avoid undampened oscillations. <S> As said, these are actually but 5 components in total: U1-A– <S> U1-D: <S> It's absolutely common to find quad-opamps. <S> The LMC6484 is a popular rail-to-rail choice. <S> Since I assume you don't plan on adding a second supply, we'll need a virtual ground. <S> R1–R10 <S> : There's resistor arrays you can buy that just contain the same resistor multiple times in a single package. <S> Easy to pick, place and solder. <S> R_adj: at some point, you need to set the threshold voltage. <S> D1 & D2: there's three-pin dual-diode packages that have exactly one pin connected to the cathode of one, and the anode of the other internal diode C1: you don't get around decoupling your power supply. <S> In fact, you should probably add one of these to the threshold voltage point (+ of U1-C) and to the center of the R8--R9 divider, too, but it'll definitely work without <A> There is an oddball chip (LTC1042) that does exactly what you want- <S> the manufacturer in fact calls it a "window comparator". <S> It even has a ground-referenced high-Z input for the window half-width. <S> You can feed in one voltage into each input and a fixed voltage to determine the width of the comparison window, so at most 3 parts if you don't have a suitable reference voltage available. <S> It's not a high-speed device ( <S> ~100usec response time). <S> Also keep in mind that, despite being shown as an active product, the fact it has not been migrated to an SMT package probably bodes ill for availability far into the future. <S> On the plus side, it's been available for decades. <A> I don't know about a name <S> but I would think the obvious way to do this would be a differential amplifier (with an appropriately chosen bias point for single supply applications) followed by the window comparator you mention.
The closest circuit with a name is a window comparator .
Identifying Source of Periodic Artifact at Op-Amp Output My MAX44251 dual op-amp has a very small unwanted 131KHz periodic artifact at the output, seemingly regardless of how it's configured. My assumption was EMI, but I can't see this 131KHz signal on any other part of the circuit. I've also tested this in multiple buildings, with multiple probes, with all other electronics turned off, and surrounded by foil shielding. What should I try to remove it? I would like to at least achieve a voltage follower with noise under 1mV. The chip was originally used in a more complex circuit when I first noticed the problem. BUT, to isolate this issue I made a whole new test PCB with fresh components. I left extra pads to reconfigure the chip in different ways while testing. Right now it is configured very simply: simulate this circuit – Schematic created using CircuitLab The bypass caps are on the bottom ground plane layer. Vias are hand soldered. I have observed the effect through both the Agilent 10X passive probe (It's hard to see), and through a probe like the following, with which I can zoom all the way to 2mv/div. Originally, it was observed because the output is fed to a comparator, and the comparator output indicated the input signal amplitude was > the desired 2mV. The waveform is periodic but kind of strange. Here's a few pics from different angles: 200 ns Stopped 50 ns Free Running 20 ns Free running 10 ns Stopped <Q> Note that this is an autozero amplifier (also called chopper stabilized) - many very low offset opamps work by periodically sampling the input offset and injecting a compensating offset to counter drift in the front end. <S> To do this there is an oscillator in the opamp together with a set of analog switches at the input. <S> This can result in clock feedthrough to the output as well as charge injection at the input pins. <S> Presumably this device is using 131kHz as the switching frequency. <S> I can't find any detailed information on the Maxim part but here is some info for an Analog Devices part that is probably similar: <S> Analog Devices Zero drift opamp <S> If you really need the low offset and drift then they are the best type of devices to use - you may need to Just limit your bandwidth and filter out the clock. <S> The bandwidth of the auto-zeroing is enough to encompass <S> 1/f noise in CMOS opamps <S> so they can be very low noise for frequencies below 1kHz, a region where CMOS opamps tend to have problems. <S> If you can't filter out the clock noise see if you can use a conventional part - they will often have a worse drift and offset performance <S> but you can get them better than 100uV offset. <S> You may also have to trade-off input bias current because bipolar input amplifiers are usually better than CMOS for this parameter. <S> Bipolar are usually lower noise as well. <S> A related problem I have had with a similar Linear Technology part (LTC2051) is that the autozero circuitry can take a very long time to recover from overload when the output saturates - many milliseconds for a part with GBW of many MHz. <S> This makes them unsuitable for any application that saturates as a normal part of its operation such as oscillators or threshold detectors. <A> I can't really tell if this is a actually a symptom of what is described in the datasheet: <S> Notice how there's a spike that exceeds \$30 \frac{\text{nV}}{\sqrt{\text{Hz}}}\$ at 65kHz – pretty much half of the frequency <S> you're observing your noise at; they didn't characterize up to 131.5kHz, however. <S> What should I try to remove it? <S> I would like to at least achieve a voltage follower with noise under 1mV. <S> If you need signal up to 65 kHz and above: An RLC notch (band-stop) would probably work best; a quick & lazy design run on my favourite passive filter design tool <S> yielded R=0.16Ω, L=1µH, C=1.5µF as possible configuration. <S> Note that you could try to use the inverse circuit (RLC bandpass; swap the (L--C) with the R) in the feedback branch of your voltage follower. <A> I agree with Marcus, the ~130 kHz would be the second harmonic of the Chopper switching frequency <S> ~65 <S> kHz. <S> A reduced 'Closed Loop Bandwidth' of your Op Amp could result in the second harmonic (~130 kHz) to have a greater magnitude than the first harmonic (~65 kHz), to solve this, as Marcus mentioned, a solution could be adding a passive filter to filter that noise. <S> There is an article by Art Kay , " 1/f Noise and Zero-Drift Amplifiers ", that talks about noise in Zero-Drift Op Amps. <S> If you want to learn more about Op Amp Noise, check out TI Precision Labs for Noise . <A> Don't have an answer, but I can tell you, for inspiration, how I would debug this. <S> First, I would try to solder a bypass cap right to the chip. <S> An 0603 part, 100nF, and use braid to connect to the other pin (for low inductance). <S> You bypass caps are behind relatuvely high inductance vias, and this can make them ineffective for the spikes. <S> The spikes are at 131 kHz, but the frequency contents is much higher, so good bypass matters very much. <S> This would probably fail :-). <S> Then I would replace the amp:1. <S> Analog Devices makes some very low offset trimmed amps. <S> The offset is not as low as in an auto-zero amp, but check it out. <S> Those are a bit more expensive, so check against your budget and offset requirements. <S> Look at AD8615 and similar. <S> The only thing, those get a bit expensive for high-volume consumer stuff. <S> 2 <S> Also, consider a good old instrumental bipolar opamp from burr-brown lineage (Texas Instruments now.). <S> Use the same impedance at both inputs to get rid of the bias current, and make sure the input impedance is low enough that the offset current doesn't matter. <S> Something similar to opa237. <S> Try a different auto-zero amp, perhaps one with spread-spectrum clock. <S> Again, look at analog devices parts. <S> Good luck
If you just need a low-bandwidth voltage follower: Use a low-pass filter.
How to Turn the 555 Timer Output (Astable Mode) into a Decaying Square Wave? I am currently working on a 555 timer in astable mode whose output will be fed into a 0.5W, 8Ohm speaker. I want a fading effect for the sound that will be produced by the speaker. I already acquired an envelope circuit which basically produces a voltage signal decaying exponentially for about 3-5 s. How can I turn the output of the 555 timer into a square wave that is also decaying exponentially within 3-5 s? AND can we also do that by only varying the voltage supplied to the 555 timer (i.e., the voltage connected to pin 8)? Here is the envelope circuit I already acquired: Thanks in advance! <Q> What you want to do is to amplitude modulate a square wave. <S> Fortunately, this is easy to do with square waves because you can amplify them arbitrarily and then clip at a adjustable level. <S> This doesn't work with other waveshapes because the result is clipped tops and bottoms, so you end up with a square wave. <S> However, when you start with a square wave, that is fine. <S> Here is a simple circuit that exploits this effect: <S> The transistor will switch on and off according to the square wave. <S> The amplitude of the signal applied to the speaker is a function of the volume adjustment voltage, fed in at top. <S> R2 and D1 perform two functions. <S> First, they give the inductive flyback current a place to go when Q1 abruptly shuts off. <S> Without that, Q1 could get fried. <S> Second, R2 causes the current decay when Q1 is shut off to have about the same profile as the current rise when Q1 is turned on. <S> This isn't necessary to get sound out of the speaker, but will make the sound a little louder than if R2 was not there (replaced by a short). <A> To be fair, instead of your envelope circuit that decreases the output, I'd simply charge a capacitor through a resistor; that leads to a \$1-e^{-t}\$ kind of voltage over the capacitor. <S> That, in turn, I would connect to the base of an NPN transistor (possibly with a bigger base resistor not to distort the voltage curve too much) in common-emitter configuration. <S> That would attenuate the input signal with rising voltage. <S> simulate this circuit – <S> Schematic created using CircuitLab Notice that I used C2 to capacitively couple your square wave into the circuit, and <S> C3 to couple it out – that forms a high pass filter (i.e. DC can't go through), and the frequencies at which that circuit cuts off depend on the values of C2 and R5, and also on C3 – you can safely make C3 a lot bigger than 100nF. <S> Don't worry about this changing your signal – it does – because your speaker doesn't care (or like) DC, anyway. <S> So what happens here is that you first have R3/R4 forming a voltage divider – so if there was nothing else, the collector point of Q1 would be at exactly 4.5V. <S> Then you couple in your signal through C2 and R5 – this "pulls" that 4.5V up and down with the high-passed input signal. <S> The variable attenuation happens because parallel to R3, we have Q1's collector-emitter resistance. <S> When the current flowing into Q1's base (from the "capacitor's voltage" node through R2) is high, that resistance becomes low – in fact, significantly lower than R3 or R4. <S> So what our signal now sees, after "coming out" of C2 is a voltage divider formed by R5 and Q1's collector-emitter resistance. <S> The lower that gets, the smaller the ratio of output- to input voltage of that divider! <S> Because, as said, we don't want DC to flow through the speaker, we then pass the result through C3. <S> Congratulations! <S> The simplest possible voltage controlled amplifier :) <S> Note that this isn't even remotely linear in amplification. <S> But square waves don't really call for "correct" or "clean" amplification, do they? <A> I'm not a big fan of the NE555. <S> I agree it's a nice little IC to build timers, oscillators of all kinds, but in this time and age, its price is rivaled by microcontrollers, which, once you've learned how to program them, make design considerably easier. <S> When you actually need something like a sawtooth, it's nice. <S> If you need an appropriately set square wave, or easy adjustability, it's almost certainly not the way to go, in my opinion. <S> I find it easier to build digital circuitry instead analog one, and it makes it easier to be exact and power-saving – with fewer components. <S> So, I'd simply use a microcontroller with a feasibly fast PWM unit (practically all you'd buy in an actual enclosure have one), and use that with a programmatically reduced duty cycle as the envelope function – a simple low-pass filter (RC) will convert the PWM, being much faster than what the human ear could perceive, to a DC voltage. <S> Basically, a PWM-based Digital-to-Analog converter. <S> And instead of externally modulating a square wave with that DC voltage, I'd simply tell the microcontroller to set the PWM's duty cycle to 0 for when my square wave is supposed to be low, and to it's current (decaying) duty cycle when it's high. <S> With anything but the very very tiniest microcontrollers you get another timer module that can generate interrupts at fixed intervals, making programming this very easy.
You could use the output of your envelope generator to drive the base of a transistor which amplifies the square wave signal.
Is it possible to extend LVDS and SPI to 3 meter distance In a hardware design application, we need to extend below signals to 3-meter cable. LVDS data @ 720Mbps Clock: 72Mhz SPI signals So, I wanted to know Is it possible to extend above signal to 3-meter distance via cable? What are the pros and cons of extending cable to 3 meter? If yes can please suggest some cable. Thank you!! <Q> If the SPI data is in one direction only then <S> yes, it can be done. <S> The problem with bi-directional SPI is that reading SPI data back from a slave (remote device) requires that the clock doesn't get too much shifted or the data returned becomes unreadable. <S> At a master clock of 72 MHz, the period is only 13.9 ns and if the overall delay from sender to receiver back to sender approaches anything like half this time then the sender (master clock generator) is unable to adequately read the data returned due to the accumulated delays. <S> So, given that signals will propagate at about 5 ns per metre (light is 3.333 ns per metre), bidirectional SPI at a clock rate of 72 MHz will start to be unreadable at just over 1 metre. <S> However, if the data is "send only" then providing the SPI clock and data is driven down <S> two coax cables correctly\$^1\$ and line receivers are used at the slave-end then the distance that can be achieved is limited only by the cable quality. <S> Hundreds of metres can be achieved with good coax. <S> LVDS data @ <S> 720Mbps <S> This can be done providing you embed the clock with the data either by Manchester encoding or scrambling techniques - I've transmitted data (using proper line drivers and terminators) over 50 metres without too much hassle at this sort of speed <S> but, it's down to using good coax (75 ohm 11 mm or greater OD) or good twisted pair cable. <S> \$^1\$ By "correctly" I mean using proper coax drivers with line terminators or maybe even using balanced line drivers and screened twisted pair (plus terminators). <A> You may want to tunnel those signals through something more robust and more isolated than LVDS and single-ended SPI for such a long run. <S> At 3 meter run the crosstalk can be fairly significant, and inductively coupled high voltage spikes are often real concerns. <S> You will have to leave the clock out and generate a separate clock on the receiving end of the cable. <S> SPI traffic can be tunneled using a TCP connection. <S> As of the LVDS, depend on your signal type, you may be able to send a compressed form of it (if it is a video feed) to save bandwidth. <A> I wanted to put this as a comment, but I don't have the reputation! <S> HDMI cable would be my first choice if I had it lying around. <S> Ethernet cable would also be a decent second choice. <S> If the data is uni-directional, the most important job you have is very careful impedance matching of all the components, to minimize the signal distortion!
A cheap solution would be tunneling those signal through Ethernet, using a SBC that is capable of handling that data rate.
What is a more effective shield for magnetic fields between 300 and 500kHz Solid copper or copper mesh? I am working on a PCB that is very crowded, and has high gain amplifiers working between 300kHz and 500kHz Typically I would use Mu metal or similar for shielding at this frequency, but obviously nobody makes Mu metal PCBs. So I have a choice of solid or hatched pours. External shields are not an option. I don't have any controlled impedance tracks. My only worry is the high frequency AC magnetic fields. We use copper mesh shielding in our RF cages, which works rather better than I expected. I suspect this is due to the shorted turns. I asked a couple of shielding companies, but they don't characterize their meshes for this sort of application. Can someone point me to data that would indicate whether solid or meshed copper pours would perform better in this situation? <Q> My only worry is the high frequency AC magnetic fields <S> It's really all about a thing called skin depth: - <S> Graph taken from this wiki page <S> So, for example, at 100 kHz, copper has a skin depth of about 0.2 mm and this means a 1mm thick screen forms a fairly effective shield against magnetic fields leaking out or leaking in. <S> 2 <S> oz copper is about 0.07mm thick <S> so maybe you will get a little attenuation. <S> At 300 kHz it's in that borderline area where you might get a reduction of a couple of dB <S> but if you are expecting a few tens of dB <S> then it's very unlikely. <S> At 500 kHz (where the skin depth is about 0.09 dB) <S> you might see a 5 dB reduction. <S> Having said that, every dB counts so it might just be enough. <A> Solid would perform better, all other things being equal, but perhaps not significantly better. <S> Since the 'holes' in your mesh will be a tiny fraction of a wavelength, the mesh should behave similarly to a thinner (higher resistivity) solid copper layer when measured from a relatively large distance away compared to the 'holes'. <S> The 'shorted turns' you mention are just eddy currents which will occur in either case. <A> Depends on whether you have repetitive sinusoids, or repetitive pulses with fast edges. <S> For sinusoids, we are trained in the limitations of SkinDepth. <S> But fast-edges is the reality for embedded systems; lacking theory, I take measurements of square-waves coupling THROUGH foil, and find 50dB attenuation with 150nanosecond delay....through the foil. <S> Here are solutions for standard sinusoidal interferers. <S> With poor control over the magnetic fields, you can reduce the victim's loop areas. <S> Thus opamps with the least possible height above the PCB are best choices. <S> No DIPs allowed. <S> And run GND under the packages, to be right under the piece of metal to which the silicon die is attached. <S> For those Resistors and Capacitors, surround them with GNDed chunks of copper, to have Eddy Currents develop <S> (are your interferers repetitive or transients?) <S> and thus partially cancel. <S> And have GND pours right under the Rs and Cs, to minimize the loop area; you need to tie the pours very close by to the upper GND, again to minimize the loop areas. <S> With repetitive magnetic interferers, with partial transmission (Skin Depth not doing much good) you will also get partial REFLECTION. <S> Multiple planes under critical opamps/ <S> Rs/Cs will implement multiple magnetic reflections, and provide better shielding of fields approaching from behind the opamps. <S> With your frequency-of-interest being nearly 1MHz, the Opamp PSRR will be poor. <S> Thus large capacitors on the VDD+/VDD- pins, with 10_ohm resistors to the central bulk supply are useful. <S> The central power will experience lots of magnetic-field noise, and you want to use LPFs to greatly reduce that repetive noise. <S> 10uF and 10 ohms is 100uS tau, or 1.6KHz F3db, <S> a 50dB reduce in 500KHz trash.
I don't think that (even) 2 oz copper on a PCB is going to be that good whether solid or hatched.
Why don't ceramic capacitors have codes for voltage rating? Say a ceramic capacitor with the code 103 (0.01 micro farad). How to identify its voltage rating? Searching for a 0.01 micro farad capacitor in Mouser the voltage rating is indicated as 1kV dc. I intend to use the capacitor in a RF receiver circuit((20Mhz) where the maximum voltage is 12 V. Is it ok to use such a high voltage rated capacitor in my circuit? Also if I don't have a capacitor of a particular value,will resolving the value into series or parallel combinations affect the quality of the receiver? <Q> Most small ceramic capacitors are rated for 50V or 100V which is high enough above typical modern solid-state circuit voltages that the capacitor voltage is not of great importance. <S> Unless you are working with higher voltage circuits. <A> Looking up 'something of the same value' in a catalogue is not the ideal way to do things. <S> It it's not marked, then keep it in labelled packet after you've bought it. <S> With 'low' values, like your 10nF for instance, if it's fairly large, a few mm long or so, then you can assume it's a low K ceramic, and like Richard says, is probably rated for 50v or more. <S> Unfortunately with higher values, and smaller case sizes, high K ceramics are used, to cram all the micro Farads into the tiny volume. <S> Here you will find voltage ratings of 3v, 5v etc. <S> One very interesting trait that you get for free with high K ceramics is a vicious voltage coefficient of capacitance. <S> You can easily end up with half, yes 50%, of your specified capacitance if you use a high K at its rated voltage, which doesn't go down well with LDOs that might need a minimum C to stabilise them. <S> Ask the manufacturer for a data sheet specific to the range, value, voltage, dielectric and case size of the part you are considering, as all of these can affect the voltco. <S> The distributor shortform datasheet is usually not sufficient. <S> Building up exact values with series or parallel combinations of ceramics caps is generally OK. <S> The problems you can run into are due to the residual inductance of either their length or the extra wire you use, causing resonances with the other capacitors. <S> For instance, one common problem is caused by paralleling a 100nF and a 1nF (a much touted combination for decoupling). <S> Unfortunately, the 100nF goes inductive at a frequecy where 1nF is still a good cap, and they go parallel resonant, high impedance, usually in the 100s of MHz. <A> How to identify its voltage rating? <S> If you don't know what the part is (i.e. the part number from a supplier) <S> then you cannot rely on anything about it other than what is printed on the component <S> and, if this doesn't contain a voltage rating then, the part becomes junk.
Like other components, ceramic capacitors have a voltage rating.
How is the input not floating when there is a pull-down resistor? I am wondering why the input to D2 will not be floating when the switch is open. If the switch is open, wouldn't it act like a mini antenna and provide a random input to the D2 pin? <Q> I guess you are getting the doubt because of confusion that the moving part of the switch is opened and this is making you think that it is floating <S> and so D2 must also be floating. <S> No no no. <S> The moving part of the switch and so D2 are at zero volts. <S> D2 is input. <S> And GND is zero volts. <S> There is no current through R1. <S> So no potential difference across R1. <S> So the voltage at D2 is also zero when the switch is opened. <S> In other words, Voltage at D2 = <S> Voltage across R1 + <S> GND voltage = <S> 0 <S> + 0 = 0 Volts. <A> The term "floating" refers to an input or tristated output that has nothing at all connected to it, so any tiny current can cause it to take on pretty much any voltage within limits. <S> The input is solidly connected to +5 V when the switch is closed. <S> If the value of R1 is appropriate for the situation there will be no problem. <S> Note that some situations (long wires, noisy environment) may call for R1 to be quite low or for additional filtering (hardware or firmware). <S> Say it takes 1.8 V for the input to be recognized as a 1 when it should be zero. <S> Then a current of less than 1.8 V/R1 will not cause problems. <S> So if R1 is 4.7 kΩ, it can deal with 380 µA of current, which is quite a lot. <S> If R1 is 1 MΩ then 1.8 µA could cause the input to be interpreted incorrectly. <S> As well as making it noise sensitive, it's possible that leakage on the PCB or out of the chip could contribute some or all of that current. <S> So why not make R1 100 ohms or something like that, you may ask. <S> It wastes power when the switch is closed if you make the value unnecessarily low. <S> Usually pull-up resistors of a few kΩ to 10 kΩ are okay in most situations, but if battery power is used you may want to consider 50 kΩ or 100 kΩ. <S> In extreme situations, perhaps with a bit of filtering, 10 MΩ may even be acceptable. <S> For example, if you want long life in a permanently-on circuit running from a lithium button cell. <A> If you push on the gate, it'll open. <S> The spring is weak enough that you don't even have to push very hard to open it. <S> It'll then stay closed until something actually pushed on the gate again. <S> A pull-up or pull-down acts like that spring. <S> You want a large enough resistor that a pin can "push" it to the opposite value easily-- <S> but as soon as it quits driving (pushing) <S> a value, the resistor ("spring") will pull it back to the value you've chosen, and it'll stay there until something drives it to the other value again. <S> It won't just sit half-open, swinging in the breeze, so to speak. <A> As always in engineering (as opposed to more theoretical fields like physics and theology ;)), it depends. <S> Any input will have a certain leakage current. <S> So, there is a tradeoff between resistor value - smaller is better in terms of fixing the open condition low, while bigger is better in terms of minimizing power dissipation, as Spehro has pointed out. <S> Which is more important depends entirely on your situation and values. <S> And, yes, the loop formed by the wires and resistor can act as an antenna. <S> For large resistors or long wires, and high-impedance inputs, pickup on external wires can be a problem. <S> You need to look up the subject of electrical shielding. <S> In fact, back many moons ago I worked on a system which had a switch with an incandescent bulb in it. <S> Since both the switch and bulb were in the same unit, their wiring was tightly bundled together. <S> The switch input picked up the current spike associated with the bulb turn-on and thought the signal meant that the switch had been pushed again, so it then turned itself off. <A> Because D2 is connected to ground, and the input you receive is the reference voltage. <S> If it's connection to ground was interrupted, then you would have an antenna.
Multiply this current by a sufficiently large resistor value and the input voltage becomes large enough to be detected as a specific value which may cause problems. Pushing the button would turn on a function, and this function turned on the indicator bulb. One way to evaluate this is to imagine a current being injected into the input. When it is open it is connected to 0 V through R1. Nonetheless, it's strong enough that as soon as you quit pushing on the gate, it'll swing closed again. A pull-down (or pull-up) is a little like a spring on a (physical) gate. This is not how it was supposed to work.
Interfacing dual supply op-amp with microcontroller I have an dual op-amp amplifier circuit (LM833) to amplify a signal with a +-10V dual-supply rail from a 22V supply with a resistor voltage divider. The output is rectified into a 0-8V output, for which I simply require a logic output above a certain threshold (about 3V). The problem is that the Arduino micro is powered from the same 22V supply through a switching regulator. So the ground references of the op-amp output and Arduino are at different potentials, therefore I cannot use a simple MOSFET to interface between the two circuits.Is there another way to safely connect the circuits without using a relay which would be too big and potentially too slow for the switching application. simulate this circuit – Schematic created using CircuitLab This is a simplified schematic showing my main problem, since the arduino ground is with reference to the -10V point of the opamp. <Q> as the mcu is really referenced to the negative rail, the output of the opamp has a DC bias (vs. the mcu's ground). <S> So just treat all measurement as such and you will be fine. <A> Instead of your makeshift voltage divider, which suffers from problems when you inject current into ground, go with a real rail splitter, like the TLE2426 . <S> They run less then $2USD in DIP packages. <S> Then, use that ground for all your circuits. <A> You could set up the Arduino's switching regulator to use the same virtual ground that you are using for the op amp. <S> That way the ground reference for both the amplifier and arduino circuit will be the same, and you could get away with a smaller regulator,because you'll be regulating only 11V to 5V <S> rather than 22V. simulate this circuit – <S> Schematic created using CircuitLab <A> Calculate the RX and R8 such that the Minimum of your OpAmp matches the Min linear input of the Arduino, and you are in the game. <S> R3 and R6 could also be tweaked for further match. <S> The short answer is low power Zener and resistor. <S> Provide more parameters like input impedance of your Arduino circuit <S> and we can certainly calculate the Zener and Resistor appropriately. <S> Hope this help.
Simply add a 10V Zener diode and a properly valued resistor RX in series between D1 and C1 so that the Max output of your OpAmp matches the Arduino Max linear range input.
In solving an op amp problem with two voltage sources, why can't we combine it? Say we have a circuit like Why can't we solve by doing $$V_{out} = -(V_{in} - V_{offset}) * (R_f / R)$$ We know that \$V_{out}\$ for a typical inverting amp (that doesn't have \$V_{offset}\$) is just \$-(V_{in}) * (R_f / R)\$, so why is \$-(V_{in} - V_{offset}) * (R_f / R)\$ for this diagram not correct? My reasoning for \$-(V_{in} - V_{offset}) * (R_f / R)\$ is because we know \$V_{offset}\$ is the constant voltage for the positive side of the op-amp. \$V_{in}\$ decreases until it reaches \$V_{offset}\$. Thus, can't we just think of it equivalently as \$-(V_{in} - V_{offset}) * (R_f / R)\$? <Q> Do a 'sanity check' on your proposal. <S> Set Vin = 0. <S> We know that Vout will be \$V_{OUT} = <S> + <S> V_{OFFSET}(1+\frac{R_F}{R})\$, which is not equal to what your equation yields: \$V_{OUT} = <S> +V_{OFFSET}(\frac{R_F}{R})\$, so no you cannot. <S> The gain from the non-inverting input (Voffset) is higher than the magnitude of the gain from Vin. <S> If you want to subtract two voltages and have equal gain from each input what you do is add a voltage divider to the non-inverting input that is of the same ratio as the feedback network (R/Rf) and that reduces the overall gain from that input to Rf/R. <S> However if that voltage is fixed, you can save two resistors by simply adjusting the value of Voffset lower by that factor. <A> Why don't you just try a couple of simple examples and see if they are self-consistent to see that it is wrong. <S> For example \$R = R_f, V_{in} = <S> 1V, V_{offset} = <S> 1V\$ <S> so that $$-(V_{in} - V_{offset}) <S> * (R_f / R) = <S> 0$$This <S> result would indicate that the output is zero meaning that the inverting input must be at 0.5V since R and Rf are equal. <S> The non-inverting input however is at 1V as defined by the problem. <S> This 0.5V differential input is amplified by the gain of the opamp to give positive saturation. <S> This is not consistent with the problem statement so the calculation must be wrong. <S> If you add \$V_{offset}\$ to the result it would be correct. <S> One way of thinking about it that it would be the same as if the ground was elevated by \$V_{offset}\$. $$-(V_{in} - V_{offset}) <S> * (R_f / R) + V_{offset} = <S> 1$$ <S> By simple observation the inverting input would be at 1V, the non-inverting input is also at 1V and the output is at 1V. <S> This is self-consistent. <A> Perhaps you were thinking that both voltage sources are in series: <S> Vin-GND-Voff. <S> If this were true, you would be right! <S> However, they are not in series because there is another element connected to GND: <S> The source that models the OpAmp output has also one terminal connected to GND. <S> Drawing the OpAmp symbol with one leg to GND (or showing the power connections explicitly) explicitly shows where the output current comes from and avoids making false assumptions. <A> Here is the general procedure for N voltage sources: <S> Short all of the voltage sources except for one. <S> Find the output voltage and call it Vo 1 . <S> Iterate through the voltage sources, shorting each voltages source, and solving for the output voltages <S> Vo <S> 1 through Vo N . <S> The total output voltage of the original circuit is the sum of each solved output:$$V_{out} = \sum_{i=1}^n <S> Vo_i$$ @SpehroPefhany 's answer is the shorthand way to say all this, which is that each input has its own gain.
There is a way to combine the solutions for the the two voltage sources using the Superposition Principle , which works for ideal opamp problems because they are Linear Systems .
Can SS pin be tied low if only one SPI device is used? I read online that to start an SPI transaction to an SPI supported device, the SS (slave select, aka chip select) line must be set to low for the entire transaction then be brought high at the end to end transaction. If I make a circuit containing only one SPI device, will I need to lower the SS line send command then raise ss line everytime or can I tie the ss line low and send unlimited commands? The device I am using is ISD1700 sound chip . <Q> [ @Kevin and @akohlsmith should post their comments as answers. <S> This is to expand on their comments. ] <S> SPI 1 doesn't prescribe the exact behavior of the SS (slave select line 2 ). <S> This behavior is dependent on the implementation of each individual device. <S> I have seen devices that can operate with the SS permanently aserted. <S> I have also seen devices that require falling and rising edges on the SS. <S> Although it doesn't say that explicitly that the SS must be toggled, the design guide (p.31) says that SS starts and ends the SPI transaction. <S> It would be prudent to assume that SS has to be toggled for the SPI transaction to come through. <S> 1 <S> SPI is more of a custom, rather than a standard. <S> 2 CS (chip select) is another name for slave select. <A> If the protocol for the slave device includes some kind of framing, whether that's with fixed-length packets, start/stop bytes or a header which specifies the packet length, then the slave device may be able to operate without a chip select. <S> I have a SPI flash memory chip in the board <S> I'm currently working on which appears to be perfectly happy with or without the chip select. <S> It can be permanently wired to 0V (enabled) with no problems. <S> This actually caused us some problems, because a contractor had set up some of the low-level I/O including the SPI, and we (and they!) didn't realise they'd not got the chip select working. <S> It wasn't until I had to extend their SPI work to add another SPI device on the same bus that I found we didn't actually have chip selects! <S> Conversely, many slave devices do need chip selects to frame the data, and sending more bits/bytes than the expected packet without releasing the chip <S> select at the end will be seen as an invalid transfer and rejected. <S> DACs will often load the new value onto the output on the chip select rising-edge. <S> ADCs similarly will often use the SPI transfer to start (and sometimes time) <S> the conversion, so they need the chip select falling-edge as their trigger. <S> Your datasheet doesn't actually say anything about how to drive your particular chip over SPI, and I'm not motivated enough to google it. <S> Exercise left for reader... <S> ;) <A> Without knowing anything specific about the SPI slave device, no, you can't just tie SS low. <S> Many devices use the leading edge of SS to reset their internal logic to the start of a new transaction. <S> For example, memories might interpret the first two bytes as address, then subsequent bytes as data. <S> Some memories don't perform the physical write until SS is de-asserted. <S> However, it won't work with most devices out there.
For some devices with the right protocol, you might be able to get away with it. It entirely depends on the slave device.
How can cold temperature (refrigerator, air con) fix a broken electronic device? I had an air con remote control that wasn't working at all. But at some point I noticed that when I turn on the air con manually and the room gets cooler, the remote control works as expected. I thought it can be caused by moisture inside the device and probably something happens with it when it is cold. I tried different batteries and it didn't change anything - the remote was operational only when it was cooler than 29 C (I live in a humid tropical country). I ended up keeping the remote in the fridge without understanding the real reason of the issue. Now several years passed and my Xiaomi Mi Band 2 stopped working. After a lot of searching I found out that many people had the same problem and putting the device in the fridge fixes it. I tried it and amazingly, it worked! What can be a reason of this behavior? Temperature, humidity or batteries? <Q> When the unit is cooled, thermal contraction makes the dodgy connection. <A> Design flaws leading to components getting too hot and thus working in critical condition could as well be a valid reason as I see it. <A> Did you repeat the test with the fridge several times? <S> What happens after some hours after you took the remote control out of the fridge, it works for some hours and then fails again repeatedly? <S> The possible design flaw was not detected in pre production tests because all tests were done at temperatures well below 29 °C. <S> I would suspect a design flaw inside one of the chips used in the circuit. <S> It is unlikely that any passive component is causing this problem.
Could be thermal expansion causing a poor connection to fail. If many other people had the same problem, it is possible that there is a common design flaw.
Does the PID Controller (LOVE 16C-3) Need an External SSR? My PID controller LOVE 16C-3 has a output of "relay". Do I connect the output of the PID controller to the inputs of an external SSR? Or is the relay already built in into the PID controller? <Q> It appears from the manual that the output is an SPST relay contact, but the rating of the contact is not stated. <A> The controller data sheet indicates that there are three outputs. <S> A voltage mode output, a current mode output and an on/off relay output via a SPST relay. <A> The relay output is SPST <S> rated at 5A: <S> You cannot use this output to directly control a typical DC-input SSR without an external DC power supply of some type. <S> It's just a normally-open contact. <S> You should not switch anything like 5A with it either, unless you want it to last a very short time. <S> Typically life at full rated current is only perhaps 100,000 operations, which might be weeks or months 24/7. <S> They should repeat the datasheet specs within the manual, but I imagine this is just some rebranded no-name Asian product anyway. <S> I doubt Love makes this kind of control these days (they did, many years ago).
I suggest you contact the manufacturer to cxonfirm the relay contact specifications, and to obtain output wiring recommendations..
3.3V/5V Linear Regulator Voltage to Ground Jumper I received this 3.3V or 5V power supply. It's neat because it fits on my breadboard and can provide two separate voltages (chosen using jumpers) on it's two outputs. I originally thought that this was a Step-Down Converter , however, it's been pointed out to be a Linear Regulator . Here, I have the left-hand side providing 5V, while the right-hand side provides 3.3V. I've used my multimeter to verify it working from a 9V battery. I am curious what the jumpers in the middle of the board will do. There are two 5V->GND, and two 3.3V->GND. I've made attempts to find information about this specific device, but I haven't found any identifying information, nor have I found any information about it online. I'm afraid to use this for longer than looking at the voltage on either side because I am unsure the purpose of these jumpers, or if/when they should be bridged for safe/normal operation. Any help identifying and understanding the purpose of these jumpers in the middle of this device would be greatly appreciated. <Q> The 4x2 header in the middle is there for you to access the voltage rails and Ground with female jumper wire or test clips or whatever. <S> It's for your convenience. <S> And no, that board does not function as a step up regulator. <S> It's not even a step down switching regulator. <S> It is just two linear regulators. <A> You have already got your answer but <S> if incase you wish to find about the linear voltage regulator, I guess you have LM1117 for 3.3V that is variable with respect to the register value you use and <S> other one isn't visible to me , most probably it would 7805 or equivalent for 5V. <A> The jumpers left and right allow you to configure the individual regulators. <S> Think of it as enable for +5 and +3.3. <S> When used as shown on a breadboard, the outer (bottom left and right, underneath) pins supply power to your breadboard power rails.
The block of pins (left of center) are output pins so you can put wires and take the supplies to other locations. It will NOT provide boost under any circumstances. The board you show is a simple 2 voltage linear regulator for a breadboard.
Intel CPU and Surface Mounted Capacitors (located directly on top) I would like to know what is the purpose of the surface mounted capacitors found directly on the top of a CPU such as the Intel i3 2120 or the one depicted in the photo ? Does this type capacitor directly feed the internal circuitry of the CPU with a charge ? Directly to a specific layer on die of this Intel CPU ? If yes does a SMC and its charge ie voltage somehow follow a trace directly to a location a particular layer on die ? <Q> These are the regular power bypass capacitors. <S> The distance from the die to bottom pads is substantial, so the inductance of nets is substantial too. <S> The CPU has multitude of rails with dynamically changing power consumption. <S> If the caps are placed only on mainboard, plastic substrate lead/plane inductance will not be able to supply changing current, and voltage will drop killing CPU functionality. <S> That's why the caps are placed as close as possible to the die. <A> What you call the "CPU" is actually a WLCSP package (the tiny rectangle in the middle, and the actual CPU die) on top of a small PCB carrier. <S> The carrier "converts" the WLCSP package to a PGA, BGA, or LGA package and also provides a small amount of area that can be used for components that wouldn't fit in or be appropriate in WLCSP such as decoupling capacitors and options jumpers. <A> These are decoupling capacitors. <S> Their purpose is to "smooth" the supply voltage, which cannot respond immediately to fast current demands. <S> The aim of each capacitor is not to feed a particular layer on the die, but to feed the whole chip. <S> Each cap is, however, often located as close as possible to a supply pin of the chip. <S> Because if located too far away, they loose their effectiveness due to the resistance of the track from the capacitor to the chip. <S> Which is why they put them directly on the small CPU integrated PCB. <A> Larger processors and microcontrollers <S> (ie with more internal circuits) always have multiple power and ground pins simply to decouple all of those circuits. <A> They are bypass capacitors and since the substrate for the cpu has circuit via's (it's like a miniature multi-layer PCB) <S> they are used to reduce power supply impedance to portions of the die. <S> They are typically solid electrolyte or ceramic capacitors. <S> This might help you: https://labs.wsu.edu/advancedmanufacturing/wp-content/uploads/sites/238/2014/10/Embedded-Capacitors-in-the-Next-Generation-Processor.pdf
They're probably decoupling capacitors serving the same purpose as decoupling caps placed between power and ground pins near any digital IC (or analog for that matter.) The caps are there to eliminate/reduce current starvation on spikes of consumption.
TDA7297 amplifier board gives no sound I have a small, simple circuit here. It doesn't work - both outputs (left and right side) are mute. It uses the TDA7297 chip, and outputs 2 x 15W. I've wired 12V to '12V', and GND to -12V. I'm beginning to think that's the problem. Speakers need negative voltages as well... I've got a few LM337s laying around, should one of these be used to provide -12V? If you need additional info, tell me. <Q> The TDA7297 is specified for a single supply, up to 18V. <S> So, it seems your mistake was connecting GND to -12V. <S> It should be connected to ground - that is, the return of your +12V supply. <S> Because this chip drives the output in a bridge configuration, the differential output signal can go positive and negative with only a positive supply. <S> You'll want to swap it out before trying again. <A> Are you putting both ST-BY and MUTE to a logic high as described in the data sheet? <S> The TDA7297 won't give any output unless you do: <S> You can just tie them high with a couple of resistors if you don't want to control them: <A> Thanks for the info - the chip was bad. <S> Used a TDA7296 ( http://www.st.com/content/ccc/resource/technical/document/datasheet/3a/2f/b7/86/30/b2/4b/6c/CD00000198.pdf/files/CD00000198.pdf/jcr:content/translations/en.CD00000198.pdf ) to replace it. <S> It seems to work fine for the moment. <S> All the answers and comments were appreciated.
It's likely that you damaged the chip by supplying it with 24V when the specified absmax is 20V.
Do I need buffers prior to a comparator? I have the following circuit which generates digital noise... The reason for the 2 diodes has to do with stochastic uniformity of the noise output and I don't really want address this aspect. The comparator is like a LM311 with a <500ns propogation delay. Some other supporting bits have been ommited for clarity. The noise coming off the Zeners is around 1Vp-p when measured 10,000 times. I intend to have a 8 sets of this circuit so I am interested in reducing the component count and not having a huge circuit board. I have bread boarded this, and it seems to work. I have measured the noise signal running at up to 8MHz bandwidth. In reality, I would be expecting to read the noise signal at around 2Mhz. My question is, should I have (op-amp) buffers on the inputs to the comparator given the presence of the 200K resistors? What would best practice recommend? <Q> Typical noise from a 24V zener at optimum current (much higher than you are running them at) is less than 200mV RMS (maybe 1 or 1.5 volts p-p). <S> A 24V zener might have 5% tolerance, meaning that your two zeners may be mismatched by +/-2.4V, meaning no signal at all. <S> If you're depending on this being truly random you will want to make sure the PSD is fairly flat. <A> The reason for the 2 diodes has to do with statocastic uniformity of the noise output <S> and I don't really want address this aspect. <S> Well, but they impact the discussion severely, so they need to be discussed. <S> The simple answer is that you do need a "buffer" circuit (actually, a level shifter) on one of the inputs. <S> As has been mentioned, for ideal results the two zeners must be perfectly matched. <S> I assume you have done such matching for your test circuit, or else you just got lucky using two zeners which came from the same wafer. <S> Matching 8 pairs is going to take a good deal more work, not to mention a certain level of wastage due to discarding the ones you can't match. <S> Plus, of course, there is no guarantee that the two will track with temperature. <S> More importantly, you seem to want very good noise statistics, what you seem to call stochastic uniformity. <S> I assume you want uniform distribution (equal numbers of 1's and 0's). <S> You need to be aware that any difference in mean zener levels will degrade this, and waving your hands and invoking 0.1 volt matching will do nothing to change the matter. <S> Of course, you can always compensate by taking your samples in pairs and looking for bit differences, but in that case why worry about uniformity? <S> I also suggest you revisit <S> the data sheet and look at figures 3 and 4 on page 7. <S> Response times for a 311 are typically under 200 nsec. <A> Check out the Miller Input Capacity of your comparator pins, right around 0V differential input. <S> Some comparators have cascaded inputs (AM685) as do some opamps (UA715). <S> The LM111 NPN diff pair has no cascodes, thus there is lots of Cmiller, but that CMiller is driven from PNP emitter followers with tiny pullup currents. <S> The Cmiller may be enough to cause a "hesitation", a halt to slewing, and a disruption of the needed independence of samples.
You could consider replacing one of the zeners with an RC low-pass filter connected to the remaining zener so that it settles near the average voltage.
Wires of Different gauge in primary winding? Would 2 different wire sizes work in a primary winding (single phase transformer) for example 50 turns of 16awg- 100 turns of 22awg- 50 turns of 16awg? All connected End to end sharing the same ac input. In theory (my theory) is it would leave more space for secondary winding and help with heat losses. <Q> Usual practice for a single (not tapped) winding is to use the largest single gauge that will fit nicely. <S> In this case, very roughly without getting into differing circumferences or packing ratios, the primary copper losses of the suggested arrangement would be 20% worse than just using common AWG20 wire, or 50% worse than using less common AWG 19 wire. <S> You can easily do this calculation from the cross-sectional areas and resistances in the above-linked table. <S> If the winding was tapped, and could optionally accept a lower voltage at a higher current then the optimal transformer might have heavier wire for part of the winding. <A> One increment in wire gauge is (approximately) a 20% decrease in cross-section area, and a 25% increase in (dc) resistance. <S> I'm making some simplifying assumptions here, like the lengths and packing factors of the #16 and <S> #22 portions are the same, skin effect and coating thickness are negligible, and so on <S> In your example, you have 100 turns of #22 wire in series with 100 turns of #16 for a total of 200 turns. <S> #16 wire is 1.95 times the diameter of #22, so it takes up 79% of the winding cross-section area. <S> The resistance of the #22 portion is 3.8 times the resistance of the #16 portion, so if the resistance of 100 turns of #16 is R , then the total resistance of the dual-gauge winding is 4.8 R . <S> For comparison, #18 wire has an area 64% of #16 wire, so 200 turns of #18 would have about the same winding cross-section as 100 turns of #16 plus 100 turns of #22. <S> Its resistance would be 1.56 R for 100 turns, or 3.12 R for 200 turns. <S> So using #18 for the entire winding would have 35% lower resistance. <A> The maximum current you can put through the primary will be governed by the smallest diameter wire.
The sections with larger wire will consume more space than if wound with the same gauge.
Why can I use P = I²R but not P=V²/R when calculating energy lost in a circuit? I am working through a book of problems and am confused by the answer to this one: A 12 V battery supplies 60 A for 2 seconds. The total resistance of the wires in the circuit is 0.01 Ohm. Q1. What is the total power supplied? Q2. What is the energy lost as heat in the wires? A1: Total power output = 12 * 60 * 2 = 1440 Joules. All good so far. A2: This is the answer in the book: P = I²R * t = 3600 * 0.01 * 2 = 72 Joules That's fine with me. However, if I use the equivalent equation P=V²/R ... P = V²/ R * t = 12² / 0.01 * 2 = 28,800 Joules Both of these equations are for P, so how are they giving me different answers? <Q> The problem assumes you understand something that is not clearly spelled out: the wires and the (unknown) load are in series . <S> Therefore they share the current, not the voltage of the battery. <S> That's the situation: <S> simulate this circuit – <S> Schematic created using CircuitLab <S> As other have pointed out, the voltage drop across the wires is small given their small resistance. <S> What you know is that the same current flows both in the load and in the wires, <S> hence that's the information you must use to calculate power lost in the wiring. <A> 60A through a 0.01ohm resistance gives a 600mV drop. <S> That is the voltage you need to use in the equation. <A> This is the answer in the book: P = <S> I²R <S> * t = 3600 <S> * 0.01 <S> * 2 = 72 <S> Joules <S> You need to get a better book then because that is plainly wrong. <S> Power does equal I²R <S> but it doesn't equal I²R <S> * t. Energy = <S> I²R <S> * <S> t. <S> What is the total power supplied? <S> The total load resistance (including wires) is 12V/60A = 0.2 ohms <S> so the total power supplied is 144/0.2 <S> = 720 watts <S> What is the energy lost as heat in the wires? <S> Power lost in the wires is 60² * 0.01 = 36 watts so energy delivered is <S> this number multiplied by time (2 seconds) = 72 joules. <S> Why can I use P = I²R but not <S> P= <S> V²/R <S> when calculating energy lost in a circuit? <S> Using ohms law, I = <S> V/R therefore, I²R becomes (V/R)²R which becomes V²/R. Just make sure that the voltage you are talking about is across a resistor that has the current I flowing. <S> Anything else is likely to be wrong or possibly "correct" by coincidence. <A> If 12 V supplies 60 A, by Ohm's law the total resistance in the circuit must be \$\frac{12~V}{60~A} = 0.2~\Omega\$. <S> Assuming the load resistor is in series with the wire, that means that the load resistor has a resistance of \$0.2 - 0.01 <S> = 0.19~\Omega\$. <S> So, from Ohm's Law, the voltage drop across the load is <S> \$0.19 \cdot <S> 60 = 11.4~V\$ and the voltage drop across the wire is \$0.01 \cdot <S> 60 = 0.6~V\$. <S> This is the voltage that must be used with the wire resistance: <S> \$\frac{0.6 <S> ^ <S> 2}{0.01} <S> \cdot 2 <S> = 72~J\$. <A> Power is energy per unit time. <S> Energy is measured in joules, power in watts (joules/second). <S> The power lost in the wires is I^2*R. <S> Your energy calculation would be correct if the load of 190m\$\Omega\$ (12V/60A - 0.01\$\Omega\$) was replaced by a short circuit with just the wiring present. <S> The current would be enormous (1200A) if the battery really held to 12V, and the wires would thus be dissipating 14.4kW and would quickly burn up. <S> Not sure why you used 48V for the voltage though. <S> In the given case 95% of the energy makes it to the load, and 5% is lost in the wiring. <S> The total power for the two seconds is 720W and 36W is lost in the wiring, leaving 684W for the load. <S> In the two seconds, 72 joules heats the wiring. <A> First of all, You need to understand that all the power supplied by the battery is not equal to the power consumed by the wire. <S> There will be losses within the battery itself. <S> for finding out power supplied by the battery we use the formula, <S> P = V*I; <S> where V is the voltage across its terminal <S> and I is current flowing out positive terminal. <S> For finding out power consumed by the resistance of wire.we prefer, P = I^2*R; where I is the current flowing through the wire/resistance and R is the resistance offered by the wire. <S> We cannot use V^2/R because we are not sure about voltage across the resistance. <S> There will always be resistance connected in series to any voltage source, which is resistance offered by the source itself. <S> Voltage gets divided between internally offered resistance and a connected load. <S> But current flowing through them is always same. <S> It is accurate to go with I square <S> * R formula for finding out power consumed by resistance.
The misunderstanding in your original logic is that the wire resistance isn't the only resistance in the circuit.
Boost 12V to 24V, high current output There are a lot of dc-dc boost modules that step 12V to 24V but are limited to low current. Is there a reason why stepping up voltage, while keeping the current high is not available? In my case, I have a solenoid that works at 24V. I have a 12V 24Ah battery and the solenoid requires 24V, ~25A. Is there a solution to boost my supply? <Q> Do you need MOMENTARY activation of the solenoid? <S> Or CONTINUOUS activation? <S> You could do some circuit tricks with switching super-caps if you need only momentary. <S> But a boost converter for 25A will be large and expensive. <S> May be better to use a 12V solenoid or add another 12V battery to create 24V. <A> I agree with @RichardCrowley, using a second 12v battery in series with the first would be more robust. <S> Since I couldn't post a diagram in a comment, here it is as a separate answer. <S> Click image to make full-size. <S> Some liberty was taken in assuming characteristics for the solenoid and control requirements. <S> This isn't super-fast, but it is simple and low-cost. <S> Two HAT1072H power PMOSFETs were paralleled to distribute heat over a greater surface area. <S> This PMOS was arbitrarily chosen for it's very low \$R_{DS(ON)}\$ of \$3.6m\Omega\$ <S> but any power device should work. <S> A down-side to this particular device is it's \$V_{GSS}\$ of -20v. <S> This means that pulling the gates to ground from +24v source would be problematic. <S> D2 12v zener diode drops 12 of these volts, so that the gates only see -12v <S> or so <S> (red trace.) <S> Note that for several microseconds, D2 conducts substantial current discharging the gate capacitance. <S> It cannot do this repetively, or it will overheat. <S> Likewise, R3 will take ~100uS to re-charge the PMOS gates after turn-off, during which time the PMOS will be dissipating large amounts of power. <S> Bottom line is, the duty cycle must be very low. <S> No cycling it multiple times per second. <S> About 22v (considering losses) is switched into the solenoid (green trace) for about 24A of drive current. <S> Steady-state losses of the PMOS should be about half a watt each when on. <S> After switching off, D1 conducts the back-emf from the solenoid for about 10mS, causing the voltage to go below ground to about <S> -1v. <S> Without D1, the PMOS would certainly be destroyed. <S> No digital logic can be connected to the solenoid either - the -1v will likely cause latch-up. <S> D1 will also slow down the mechanical release of the solenoid. <S> If this is a problem, research solenoid clamps . <S> Q1 is a high-current NPN, driven very hard (Ib=100mA) to squeeze as much switch-on speed from the PMOS as possible. <S> This drive can be relaxed, at the cost of increased switching loss. <A> You could get a cheap 12 V -> 120 VAC inverter of the type people use to run their plug-in appliances off of a car/boat/RV battery, and then use a 120 VAC->24 V transformer/power supply. <S> This is bulky and expensive compared to something made for your purpose, but can be basically plug-and-play.
In general, it would be better to avoid the high voltage step if all you need to do is drive a solenoid, but assuming you are in some mobile application, it might be useful to have 120 VAC for other reasons.
RJ45 jack to PCB Everyone, hello! So I'm building a PCB in my head right now, and I just wanted to quickly eliminate a thought I had in my mind. When I add a RJ45 jack connector to my PCB board, there are (depending on how the connector is build, of course (with LED or not, etc)) normally 8 PINs for the 8 wires in the cat5/6 cable. I put together this quick picture: Is this correct? Do the numbers on the RJ45 jack connector correspond with those on my cat wire? <Q> Is this correct? <S> Do the numbers on the RJ45 jack connector correspond with those on my cat wire? <S> Not necessarily. <A> I found myself asking this exact question at work this week after encountering an RJ45 connector with a somewhat different PCB-side pin-out than what I was expecting (I was expecting something along the lines of what the original poster suggests in their jack diagram). <S> Digging a little deeper, I found there are two common PCB-side pin-out configurations. <S> This datasheet from TE Connectivity labels them as "traditional" and "Category 5": 5558341-1 Datasheet Similarly, browsing through entries in the tables in this catalog document indicates a mix of pin-outs out there: TE Connectivity modular jacks catalog <S> As other people have suggested, definitely check the datasheet for the specific part you intend to use. <S> I realize this answer comes long after the original question was posted, but hopefully it helps someone else avoid the moment of excitement I experienced during a PCB layout review yesterday afternoon. <A> Your first problem is that you have labeled the plug contrary to convention; precisely backwards.
You have to use datasheet for the connector, and create device in your EDA tool as per datasheet with proper symbol and package. Your second problem is that pins out of the jack don't always correspond directly to the pins inside the jack, so you need to check the datasheet and or with a multimeter.
How much can a power brick safely vary from what the device it's used with expects? How much can a power brick safely vary from what the device it's used with expects? As an example, let's say I have a device that needs an AC=>DC power brick. The device expects 19V/1.58A, but the brick is missing. Now let's say I find a brick where the connector fits the device and is also 19V, but outputs 3.42A. How safe is this likely to be for the device? Will the device only draw the power it needs, or am I likely to blow a capacitor somewhere? If that latter, this example the brick provides more than twice the current requested. How much closer would have I have to get to be reasonable? How much can voltage vary vs amps? Given different devices likely have more tolerances than others, is there a good rule of thumb to look for to know how much you cheat on matching power brick to device? While the example does match a real situation, I'm also interested in the general case. <Q> These bricks are constant voltage supplies , i.e. they're both spec'ed to deliver 19 V. <S> The 1.58 A and 3.42 <S> A are specifications for the maximum current they can supply at that voltage – using less than the supply can offer must work. <S> Physically, a power supply can either define the voltage it offers, or the current it pushes through a load – never both, because for any load, one is a function of the other. <A> Voltage is important. <S> You may be able to get away with 18.5V, but it may take longer for the battery to charge up full. <S> Or maybe the battery will never charge back up to 100%. <S> Supplying a HIGHER voltage than the rated load can be assumed to always be dangerous. <S> NOT recommended. <S> A load will draw only as much current as it needs. <S> Having a source capable of MORE current is not a problem. <S> You can plug a 5W night-light into the same power source that will supply a 1000W light. <A> The answers here are mostly correct, although there are two things to consider when connecting a supply with significantly higher current capability: Most power bricks nowadays are switchmode converters, and many of them fail gracefully if they are overloaded by either cycling or limiting current. <S> So if the device to be powered by the 19V, 1.58A supply fails with a short circuit, the original supply is unlikely to be able to deliver more than like 2.5A, but the supply might go up in smoke if it is badly designed. <S> On the other hand, the 3.5A supply will likely deliver 4A if it does not shut down on overload. <S> In a cheap device without an input fuse, there is the possibility for the broken device to catch fire due to the higher power supplied into it. <S> As long as the device is not broken, the stronger supply does most likely no harm. <S> Furthermore, there are devices with an input fuse that is quite close to the expected operating current of the device, and might be blown by the inrush current. <S> These designs rely (on purpose or by chance) on the limited current supplied by the bundled power brick. <S> This gets more likely, if the output voltage of the replacement supply is also (even slightly) higher than the original supply.
A stronger brick might provide enough inrush current to blow the fuse.
Why do 1 pF capacitors exist? What kind of uses do engineers find for 1 pF or lower-value capacitors? This is the kind of value one gets with two bits of wire close to each other or two tracks. <Q> The smallest capacitor I've used recently, in a filter in a 6 GHz receiver, was 0.5 pF. <S> There were some 2 nH inductors there as well, and you could argue that those could be made with a few mm of track. <S> However, both were smaller than the equivalent way of implementing them in copper. <S> Perhaps more importantly than the size, is that they were discrete components. <S> When I wanted to change the capacitor from 0.4 pF to 0.5 pF, to retune the filter, I didn't need to respin the board; I just changed the bill of materials. <A> I use a 0.8 pF capacitor in a photodiode transimpedance amplifier (TIA) across the feedback resistor to reduce op-amp noise gain <S> and I've used select on test capacitors from 0.5 pF upwards to centralize a 400 MHz colpitts based VCO. <A> Here a good impedance matching between the transmitter and the antenna is essential for good performance, and you'll usually do the fine tuning with capacitors. <S> A 1 pF mismatch can easily make a 20% output power and thus reading-distance difference. <S> You don't use 1 pF or smaller capacitors alone. <S> They're usually used in parallel with a bigger capacitor. <S> So if your circuit calls for a 19 pF capacitor somewhere you'll use 18 pF and 1 pF in parallel. <S> Why not use 10 pF and 9.1 pF <S> in parallel you may ask: The reason is, that it's hard to find 1% tolerance capacitors below 10 pF. Small values come with an absolute tolerance of - let's say - +/- <S> 0.3  <S> pF. <S> You get a better overall precision if you use a precision 18 pF part in parallel with a not-so-good 1 pF cap. <A> I'll sometimes use small caps to help match capacitance in filters. <S> Something like a State Variable filter in the 100kHz range, (not often 1 pF, but 2.2 or 3.3 is not uncommon.) <A> In the case of a C0G or a proper microwave dielectric, the discrete capacitor can be an order of magnitude less lossy than a bog standard PCB material like FR4. <S> Less loss means your filters have lower attenuation and have higher Q which helps in blocking unwanted frequencies or making more stable PLLs etc.
I've also used a 1 pF capacitor in a quadrature FM detector for driving the tank so that I get high Q and the necessary phase shift of 90 degrees. In addition to everyone else's answers, discrete capacitors tend to be less lossy than that of an embedded solution. You'll also find them in RFID reader antenna matching circuits.
How can I get rid of this spike in my overvoltage protection circuit? simulate this circuit – Schematic created using CircuitLab I am trying to design an overvoltage protection circuit. And this is the circuit above, and this is the LtSpice circuit below: This circuit somehow manages to function correctly. Meaning, it accepts input only for voltage level between 2V -3.6V, when higher voltage is applied, it closes the PMOS (M4 in CircuitLab and M1 in LtSpice). But the problem is ripple and the spikes! I know spike is formed because M1 can not open fast enough to compansate fast rise of Vin to gate of M2. But I can't think anything for getting rid of ripples. spike occurs at both circuitlab and ltSpice. But in circuit lab, ripples not seen. Thanks in advance. <Q> The most basic way to get rid of voltage spikes is to low pass filter them. <S> Make C1/C2 (1uF) bigger and see what your results are. <S> The other way is to make M1 shut off faster of course. <S> R6 is the path to do that. <S> Something that makes me wary of the circuit is the position of L2. <S> It's most likely being used as part of a low-pass filter to begin with, but in the event of a voltage spike, the position of M1 with the inductor causes a significant voltage spike on the left side of M1 as M1 is shutting off. <S> This could exacerbate the problem you're seeing. <S> To get around this, you may want to add a diode across L2 facing backwards to allow any inductive spikes you cause to bleed out through the diode. <A> There are a few things I don't understand in your circuit, but mainly the presence of the inductor, which seems small enough to not matter for the seconds worth of switching signals, but also significant enough to give a nice, short kickback, to matter as a spike. <S> While your circuit seems small enough (which might suggest a need for simplicity), may I suggest an alternative, maybe with <S> 339 or similar open-collector: <S> Q1 and Q2 are the internal open-collector, and Q3 is there for inversion. <S> The thresholds can be easily calculated, I'll leave that to you, if you want this. <S> It's a simple schematic, meant to show you the alternative, not to present you with a full schematic. <A> Solved. <S> I added shunt capacitor between M1's gate and source. <S> So this way VSG voltage of M1 increases faster than before also, when M3 also triggered, \$\frac{C_1 // R_6}{C_{SG} // <S> R_{DS3} <S> + <S> C_1 // R_6}\$ stays small since \$C_1\$ is much more bigger than \$C_{SG}\$ <S> so M1 remains closed.
To pinch it off faster, you would have to lower R6 so that the voltage spike travelling down the line transfers its energy to the Gate of M1 faster. Look up voltage-snubbers for more info on this.
LED's for a project won't work in parallel I am currently working on a model kit and am wiring up all the LED lighting in parallel and have run into a problem. When using blue or white LED's they work fine in parallel and then when I add a red,green, or yellow LED only the red,yellow, or green will light up even though they appear to be the correct polarity. I don't believe this to be an issue with current as multiple white and blue can be in parallel while it only takes one red to turn the others off. Power source is a 3V battery cell. <Q> Each LED has a particular "forward voltage". <S> For red, typically 1.8V, while blue/green can be as high as 3.2V. <S> What is happening, is when you add the red LED, it becomes the path of least resistance, due to the (much) lower forward voltage, and all current goes through the red LED. <S> So, let's say your power source is 4.5V (3x alkaline batteries), and each LED is rated for 20mA of current (pretty typical). <S> If the red LED has a Vf of 1.8V, you need to give it a series resistor of 135 Ohms. <S> If the blue LED has a Vf of 3.2V, then it gets a series resistor of 65 Ohms. <S> I can get into the math if you'd like <S> (it's not too bad), but there are calculators online too: <S> http://led.linear1.org/1led.wiz <S> These LED+resistor pairs can then be connected in parallel, and your lights will work. <S> edit:I just read that your power source is a little coin cell battery, these tend to have very high internal resistance, which is why the red LED is not burning out, but rather absorbing all the current. <S> It is acting as though there is a high-value resistor in series with your parallel LED's. <S> When you put diodes in parallel like that (LED stands for light emitting diode), only the one with the lowest forward voltage will conduct, so the red wins here. <A> LEDs have different forward voltage drops depending on the chemistry/silicon solution used. <S> White LEDs use Blue/Ultraviolet LEDS <S> so are about the same Vf. <S> From the above you could see that you could parallel Blue/White and Red/Yellow/Orange, but otherwise the lowest Vf LED will take all the current. <A> The forward voltage for white and blue LEDs is much higher than for the other colors. <S> It is NOT recommended to connect LEDs (of ANY color) in parallel as even LEDs of the same color have slightly different forward voltages. <S> Ref: <S> https://en.wikipedia.org/wiki/LED_circuit <S> (you could have looked this up yourself)
You need at least one "current limiting resistor" per LED , and you need to size them appropriately for each LED's forward voltage.
How to make 5v DC UPS Circuit? My objective is to build a Circuit which will draw current from Solar Panel, recharge a battery as well as run the load even if voltage from solar panel goes too low. I have made the following circuit, where V1 is a Solar Panel 3-10 V output, BAT1is a Rechargeable Li-ion battery, LOAD is a submersible pump which draws about 100 mA. simulate this circuit – Schematic created using CircuitLab Will the circuit perform my objective? <Q> There are several problems with your circuit:- A '3.7V' Lithium-Ion cell can be safely be charged up to 4.23V, but no higher or it will explode! <S> Your voltage regulator is set to produce 5.0V, and D2 drops 0.5~0.9V <S> depending on charging current, which could put up to 4.5V on the battery. <S> However D3 drops about 1.7V at normal operating current (assuming it is a red LED, other colors may be higher) leaving only 2.8V so the battery will never get charged. <S> Your 5V 3W solar panel should be able to deliver 600mA at 5V in full sunlight. <S> However at 600mA D1 drops <S> ~0.7V and U1 drops <S> ~1.8V, so the regulator output voltage would only be about 2.5V. <S> At low current the solar panel's voltage may rise to ~6.5V <S> and the regulator will have lower voltage drop <S> so its output voltage may be sufficient, but the battery would charge very slowly. <S> Most linear regulators require input and output bypass capacitors to prevent unwanted oscillation. <S> The LM317 is better than many, usually only needing 0.1uF across the supply input. <S> If using a different regulator you should follow the manufacturer's recommendations. <S> D1 is redundant and should be removed. <S> U1 could be replaced with an LDO regulator such as the MIC29150 <S> which drops less than 0.2V at 600mA. <S> You should connect battery negative directly to the solar panel so that charging current doesn't go through the LED. <S> This could result in the battery getting up to 4.5V, so you must reduce the voltage regulator's output voltage until the 'open circuit' voltage after D2 is below 4.23V. <S> Your circuit doesn't include over-discharge protection. <S> (Protection Circuit Module). <S> This will also protect against over charging and accidental short circuits. <A> You need to replace the regulator with a regulator + charge controller. <S> A very common choice is the TP4056, which is available packaged on convenient little modules all over eBay for a few dollars (just search for TP4056). <S> Feed the output from the regulator into the "input" side of the charge controller, and drive your circuit from the output side, with a battery connected across the output terminals. <S> Use protected lithium cells which will auto-cutoff on excessive discharge. <A> I think you misread the pump specs. <S> Did you calc 37 Ohm? <S> Most motors have winding DCR resistance of <S> are 8~10% of the rated V/I <S> so surge current is increased on start this V+/DCR 300mW pump? <S> maybe 450mW? <S> I suggest you pump <S> is 4.5V @100mA <S> rated thus start current is 800 to 1000mA <S> Your design too inefficient with all the Silicon diode drop and <S> the V PMT would be around 8V or 80% of the Voc (open cct) <S> so it will not generate less than 50% of rated max PV power at 3.9~4V. <S> Choose a voltage limiter of 3.9V and drive from LiPo direct. <S> Then make sure load is removed at 3V with hysteresis to 3.3V. EDIT <S> Your LDO is set for 5V . <S> If the LiPo reaches 4.4V, if std. <S> chemistry, it may explode from critical self damage. <S> Max 4.15V to LiPo for longer life.
To prevent the battery from being damaged if for some reason the solar panel cannot maintain sufficient charge, you might consider adding a PCM
Will the IC mess up if the inputs that don't affect the output are disconnected? Here's the situation. I'm trying to incorporate ANY decoder in the HC family to decode two bits. I'm also using the eagle autorouter. I decided to go with 74HC139 since its a dual decoder and the pin arrangement is convenient, BUT because I'm not using one of the decoders, I tied pins 13 through 16 to VCC to effectively disable the second decoder, but when routing on the PCB, tying adjacent pins together eliminates routing opportunities and its a major cause of my routing to not complete. Many chips have an input that controls everything. In this case, the 74HC139 has a gate input G on pin 15 to fully control the output. If it is set to high, all output lines are high regardless of pins 13 and 14 (input bit 0 and 1). Because of this, I begin to think I can just tie pin 15 and 16 together (make G high) and then leave pin 13 and 14 open. Is this acceptable for an HC series chip or will bad things happen (even though the output is exactly the same regardless of the level of pin 13 and 14)? <Q> The power consumption increases by orders of magnitude if the pins are allowed to wally around in the linear region. <S> If the input does not affect the logic function, then it doesn't matter what logic input state it takes. <S> It can be tied high, low, or even to another output, as long as it is a valid logic level, so there are usually plenty of options for helping the layout out. <A> Consider output pin 16(Vcc) to pin 15 and pin 14,13 to pin 12 <S> ((2Y0) <S> so you can route between 15-14 or shift to 14-13. <S> Never leave floating CMOS inputs as it becomes more sensitive to stray impulse E-Field induced by nearby ESD. <A> Ideally you would tie pin 15 (2E-) to Vcc (pin 16 adjacent) since it is active low, and tie pins 13 & 14 to GND since they are active high. <S> Assuming you are using a double-side board, are you routing signal traces between the pins on BOTH sides of the board?
Bad things happen with HCMOS logic if you allow any input pin to float.
How does feedback make a system stable even in the presence of an inherently unstable element in that? Consider the transfer function of a block being $$\frac{1}{s-0.5}$$ which is unstable in open loop. If we go for a feedback, magically it becomes stable even with the presence of the inherently unstable block. My thoughts on these are When an element is unstable , it doesn't mean it is unstable for all inputs. For certain inputs the block can still produce stable outputs. During feedback, the input given to the the block gets modified such that output doesn't blow up. My questions are Are the above observations correct? The impulse response of the block is $$ e^{0.5t}u(t) $$ What the block does is, take the area under the signal at present instant and blow it up for subsequent instants. If so, a positive valued input should blowup the output exponentially. Then why is the output not blown up (exponentially) in following case, shown in figure? The signal shown as input is the actual error signal when we use the block in a closed loop format with unit step input. <Q> " When an element is unstable , it doesn't mean it is unstable for all inputs. <S> For certain inputs the block can still produce stable outputs. " <S> At first, an "element" (a part) cannot be unstable. <S> It is better to use the term "active block" or "amplifier". <S> Hence, an amplifier can be unstable if it has feedback, which produces a closed-loop pole (pair) with a positive real part. <S> This is true for all inputs because it is the feedback loop which produces self-excitement of the system - not the input signal. <S> " During feedback, the input given to the the block gets modified such that output doesn't blow up. " <S> An unstable system can be stabilized if the overall negative feedback overrides (dominates) the positive feedback which would cause instability (without negative feedback). <S> In your case (example), the gain block has an inherent positive feedback (causing a pole at +0.5). <S> This gain block ist stabilized using - as shown - 100% negative feedback causing a total closed-loop gain of "2 (and a pole at "-0.5") <A> Not necessarily all feedbacks stabilize the system. <S> In your pic, if it were positive feedback, the system would be unstable. <S> When an element is unstable , it doesn't mean it is unstable for all inputs. <S> For certain inputs, the block can still produce stable outputs. <S> No. <S> When an LTI system(like the one you have) is stable, it stable for all stable inputs. <S> When an LTI system is unstable, the response is unstable for all stable and unstable inputs. <S> Only for non-linear systems, a certain input range may stabilize and few will lead to an unstable response. <S> Yes. <S> The reason why it is stable in this case is that for some input say x when given just to your unstable system, it generates a response(high value). <S> This high value is given back to your unstable system but with reversed polarity/effect. <S> So this feedback signal again <S> when given back to the system, it generates high value(this time in opposite polarity) and the process continues and so on. <S> So for any signal, your unstable system generates a response which is fed back negatively/counteractively to the system thereby stabilizing it. <S> Though the system is overall stable, internally it is unstable <A> \$V_{out} = <S> \dfrac{1}{s-0.5}\times (V_{in} - V_{out}\$) <S> Rearranging: - \$V_{out}(s-0.5+1) = <S> V_{in}\$ and: - \$\dfrac{V_{out}}{V_{in}} <S> = <S> \dfrac{1}{s+0.5}\$ <S> i.e. a previously unstable system becomes stable with negative feedback. <S> Should the minus 0.5 term have been minus 1 (or more negative) then using the simple negative feedback in the question would not have produced stability.
During feedback, the input given to the the block gets modified such that output doesn't blow up.
Phase between two sinusoids and which one is leading that's my first question here.I'm studying fundamentals of electric ciruitsand I faced this question: Determine which one leads and by how much:$$v1(t) = 4*\cos(377t + 10)$$$$v2(t) = -20*\cos (377t)$$ So I converted $$v2 = -20*\cos (377t)$$ to $$v2 = +20*\cos (377t+180)$$ and graphed the two sinusoids on the unit circuit but I'm confused about which one is leading the other and by how much Thanks in advance!! =) EDIT!!: <Q> You have got these two equations: <S> $$v1(t) = 4*cos(377t + 10)$$ and$$v2(t) = <S> 20*cos <S> (377t+180)$$If you substitute t=0, you will get \$v1(0) = <S> 4*cos(10)\$ and \$v2(0) <S> = <S> 20*cos(180)\$. From the values you can conclude <S> that at t =0, v2 has a value which cosine does at the end of its period and v1 has a value which cosine does at the beginning of its period. <S> So, we can say v2 is leading v1. <A> Represent both in terms of sine before finding which one leads/lags. <S> \$v1(t) = <S> 4*cos(377t + 10)\$ becomes \$4*sin(377t + 10 + 90) = <S> 4*sin(377 <S> t <S> +100)\$ \$v2(t) = <S> 20*cos (377t+180)\$ becomes \$20*sin(377t + 180 + 90) = <S> 20*sin(377t + 270)\$ Normalize both. <S> So you get normalized \$v1 = <S> sin(377t +100)\$ and normalized \$v2 = <S> sin(377t <S> + 270)\$. <S> Now you can see v2 leads v1 by 170 degrees. <A> In this case you already represent both in the same terms (cosine) so you can see which one is leading by seeing which phase is greater. <S> In this case \$v1(t) = <S> 4*\cos(377t + 10)\$ and <S> \$v2 = +20*cos <S> (377t+180)\$. You can see that v2 has greater phase (180) than v1 (10). <S> Now you know that V2 is leading V1 by 170 (180-10). <A> if offset was 0 you would have a complementary sinewaves or a "split-single phase " outputs. <S> e.g. centre-tapped transformer output. <S> with v1 much lower amplitude.
This looks like a "split single phase" except unbalanced (v1 << v2) regardless of inbalance, v1(t) is clearly leading +10
24V output with microcontroller using mosfets I want to controll 24V output which will be used by PLC with 3V3 logic uC. I've created sth like this: Q1 is my output from uC. VIN1 is supply voltage and COM1 common of it. I want to have various output voltage (like 5-24). But let's focus only on 24V now. Will this circuit work? What if there will be no load on Q1OUT ? Will transistor boil to death? Am I missing something? Thanks in advance and best regards,g.voooo16. <Q> A MOSFET needs a gate voltage well above the source to conduct properly, for your type ~ <S> 10V. Obviously your circuit can't deliver this. <S> That's why the common way to use such a transistor is with the source grounded and the load at the drain, and teh collector of the PC817 at a suitable voltage level (12V would be OK). <A> I think you want something like this: simulate this circuit – <S> Schematic created using CircuitLab <S> There are far better and more efficient ways of doing this but this is probably the simplest. <A> Which requires a high side gate driver . <S> (eg: a boost converter such as LT1161 ) <S> Instead, you could use P channel mosfets. <S> You turn them on by pulling Vgate to common, and a pull-up to 24V turns them (slowly) off again. <S> However, P channels are often more expensive or have higher on resistance. <S> as an BTS4142, <S> but you can get more advanced versions with diagnostics and sensing. <S> A bonus feature of high side switches is that they are more robust than a standard fet or transistor since they include thermal shutdown and load dump protection. <A> It depends on your load. <S> You should be able to use any transistor. <S> Or an open collector buffer. <S> You can drive the 74LS07 with a minimum high level voltage of 2 V, so 3.3 V should trigger it securely. <S> And it can take up to 30 V into it's open-collector. <S> Data sheet says I(OL) of 40 mA, not sure why they say "output low", that should be zero. <S> So 40 mA at 30 V should be safe perhaps? <S> After that a power transistor. <S> Your circuit seems to have Q1OUT1 tied to COM, i.e., always zero, and the FET shorted from VIN1 to COM when it opens. <S> So as planned I'd say it (or something around it) will "boil to death" quickly. <S> And now I see you have an opto-cupler as input here, so it depends on its data sheet. <S> That PC817 you show here can take 80 V over collector-emitter already. <S> And 50 mA. So tie it via a pull-up (and current limiting) resistor to your 24 voltage without a problem.
Since the signal levels of N channel mosfets require a positive gate voltage as seen from source, you'll need to make 24V + Vgate. In my opinion the best option would be to use High Side Switches .Such
DIY zero-crossing circuit, how crucial are component values? I want to build this circuit, taken from here , and I'm wondering exactly how crucial exact component values are. I don't have any 220k, 22k, or 4.7k resistors. I'm wondering if I can substitute two 100k in series for the 220k, two 10k for the 22k and a 5.1k for the 4.7k. Of course I could do two 100k and two 10k to make the 220k, but that's 4 resistors in place of one. Will the 20k difference make that much of a...difference? Also the circuit calls for 1n4148 or equivalent diodes. I have 1n4007. Since those are really just to make a bridge rectifier, could I just use a bridge rectifier component, or just substitute the 1n4007 diodes? Finally, is a 2N2222 an acceptable substitute in this case for a 2N3904? <Q> All your suggested substitutions are just fine. <A> 200k total will be just fine. <S> 20k for the 22k is fine, as is 4.7k for the 5.1k. <S> 2n2222 has slightly lower gain than 2n3904 at 10mA <S> (75 plays 100), but I doubt the difference will cause a problem. <S> 1N4007 diodes are much slower than 1n4148, this might cause a small time shift in the detected zero crossing, but the circuit should still work. <A> I can't see any reason why not. <S> The resistors for instance are just voltage droppers and a current limiter. <S> The 4.7k is a pull up. <S> None of it looks critical. <A> Two series 10K resistors in place of the 22K. Using 5.1K in place of the 4.7K. <S> Replacing the 1N4148 diodes with 1N4007 should work as well but they will be a bit harder to work with because of bigger body size and thicker leads. <S> So I think you are free to experiment. <S> Just be aware that your result will not be as compact. <S> Also use much care to check your wiring on the mains side and be aware that testing mains attached circuits can be dangerous and requires extreme caution. <A> There's a basic problem with the circuit around the 2N3904 transistor and how it gets biased (more further down)... <S> For the resistors <S> yes, and given the applied voltages, two in series will likely be better in terms of voltage rating - read the data sheets of the resistors you want to use because voltage rating is important and so is power rating. <S> For the diodes, possibly (although the reverse turn off time for the 1N400x series is particularly crappy compared to the 1N4148). <S> However, I expect that a 30 us delay isn't going to make a big deal. <S> Also with using the 1N4007 there is zero doubt it can survive the full voltage applied whereas the 1N4148 would not if mis-connected. <S> The 2N3904 is only rated at 40 volts from collector to emitter <S> but I'm struggling to see how that device works in the circuit <S> so I think you have a basic problem here with the original circuit. <S> I'm struggling with this probably because it's been a long day but do consider simulating it to see if it works or wait for someone to explain away my doubt.
Two series resistors for the 220k is just fine, in fact it will improve safety, as you get two times the resistor voltage rating. The circuit should work OK with the substitutions that you propose for the resistors. There is nothing critical in this circuit except the performance (CTR) of the optoisolator. The 2N2222 transistor should be just fine in place of the 2N3904. Two series 100K resistors in place of each 220K.
How to set up 40 hz flashing LED lights to light a room? I am trying to figure out how to light an average size living room or bedroom with lights flashing at 40 Hz at the same time (one big light or many small ones). I assume the range can probably be +/- 3 Hz or less but the target is 40 Hz. This range appears to be out of the range of a common strobe... I know there are a million answers for this problem, I figure LEDs have a natural advantage (but could be incandescent), AC or DC options will be considered, but the most user friendly options will likely win out. I would like to set something up that even my grandmother could turn on without thinking twice. The background information regarding why this is such a hot question on the internet can be found here: http://www.radiolab.org/story/bringing-gamma-back/ Thanks in advance! <Q> As noted by Peter Camilleri : This might help sufferers of Alzheimer's disease, and I certainly hope it does, but it may cause problems for other people. <S> Generating a 40Hz square wave is not difficult. <S> The simplest solution would likely be an astable 555 timer circuit. <S> You could also use a microcontroller, but that is a significant hassle in comparison. <S> Note that the 555 can only output 200mA, so you may need to put a transistor on the output to drive your light. <S> LED is probably the best choice for the light source. <S> The filament in an incandescent bulb will remain hot and luminous briefly after it is switched off. <S> At 40Hz, the overall effect might be more like a dim bulb than a flashing bulb. <S> An LED will turn on and off abruptly. <S> One light is probably better as well, just because you won't have to have power wiring throughout the room for distributed lights. <S> Think battery power, like a USB power bank. <S> There are significant electrical safety problems associated with powering things from the mains, especially if the user is suffering from Alzheimer's disease. <S> You want your system to present no hazard to the user. <S> This circuitry is relatively small and simple, so you could assemble it on stripboard/veroboard. <S> I would do it this way. <S> USB Power Bank -> <S> Astable 555 timer -> <S> Driver transistor - <S> > <S> Light <S> Here is a calculator for the 555: http://www.ohmslawcalculator.com/555-astable-calculator <A> Technically, this is trivial. <S> LEDs (including white) will switch much faster than 40Hz, so it's a matter of switching current to the LEDs. <S> Practically, it might be slightly more difficult because most consumer level products have a power supply + driver circuit built-in which cannot be switched that fast. <S> One approach would be to use 12V lamps with only resistors inside (some will have a driver and may not be suitable) and a beefy 12V supply. <S> Then you could use a simple MOSFET to switch the current. <S> A 555 timer or a cheap function generator could be used to drive the MOSFET (probably through a driver chip). <S> The function generator would have the advantage of a frequency display so the results would be repeatable. <S> Using 12V also makes it less likely that someone will be accidentally electrocuted. <S> To nail this down more firmly, you need to define how much light you actually need, what safety standards you are working to (many of the power supplies will require an enclosure, fusing and maybe input filtering external to the metal case they come in) and how the lights will be mounted etc. <A> Essentially what you are doing is PWM dimming - just at 40 Hz instead of several KHz. <S> (PWM dimming pulses the signal at a certain duty cycle for the brightness desired.) <S> A typical LARGE RGB LED system is set up like this: 12VDC power supply (sometimes 24V) <S> An RGB or monochrome brightness controller , which takes user input and generates 12V modulated with PWM. <S> An amplifier which inputs power and the 12V PWM signal, and outputs that same pulsed signal at much higher current. <S> The LED strips or spot lights, which then "shimmer" at whatever the PWM frequency is. <S> Normally the controllers have enough current to drive a few lights directly. <S> For a large system, their output is used strictly as a signal into the amplifiers. <S> Commonly they have 3 channels (R G B). <S> You can use monochrome lights and drive them off one channel, or split the signal to 3 channels and have 3 branches all monochrome. <S> Or simply go RGB, but the color CRI may not be great. <S> Replace the controller with a simple circuit, perhaps 555 timer based, which outputs 12V PWM at fairly low current - only enough to gate the amplifier. <S> Now you don't have to worry about switching power, the off-the-shelf amplifier does it for you. <S> You can make the LED lighting as bright as you please, depending on how many emitters and amplifiers you are willing to stack. <S> Generally one amplifier will power more light than you're likely to want - <S> 72W of LED light is quite a lot.
A single high power LED can provide significant illumination. There are lots of LED lighting products designed to work with PWM dimming, mainly for RGB controllable color, and I'd just dive into that parts bin.
How to wake up ESP8266 with light change? I want to send information to the server when the light changes (turns on or turns off). As for now, I have a photoresistor connected to ESP8266's ADC pin. I'm measuring voltage and sends information to a server when it changes much. ESP stays always on. Here is my current circuit: However, I'd like to make it in slightly more energy efficient way. The sensor will be used in a bathroom, so the light is usually turned off. Perhaps I could make ESP8266 wake up somehow by photoresistor and then send a request to the server and wait for the light to turn off back again and then send the second request and enter the deep-sleep mode? Or maybe there is a better way? I'm seeking help in creating a circuit. What should I use? How the circuit should look like? <Q> The deep sleep functionality of the ESP8266 is managed by tying pin 16 to the RESET pin and when you call the deep sleep function you pass the number of microseonds you want to sleep. <S> Then the microcontroller sets pin 16 high and goes to sleep. <S> After the specified amount of time the pin 16 goes low causing the ESP8266 to reset. <S> Please see the "low power solutions" pdf from Espressif for the API details, including some application notes. <S> So, your plan of connecting to pin 16 is not going to work exactly. <S> You need a circuit that detects that pin 16 is high and then generates a low pulse on RST when your condition triggers. <S> Without knowing more details about your circuit and exact triggering condition or is hard to provide a detailed answer. <A> Enter deepsleep without connecting GPIO16 and RESET leeds to endless deepsleep unless you pulse reset with an extern circuit! <S> That is what you have to do. <S> Connect your photoresistor to a differential-Amp with monoflop in series to ensure clean pulses on reset pin or use a ultra low power mcu to do that. <S> So every time the light changes the differntial-amp detects the high slope and triggers the Monoflop! <S> Reading Pin 16 is not a musthave you can use a timeout in monoflop but adding an AND-Gate is also not really hard to do. <A> Have your photoresistor wake up the esp whenever the light is turn on, then send to server. <S> That should save a lot of power <S> See Esp8266
You could just put the esp into light sleep mode, and tie a gpio pin as an interrupt to wake it up.
why ultrasonic module sends out 8 cycles ? and , why the trigger pulse is 10us? this is the operation of the ultarsonic module HC-sr04 : The timing diagram of HC-SR04 is shown. To start measurement, Trig of SR04 must receive a pulse of high (5V) for at least 10us, this will initiate the sensor will transmit out 8 cycle of ultrasonic burst at 40kHz and wait for the reflected ultrasonic burst. When the sensor detected ultrasonic from receiver, it will set the Echo pin to high (5V) and delay for a period (width) which proportion to distance. To obtain the distance, measure the width (Ton) of Echo pin. is the number of 8 cycles related to the microcontroller of the module ,I think that but why? don't forget the second question why the trigger is 10us ? <Q> The receiver and transmitter are mechanically tuned to the frequency, so it will take a few cycles for the amplitude to ring up to the maximum (the transmitter will ring up in amplitude as you drive it, and the receiver needs to 'hear' a number of cycles before it reaches full output, <S> so you better drive it for enough cycles). <S> It's also of no advantage to have too long a sequence of cycles. <S> That is why the designer programmed the microcontroller to output 8 cycles in particular, in answer to your first question. <S> Read any reference on 2nd order systems for an explanation of Q and resonance. <S> The center frequency of this mechanical resonance is typically specified to +/- <S> 1kHz <S> (+/-2.5%). <S> Here is a typical one: <S> Note the ringing specification of 1.2ms for this product, which implies a much higher Q. <S> It is a waterproof type and has too high a Q for good results in a ranging application. <S> You can find more information in this answer. <S> In answer to your second question, the 10us is probably to allow the firmware in the microcontroller to recognize the input. <S> If they don't use an interrupt but rather a tight loop it might take that long to traverse the loop so a shorter pulse might be missed some of the time. <A> trigger pulse is the requirement of controller. <S> the number of pulses provided is the optimum number for generating ouput voltage at receiver side. <S> to understand that i performed an experiment: I used two 200kHz US transducers, one as transmitter and other as receiver at a distance of 40mm. <S> On sending pulses from transmitter the receiver gives an output signal which is conditioned to give a mountain like peak. <S> The big peak is the main signal that is transmitted, the second peak is the signal that is reflected and detected. <S> Similarly other smaller reflections are detected. <S> So as we increase the number of pulses the amplitude of the received signal increases and saturates at a point. <S> After further increase in number of pulses results in increase in reflection peak, which are not required. <S> Hence from this experiment I concluded that for 200kHz, at 40mm the optimum number of pulse required to get maximum output is 6. <S> Similarly the number of 8 pulse might be calculated.also some sensors provide this information on data sheet. <S> e.g. Air Ultrasonic Ceramic Transducers <A> Yes, the 8 cycles of drive at 40kHz is related only to the microprocessor timing driving the output. <S> The HRC-SR04 has a microprocessor on it that does all the timing for send and distance calculation. <S> The output signal is actually created by an RS232 driver (MAX232A). <S> The driver creates it's own +ve and -ve <S> supplies to drive an RS232 line. <S> There is a delay from the 10 uS input trigger to allow the MAX232 to stabilize <S> it's + <S> ve and -ve supply (typically it reaches +/-7 V). <S> The microprocessor then sends the 8 cycles of drive to the sender (14 V p-p through 600 Ohm resistor, so there is no waiting for an osc to reach amplitude. <S> The sender does have a natural oscillating frequency, but in this application it is actively driven by a square wave, there is no oscillator circuit. <S> The sender is driven by the RS232 driver and damped heavily (600 Ohms) when the digital signals stop. <S> One guy did a lot of excellent work on the HC-SR04 . <S> I'm not sure what MAX232's he's talking about but in my experience the output drive voltages are closer to 7 V rather than his quoted 10 V. <S> Either way the material on his website is superb.
Yes, the input trigger is related only to the onboard microprocessor detecting the start pulse.
Which transistor should I use in my circuit? I've made a rudimentary flood alarm (a circuit that rings a buzzer when the water in a reservoir is full) using a 9V battery and a cheap Chinese buzzer that came without a current rating. All I know is that it operates between 6V-12V. There's no power rating on it either, and my multimeter is broken so I can't measure the current myself. There are two parts to the circuit I'm trying to modify it into. Connect a small low-heat capacity resistor in series with thebattery (to limit current) and put the two open ends of the circuitas probes in the water, so that the probes are connected by thewater, the circuit is completed. I want this part to act as thecontrol voltage, applied to the base of the NPN transistor (since Iwant the circuit to close only when the HIGH signal is applied tothe base). I also want to supply the transistor with 9V which is passed only when the voltage at the base is also applied (i.e., circuit is complete due to the water). Here's a basic circuit diagram of what I'm trying to create: I'm new to this, and have no idea what transistor to use. What should be the value of the resistor? Also, do I need to use any other parts to ensure the proper behavior? Please advise. Also, is this circuit feasible for long term use? When the battery voltage degrades, will the transistor be able to adapt? I can't use an AC source coupled with a 7809 IC as I want this to be battery operated. Please suggest a better way if need be. <Q> Here is a bit better way: simulate this circuit – Schematic created using CircuitLab <S> If the probe resistance drops below some tens of M ohms, the beeper will sound. <S> No more than 9uA flows through the probe so electrolysis is minimal. <S> This will work with beepers up to at least a couple hundred mA, above that and Q2 may get too hot while partly on for a TO-92, so you could use a TIP31 or similar TO-220 part (just for Q1). <S> C1 is to keep the battery voltage more steady as the battery ages (under varying load during the audio frequency beeping cycle), C2 prevents RFI from triggering the beeper. <S> R4 and R2 prevent leakage from triggering the beepr and control the maximum resistance that will trigger the beeper. <S> R1 limits the probe current to prevent electrolysis or overdriving the base of Q1. <S> Q1 and Q2 are in a Darlington configuration which provides a theoretical current gain of perhaps 50,000, which is tamed somewhat by R2/R4. <A> Your circuit shows the buzzer on the low side of the transistor, and the transistor as an NPN. <S> This configuration will not work. <S> The buzzer needs to be connected between the collector and the positive terminal of your battery. <S> The transistor itself doesn't really matter, and any regular transistor will do. <S> 2N3904 <S> and 2N2222 are common. <S> The size of the base resistor in a simple circuit like this is not critical, but there is a problem: the water is in series with the resistor. <S> Performance will vary depending on the conductivity of the water. <S> The amount of current flowing through the buzzer is determined by the amount of current flowing into the base of the transistor. <S> If the water path is resistive, less base current will be able to flow, and therefore less current through the buzzer. <S> The result may be that the buzzer is very quiet or intermittent, which is not good for an alarm system. <S> The electrodes you use are liable to corrode and become less conductive as well. <A> Move the buzzer between the battery positive and the npn transistor collector. <S> But first connect the buzzer to the 9V directly, and use a multimeter with a ammeter mode to measure the current. <S> Use that to figure out the transistor type. <S> that said, if under 1 Amp, you could just use a 2n2222 or similar common npn transistor and be done with it.
If you want to put the buzzer on the low side, you need to use a PNP transistor.
Using capacitors to prevent surge current on lead-acid batteries? I'm using a 300 Ah lead-acid battery bank, and a 12V->230V 1000w pure-sine inverter, to power a residential-type refrigerator. With a bit of experimentation, I've managed to reduce the starting power required to a peak of approximately 1500w for 400 ms, which is within what that the inverter can provide. So far, so good. Unfortunately, this draws a peak current, I'm guessing, of about 100A on the battery bank, which causes the voltage to drop for a brief moment to 11.5V, even when fully charged. Over several months of use, I've realized that the battery bank capacity is severely reduced by these peak currents, reducing the 300Ah capacity to something more like 100 Ah. Perhaps I've already damaged the batteries. A more suitable replacement would be a battery type that can handle these surges, e.g. LifePo4 (designed for 3C peak, e.g. 720A). But the price for these batteries are simply prohibitive: my 300Ah, 80%/240Ah usable, lead-acid bank cost about 400 USD; a LifePo4 240Ah bank would cost approx 1400 USD). Another option is to add some kind of additional capacitance. For example, ultra/supercapacitors. I'm not sure what kind of specification I would need. The voltage would be approx 12.5V, and should be able to release 500 J before reaching, I'm guessing, 12.1-12.3V. Wouldn't this mean that I would need more than 1000F? I'm thus faced with a number of options: a) replace battery bank (1000+ USD) b) replace starter motor with Danfoss BD35F (15A peak, approx 450 USD) c) add supercapacitor (how many Farads? 3F seem to cost approx 50 USD) d) design a circuit that temporarily draws current from a standard car starter battery instead (50Ah 12V car battery costsabout 75 USD) I'm thinking that option D might be the simplest and most universal.I could connect it in parallel only when starting the fridge, and disconnect it for the rest of the time, while allowing it to draw a charge through a diode. I'm assuming that the batteries would compete to deliver the current, but that the starter battery would maintain a higher voltage, thus winning the battle, and being the primary deliverer of current. Alternatively, I'd have to disconnect the battery bank temporarily, to ensure all power being drawn from the starter battery. The easiest is obviously to spend 1500 USD for fridge that is designed for 12V, but, I like being hands-on. Ideas are welcome! Additional note: As I understand it, the surge current is only 100A x 12.5 V for 500ms, or 625 J. A starter motor battery with 50Ah/12.5V would have 112kJ capacity at a 5% discharge, which would allow for 180 starts. Update: I've since replaced the lead-acid batteries with LiFePO4 instead. However, if you wish to improve the starting current performance, I believe that you could wire a small 6Ah LiFePO4 (e.g. motorcycle starter battery) in parallel, operating in a voltage range of 12-14.4V.However, my realization is that I don't know why anyone would ever want to buy lead-acid batteries in the first place. An absolutely outdated technology. <Q> It seems that your either your calculations are far off, or you have a bad battery pack - particularly, you have at least one weak cell. <S> This document suggests that, to get 11.5 volts during peak discharge you must be drawing on the order of 2C. For a 300 Ah battery that's 600 amps+. <S> Of course, different batteries have different discharge characteristics, so the curves should be taken with a grain of salt, but I'm inclined to accept them as a starting point. <S> As for using a supecap, the calculations are pretty straightforward. <S> $$\frac{dv}{dt} = <S> \frac{i}{C}$$ or in simple terms a 1 F supercap will discharge at 1 volt/sec for a 1 amp current. <S> Even assuming your current peak is only 100 A, you'll get a 100 V/s droop per farad. <S> To produce a 0.5 volt drop in 400 msec, you'll need $$C = \frac{i}{\frac{dv}{dt}} = <S> \frac{i\times dt}{dV} = <S> \frac{100\times 0.4}{.5} = <S> 80F$$ or about 27 of your 3F units, for a cost of about 1350 dollars. <A> I'd suggest a simple cure for your problem is to use a LiPo car start pack in parallel with your batteries. <S> These units use LiPo cells (as do many larger 4S1P RC battery packs) capable of supporting 30C for very short periods of a few seconds. <S> Even if you leave the unit permanently connected, your battery charging system will never overcharge the LiPo (in fact it will always leave it undercharged). <S> They also need very specialized charging and balancing electronics. <S> They are a great idea, but just not consumer friendly yet. <A> My wild guess is that the inverter very likely has input capacitors, meant to decouple the internal switching operation from the 12V supply. <S> Connect a discharged capacitor to a 12V supply, and you get a very sudden rise in current. <S> Now, the inverter doesn't have to charge these capacitors that fast – it would probably work if you had the following option: load the caps slowly, and only after they've reached a reasonable charge, and only after that turn on the inverter <S> Probably, 2. could also be replaced by simply not turning on the load overly fast. <S> What you could try to do is: Connect the inverter with a 0.5Ω or something resistor in series. <S> Wait a second or two. <S> Now that the capacitors hopefully are charged, bypass the resistor, e.g. with a relay. <S> turn on the inverter. <S> You'll need to find something that has a low enough, but not too low, resistance at turn on. <S> There's load resistors that are designed exactly for this purpose, but a coil wound of normal copper (or aluminium, for that matter) wire might even do the job better (having a high resistance to fast-changing currents, and a low one for DC).
There are Supercapacitor based battery replacements that would provide superb high current capability, but they are terribly expensive.
Possible outcomes of not using a current limiting resistor in this LED driver? I have this LED Driver in my hand.I would like to run my LEDs at the maximum brightness possible - meaning I am thinking of excluding the R_EXT (current limiting resistor pin) connection to a resistor. The datasheet (page 18) doesn't say much other than The recommended minimum value of REXT is 18kΩ, orit may cause a large current. So I don't know if it is ok or not. Will I hear high pitched noise because the driver is over-driven? Will it kill my IC and possibly LEDs in the long term? <Q> I OUT is specified to be 34mA per matrix line, and note 1 states: <S> The average current of each LED is I OUT /10.5. <S> As such, if the current is too much higher than 34mA / 10.5 = 3.24mA then the device may become damaged. <S> This corresponds to a resistance of 64.7V / <S> 3.24mA = 19.97kohm. <A> This chip uses a switched current mirror approach to control the LED current. <S> The current you suck out of pin 6 <S> (R_EXT) is reflected (to some nominal ratio and accuracy) in the output current. <S> If you did something like shorting pin 6 to ground (0\$\Omega\$) that alone could damage the chip. <S> They probably have not designed this chip for an enormous lifetime in the first place (it's aimed at typically short lived consumer applications), so <S> I suggest you stick the <S> recommended value and concentrate on finding a brighter set of LEDs, or use another drive method if you need more brightness. <A> REXT is not inside the power path, so it is not a current limiting resistor. <S> Instead, it is used to create a comparison value that is used as a reference for the actual current limiters (either in the row or the column drivers). <S> If you run this out of spec, anything may happen, including having no current limit (fries the LEDs) or having a current limit close to zero (no output). <S> It is unlikely to damage the driver IC itself, I think (everything connected there internally has a fairly large impedance), but since it's a pointless configuration that isn't worth much.
Running at higher than recommended current could result in overheating or long-term unreliability due to temperature or electromigration effects.
Why is it better to ramp a stepper motor than not? I have been working with a stepper motor, to which I made a controller which drives the stepper motor using a trapezoidal speed ramp. It logically makes sense that it would be hard to stepper motor to start at a target speed without accelerating up to it, but i am currently looking for some literature that also states that doing this is also makes sense. I need some literature that confirms my theory, which i cant find anywhere, or anything that well explains the benefits of doing it so?,and what you gain. I was prior to my project advised to look at it, which is why i didn't try to just give it a simple PWM signal. Maybe asking my questions rather than literature is a better idea. Why is stepper motor benefiting from ramping, I mean DC motor can easily start a certain speed? If you choose to microstep you stepper-motor, wouldn't it be redundant to use a speed ramp? there would not be "that far of a distance" between the coils, which would only suffer for the torque...? <Q> The stepping motor has a field that rotates at a speed that the controller determines. <S> The permanent magnet rotor can lag behind the rotating field by a bit <S> but if it slips too far (like by more than half a pole, which is perhaps 0.9 angular degrees) it won't rotate at all and will just sit there and buzz. <S> When you first start rotating the field (by altering the currents in the coils) the magnetic field has to provide torque for the load as well as to accelerate the inertia of whatever is rigidly attached to the shaft. <S> Once it gets up to speed it needs only to provide the load torque. <S> The faster the shaft turns the less available torque there is (because of losses in the motor and inductance of the windings), so even a linear ramp is not ideal. <S> In any case, by ramping the speed up you can achieve a higher RPM for a given load and inertia than you would otherwise. <S> A DC motor is nothing like that. <S> Put a huge load on the shaft (ie. <S> stall it) and it will provide a large amount of torque in the correct direction, so eventually even a very high inertial load will get up to speed if you don't burn out the motor. <S> Steppers have limited torque- <S> the stepper tends to get hotter sitting there with no load on its shaft than rotating at high speed (many controllers will scale back the current if it's idle). <A> If you measure the DC motors start precisely, you will see that it does not start at a certain speed immediately, it will need some time to accelerate to that speed. <S> It is not possible to accelerate a mass within an infinitely short time. <S> If you look into a good datasheet for a stepper motor, you may find that it depends on the type of motor and the load what speed ramp is necessary. <S> If the speed is very low, the motor will start without a ramp. <S> But when you use a stepper motor for precise positioning, you don't want the motor loosing some steps. <A> The moment of inertia for the driven system may be significant, and the motor cannot accelerate to final angular velocity without putting very high torque on the shaft. <S> You want to limit that torque, so the motor doesn't stall (miss a step), or overstress (twist) <S> a shaft,or a cause a coupling to slip. <S> Ramping the angular velocity up (and down) does this. <S> If there is 'stiction' in the moving system (as, when a lubricating filmmust be reestablished by rotation), slow initial steps can help (butramping down doesn't) . <S> Steppers move in a jerky fashion, there is significant acceleration on each step, so it is common to use a compliant motor coupling (with some springiness) in order to smooth the rotation of the driven system. <S> In a system WITHOUT a compliant coupling, ramping might not be as effective.
The motor is loosing steps if it should accelerate faster than possible with its given force and the total rotational mass.
Convert a [0,5]V wave to [-2,2]V wave Using a PIC, I got a signal oscillating around 2.5V +-[0,2.5]V approximately. This is intended to generate a simple sound through a small speaker. The speaker, unfortunately works with 0V +-[0,2]V, and I expect the direct usage of 0-5V not resulting in the same sound (or even breaking the speaker). Consequently, I would need to displace the ground to 2.5 for the speaker. simulate this circuit – Schematic created using CircuitLab Could someone indicate me the direction for a solution? Current status: I did not managed to go very far, Using opamp, but they mostly threat the input voltage, so a negative voltage source is required. I should probably reminder how they work in case it is the solution. Splitting the voltage with resistors, but that did not convinced me due to attenuation. I finally looked for some LM317 to generate a ground at 2.5V; However, I am not sure if it would work when the wave provide "negative" values. <Q> Place a capacitor in series with your signal to remove the DC offset. <S> Maybe 10µF non-polarised. <S> You can then use a voltage divider (or potentiometer) as an attenuator. <S> simulate this circuit – <S> Schematic created using CircuitLab Note that driving a speaker direct is not recommended (and may not even work properly). <S> Instead you should use some form of power amplifier to provide the current the speaker needs. <A> Your output signal is 0-5V, or 2.5VDC +/- <S> 2.5VAC. <S> You can remove the DC content of a signal by passing it through an AC coupling capacitor. <S> The size of these components will depend on the frequency response desired. <S> C1 will tend to be large (in the uF range). <S> This tool can help you size the components: http://sim.okawa-denshi.jp/en/CRhikeisan.htm <S> simulate this circuit – <S> Schematic created using CircuitLab <A> If you're just making "beep" sounds, there's no need to use a fancy circuit. <S> The easiest to use are the piezoelectric transducers. <S> You can probably drive it directly with the PIC digital output pin, or user 1 transistor at the most. <S> Take a look at the datasheet for this part I randomly picked. <S> http://www.digikey.com/product-detail/en/tdk-corporation/PS1240P02BT/445-2525-3-ND/935924 <S> Piezoelectric transducers are resonant at high frequency so you'll need to use several kHz. <S> The simulation shows the circuit driving roughly 180 milliWatts into an 8 Ohm speaker at 500 Hz. <S> I hope that helps. <S> -Vince <A> There are so many circuits to drive a speaker. <S> The link here describes multiple ways of achieving your goal. <S> LM386 is widely used as an audio amplifier in hobby projects and interfacing circuits are easily available. <S> Depending on the power output requirement, suitable audio amplifier can be chosen. <S> The LM386 can easily drive a 8 ohm speaker. <S> The gain can be adjusted easily by proper biasing. <S> Another bunch of good solutions are here . <A> simulate this circuit – Schematic created using CircuitLab <S> Use an LM4865
You can attenuate by using a voltage divider. If you want to drive a real speaker and just make beeps but at wide frequency range, then you can just use a simple push-pull circuit with a large coupling cap.
What happens to the maximun operating ratings when the device is unpowered? I have a circuit with an OpAmp and a current transformer. My circuit applies a DC bias to the CT to be able to process the signal with an OpAmp with a single power supply, because the CT provides an AC signal. So far, so good. I am wondering about what happens when the circuit is unpowered but the CT is still connected. In this case I don't have a DC bias, so I could have ±1V RMS at the OpAmp input pin and its datasheet clearly specifies that absolute maximum ratings are -0.5V and Vcc+0.5V. This is not a problem when I have the DC bias working, but it will disappear when power is off. So the question is simple: what happens with this circuit when unpowered but the current transformer is still providing an AC signal? Should I do something like adding a FET in parallel to the current transformer to short-circuit the CT when no power is available? I am concerned about the OpAmp health and the transient at switch on/off. <Q> This is not good. <S> The protection diodes will be forward biased, and the power rail partially powered. <S> This might be OK, depending on what is connected to the opamp power and what exactly the datasheet says about this. <S> It might be acceptable to add diodes in series with the opamp power leads so that the ±1 V on the input pins doesn't try to power up the whole power net. <S> If you do this, make sure to put the bypass capacitors on the opamp side of the diodes. <S> However, a simple fix is to use a CT with half the gain. <S> Now it will produce only ±500 mV signals, which the opamp can handle when powered down. <S> You've got a amplifier in there anyway, so ±500 mV should be good enough unless you're doing something unusual. <A> You should add enough series resistance to limit the input current to less than 10mA. <S> You can exceed the +/-0.5V <S> if you limit the current. <S> I suggest limiting it to <S> well under 10mA so any spikes will not cause problems. <S> In fact, limiting the current to less than 10mA at the point where the CT saturates is exactly what I would do, because you may not be able to control what current flows through the CT primary under all possible conditions. <S> You could also use Schottky diodes such as BAT54 to shunt current away from the inputs, but such diodes tend to be leaky (possibly affecting accuracy) and you still have to ensure that the current is suitably limited. <S> Note the recommendation to limit input negative voltage under operational conditions. <S> This could cause start-up issues if you don't add the Schottky diode to ground in addition to limiting the current. <S> The suggested 1N5818 has more leakage than the BAT54, but has a better chance of limiting the voltage. <S> You might want to seriously consider using a different op-amp without this latch-up 'feature' if this is a complication. <S> It's the sort of thing that can cause you to pull your hair out with field problems. <A> The absolute maximum ratings for current into the op-amp's inputs states 10 mA <S> and here's where this helps. <S> If you don't feed the output of the CT directly into the op-amp input pin but instead, feed via a 1 kohm resistor, you will only potentially exceed the input current if the peak voltage from the CT exceeded 10 volts. <S> You can of course choose a resistor that is significantly bigger than 1 kohm; I was just giving an example. <S> Other than that you are quite right to be cautious in this situation. <S> Looking further into the data sheet this becomes clear: - <S> So, I would follow the recommendations shown. <A> What happens when Vin exceeds supply rail by 0.5V? <S> Nothing until the supply turns on and then the CMOS OA turns into an SCR crowbar across the supply rail if the condition still exists triggering an inherent PNPN substrate which is an SCR. <S> and draws as much current as possible, possibly frying it , until current is removed from supply. <S> ( read about CMOS latchup ) <S> You must specify your input environment and worst case transient with CT, Rb etc before you start ANY design. <S> In spite of this missing info... here are a few ideas. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> This is one of dozens of solutions. <S> In this example I use the source current to bootstrap the supply via D1,2 to prevent latch-up and current limit with 100k. <S> This of course adds temporary burden to the CT and saturation may cause be an issue, which invalidates this option , same for a Zener clamp. <S> ALWAYS SPECIFY WORST CASE TRANSIENT INPUT v,i, <S> t AND ADJUST DESIGN TO PROTECT <S> ALL INPUTS AND OUTPUTS BELOW ABSOLUTE MAX. <S> Op Amp Iq is < 150uA @5V thus Req=6k7. <S> The 1uF absorbs input transients due to impedance ratio. <S> U1 input is diode clamped internally but diode is limited to 10mA unlike external BAT54 which supports 100mA @0.5V
You are right, when the circuit is unpowered the CT output could violate the absolute maximum ratings of the opamp.
Should I consider debouncing my push button? Considering a +5V battery source, I have a set of input switches. These switches are push buttons which stay closed upon clicking and open upon clicking again. One side of a switch is connected to the positive side of the battery while the other is connected to a pull-down resistor, 10 kΩ specifically, and my combinational circuit.This circuit contains 74LS-series DIP ICs. With that set-up should I still consider debouncing my circuit or not? I'm thinking whether this set-up can affect one of my sequential circuit which send pulses when one input is clicked with the use of XOR gates, capacitors and resistors. <Q> Yes, you should consider debouncing your push button if the push button does not do this for you. <A> Some applications simply poll logic level periodically looking for a high or low state. <S> In those cases you might be able to get away without debouncing, but you need to study the specifics of the application. <A> You should debounce the switches if bouncing on opening or closing would cause trouble. <S> This really should have been obvious. <S> We don't know what's in the "output" block in your diagram, so we can't say. <S> It looks like you have a edge to glitch converter in front of it. <S> Bouncing switches would therefore cause multiple glitches. <S> Again, only you can say whether that's OK or not.
Generally, if you have a circuit that detects edges and triggers some action (counter, interrupt, etc) then you need to debounce, otherwise every edge of a bouncing switch will be counted.
How can I limit current on a 24VDC motor at start up? I am trying to lift a platform hydraulically with a mini power unit that has a 24VDC motor. We are using a converter box to convert 110VAC to the DC of the motor. These converters are only rayed to 40 amps. We have a roughly 200 amp, 24VDC inrush current that lasts between 0.5-1 second and it is too much for the motor at start up. I am desperately looking for a solution. I have looked at capacitors with no success. Someone suggested “soft start”/voltage regulators, integrated load switches, or thermistors. I have no knowledge or experience with any of these. I am not an engineer. I'm searching for solutions for my friend. Any help or suggestions would be greatly appreciated. GXC <Q> You need an inrush current limiter . <S> With the details you provided (voltage, current) <S> you should have no trouble picking out one that will work for your application. <A> Just use a DC Drive. <S> They inherently provide ramping, and current limiting. <S> There are several available for 24VDC motors, with various supplies, the most common being 24VAC, which can be provided by a simple transformer. <A> Using an NTC <S> (Negative Temperature Coefficient) <S> Thermistor as Adam suggests as Inrush Current Limiter is possibly a good solution as long as you are not planning to start and stop repeatedly. <S> An NTC in series in the circuit works as follows: <S> Initial State : NTC is "cold" -- <S> > "High" resistance Apply Voltage on circuit --> <S> You essentially get a voltage divider between the motor resistance and the NTC so less voltage on the motor windings --> <S> less current. <S> As current flows through the circuit, the NTC heats up, being a temperature dependent resistor, its resistance decreases --> more voltage is applied to the motor. <S> In steady state operation the NTC remains "hot" providing a supposedly "negligable" resistance to the circuit and all voltage is applied to the motor. <S> Durring steps 2 and 3 <S> you assume that the motor windings develop enough torque to overcome the initial startup requirements and <S> the motor starts turning so that <S> a Counter EMF is generated. <S> Depending on when that happens the NTC selected will be more or less effective on limiting the current to start the motor. <S> If you stop the motor , the startup conditions of the motor will be similar to the first startup, but the NTC will need to cool down before being able to provide the same initial conditions. <S> How much will depend on the NTC parameters, ambient temperature and the motor startup torque requirements amoung others... <S> If you plan to start / stop frequently , you could: to reduce the time to cool down I would suggest increasing the surface area of dissipation of the NTCs by using more NTCs (series/parallel) that satisfy the circuit requirements. <S> You could incorporate another switch to bypass <S> the NTC once the current requirements enter within the range of your converter, thereby allowing the NTC to start cooling down earlier. <S> Cheers
Incorporating a bypass switch will also allow you to extend the solution to use plain power resistors too, on their own (perhaps with multiple stages) or in conjunction with NTCs.
How to turn on LED with only a cathode pin I'm looking at the datasheet for some TIL311 hexadecimal displays which I ordered (but have not yet arrived. (Actually they appear to be TIL311 clones, but should be compatible.)) According to the datasheet, the left and right decimal point LEDs have their cathodes exposed via pins 4 and 10. The anodes are not connected to a pin; I assume they are hardwired to Vcc within the IC. I want to turn the decimal point ON when I have +5v on a certain wire. Am I correct in thinking that the right way to do this would be to use a discrete transistor to allow current to flow from the cathode to ground when it (the transistor) turns on? If so, what's a good kind of transistor to use? Or is there a simpler way that I haven't thought of? <Q> Read carefully the datasheet. <S> The info you are looking for is there. <S> Therefore the two decimal point LEDs are connected between pin 1 (LED supply, common for both) and the two cathode pins (4 and 10). <S> Then it's up to you how to power them up. <S> If you want to control them independently, you just wire pin 1 to a suitable positive power rail and put any switching device between each cathode and ground. <S> It may be a BJT, a MOSFET or even a relay. <S> If you want to control them via a MCU GPIO pin, you can also connect it to that pin(s), as long as the MCU can sink enough current (of course you must add a limiting resistor in series). <S> Since the datasheet reports a 5mA recommended operating current for DPs: <S> you may be confident that many modern MCUs can sink <S> that much current (for example a GPIO pin of the ubiquitous Arduino boards, from its ATmega328P MCU, can handle it without problem). <S> For example: drive the GPIO pin LOW to light up the decimal point whose cathode is connected to pin 4 of the display. <A> You could use a low-side NPN transistor (e.g. 2N4401) or N-channel MOSFET (e.g. 2N7000). <S> Connect the switch's emitter/source to ground and feed an on/off signal to the base/gate through a resistor (say 10~100 Ohms). <S> Unless you want it always on -- then you could just connect a resistor to the dot pin to ground (again, ~1k Ohm). <A> The datasheet schematic and description tell you all you need to know. <S> The anodes of the decimal point LEDs are connected to the supply and you need to provide current limiting. <S> The other LEDs are controlled at 5mA more-or-less. <S> I do not see a spec for decimal point forward voltage, but it should be about 1.8V for a red LED, so a resistor of about (5V-1.8V)/0.005A <S> = 640 ohms (use 680 as the next highest standard value) should be fine. <S> With 5mA collector current, your base should get something like 1/20 of that, so that's <S> 250uA. Vbe is about 0.7V so a base resistor of (5V-0.7V)/250uA = 17.2K (you can use 10K or 15K) will work well. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> When the input is at 5V, the 280uA or so base current turns Q1 on, 5mA passes through the decimal point LED and it illuminates.
Connect the dot pin to a resistor (~1kOhm), and connect the other end of the resistor into the switch's collector/drain.
select any 2 of multiple inputs I am trying to input any two of six sensor outputs to a microcontroller that has only two compatible ports. My first idea was to use two 74hc4051 8:1 MUX IC's but it would require 3+3=6 selection pins. However, since I am trying to select any two of six, there are 30 possibilities and therefore 5 selection pins should suffice (logically). Is using two 74hc4051 kind of "in parallel" ok? Is there a way to solve this problem with only using 5 selection pins? Thank you. <Q> Some ways to address this problem: Get a bigger microcontroller. <S> Use the micro you do have more intelligently. <S> You apparently have a total of 7 connections to the micro available, since you say that two inputs and 5 select outputs would work. <S> Very likely the 5 output pins you would use for picking the selection can be configured as digital inputs. <S> Step back and think about this at a higher level. <S> Your question smells strongly of being about the details of a particular way to addressing the problem, when the right solution is to address the problem in a different way in the first place. <S> To actually answer this (rather contrived) question, you have 30 possible mux configurations, so it is possible to encode those in 5 bits. <S> However, decoding from the 5 bits to the 6 separate mux control lines might be more complicated than you are willing to do. <S> In the arbitrary case, this can be done with a lookup table (memory) that has at least 5 address lines and 6-bit words. <S> Now you have the additional problem of getting the data into this memory somehow. <S> Another option is to multiplex the 6 bits into the two muxes. <S> You could do this with a 3-bit data bus and two separate clock lines for latching the data bus value in front of each of the mux select inputs. <S> It may also be possible to find muxes with a serial interface like SPI and IIC, but I haven't looked and have never used such chips. <S> The 6 mux control lines could come from a shift register with a output latch. <S> That would only require 3 data lines from the micro: Data, Clock, and Latch. <A> One way is to feed the select inputs of a 8-to-1 mux with 3 select lines. <S> Then use a 3-bit adder with carry-in set to 1 and feed it with the original 3 select lines adding them to another 2 select lines. <S> Feed the adder outputs to a second 8-to-1 mux. <S> Now you can route through any two inputs with 5 select bits. <A> Actually imho the number of valid combinations works out to 6x6 = 36, if the conditions are that ANY 2 of 6. <S> This includes duplicates - hence the extra 6 over your 30. <S> However if the constraint of double's and of "reverse pair's" is eliminated, then there are actually only 15 unique combinations. <S> Just some food for thought. <S> Also, it would be useful to know what these signals are, and how they are being used. <S> Based on this some entirely (i.e. simplified) method might be discovered. <S> And lastly - if none of the above is valid, then the solution's proposed by Dave Tweed (shifter's) is probably the simplist.
Just connect the 6 signals directly to 6 micro pins, then do whatever selection you want to perform in firmware. Consider what you are really trying to accomplish, without assuming a particular way of accomplishing it.
Is my pull-down resistor value correct? I'll be using a momentary push button, SW1 as shown in the figure. With that, I also decided to make a D flip-flop act like a latch by connecting the switch to the clock. My question is if my pull-down resistor value is correct. I'll be using 74LS DIP IC gate specifically HD74LS74A . According to the data sheet, the V il is about 0.8V while the I il for the clock input is 0.4mA. Based on my readings in forums, I divided the two resulting to 2KΩ. Should I aim for 2KΩ or should I use a higher or lower value for the pull-down. Sorry I'm not very familiar with this topic. simulate this circuit – Schematic created using CircuitLab <Q> You are making a small mistake. <S> Your V(il) reading is a maximum, so anything below it is okay, but above might not be seen as a low input. <S> You can also see that the I(il) input current is negative, which means current comes out. <S> So your pull-down resistor will need to be lower to guarantee operation. <S> However, you can also put the switch in the bottom part, since a switch has a very low resistance when pushed, and then put a 1k to 10k pull-up resistor. <S> Because you can see that the minimum input high voltage is only 2V and that the current it draws at a high input is ten times as small. <S> That would look like this: simulate this circuit – <S> Schematic created using CircuitLab <S> With 40μA sourced sunk by the clock through your pull-up, the 10k will only lose 0.4V, which gives 4.6V. <S> Very well above the minimum input high voltage. <S> When you push the switch, that's likely less than 10 Ohms to ground, so with 0.4mA <S> coming out of the clock <S> the voltage will nearly not be above ground. <S> 4mV is very negligible in digital circuits running on 5V. Even in 3V3 and 1V8 circuits 4mV is assumed 0. <S> Last Edit <S> Of course, if your data depends on the clock (such as with a flip-flop driven toggle circuit), you will soon find you also want a capacitor in there. <S> If you put in a capacitor next to where ever your resistor ends up being, you will smooth out accidental multiple pulses. <S> We call those accidental pulses when we talk about buttons "contact bounce". <S> It's a very common thing and should be very easy to find on this site and Google. <S> With 10k, you would need between 100nF and 1μF most likely. <S> Also depending on the button type and such. <A> Having the switch to Ground also reduces the current consumption when the switch is open. <A> However I'd suggest you should not implement the switch this way. <S> Your switch may be some distance (inches or more perhaps) from your logic PCB, and it is poor policy to run a supply voltage ( <S> +5 VCC in this case) to any panel mounted switches. <S> The reason is that any short to Gnd will potentially short out your supply voltage. <S> This might not damage your logic or power supply, but it will cause a reset or malfunction of your logic. <S> I'd suggest the following if you want to use an LS7474 device: <S> simulate this circuit – <S> Schematic created using CircuitLab Notice in the schematic above the *SET input would be pulled low by the switch, and would actually set the 'Q' high (if it was not already so) immediately. <S> The circuit is immune to switch bounce, and the Q remains set until cleared by your other logic or microprocessor pulling the *CLR low. <S> Notice from the datasheet that if both *CLR and *SET are pulled low at the same time, the Q output remains high until either *CLR or *SET go back to one, where the state of Q is defined by the last one to go high. <S> Your circuit as shown shows no way to set 'Q' to an initial state, or to clear 'Q' after you have read/used the value. <S> This one above uses the *CLR to initialize or reset Q. <S> The 2k used as a pullup is a rather arbitrary selection. <S> It's best to have some current flow in the switch (it's called a wetting current) and in this case you will have 2.5 mA from the 2k and 0.8 mA from the *SET for a total of 3.3 mA in the switch when depressed.
Since bipolar TTL (74nn, 74LSnn, 74ALSnn) inputs source current, it is recommended practice to put the switch between input and Ground, with a pull-up resistor of 5 - 10K. This way, when the switch is closed, the input is very definitely a Low, with no need to hope that the pull-down resistor value is low enough resistance to guarantee that the input will be seen as Low. Your 2k Ohm value is only correct to set an absolute maximum V(IL) value, you should make it less than 2k to ensure you generate a lower voltage than the V(IL) spec for the device.
What is this PCB (IC?) connector called? Can anybody tell me what this connector is called and how I could purchase one for my own prototype board? This is a picture of a Nintendo Wii motherboard (bottom) and the bluetooth adapter (top). I'd like to connect this bluetooth adapter to my own board for a project I'm working on so I need a connector like the one on the motherboard. Here is another picture of both the board connector and module plug: Thanks for any help! <Q> It is very similar to the Hirose DF40 surface-mount "riser" connector. <S> But I don't see any 16-pin versions. <S> I wonder if that isn't a 20-pin version with the two end pins missing from each end? <S> Ref: https://www.hirose.com/product/en/download_file/key_name/DF40/category/Catalog/doc_file_id/31649/ <A> If the quest is to find the connector type only, then it is very close to the slimstack connectors from Molex. <S> http://www.molex.com/molex/products/family?key=slimstack_fine_pitch_smt_board_to_board_connectors&channel=products&chanName=family&pageTitle=Introduction&parentKey=board_to_board_connectors <S> Images for reference: 16 pins are available. <S> Unless p itch and mated height is known, a single part cannot be identified. <A> Just to add, although I know it's been a while. <S> I've measured it and the exact part number is Molex 0541020164. <S> https://www.digikey.com/product-detail/en/molex-llc/0541020164/WM8876CT-ND/3197306 <A> I call them "board to board" connectors. <S> Connector of this style have become very common in laptops, etc, and are made by all the usual connector companies in a variety of sizes and stacking heights. <S> " You might be able to determine the manufacturer and model of those with enough detective work.
You can search Digi-Key.com under the connector subcategory " Rectangular - Board to Board Connectors - Arrays, Edge Type, Mezzanine .
Total power conservation in transformer Does the equation V1 X I1 = V2 X I2 hold for a transformer when coefficient of coupling is less than unity? Or does the coefficient have no relevance? <Q> The equation is for an ideal transformer. <S> The efficiency of a transformer is defined as the ratio of the output power to the output power plus the losses. <S> The losses depend on the transformer application circuit. <S> For example, a heavily loaded transformer will have more loss due to the winding resistance. <S> The coupling coefficient does appear in the efficiency calculation, so yes it is relevant. <S> However, the coupling coefficient is often translated to 'leakage inductance'. <S> There is a straightforward calculation to translate coupling coefficient into leakage inductance . <S> See the Radiotron Designer's Handbook Fourth Edition page 204 to 206 for how to calculate transformer efficiency accounting for leakage inductance and other losses. <A> Such a transformer can be modeled as an ideal transformer with an ideal inductor in series with the primary and/or secondary. <S> There are no energy loss sources in that arrangement, however the voltage will drop as more current is drawn and the current will lag the voltage by more than it would be with an ideal transformer. <S> So the regulation is negatively affected. <S> Transformer energy losses come from core losses and copper losses. <A> Your title is this: - Total power conservation in transformer <S> But you are talking about VxI in the body of your question and <S> this isn't necessarily power (watts that can heat up something and that consumers are billed for). <S> If your question was "is power conserved when the coupling is less than 100%" then the answer is YES with the normal transformer provisos/smallprint: - No copper losses No eddy current losses <S> No core saturation <S> OK going back to VXI not being true power: - What you appear to be describing in the body of your question is apparent power and not real power . <S> With apparent power (VA), and less coupling, the output VA falls whilst the input VA doesn't fall by the same amount. <S> But, the bottom line is that if transformer losses can be ignored, output power will equal input power just as it is for a 100% coupled transformer.
There is no inherent energy loss resulting from a coupling factor of less than unity.
Opamps used in low voltage applications How is it possible to use op amps on a supply of (+3v), for example: mp3 player and other battery operated devices? What type of op amps do we use in low voltage applications? How is it possible they have such a big output voltage in relation to the supply voltage? This is my first time dealing with op amps in low voltage applications. I'm grateful for any kind of feedback. <Q> They tend to be called rail to rail, or R2R amplifiers. <S> They can be R2R on input only, output only, or both. <S> Many use CMOS internally, though bipolar designs also exist. <S> With low voltage gadgets, their creation has been a necessity. <S> In the bad old days, high voltage rails were the norm (+/- 15v), and bipolar designs happily stayed a volt or three away from the rails. <S> You can't do that with battery powered devices today. <A> How is it possible to use opamps on a supply of (+3v), for example: mp3 player and other battery operated devices? <S> A supply voltage of 3.3V is actually quite high for integrated circuits. <S> Voltages on the order of 1.2V to 3.3V are quite common. <S> what type of opamps do we use in low voltage applications? <S> The input stage is often standard, since the common-mode voltage can be set to a fixed level. <S> The final stage of such an opamp looks like an inverter (push-pull stage). <S> The tricky part is controlling the quiescent current. <S> Such output stages are called rail-to-rail. <S> how is it possible <S> they have such a big output voltages in relation to the ? <S> supply voltage? <S> Outputs are differential. <S> We don't have one output fixed at 0V and the other moving, but both outputs moving up and down. <S> So the amplitude can be almost equal to the supply voltage. <S> This gives four times the output power compared to a single-ended output. <S> If that's not enough a boost converter is required. <S> There is no way around that. <S> For audio <S> (MP3 players, if they still exist) the output signal is usually generated using a class-D amplifier. <S> Here the output is switched on and off to generate a PWM signal, which results in a higher efficiency. <A> How is it possible to use opamps on a supply of (+3v), for example: mp3 player and other battery operated devices? <S> Bipolar transistors in linear operation probably only need about 0.6 volts to operate properly at the base and maybe 1 volt across collector to emitter to yield a usable output voltage range. <S> MOSFETs need a little more but not much more. <S> Both/either are used in op-amps. <S> what type of opamps do we use in low voltage applications? <S> We have to use what are called rail-to-rail opamps because these are specifically designed to maximize the range of the low voltage available for powering the device. " <S> Rail" aka power supply rail or supply voltage. <S> how is it possible <S> they have such a big output voltages in relation to the supply voltage? <S> They can only produce output voltages within the power supply range. <S> For instance, if the power rails are 0V and 1.8 volts then the output will be limited to a range of 20 mV to 1.78 volts (under no-load conditions). <S> Some are worse than others of course.
For a given load impedance and output power a certain voltage is needed.
NOT gate with transistor schema http://www.electronics-tutorials.ws/logic/log47.gif?x98918 When A is powered, why does the current go to the ground and not to Q? <Q> For the purposes of the NOT gate, you are looking at voltage and not looking at the current. <S> The next "logic unit" that follows will be designed to consider the voltage at OUT, not the current. <S> Mostly. <S> In order to consider the voltage, the next circuit will necessarily sink or source a little current (into or out of OUT.) <S> So in reality some current also actually does get exchanged through the OUT pin. <S> And the more logic unit inputs you tie to this output, the larger this current becomes. <S> At some point, the circuit you show won't be able to properly do its job. <S> So there is a limit called "fanout." <S> But for understanding it, you only need to realize that it is the voltage present at OUT, not the current, which defines the meaning of OUT. <A> Therefore the current cannot flow through to Q. <S> When current flows between the base and emitter, the transistor "switch" closes, connecting Q to ground. <S> Effectively the transistor becomes a very low value resistor on the low side of a voltage divider (made up of the transistor and R2). <S> When your low-side resistor in a voltage divider is a MUCH lower resistance than the high-side, then the voltage on the output (Q) is pulled very low (close to ground, or 0V). <A> Assuming a load with a certain impedance is connected to the output, current will flow to it whenever A is off (0V). <S> This is because it follows the lowest impedance path. <S> With a NPN, there will be a small amount of current flowing to the ground. <S> With a NMOSFET, it would flow directly to the output whenever 0V are applied. <S> If 5V are applied to the base (gate for MOSFETs), you will create a current path between collector and emitter. <S> Thus, current will follow this low impedance path rather than going through the high impedance path which would be your load. <S> Note that you will most likely have a small amount of current going to Q <S> but it would depend on the load resistance and how you design your circuit.
The current from A only flows one direction (through the emitter to ground) because the base-emitter junction of a NPN transistor is effectively just a diode.
What effect does using a termination resistor that is larger than the characteristic impedance of the transmission line? I have seen that when terminating an RS422 point-to-point connection, you should terminate the signals with a parallel resistor that matches the characteristic impedance of the transmission line. Most sources recommend 100-120ohms. I saw another post here that mentioned the effects of using too small of a terminating resistor, but what happens if you use a terminating resistor that is double, or 10 times the value of the characteristic impedance of the line? <Q> On an open end, a short pulse will be reflected and travel back the line. <S> On a shorted end, a short pulse will also be reflected, but inverted, too. <S> A resistor dampens this effect, i.e. the amplitude of the reflected signal will be smaller. <S> And for a certain value, the pulse will not be reflected at all. <S> This is the value used for termination. <S> Usually, transmitted signals are not short enough to be reflected completely, but every edge would cause a reflected pulse, which causes all kinds of trouble. <S> See also <S> What and Why's of termination? <A> This recent question mentions a way of estimating this graphically. <A> Infineon's application note <S> EMC and System-ESD Design Guidelines for Board Layout has simulations for various parallel termination resistors, which show that you'd get more ringing:
If the resistor is too large, you will get incomplete damping of the fast edges of the signal, resulting in increased "ringing" and longer settling times.
How to get -5 to 5V with AD5668 I'm more programmer than electrical engineer. I have connected Arduino with AD5668. I want to control analog synth such as Korg MS-20M. For the filter, it takes -5 to 5V. Right now I can generate only 0-5V with digital values 0-65535. I want to generate -5V to 5V straight out of Arduino with digital values 0-65535. AD5668 takes a reference voltage. Right now I supply it 5V from Arduino. Could this be a solution? To supply -5V reference voltage? I would like to make some simple DIY solution hopefully without any new parts in the circuit. I was thinking that AD5668 has all the required in itself like OP-AMP, but I guess it does not generate smooth -5 to 5V voltage. <Q> The AD5668 takes a single ground referenced 5v supply, and produces several ground-referenced 0 to 5v output voltages. <S> It interfaces directly to a ground referenced Arduino. <S> If you are going to ride the horse in the direction it's going, you keep those components ground referenced, and supplied with a single 5v. <S> The AD5668 only produces a 5v swing, and you want a 10v swing. <S> Even if you could shift it below ground, you won't get the swing you want without further components. <S> The simplest way to build on what you have is to follow the 5668 with an op amp supplied with at least +/- <S> 5v rails (if you use a rail to rail type) or higher than that (if you use an older style opamp). <S> A gain of 2, with a shift, is quite easy to come by. <S> This is just one solution, which inverts the sense of the output. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> Ideally the 5v offset reference and the DAC reference will track, to minimise shifts with temperature or power supply voltage variations, so have a 5v reference which also supplies the DAC reference. <S> If you still want to use the DAC internal reference (I always do, they're usually good enough for all but the very highest stability), you could dedicate one output channel to providing the reference for the other channels, or indeed use the 2.5v refout feature. <S> Where you use one channel, it would be better to eliminate all the R1, R2 components completely and provide a programmed 1.667v reference directly to all the +ve amplifier inputs. <S> That would give you 7 channels of -5 to +5 control, with just two quad amplifier packages. <S> Where you use the 2.5v refout, divided it down to 1.667v by using R1=10k, R2=20k. <A> The reference voltage has to be essentially within the supply rails. <S> Applying -5V will destroy the chip. <S> If you need -5 to +5 you will need to add an amplifier/level shifter at a given output- to multiply by 2 and add a suitable offset. <S> That will require a negative supply of at least -5V <S> (you won't quite get to +5 or -5 with a +/-5V supply). <S> Here is how I would do it with this particular chip (-2 version with 0-5V out): simulate this circuit – <S> Schematic created using CircuitLab <S> You only need one reference buffer (OA2) but you do need one amplifier per output. <S> The output op-amps require power supplies of <S> at least +/-5V. <S> If you use closer to <S> +/-5V <S> you will need rail-to-rail output and input common mode range must include 3.33V. eg. <S> OPA2188. <S> You do need the reference buffer because the output impedance of the internal reference is 7.5K ohms. <S> The stability will only be as good as the reference, so using the internal precision reference makes a lot of sense. <S> If you were to use the power supply you would add a lot of noise and imprecision into the output. <S> If you want high accuracy commensurate with the 16-bit DAC you can use a single precision resistor array for the two pairs of resistors such as a Vishay ACASA1002S2002P1AT . <A> To convert a unipolar DAC output to a bipolar DAC output requires an op-amp interconnected with the REF pin like this: - The example above is for a different DAC but the technique is standard for unipolar DACs. <S> I would use supplies slightly bigger than +/- <S> 5V for the op-amp just to ensure full coverage and avoid the need for rail-to-rail op-amps. <S> Even if you are using the internal reference the data sheet says it is available: - The AD5628/AD5648/AD5668 have a common pin for reference input and reference output. <S> When using the internal reference, this is the reference output pin. <S> When using an external reference, this is the reference input pin. <S> The default for this pin is as a reference input. <S> Note that the reference out is only 2.5 volts and here's ADI's take on getting a bipolar <S> +/- <S> 2.5 volt output using an op-amp if you used an external 2.5 volt reference (or the internal 2.5 volt reference): - Note that the circuit to the left generates a bipolar supply from 12 volts. <S> Circuit taken from ADI reference design <S> CN0183
The AD5668 can only supply 0-5V at its outputs (or 2.5V if you use the -1 version with internal reference).
Understanding voltage and current of a phototransistor w/ collector resistor I want to study the circuit of an Infrared proximity sensor, so I assembled a circuit with an infrared LED (940nm) and a phototransistor. When no current passes from the LED, obviously the phototransistor is switched Off, thus the whole amount of current passes from the A0 branch. In that case I read from A0 a 1023 value which is equal to 5V for a 10bit ADC (Arduino). When current passes from the IR Led, thus the Led is on, the phototransistor should be switched On, thus a considerable amount of current should pass from the phototransistor to Ground. Yet, even if LED and phototransistor are positioned extremely close, I read from A0 a value no less than 900, which means that only a 10% of the total current reaches the Ground. I expected (and desired) when the IR Led is On, the value of A0 to be near zero, thus the phototransistor to be fully open and almost the whole current to pass from it. Do I miss something there? Should I change something to the circuit or the components, in order to get an almost clear 0V or 5V? <Q> Read the datasheet . <S> It should tell you what the expected phototransistor current will be. <S> That is apparently not enough to cause 5 V across a 10 kΩ resistor. <S> Do the math . <S> At full illumination, the A/D reads 900 out of a 0-1023 full scale range, which is 5 V. <S> That means the output is at 4.4 V, which means that there is 600 mV across the 10 kΩ resistor, which means that the current is 60 µA. <S> That is apparently the current your phototransistor can support with the illumination you are supplying. <S> There are several things you can do about this: Nothing . <S> As things are now, you can read the illumination to one part in 123, or basically 7 bits. <S> Is that perhaps already good enough? <S> What are you really trying to measure. <S> For many applications, 7 bits plenty. <S> Use a larger resistor . <S> In this case, the pullup resistor is being used as a current to voltage converter. <S> You can think of the resistance as being the gain of the conversion. <S> A 20 kΩ resistor would give you twice the voltage, for example. <S> The downside to this is that the impedance of the voltage signal goes up. <S> Check the A/D datasheet to see how high a source impedance it is specified to work with. <S> For some A/Ds, higher source impedance can be tolerated if the acquisition time is lengthened. <S> Again, consult the A/D datasheet to see what your A/D needs. <S> Amplify . <S> You have a 600 mV signal that you want to be closer to a 5 V signal. <S> That's exactly what amplifiers do. <S> In that case, I'd probably flip the phototransistor and resistor so that the signal starts at 0 V with no light and goes up with more light. <S> A gain of 8 would just about do it. <S> If the value at low light levels is important, then make sure to use a opamp that can handle signals down to ground on both the input and output. <S> Or, use a small negative supply from a charge pump or something so that 0 V is well within the opamps linear region. <S> Use a higher resolution A/D . <S> Many microcontrollers have 12 bit A <S> /Ds built in nowadays. <S> Changing only the 10 bit A/D to a 12 bit A <S> /D gives you 4x the resolution, or about 9 bits in this case. <S> Is that enough? <A> You may be misunderstanding the way in which the circuit is working. <S> The Arduino's analog input pin should have a high impedance, and so should have little effect on the action of the circuit. <S> So, to a close approximation, all the current in the circuit runs from the +ve supply, through the 10k resistor, through the phototransistor, to ground. <S> The thing that is varying is the current that the transistor is allowing through. <S> The more photons hit the transistor, the more electrons it lets through. <S> Realistically, the voltage across the transistor will never be zero - because it's a transistor not a switch. <S> And the current it lets through will be limited by the amount of light you can shove into it. <A> The voltage across the phototransistor cannot go to zero, even if hit with a many-watts IR laser. <S> The Vce(sat) from your phototransistor specsheet is 0.8V. <S> So, if Arduino gives 1023 for +5v, that means the very lowest reading for your transistor (when in bright sunlight, etc.,) the Arduino would report a value of 164 <S> ( = 0.8/5 <S> *1023). <S> If replacing the 10K with a 330K doesn't fix the problem, then use a voltmeter to check the actual voltage across the phototransistor. <S> How low does it go when the IR LED shines upon it? <S> Also try blasting it with an old-style non-LED flashlight, also a 100watt incandescent bulb, or some outdoor sunshine. <S> And, power up two or three of your IR LEDs, and aim them all at the phototransistor. <S> Verify that Arduino D/ <S> A input pin is actually measuring a 5V span when reporting 1023: for example, feed it 1.6v from a new alkaline cell, and see if it reports approximately 330 ( = <S> 1.6/5 <S> *1023). <S> Feed it 0V and make sure it reports a value very close to zero. <S> PS Add a vis-red LED in series with the 10K resistor. <S> That way you can "see" any changes in the phototransistor current. <S> Once you figure out the original problem, next try connecting an IR LED in series with the phototransistor, then aim them at each other. <S> It becomes a flip-flop which detects IR light. <S> A brief pulse of ambient IR light will turn on the circuit, and then it keeps itself turned on via the IR LED. <S> Then to turn it off again, you have to momentarily turn off your LED (or stick cardboard between the two.) <S> Also add a vis-red LED in series, so you can see this happening without an Arduino or a voltmeter.
Your circuit is measuring the voltage across the transistor, which is equal to 5V minus the voltage across the resistor, at whatever current the transistor is allowing through .
positive and negative voltages from power supply How to get +ve and -ve voltages from the single power supply which doesn't have the functionality of +ve and -ve voltages. I have tries with the voltage divider circuits with two 10 Kilo Ohm resistor with the 10V supply because i want to have the +5V and -5V but after having this circuit the voltage fluctuating constantly. <Q> You can make a rail splitter like this: - It (more or less) actively "fights" to keep the output terminal (VGND) half way between the upper and lower power rails. <S> The problem with just using resistors is that they obey ohms law and, if you start to draw current, the voltage shifts towards one rail or the other depending on the direction of current flow. <S> You can also gets chips to do this such as the BUF634: - It works with power rails from a couple of volts to +/-18 volts and can deliver 250 mA BUT be aware of power restrictions and heatsinking. <S> For lower power applications, a simple op-amp with do the job. <S> Depending on what current draw you want try <S> this google search for circuit images. <A> Tie the + output of that supply to the ground you already have. <S> Now the - output of this second supply is your negative supply. <S> For low currents, a charge pump might be all you need. <S> You can make one easily from a couple of transistors, diodes, and capacitors if you already have a square wave someplace. <S> That someplace could be the clock output of a microcontroller, for example. <S> There are also dedicated charge pump chips that you only provide the capacitors to. <S> For higher currents, a switching power supply with inductor is more suitable. <S> There are chips for this too. <S> You will have to supply the inductor, input cap, and output cap. <S> Depending on the chip, a few other parts may be needed too. <A> A dual-output supply is usually best. <S> Assuming you want to stay with the 10V supply: You can use a rail-splitter such as the TLE2426 to accomplish this, as an alternative to the voltage divider. <S> Read the datasheet carefully if you go this way. <S> It's also possible to use an op-amp but any output capacitance needs to be decoupled lest it lead to tears and much gnashing of teeth.
If you are stuck with one DC input power voltage, then you can make a negative voltage easily yourself. The first answer is to get another supply.
Earth Grounding an HV Power Supply I'm using a Matsusada HV Power supply up to 20 kV. The manual mentioned that the ground terminal of the chassis should be connected to earth. And I had a few questions What are the best, or at least acceptable, ways to make this connection. Would it be OK to connect it to the earth ground in the power outlet? If so, is there some sort of adapter or tool that makes it safe to access the earth ground from the power outlet? I'm wary of poking around outlets. Is there a reason why the user manual instructs the users to make the earth ground connection? Doesn't the instrument have access to earth ground through the power outlet via the AC power cord? The only reason I can think of is that they don't trust all buildings to be connected properly. Thanks <Q> Consider this scenario: While the power supply is turned on and outputting a high voltage, somebody abruptly removes the power cord. <S> This would break the "protective bonding" provided through the power cord. <S> However, capacitors inside the supply, or in whatever its output is connected to, could still hold a high voltage. <S> It could take seconds or longer for such capacitors to discharge. <S> If there is a leakage path from the high voltage to the case, the case could become hazardous during this time. <S> Having a second earth connection reduces the risk in this scenario. <S> I don't know which safety standard <S> this supply is designed to, but I have access to IEC 61010, which is the safety standard for many kinds of test and measurement equipment, and other safety standards tend to have similar requirements. <S> In section 6.5.2.2, 61010 requires, Equipment using PROTECTIVE BONDING shall be provided with a TERMINAL that is suitable for connection to a protective conductor and meets the requirements of 6.5.2.3. <S> And in section 6.5.2.3, b) <S> The integral protective conductor connection of an appliance inlet shall be regarded as the PROTECTIVE CONDUCTOR TERMINAL. <S> c) <S> For equipment provided with a rewirable flexible cord and for PERMANENTLY CONNECTED EQUIPMENT, the PROTECTIVE CONDUCTOR TERMINAL shall be located near the MAINS supply TERMINALS. <S> I'm not certain, but this distinction between an "integral" and a "rewirable" protective conductor or flexible cord may be why a device using a removable power cord might be required to have a separate protective conductor terminal. <A> I agree with @ThePhoton overall. <S> The earth pin in the IEC connector should be an extremely low resistance path to the chassis ground stud. <S> How you connect the supplemental earth depends on your lab setup. <S> A permanent, sealed mechanical bond (nut, bolt, and washers) between cleaned surfaces (buffed and cleaned with alcohol) is ideal. <S> That level of rigor is probably not necessary in this application. <S> The scenario @ThePhoton described will happen somewhere eventually, but it's still an unlikely event. <S> If your power supply is sitting on a shelf and not moving, there is about zero probability that the IEC connector will fall out. <S> For short term use, the earth pin of a socket is safe to use because it connects to the dirt outside. <S> (Unless your building is heinously, illegally, dangerously miswired) Just stay away from the live and neutral. <S> Put some insulating tape over those sockets. <S> I'm not convinced that's a highly reliable connection, but you could try using that screw to attach a ring terminal connector to earth via the junction box. <S> If you're going to install the power supply permanently or semi-permanently, you need to know with confidence that that connection is robust. <A> The Japanese have several (at least two) different mains power distribution systems -- one at 60 Hz and one at 50 Hz. <S> This wiki page says the boundary between the two regions contains four back-to-back high-voltage direct-current (HVDC) substations to interconnect these two power grids. <S> These systems are grounded using a Terra-Terra grounding approach and often, but not always, with an entrance GFCI at each customer site. <S> I suspect this separate ground lug may be present to deal with power distribution systems similar to those found in Japan. <S> Why don't you contact Matsusada and just ask an appropriate engineer there? <S> I'm pretty sure you will get a meaningful reply from them. <S> As a separate note, I think it's very unlikely the power inlet will be a danger when the plug is removed. <S> But given the voltages involved, that's something else I'd test (even after properly attaching to the grounding lug, if appropriate.) <S> I'd want to know if there is any possibility of accident due to pulling the plug out of the wall and touching any of the exposed, presented contacts. <S> And it's simple to test. <S> Worth doing, just in case.
The screws that hold outlet cover plates on typically screw into the junction box, which is earthed. Any other arrangement would be irresponsible, dangerous, and probably illegal.
Changing DB9 Gender: Crossover or Straight? I have a USB-DB9(Male) that needs to communicate with a device that has a DB9(Male) port. Do I connect both DB9(male) ports together using a null modem (crossover) cable or a straight through cable? Pinout of device is here . Pin 2 is Transmit, Pin 3 is Receive. Pinout of USB-RS232 cable, I assume is the same pinout as the one found on computer motherboards. Pin 2 is TX, 3 is RX. <Q> The only way to be sure is to measure the voltage on pins 2 and 3 with a multimeter while the device is powered up, but otherwise idle. <S> The pin that is functioning as an output (regardless of whether it is called "Transmit" or "Receive") will have a definite negative bias on it (anywhere from -5V to -12V typically), while the pin that is functioning as an input will be close to 0V. Connect the input pin of the device to pin 2 of the PC (or USB to RS-232 adapter), and connect the output pin to pin 3. <S> After looking at Table 9 in the manual, I think that the description of the two cables strongly hints that the device is DCE, which means that you'll need a straight-through cable. <A> This depends on whether the devices are "DTE" or "DCE" . <S> If they're both computers, you need a null modem. <A> I would try without cross-over first, and if you don't get a response, try crossing tx and rx. <S> I used to have a set of gender changers, cables and null-modems with me at all times, before USB...
If one of them is a modem, or modem-like device, then you don't. RS-232 is often a case of trial-and-error.
Sealed, long, thin glass tube with two wires and tiny filament - what is this? I found this thing, and have no idea what it is. The tube is 30 mm long, about 5 mm in diameter. Both terminals are connected with two drops of glass. There seems to be a tiny wire or filament connecting both wires inside the tube. Any suggestions? <Q> I'm thinking more like RTD. <S> With a thermocouple, the two leads would be two different materials. <S> With an RTD, the very thin wire at the tip would be platinum, and its resistance would change in a calibrated way with temperature. <S> Can you put it under a microscope of some sort? <S> I bet you'll find that there's a very tiny coil of the very fine wire embedded in the glass at the very tip. <A> Looks like a "glass bead" style of thermistor. <S> Very common, but usually much smaller. <S> Does your DMM read it as resistor? <S> Ohms changing when warmed with fingertip? <S> Maybe it's a replacement part for a liquid probe. <S> Not hollow. <S> Aha, here's one. <S> Also another. <A> Probably a thermocouple. <S> Put a mV meter on the leads, put your finger on the tip and you should measure some 10s of mVs. <S> Take your finger away and the mV should drift down to 0. <A> Curious. <S> Maybe it's intended to break and open the circuit under some conditions such as shock (mounted with a weight, for example).
Usually the glass bead thermistors look like a tiny glass sphere w/thermistor inside, or a thin solid glass rod with a little sphere at the tip. Some pH electrodes look a bit like that. Some hint as to where it might have originated could help.
Inverting amplifier to measure shunt voltage? I've built a motorhome-type vehicle, and wish to perform coulomb counting for the battery bank. I've placed a 100A/75mV shunt between the battery bank negative, and the negative bus (which is also connected to vehicle chassis to reduce wiring cost for alternator charging etc.) simulate this circuit – Schematic created using CircuitLab How can I most accurately measure the mV across the shunt? The value will typically be 1-10 mV, up to 100 mV peak, and will be either positive or negative, depending on the direction of the current. I understand that I may need an inverting amplifier, since the microcontroller will be grounded at the load level, e.g. unable to measure a negative voltage.Or is it sufficient just to use offsetting? I'm new to amplifiers, and worried that I'll spend countless hours trying to get the wrong components to work, particularly having difficulties accurately reading the 1-5mV level. Typical usage, as measured across the shunt with a multimeter: - Charging at 20-30A = (negative) 15-22mV - Constant loads, ventilation etc., 1-2A = 0.75-1.5mV - Peak charging from alternator 50-80A = (negative) 38-60mV The multimeter reads the values quite well/stable. <Q> so there's no problem there <S> but, given that the current can be negative as well as positive I'd create a small negative supply to power the op-amp symmetrically about the ground point. <S> Then I'd go for something like an OPA333 as the op-amp. <S> If you need more bandwidth then something like an <S> ADA4528 is also good. <S> If you are looking for budget parts - you get what you pay for. <S> Basically run the op-amp as a non-inverting amplifier and add offset to centralize the signal produced into the range of your microprocessor's ADC. <S> You might even consider a low offset-voltage Instrumentation Amplifier like the AD8222 fed from a symmetrical supply <S> - it has a pin you can set for the offset called "REF". <S> You can get very cheap DC-to DC converters (very small too) that can be wired to take a positive supply voltage and produce a stable negative output voltage. <A> There's a product category called "current sense amplifiers" designed for just this scenario, where voltage across a shunt resistor must be read outside the supply rails of the amplifier. <S> Most of these parts are designed only to work with input voltages at or above the positive rail, but a few allow measurement below the negative rail. <S> For example, INA193 can measure differential voltages offset from -16 to +80 V: <S> You can also look at the datasheets of these parts to see the circuit topology that allows measuring outside the rails, and reproduce it with discretes, although accuracy might suffer from not having components as well matched as you might get on-chip. <A> I'd suggest <S> this as prerequisite reading for you. <S> There are several article parts (see end of page two) that cover most of the fundamentals. <S> TI make excellent High and Low side Current monitors <S> INA138 <S> (you need two of these to do bi-directional, see Figure 15 in datasheet), <S> the automotive INA169 (again you need two) and INA210 . <S> Configuring amps for low side detection can be more challenging, so I'd recommend using High side measurements (it makes no difference to your system). <S> If you are committed to using Low side detection them you can use the LM3900 Norton opamps to obviate having to use negative supplies. <S> Again here, you'd have to have separate LM3900's for charge discharge sensing (though only a single sense shunt resistor).
You can get op-amps that are dc accurate down to a handful of micro volts I'd recommend use of the INA169, it's really easy to use and there is a small PCB version available from Sparkfun for $9.