source stringlengths 620 29.3k | target stringlengths 12 1.24k |
|---|---|
How can I improve the response time of a low pass filter? I am busy with a high order low pass filter. How can I improve the response time of a filter? If I use a higher ordered filter, does it improve? Also, if I use an op amp with a faster slew rate, does it improve? My application is that amplify and get filter the load cell signal. My load cell signal is changing between 1 Hz to 10 Hz. There is three stages in my signal conditioning circuit. First stage Instrumentation Amplifier to amplify the signal(AD8221), second stage is second order low pass filter with OP07C op-amp (Sallen-Key type, corner frequency is 10 Hz), third stage is voltage follower with again OP07C. According to my test results, when I compared original signal to output of amplifier (first stage) there was no significant delay between two signals. However when I compared original signal to output of voltage follower there was significant delay. The delay was approximately quarter of a period of original signal. So I have thought that I have to improve my filter rise time. Or do I have to change my op-amp with higher slew rate one. According to all your answer, should I use higher cutoff frequecy with same op-amp (OP07C)? Most of you mentioned "group delay" of a filter. What does "group delay" depend on? I got it firstly depends on corner frequency of a filter. Is there any effect order of filter to group delay? <Q> You cannot greatly change response time of a low-pass filter by changing its' order. <S> What you have to do is change its cutoff frequency - the higher the cutoff frequency, the faster the response. <S> Look at it this way. <S> A low-pass filter removes high frequencies, right? <S> And if you want the filter output to change more quickly it must contain more high-frequency components. <S> You know, fast change means high frequency. <S> So the only way to get faster response from the filter is to let more high-frequency signal through, and that means changing the cutoff frequency to a higher one. <A> If the interferer is significantly away from the wanted frequencies, different filter types can improve response time of the wanted signal. <S> If you are looking to keep the time delay between two signals very close and only one of those signals needs to be filtered you can opt to filter both and therefore keep the time delays still acceptably close. <A> The behaviour of a filter circuit in the time domain and in the frequency domain is not independent on each other. <S> Hence, you cannot change one without the other. <S> That means (as always in electronics): You have to accept a trade-off between the behaviour in both domains. <S> Either you have specific frequency requirements (corner frequency, damping values) - and you have to accept the resulting time properties (group delay variations). <S> Or you have certain requirements in the time domain (group delay, step response) and you have to live with the resulting frequency response. <S> The latter case is typical for Bessel-Thomson type filters which are selected primarily because of their good group delay properties (but have rather poor damping properties). <A> Generally speaking, unless extreme cases, slew rate in not important in filter design - unless the slew rate starts to interfere with the actual functioning of the design of the filter - distorting the signal for example. <S> Also, generally speaking, 'response time' increases with the order. <S> The selection of the filter architecture is the main factor in delay - delay is rarely constant with frequency, so you also have to decide if the filter has to show the same delay at each frequency or not. <S> In a lowpass filter, delays tend to increase in the reject zone. <S> So, you need to decide the architecture... <S> An interesting page on the subject is Analog Devices phase response comparison , where you can actually see the different responses as dependent on frequency. <S> If predictability of response time is a factor, you might want to consider migrating to digital filters. <S> FIR filters have a constant time response. <A> I guess the cause of your delay is multiple phase-shift caused by using capacitors between amplifier cascades. <S> For low frequency (10Hz you mentioned) the summary delay may be significant.
| Usually, the higher the order of the filter, the longer the response time so the trick is just filtering sufficiently to get a manageable signal-to-noise ratio.
|
What tests should I perform before I claim my enclosure is Type 1? I've seen varying definitions of "type 1" enclosure, and most of them are informal. I've also heard it informally explained that I should be able to drop a screw into the top of the unit and not have it contact any live parts, but that's also informal. Is there a defined series of tests I can perform to claim type 1? <Q> Well, you can also call it a banana type 1 enclosure then or whatever else you want, because the name is rather meaningless, if it is not bound to a specification. <S> I guess you are referring to the NEMA enclosure types , which states type 1 to be General-purpose. <S> Protects against dust, light, and indirect splashing but is not dust-tight; primarily prevents contact with live parts; used indoors and under normal atmospheric conditions. <S> NEMA Enclosure Types is a pdf file that includes: <S> The purpose of this document is to provi de general information on the definitions of NEMA Enclosure Types to architects, engi neers, installers, inspectors and other interested parties. <S> [For more detailed and complete information, NEMA Standards Publication 250-2003, “Enclosures for Electrical Equipment (1000 Volts Maximum)” should be consulted. <S> This Standards Publication as well as all otherNEMA publications are available from IHS @ 800 854-7179 or http://www.global.ihs.com <S> ] <S> The included TABLE 2 includes that type one "Provides a Degree of Protectiona gainst the Following Conditions": <S> Access to hazardous parts Ingress of solid foreign objects (falling dirt) <S> But as the document says, you should consult the standard specifying document. <S> NEMA 250 and NEMA ICS 6 are commercially available. <S> If you are a company/business and you want to sell products compliant to this specification, you should buy these specifications in order to do so. <S> There is little to no point in buying these specifications as a private person. <S> If you are just a curious private person, you should check your national/country/state library. <S> chances are they do have these specifications available and you can read them. <S> If you are a student, ask your univerity or univerity library. <S> They should have a copy of the specification available for you to read. <A> In this context, enclosure type seems to be a NEMA thing. <S> There are many types listed in that document, here is a small sample for completeness. <S> Type 2 Enclosures constructed for indoor use to provide a degree of protection to personnel against access to hazardous parts; to provide a degree of protection of the equipment inside the enclosure against ingress of solid foreign objects (falling dirt); and to provide a degree of protection with respect to harmful effects on the equipment due to the ingress of water (dripping and light splashing). <S> Type 3 Enclosures constructed for either indoor or outdoor use to provide a degree of protection to personnel against access to hazardous parts; to provide a degree of protection of the equipment inside the enclosure against ingress of solid foreign objects (falling dirt and windblown dust); to provide a degree of protection with respect to harmful effects on the equipment due to the ingress of water (rain, sleet, snow); and that will be undamaged by the external formation of ice on the enclosure. <S> As to the tests required to claim the enclosure is Type 1, it appears that those documents are behind a door you must pay to open... <A> The NEMA 250-2003 standard (sorry, no better link..) is defining the types and tests for the applicable criterions.
| Type 1 Enclosures constructed for indoor use to provide a degree of protection to personnel against access to hazardous parts and to provide a degree of protection of the equipment inside the enclosure against ingress of solid foreign objects (falling dirt).
|
How to create a locked door detector? I'm trying to build a device that alerts me when I leave home without locking the door. I have a little space inside the door (width 8mm x height 130mm x depth 8mm) where I plan to install the microcontroller, a small button that gets pressed when the piece of metal of the door slides in (door locked), a battery and a rf transmitter. The questions are: push buttons can detect the pushed/unpushed state of the button, or they simply give me a single "one-time" signal when the button is pressed ? do you think the space available is enough for this project ? <Q> There are two kinds of push buttons. <S> There are some with a lock mechanic (which will remain on the last state until it's pressed again) and there are some without this lock (which will remain open/closed while the button is pressed). <S> The problem I can see with the push buttons as sensors in this case is because they have limits of activation. <S> Sometime they will wear and lose sensibility or even they will not switch anymore. <S> Datasheets specifies it, usually is about hundreds of thousands or millions times. <S> I think the space is enough, but it will relies on your skills designing the PCB. <A> Good luck! <A> I am working on a similar project and I'll be using a "roller lever limit switch". <S> You can find them for around 1 or 2 dollars for 10 switches on ebay. <A> I would use a reed relay instead a mechanical push button. <S> Attach a tiny magnet (e.g. a sticky magnet tape) on the door lock moving piece and the reed relay tube on the door frame.
| Instead of using a button you could make it so that when the lock is in the locked position it completes the circut (i.e touches a conductive material) which would change the state of the input pin on the ardunio.
|
What is the purpose of a "carry in"? I'm currently trying to learn how binary adders work, but I don't understand what a "carry in" is for. What is the purpose of a "carry in"? <Q> It's important to understand there's a difference between a half-adder and a full-adder. <S> A half-adder is the simplest. <S> It has 2 inputs and 2 outputs. <S> It's basically a XOR. <S> The primary output is only 1 if one of both inputs is 1, but not if both are 1. <S> That's Sum . <S> The second output is only 1 if both inputs are 1. <S> That's Carry . <S> That's nice, <S> but only if you're adding two bits. <S> If you need more bits, you'll have to combine some adders together. <S> Here's where full-adders come into play. <S> The Least Significant Adder is a half-adder, and every More Significant Adder will be a full-adder which will take the Carry of the previous adder. <S> A <S> B <S> Cin Cout <S> Sum0 0 0 0 01 0 0 0 10 <S> 1 <S> 0 0 <S> 11 <S> 1 <S> 0 <S> 1 <S> 00 <S> 0 <S> 1 <S> 0 <S> 11 <S> 0 <S> 1 <S> 1 <S> 00 <S> 1 <S> 1 <S> 1 <S> 01 <S> 1 <S> 1 <S> 1 1 <S> (shamelessly copied from Wikipedia) <S> If Carry in is 0 , the behaviour of a full-adder is identical to a half-adder. <S> However, if Carry in is 1 , the behaviour of Sum is inversed and the behaviour of Carry out changes into a OR. <S> As long as any of the inputs is 1, Carry out is 1. <S> Carry in is required to turn a basic 2-bit adder into a multiple-bit counter. <S> That's the purpose of Carry in . <A> By linking I mean that, if your computer architecture has a ALU with a word size of 8 bits and you need to do a 16 bit sum, the ALU can use the Carry flag, placing it on its carry in as a way to allow the processor to continue the sum from the previous one. <S> This allows two 8 bit sums to become a single two step 16bit sum. <A> The purpose of the "carry" in is to accept the "carry" out of the previous adder. <S> Carry works just like normal arithmetic.
| Besides what is said by those who replied earlier, Carry can also mean an input coming from the flag register that allows linking one sum on a ALU to the next one.
|
measure instantaneous position of a solenoid piston? I'm trying to improve speed & force of a solenoid and its power electronics strategy. So far I can measure many variables such as : tension current waveform shape time to reach final excursion How can I measure the instantaneous position of the piston while it is moving? being able to see the signal as an analog value is a plus... there must be a simple way... :) (source: globalsources.com ) <Q> Put a high speed camera on it with a calibrated grid background. <S> This way you don't add any mass/dashpot to your system. <A> 1.) <S> Connect the armature to a linear pot used as a voltage divider and plot the voltage out of the pot along with, say, coil current on an oscilloscope. <S> 2.) <S> Connect the armature to the core of a variable inductor in an oscillator. <S> 3.) <S> Connect the armature to a mirror and use it to deflect a LASER beam a la mirror galvanometer. <S> 4.) ... <A> Another alternative is to construct an LVDT https://en.wikipedia.org/wiki/Linear_variable_differential_transformer <S> Either way, you're going to have to put in some work to build an experimental setup. <A> One method would be to add a rack and pinion to the solenoid plunger. <S> The pinion could move an encoding wheel that people less a photo interrupter to determine absolute position. <A> Pop an accelerometer on it and double integrate. <S> Should be OK for the short period of time involved, and a motion much faster than drift, but I'm not sure if the magnetic field of the solenoid would be an issue.
| You could place a small permanent magnet on the end of the solenoid and use a Hall sensor to measure the change in magnetic field and map that to a distance.
|
Reconciling V, A, iPF and kW for my air conditioner On the energy meter installed by my utility company (a 1-year old digital Landis+Gyr), I noticed the following steady-state readings when my inverter air conditioner (with a variable speed compressor) was running and I am trying to figure out what could be happeningVoltage: 230VCurrent: 2APower Factor: 1.0Power: 315W.Clearly the power reading is [happily] much less than expected - ordinarily I would expect power to be V times A times PF but that is not the case.To ensure the energy meter was not defective (it's just a year old) I connected a 200W incandescent lamp and got 0.75A with 175W, which shows that the meter is correct to within a small margin of error. Can I conclude that the power shown by the energy meter is lower than VxAxPF for the AC is because the compressor is probably drawing pulses of current rather than a continuous 2Amps? (I am not conversant with the exact speed control mechanism of inverter ACs.) If so would it then imply that energy meters such as the Landis+Gyr are NOT designed to show true RMS currents? Thanks - Ram <Q> No you can't assume that. <S> A compressor is primarily a motor which will have a relatively steady current draw. <S> The inverter may convert that to pulses, but a PFC inverter with power-factor correction would not. <S> But a motor has friction and requires lubrication. <S> As the motor ages, friction will increase, and the viscosity of the lubricant changes with age and temperature. <S> Also the load on the motor will change according to the work being done by the compressor - which is a function of the temperature on both sides. <S> The motor's ratings must take these factors and other variables into account. <S> On another day, with different temperatures and a much older motor, you may find it's power is close to its rating. <S> All you can conclude is that today's measurements show a lower than rated power consumption. <S> If you need to test the power meter for accuracy, you'll need to test it with calibrated loads - both resistive, and non-linear, (such as a bridge rectifier, reservoir cap, and resistive load) not random pieces of equipment. <A> I believe that you are saying that "Voltage: 230V Current: <S> 2A Power Factor: 1.0 Power: 315W" are all readings of the meter, not AC nameplate ratings. <S> The inconsistency certainly indicates some difficulty with the meter. <S> The input current distortion is due to the rectification of the input current rather than the pulsed nature of the inverter output. <S> The real power would be calculated as fundamental current X voltage X displacement power factor. <S> I would expect that would be what you would be paying for unless you are penalized for distorting the current. <S> The old fashioned rotating disk kilowatt-hour meters very effectively ignore the harmonic distortion effects and measure real power. <S> Can you get an explanation from the utility company? <A> I believe the following references almost completely answer my question. <S> Thanks to Charles for helping me get there. <S> Reference 1: <S> Paper titled Harmonics and how they affect power factor and Reference 2: <S> Q&A on EnergyExperts.org <S> Reference <S> 1 points out that real power equals VxAxRealPowerFactor and has a very illuminating formula and graph showing how real power factor drops with increasing distortion even though displacement power factor can stay close to unity. <S> Also points out that "Single-phase power electronic loads such as desktop computers and home entertainment equipment tend to have high current distortions, near 100%. <S> Therefore, their true power factors are generally less than 0.707, even though their displacement power factors are near unity." <S> Reference 2 clearly says "All AC electric meters account for power factor when they register and record real power. <S> Most utility revenue meters only recognize displacement power factor ." <S> Therefore what is most likely happening with my case is that the power factor being reported by my energy meter is displacement power factor which is 1, but the real power factor is closer to 0.7 (based on the VA product and the reported Watts). <S> According to the formulas and figure in Reference 1, it follows that if the energy meter is correct about the real power and the RMS current, the THD of the current drawn by the AC would be about 100%. <S> For the benefit of those who do not want to get into the math, here is a qualitative explanation of why this happens: a [hypothetical] capacitive or inductive load may generate zero current distortion but shifts the current waveform. <S> In contrast however, some appliances can severely distort the current but yet have the current waveform remain in phase with the voltage (i.e., the fundamental remains in phase with the voltage). <S> That means that there is no phase shift per se so the energy meter reports PF=1. <S> However harmonic currents which are at a frequency different from the voltage do not contribute to power, hence the total/true/real power factor is less than unity.
| I would suspect that the AC current is distorted and the meter is displaying total RMS current rather than the fundamental and the displacement power factor rather than the total power factor.
|
Is it OK to inject voltage to an unpowered LDO output? I'm designing for the first time a PCB that can be powered from an external +12V supply or from the USB connector. In the input of the board, just after the power connector (VINLDO net is the +12V power input), I've placed two LDOs in series. The first provides regulated +5V and the other +3.3V as the schematics shows: When VBUS = +5V and there's no voltage in VINLDO net could I damage the U5 ( MCP1703AT-5002E/MB ) voltage regulator, since I'm "feeding" a +5V signal into its output? <Q> As Ignacio pointed out there is a parasitic body diode inside the regulator from the output to input. <S> If VBUS has a very low source impedance then the C15 will get charged quickly through U5 and there is not much limiting the current. <S> Or, anything connected to the VINLDO input could draw current from VBUS through U5 (for example, shorting to ground could kill the regulator). <S> Edit: To make this a bit more clear, here is the internal diagram of U5: <S> One possibly practical solution if this appears to be an issue is to add a Schottky from output (across U5's body diode and in the same direction) to input and a polyfuse in series with the VINLDO input. <A> It is safe to apply a voltage to the output of a LDO regulator provided that it is not higher than the input voltage . <A> You can solve this by placing in series an 'ideal diode' device such as ISL6146A. <S> ISL6146A <S> By using a FET as described you prevent voltage, down to 1V per the device datasheet, from reverse biasing anything before the external FET. <S> However because of the body diode voltage would always pass through. <S> If this is undesirable, a second FET in series with the first but pointing in the opposite direction would prevent this condition as well. <S> To clarify, one FET will act as an ideal diode so you don't have the voltage drop but really only functions down to 1 volt. <S> Two FET diodes, where the body diodes face eachother, prevents this condition and the device will be off down to 0 volts. <S> Good luck.
| Many LDO regulators have a parasitic diode from the output to the input that may become forward biased if the input is at a lower voltage than the output, thereby allowing a potentially destructive amount of current to flow.
|
One resistor on two LEDs This question is a little bit stupid and silly. As I am chemist, I don't remember electricity physics very good. As I remember it shouldn't harm anything, but I need to be sure. LEDs will be blinking sometimes together. But not longer than 50ms. They will be parallel for only short time. Because they supposed to blink reporting 2 modes 1st - normal, 2nd - error. And switching between them can be no longer than 50ms. simulate this circuit – Schematic created using CircuitLab I use resistor for both LEDs, but it just curiosity question. <Q> The above circuit is Ok, as long as only one LED is on, it'll work fine. <S> If both leds are on, that's alright, they won't get damaged, but their behaviour are unsure; depending on their characteristics, probably they will glow with a different brightness, but thats all. <S> But I still highly suggest that you use separate resistors for each led, because that's the right way to do it. <S> It's never a good design to wire diodes in parallel. <A> they are never in "parallel", since they have different anode connections. <S> they do share their cathode connection though. <S> Yes it will work, with the following drawback: <S> When pin # 1 and pin # 2 are both High (~5V), the LED with the Lowest forward voltage will light up much more than the other one. <S> Possibly so much more that it seems like only one LED is on. <S> The resistor will always ensure safe operation, but you might see only one LED light up because the LEDs share their cathode. <S> A 220 ohm resistor is cheap and small it would be best if you used it, but you won't damage anything by using this configuration. <A> If the LEDs are different colours, only the one with the lower forward voltage will light when you expect both to light. <S> For example, red LEDs typically have a forward voltage of about 1.8 volts, while green LEDs are 2.2 volts. <S> If you have a red LED and a green LED in your application, only the red LED will light when you expect both to be on, if the LEDs share a single resistor.
| If the two LEDs are the same colour, using a single resistor will probably work, but the LEDs will be dimmer when both are on than when only one is on. Yes, it will work, but I don't recommend it. There will always be a slightly difference in the forward voltage drop of the LEDs, even if they are from the same production batch.
|
How to understand the timing report after synthesis? After synthesis of my verilog code. I am getting the below timing report. I think it showing any mistake in my code. Timing Summary: Speed Grade: -2 Minimum period: 2.334ns (Maximum Frequency: 428.376MHz) Minimum input arrival time before clock: No path found Maximum output required time after clock: 1.282ns Maximum combinational path delay: No path found The main thing which bother me is the comment highlighted by bold. Is it showing of any kind of error? <Q> No it's no error. <S> Synthesis just estimates timings because you didn't apply any constraint file. <S> In the normal ISE flow, constraints are applied in the translate step. <S> If this is to late and you need earlier constraint checks or optimizations, then you can apply a XST constraint file (*.xcf) with timing information. <S> The syntax is the same as in ucf files but only timing constraints are allowed. <S> The processing of an xcf file can be enabled in the synthesis process properties. <S> Edit: <S> Sorry <S> I overlooked your bold lines as I wrote my answer. <S> There are 4 types of connections in a design (in order of your reported lines): clocked element to another clocked element (e.g. flip flop) Input pin to clocked element clocked element to output pin Input pin to output pin <S> When synthesis reports No path found , it just means this type of path does not exist in your design. <S> And so it can't report any timings. <A> It is not an error. <S> Minimum input arrival time before clock: No path found <S> Maximum combinational path delay <S> : No path found And this means that there is no logic path from any input to any output without a flip-flop in between (= combinational path). <S> It seems that your design does not have any inputs. <A> Minimum period: 2.334ns (Maximum Frequency: 428.376MHz)Minimum input arrival time before clock: No path foundMaximum output required time after clock: 1.282nsMaximum combinational path delay: No path found Hi! <S> Your code is correct and synthesis too. <S> Better You apply input values directly at that statement only instead of applying in testbench. <S> Then you can observe combinational path delay.
| This simply means that there is no logic path from any input to a flip-flop (or latch).
|
Why cannot we work in millivolt range Generally we work in terms of either 5V or 3.3V for the micro controllers. Why cannot we work in millivolt range? Just I wanted to know the limitations of working in millivolts. <Q> Even if you could design logic circuits to work at sub 100mV logic levels, power supplies that feed the logic are usually quite noisy and this noise will also appear superimposed on the logic signals - getting a logic supply that doesn't produce noise that could turn a 0 into a 1 or a 1 into a 0 would be fairly tricky. <S> You'd be looking at about 30mVp-p noise maximum and probably more like 10mVp-p for decent reliability. <S> It's not just noise but <S> power supply accuracy too - producing a power supply whose voltage drifts up and down (say) <S> +/-0.25 volts under all load and temperature ranges isn't that hard but doing so (and keeping spurious noise) to below (say) <S> 20mV maximum is a big challenge. <S> But, as has been mentioned by @PlasmaHH, transistors inside logic gates need a certain voltage to turn on and if you can invent a transistor that can turn on and off reliably with a 100mV range of input voltage then you should become very rich. <S> I'm not saying it's a laws of physics thing <S> but it very well might be. <S> Remember, the beauty about digital solutions is that they avoid digital corruptions by have a distinct "voltage gap" between high and low. <S> Currently some chips use 0.8V as the logic supply voltage so things are moving this way. <A> Semiconductors switch on and off at minimum voltages based on the materials used. <S> Typical for silicon is 0.7V to 1.2V. <S> Some logic gates need more than one transistor to do their job so a higher voltage is needed. <S> Then some additional supply voltage is needed to make up for losses across a circuit and noise and tolerances. <S> There are materials with lower voltage thresholds, but they are more expensive or more difficult to manufacture, so are less common. <S> Power supply noise comes mostly from fluctuating load of the circuits it is powering. <S> But it needs to be considered. <S> You don't want a surge in power from one part of a circuit to cause an error in another part of the circuit, so additional headroom is needed to make sure the supply voltage is enough that false ones or zeros are not detected. <S> The comment about an Arduino needing more current at a lower voltage is just not a correct answer to your question. <S> The poster is probably thinking of a light bulb or heater that needs more current at a lower voltage to provide the same wattage of illumination or heat. <A> ULV ICs operate at 800mV or even slightly below ( <S> 775mV for some low power Intel CPUs). <S> If you want to operate a relay, turn an LED on, even change an LCD segment, it takes more than 1 volt, so you need voltage translators for almost everything. <S> You can directly operate many power MOSFETs from a 5V MCU, but your design choices have dwindled few at 1.8V. <S> Some MCUs today use a lower voltage core voltage and have internal voltage translators for the I <S> /O for just this reason. <S> So you might have a 1.8V core voltage and 3.3V I/ <S> O.
| Lower voltage is often not an advantage for microcontrollers because their interface with the real world represents a higher portion of system cost than in, say, a smartphone CPU. Looking at the answers before mine, the best has to do with the gate voltage thresholds and diode drops.
|
Why does temperature modify the characteristics of a diode? Everyone knows that temperature affects every semiconductor device you can think of, and diodes are no exception. From the below graph, we can see that the temperature has marked effects on pn junction diode and zener diode. PN Junction diode Zener Diode Source : Concept electronics Now we can see that in an PN junction diode,in the forward bias region increase in temperature causes decrease in the cut-off voltage,whereas in the reverse bias the opposite thing happens. I know that these can modeled using the diode-current equation.But conceptually I can't understand what happens to the charges with change in temperature which causes these change in the characteristics. I also can't understand why the zener diode behaves differently from that of the junction diode in the reverse bias region.Please explain me this too conceptually. <Q> Ok, there are many things at play here. <S> Let me just quickly define a few things for you. <S> I'm assuming some background knowledge since you mentioned the Shockley equation. <S> A diode is formed by joining a piece of n-type and p-type semiconductor. <S> This leads to diffusion of electrons and holes which creates a current. <S> As a result, the space charge region (SCR) is formed. <S> The space charge region creates an electric field that creates a drift current that cancels off the diffusion current. <S> Hence at thermal equilibrium, there is no current. <S> A zener diode depends on quantum tunneling. <S> This means that the breakdown voltage is achieved once the p-region valence band edge is raised above the n-region conduction band edge. <S> This allows the electrons in the p-type valence band to tunnel to the conduction band of the n-type region. <S> This creates a current. <S> An avalanche diode (that's not a regular diode, its an avalanche diode), depends on the avalanche effect. <S> When the SCR field exceeds a certain amount (known as critical field), electrons get accelerated to very high speeds and start knocking other electrons into the conduction band. <S> This creates a huge current. <S> Notice the difference in operating principle between the zener and the avalanche diodes. <S> Ok, now to tackle the questions. <S> This analysis is simplified but should be good enough. <S> This affects diffusion current only minimally as the rise is around the same on both sides so we can approximate diffusion current to be constant for small increases in temperature. <S> Drift current increases proportional to the carrier concentrations however and so drift current increases greatly. <S> This means that a smaller electric field is required in the SCR to offset the diffusion current. <S> Due to this smaller electric field, the turn-on voltage of the diode decreases. <S> In a zener diode, when you raise the temperature, the energy of electrons increases. <S> Consequently, the tunnelling probability increases and the reverse breakdown voltage drops. <S> (not entirely sure of this but seems plausible) <S> In an avalanche diode, when the temperature is higher, the built in field drops as per the previous explanation. <S> Hence, a larger applied voltage is needed to reach the critical field and so breakdown voltage increases. <A> Semiconductors work in general because thermal energy lifts some number of electrons from their "ground states", where they are bound to a particular nucleus, into the conduction band, where they are free to move about. <S> The number of electrons in the conduction band is a strong function of temperature, but it is also a function of the relative doping levels in the various parts of a semiconductor device. <S> The relative levels of conduction-band population is what determines the electrical characteristics of the device. <S> Whether one population rises faster or slower than another with respect to temperature can make the difference between having a positive or negative temperature coefficient in the electrical characteristics. <A> because they are made of semiconductor materials. <S> In low temperature a semiconductor does not conduct current but as the temperature rises its conductivity also rises. <S> That's where the names come from, not conductor not insulator but a middle thing called semiconductor. <S> In other words, when you increase the temperature of a material, the movement of the electrons inside the material also increases, which results more possibility for conductivity. <A> Forward Bias of PN Junction Diode: <S> As you increase the temperature, the intrinsic carrier concentration increases. <S> This pushes the fermi level closer to the intrinsic fermi level (the middle of the band gap). <S> Since the built-in potential of a diode is determined by the difference in fermi-levels in the p-type and n-type regions, the fermi level in each region moves closer to the middle of the gap, and the built-on potential is decreased. <S> Reverse Bias: <S> Intrinsic concentration would increase with increase in temperature and hence minority charges would increase with increase in temperature. <S> The reverse current depends on minority carriers. <S> Hence as the number of minority charge carriers increase, the reverse current would also increase with temperature
| In a regular diode, when you raise the temperature, the carrier concentrations rise greatly.
|
is sound produced by varying current or voltage? In a sound system (computer, stereo, CD, etc.) is the (just) current or voltage (and therefor current) modulated to create the output to the speakers? If the answer is both, what are some examples of each? <Q> There are two main ways electronics can generate sound: As Dave said, some speakers use variable current to create a variable electromagnet which moves the cone and produces sound (of course, you need some voltage to induce the current). <S> Another way is with a piezoelectric material . <S> When you apply a voltage to certain materials they can mechanically change shape. <S> By varying the voltage, you can produce vibrations, and thus sound. <S> Again, these devices must consume some current, but this is can be small compared to the voltage. <S> In summary: All electronic sound sources must have current and voltage to operate because they convert electrical energy into sound (and heat) energy. <S> The electrical power they consume is given by \$P = <S> I V\$, where P is the power <S> , I is the current, and V is the voltage. <S> In piezo devices V may be quite high and I quite small, and similarly in electromagnetic devices I may be quite high and V may be relatively small. <S> However, if either of them is 0 you get no power, and thus there can be no sound. <A> Typically when you change one (voltage or current), the other will change as well (except with infinite resistance ie. <S> open circuit or zero resistance <S> ie. <S> superconductors). <A> Prompted by a comment by @BruceAbbot (on a previous answer of mine that I deleted because it wasn't spot-on) <S> I did some further researches and I found a reference that seems perfectly fit to answer your question. <S> In short: modern audio power amplifier generally have a very low output impedance (fraction of ohms) and act as (almost ideal) voltage sources. <S> Therefore, using your terminology, they "modulate" the voltage across the speakers, which react absorbing the current needed for their operation, as their characteristics mandate. <S> The reference is Audio Power Amplifier Design Handbook , by Douglas Self (link to google books) , under "Damping Factor" section. <S> Excerpt: <S> Audio amplifiers, with a few very special exceptions, approximate to perfect voltage sources, i.e. they aspire to a zero output impedance across the audio band. <S> The result is that amplifier output is unaffected by loading, so that the frequency-variable impedance of loudspeakers does not give an equally variable frequency response, and there is some control of speaker cone resonances. <S> The few exceptions cited are trasconductance power amplifier used for so-called current-driven loudspeakers , where the amplifier act like a current source and "modulates" the current into the loudspeaker, which reacts by generating a voltage across itself accordingly. <S> See also this EE.SE answer: <S> How important is impedance matching in audio applications? <A> Many good answers, mine is short. <S> Voltage causes current, current creates force, which in turn moves the magnet that makes sound waves. <S> Good amplifier makes all that stuff very accurately. <S> With good speakers you will only hear the initial signal. <S> Otherwise all sorts of ringing may occur on each transformation.
| But speaking for speakers, most of which consist of a magnet and a big wire coil connected to a paper cone, it is the current flowing through the coil which creates the force that moves the coil and cone and produces the sound you hear.
|
Why does this work for biasing an AC signal for A/D conversion I have a working circuit for biasing the AC signal going into my ADC, but I cant quite wrap my head around why it works. I can see that it resembles a high pass filter but how/why does it add the two voltages together? For example if the AC signal is at 1.5V, the ADC input is at 4V (1.5V + 2.5V). The 2.5V comes from a simple voltage divider circuit. The AC signal is coming from a voltage follower op amp. <Q> It's not quite like that, let me show you the proper circuit: <S> simulate this circuit – <S> Schematic created using CircuitLab C1 is a DC blocking capacitor - meaning at steady-state <S> , the right-hand side does not know what's going on with the left side. <S> When there is a difference in voltage, things start to happen. <S> This allows us to pretend in DC analysis that the capacitor C1 is an open circuit, leaving the node between R1 and R2 a simple voltage divider of 2.5V. <S> When there is a sudden change on the input signal on the left side of C1, the change is reflected on the right hand side, and the voltage divider no longer acts like that - rather the node voltage will change to reflect the change on the input. <S> If the left side shows a -400mV drop below 0V, the node on the right will be 2.5v - 400mV until the capacitor charges anyway. <S> The 2.5V "bias" on the right side allows single-supply circuitry like a microcontroller's ADC to read values which it normally cannot. <S> You can deal with the bias in software, to read out <S> + <S> -2.5V from that sense input. <A> Agreed with the answer given by @KyranF, but I would also like to add that capacitors resist change in voltage. <S> This means that when the AC voltage swings between -2.5V and 2.5V, the capacitor will draw/produce (Depending how you look at it) <S> whatever current it needs to maintain this voltage. <S> So that causes a voltage/current swing in the 1MΩ resistor. <S> I would also argue that the circuit given by @Black Emperor is not entirely wrong. <S> Ideally <S> (Note ideally) <S> an ADC pin would not draw any current, so we can treat the ADC node as an open circuit. <S> Let's say we apply zero volts at the AC signal pin for a very long time. <S> The cap would also be an open circuit and there wouldn't be any current flowing through the resistor, <S> thus the ADC pin sees 2.5V, this is the known bias. <S> If the AC signal starts to fluctuate, the cap would force the voltage across it's terminal to remain the same, causing current to flow and changing the voltage across the resistor which can be read by the ADC. <S> The only reason why I wouldn't suggest to implement that exact circuit is because a cheap ADC would have a low input impedance. <S> This low input impedance might be on the same scale as the 1MΩ resistor (causing it to appear less like an open circuit) and current would start to sink into the ADC and possibly cause damage. <S> Hope <S> I was clear, good luck! <S> Josh <A> Even though the OP didn't provide schematics to the converter circuit, The reason why you should have the 2.5VDC offset is because of the DC voltage at the Vref pin when its capacitively coupled to AC common. <S> This is actually normal here since 2.5V is half way between the OP's Vcc and DC Gnd which is where the bias at signal zero crossing should be. <S> This is why some designers use split rail power (+/-V) <S> so the offset input voltage DC offset product is near 0V. <S> So I would suggest that you refer to the data sheet of the ADC so you can see how they supposed to be build up with the "typical circuit design" and go from there if you want to play with modifying circuit parameters.
| The only issue I see is that you trying to actively bias a circuit that already has the bias circuit installed in the ADC.
|
Electrical noise sources in farms I am designing the data logger of a solar-powered automatic weather station that will be installed in farms. It's used to gather data from environmental sensors (wired) and send it to a host using the cellular network. One of these sensors is a Solar Radiation sensor. Its sensitivity is 15uV. I am designing the analog front end and already filtered the mains 50 Hz that may be present due to nearby power transmission towers. My question is: What are the other external noise sources that are present in a farm that may interfere with my system? <Q> Electric fences are a nice wideband source of interference. <S> Especially if there are bad contacts on the way (rusty connections, etc.). <A> Anything that can also be anywhere else. <S> Radio, TV, Radar, anything. <S> Post-RF-Radio any place on earth can have any amount of interference in the μV scale. <S> It's why those designs need extra special attention, no matter where you put them. <S> But be glad you're not designing for outside-of-earth <S> , that's even more annoying. <S> And, of course, as Spehro says, lightning is always a fun thing with outside-electronics. <S> Both being hit by and picking up induced spikes, the latter being even more likely, since "nearby strike" in that sense on a μV sensor can still be 100's of meters. <A>
| In a farm, I would look for tractors or anything with engines and ignitions that can cause interference.
|
What are the consequences of connecting two motors in parallel? I am using two DC motors rated at 36V and maximum current draw of 5A. To reduce the number of motor-controllers, I am planning to connect them in parallel. The two motors are required to run at the same speed, so wiring them in parallel will ensure same PWM signal to both these motors. Both the motors are unidirectional. Both the motors are identical (electrical rating, manufacturer, load). Also, they need not rotate at exactly the same speed, there can be slight variation (15%). The motors will be driven in an open-loop, there is no feedback. The motors will be connected to brushes. My concern is: What happens if one of the motor stalls? Theoretically, this should not affect the other motor as they are in parallel and the UN-stalled motor will receive the required voltage and also assuming that the batteries are able to supply sufficient current. What happens if one of the motors produces back EMF? Is it possible for a stalled motor to produce back EMF? Should I be using a circuit-breaker/PTC fuse/fast-acting fuse in series with the motors? <Q> A simple PWM controller will cause each of two similar motors connected in parallel to run at approximately the same speed (with some minor change on each due to loading). <S> That is because the resistance of the rotor winding is <S> small, back EMF is proportional to speed and torque is proportional to applied voltage minus back <S> -EMF (divided by rotor winding resistance). <S> To a first approximation, speed is proportional to applied voltage, and a PWM source behaves like a constant voltage (not like a series resistance). <S> A closed-loop controller with feedback of some kind (tacho) will act similarly- <S> the motor with feedback will be controlled well but the other will speed up and slow down in sympathy with the loading on the controlled motor. <S> It really depends on the nature of your motor controller. <S> In answer to your specific questions: If one motor stalls the current will increase. <S> If the motor controller can supply the full stall current plus operating current for the other motor then the non-stalled motor will be unaffected. <S> Otherwise, it will slow down or may stall. <S> All DC motors produce back EMF- <S> it's proportional to the rotational speed. <S> No, since it's proportional to rotational speed, at speed = 0, back EMF = 0. <S> There's going to be inductive 'kick' at 0 RPM which is unrelated to motor RPM, but related to motor inductance (and current, which is high- perhaps even high-est when the motor is stalled). <S> You should follow the protection and fusing recommendations of the motor controller and the motor manufacturer and seek help if there is a conflict between the two. <A> If one motor stalls, you have to consider not only if the battery can supply the current, but what will happen to the controller. <S> Back EMF is what determines the current the motor draws to produce the torque necessary to drive the load at a given speed. <S> Each motor will produce back EMF according to the load it sees. <S> If one motor sees more load, it will produce less back EMF, reduce its speed and draw more current. <S> A stalled motor will produce no back EMF and the current that it draws will be limited only by the resistance of the armature. <S> A fuse would protect a stalled motor from burning up. <S> It shouldn't be fast-acting. <S> The motor needs to be able to power through a brief overload without blowing a fuse every time. <A> If it is a open loop without feed back, in case of stalling of one motor the current will increase to very high value causing damage of the motor / the power source. <S> So overload / current cutoff protection should be used in the circuit.
| However , a more sophisticated controller with IR compensation or back EMF measurement will cause the motors to interact and loading up one motor more will cause the other motor to increase in speed, while not providing optimal control for the first motor.
|
Is BeagleBone Black a microcontroller or computer? I started working on BeagleBone Black , and I cannot find out whether BeagleBone is a microcontroller, or some kind of computer? If computer, what makes it a computer? I worked on different Cortex-M microcontrollers, but I am not sure what BeagleBone really is. <Q> The BeagleBone Black is a single-board computer (SBC). <S> It contains a AM335x ARM® Cortex-A8 which is a microprocessor (not microcontroller) with some peripherals, including two 32-bit 200 MHz co-processors intended for real-time processing. <S> The distinction between microcontroller and microprocessor is that the program memory and peripherals are typically external to the latter, though the distinction has faded somewhat in modern times as some processors have many peripherals on board and external memory buses which may or may not be used. <A> While according to ARM processors classification, are intended for general computing applications as opposed to ARM Cortex-M series, which are intended for microcontroller applications. <A> BeagleBone Black is a microcomputer. <S> Mostly because it runs a processor, Sitara ARM Cortex M8, and one of the main features of the board is that it can run Linux. <S> If you go on the Texas Instruments site in the Sitarra section, you will see that most people programming this board interface the board with Linux shells. <S> Isn't that enough proof that it is a computer? <A> Traditionaly there was a split between microprocessors which are designed to drive a bus system with memory and perhipherals and microcontrollers which have processor, perhipherals and memory on one chip. <S> More recently chips like the ones on the Pi and beaglebone have appeared. <S> These have the core perhipherals on the chip like a microcontroller but unlike a microcontroller they use external memory. <S> The industry calls these chips "SOCs" (which stands for system-on-chip, a name I find somewhat puzzling since an important component of the system is not on the chip).
| BBB is a computing platform, having a TI Sitara AM335X microprocessor on board, which is ARM Cortex-A8 core.
|
What are the holes on an optical flow sensor IC? The right hand image is a flow sensor IC for an optical mouse available from Sparkfun. On the left is another optical flow IC with a camera attached from a Chinese distributor. It seems that the holes in the IC are a common property for optical flow sensor ICs. What purpose do they serve? Why are they there? <Q> These chips were designed for optical mice and are part of a multi-part assembly. <S> The outer rectangular holes are probably alignment features for the clip that holds the IC down during reflow soldering. <S> The clip keeps the IC at the correct height and orientation as wells as providing a shield for the backlighting LED. <S> I talked to a friend of mine who designed some of the original optical mice chips for HP in the 90s. <S> Since the die is mounted on the topside of the package, the lead frame is supported by pins during injection molding. <S> When the mold and the pins are removed, the holes remain. <S> Data Sheet Ref, page 3 & 4. <S> datasheet <S> You can also look at datasheets from other Avago parts at Digikey. <A> Almost certainly alignment pin holes from the injection moulding machine. <S> Most ICs are assembled on the leadframe while it still has metal bridging the pins and they are cut away after encapsulation moulding so the leadframe alignment is not disturbed during moulding. <S> These devices likely use a somewhat different moulding process as they have to keep the bonding pad locations free of plastic and in the right place to allow for wire bonding after IC attachment. <S> Another thought occured to me that may be equally relevant, they may be used to hold anvils (a bunch of tapered flat topped pins) during the ultrasonic wire bonding process <S> so it makes a reliable bond when otherwise the plastic case would have to provide the counterforce which may be inadequate in practice. <A> I was very interested in this myself <S> and I have taken apart about 10 sensors in the last few days <S> and I am convinced the holes are used during the ultrasonic welding of the bond wires, as stabilization. <S> Because the sensor cant be covered with plastic like normal chips, they use partial plastic molding on the metal frame the sensor chip is placed on. <S> Then to bond the chip to the metal frame they most likely insert pins in the holes to support the metal frame. <S> The holes in the back are exactly lined up with the pads on the metal frame the chip is bonded to. <S> This was the case on every sensor from every manufacturer.
| They will be used to keep the internal leadframe sections in the correct position when the casing is moulded so that the IC can be placed in the final place and bonded to the leads inside the case.
|
What is the maximum voltage drop on an LDO? I'm a long time lurker :) How do I tell what is the maximum voltage drop an LDO can handle?My mentor explained adjustable LDOs like this to me (paraphrased of course): "An LDO is essentially a high precision, low range, voltage controller that requires a slightly higher input voltage to function. For example, even though an LDO is rated at (1.24-26)V if the input is 25V, it will only be able to output (24.2-24.8)V." How can I find these boundaries in a datasheet? Considered components: MIC29150/29300/29500/29750 High-Current Low-Dropout Regulators LT3015 Series - 1.5A, Low Noise, Negative Linear Regulator with Precision Current Limit Sorry if my English is not good. C++ is my native language. <Q> An LDO or any linear regulator can drop any amount of voltage as long as two conditions are met. <S> First, the maximum input voltage is not exceeded. <S> Second, the wattage dissipated by the regulator is taken into account. <S> For example if using a 7805 with an input voltage of 25V with an output current of 100mA. <S> The regulator is dropping 20V and dissipating (V*I) <S> 2W. <S> The wattage is quite high and would require extensive heat sinking to keep the regulator from burning up. <A> LDO means low-dropout regulator. <S> This is understood to be a type of linear regulator. <S> The minimum difference between input and output is called the dropout voltage. <S> So an LDO deserves the name only if its dropout voltage is "low." <S> Many old LDO's don't really deserve to call themselves an LDO by today's standards. <S> Anyway, that is not what you asked about. <S> There are normally two constraints on the maximum input voltage. <S> One is that there is simply a maximum recommended operating voltage. <S> If you go above that, you may wind up with problems. <S> Second is determined by heat dissipation. <S> The power dissipated by a linear regulator is (Vin - Vout <S> ) * Iload. <S> So what you normally do is figure out your maximum input voltage and maximum load current and use those to calculate the dissipation. <S> Then you have to check the thermal resistance of the component to figure out whether dissipating that amount of heat will cause the silicon to get too hot. <S> I am sure you can find detailed instructions about thermal calculations on the WWW or in the search box for this forum. <S> In general, you will dissipate less power with lower Vin and lower load current. <A> LDO stands for Low Dropout Voltage. <S> An LDO voltage regulator is able to regulate its output voltage even if the input voltage is only slightly above the output voltage. <S> The required minimum difference between the input and output voltages for the regulator to stay in regulation is given as the "dropout voltage" on the data sheets. <S> It is given for different levels of output current. <A> if the input is 25V, it will only be able to output ( <S> 24.2-24.8)V. <S> That's not right. <S> The maximum input voltage is clear enough, the input cannot be higher than that. <S> The drop-out voltage is the minimum amount the input voltage has to be higher than the desired output. <S> Be aware that the drop-out voltage depends on the current you draw from it. <S> So if the drop-out is 0.5V at the highest current you will draw and you want 6V out, you need to always at least supply 6.5V. <S> Then, the maximum voltage differential between in and out may be given for one or two types out there, but it's not likely to happen, because that's what the maximum input voltage and maximum power dissipation are for. <S> A linear regulator (LDO regulator is a subclass of linear regulators) is not magic, any power drained at the input, but not supplied at the output will be turned into heat. <S> As opposed to a switching regulator, which will - at the cost of extra components and more output ripple in most cases - try to be as efficient about it as possible in the situation. <S> If you put 20V in and take 2V out, but you want 100mA, that means the LDO has to "absorb" 18V at those 100mA, which makes 1.8W of energy it turns right into heat. <S> So if the regulator is not equipped for that, or the way you mount it doesn't support getting rid of that, it will be destroyed. <S> However, if you take 2mA out of it, that's only 36mW and that can be handled by any linear regulator, even when it's not mounted at all. <S> Unless, of course, it's a high precision regulator with a maximum of 1mA output, but then it's the limited current that does it, not the power. <S> 36mW is absolutely negligible. <A> Do you mean the maximum voltage drop or the maximum output voltage? <S> For the mic29150 the dropout voltages are listed on page 7 for the LT3015 on page 5 for a variety of current. <S> You have to allow for ripple and variations of the input voltage. <S> The lowest rectifier output voltage must be above the LDO output voltage plus dropout voltage plus ripple plus many variation of the input voltage. <S> As an example if you wish 20 volts output at 100mA with the mic29150 and there can be 10% variation of the input voltage. <S> The normal input voltage would need to be 20 + 2 + 200mV (dropout) = <S> 22.2V. <S> At high voltages you may not need an LDO as the other variations may dominate. <S> Also be careful about the difference between the absolute maximum voltage and maximum operating voltage - for the mic29150 <S> the absolute max voltage is 60V <S> but max operating voltage is only 26V. <S> The circuit is not guaranteed to operate at the absolute max, only not be destroyed. <S> At high input voltages it is probable that you may be limited by device dissipation. <S> Also with bipolar LDOs be aware that the quiescent current can increase greatly when the input voltage drops close to or below the set output voltage - <S> for example see the graphs on page 9 for the Lt3015.
| The maximum output voltage would be the maximum input voltage minus the dropout voltage.
|
What happens to voltage source if I take out both volt and current with separate circuit using diodes and then combine both separate circuits? I have 3.8V and 1.2Ah battery. I will use a step up circuit that gives 5v and 200mA output using 2v in (from my battery). Then I will use blocking diode to take voltage only(5v) and I don't need current from this circuit. Again I will also use a step down circuit that gives 1v and 2A output using 3.5v in (from my battery). Then I will use another blocking diode to take current(2A) only and I don't need voltage from this circuit. So can I get 5v and 2A output in this way from a 3.8V and 1.2Ah battery? And now what will happen with my battery? I need to understand that if I can get more power out of the circuit than comes out of the batteries. To extrapolate what I want to do, imagine I want to power my house with 240V @ 100A (24KW). I want it with a 1V @ 100A (0.1KW) power source combined with a 240V @ 1A (0.24KW) power source. If to power my house with 1v@100A(taking the current only from here using blocking diode) and with 240v@1A(taking the voltage only from here using another blocking diode) and combine both of this to get 240@100A. Is it possible? Well if it is possible I will again feed back the 5v and 2A output to battery to recharge it. So before being the battery empty(if) I will be recharging it again by the estimated output from the combined circuits. Will the battery really be empty after producing separately stepped volt and current or can I get volt(5v) and current(2A) greater than my battery (3.8V,1.2Ah) in this way? Does my thinking have a hope? My step up and step down circuits are as following as example: http://www.alibaba.com/product-detail/DC-DC-2-0-5-v_1547670640.html?spm=a2700.7724838.102.7.vDaE3Z http://www.amazon.com/DROK-Converter-4-5-24V-Rrgulator-Constant/dp/B00C4792T2/ref=sr_1_16?ie=UTF8&qid=1436885493&sr=8-16&keywords=current+regulator <Q> I have 3.8V and 1.2A battery. <S> OK, what that means is that the battery has a nominal output voltage on 3.8 V when the terminals are open and can push 1.2 A of current when the terminals are shorted. <S> These conditions are not true at the same time. <S> In other words, there's some V/ <S> I graph that describes the relationship of voltage to current (given some charge level; it falls off as the battery discharges) <S> that is monotonically decreasing, and all you know are that the points (3.8 V, 0 A) and (0 V, 1.2 A) are on that curve. <S> I will use a step up circuit that gives 5v and some current output using 2v in(from my battery). <S> This sounds like you're confused. <S> A step-up switching power converter will need to take 3.8 V in (nominal) and output 5 V in this case. <S> The output current maximum will depend on the power available from the battery. <S> Remember that V/ <S> I graph I mentioned? <S> the circuit will settle at some combination of V and I, and the power delivered (P_IN = <S> V_IN <S> * I_IN) must be greater than the power out (P_OUT = V_OUT <S> * I_OUT). <S> Then i will use diode(say zener) to take voltage only(5v). <S> A Zener diode, properly connected, simply sinks enough current through itself to bring the voltage across its terminals down to its Zener voltage. <S> If there isn't that much voltage across it in the first place, it will act like an open circuit. <S> If forward biased, it acts like a regular diode with a small voltage drop. <S> So this is in parallel with your step-up circuit? <S> Then i will use another blocking diode to take current(2A) only. <S> Okay, at this point I have no idea what you're doing <S> and I'm pretty sure you don't either. <S> Can you draw a schematic? <S> i have no idea how that alibaba thing hooks up. <A> As Mike DeSimone points out, your battery can't produce 3.8 V and 1.2 A at the same time. <S> But even if it did, that would only be about 4.6 W. <S> You want to use it to power something with 5 V and 2 A. <S> That's 10 W. <S> You can't do this without first overturning the entirety of conventional physics by disproving conservation of energy. <A> Attempting to connect supplies with different voltages will cause current to flow directly between them, possibly resulting in damage or death; do not attempt to connect them together.
| Further, the power from the battery needs to be enough for both converters; one converter can starve the other, and if that isn't enough power, it'll pull the battery voltage down to UVLO level. I will also use a step down circuit that gives 1v and 2A output using 3.5v in(from my battery). Again, 1 V is the nominal output and 2 A is the maximum the converter can deliver.
|
PLC with or without PC I heard from a colleague that typical PLC serve as an interface between a the signals and, for want of a better word, a PC. The connection, being typically done with ethernet, and the PC runs some Codesys, or Labview applications. This was the way the application could be changed while running, which is one of main advantage of PLC for debugging and maintenance. However, looking at one example, like this one , I can see the Ethernet ports, but I can't find any precise information about that topic. Looking around, I found that a remote PC can be used as a server and thus the PLC would communicate with it, typically via Ethernet. But it is not a must. Can someone clarify that trivial point for me? Must or must not a PLC be connected with an external PC to run the application. And if it's not, can we still change the code on-line? For the background, I have to decide on using a PLC or a µC-based solution, and up to a few days ago I ignored the existence of PLCs. I should add that I have read the question: Why use PLC instead of microcontroller? , but unless I missed it, it does not answer that specific question. <Q> Can the PLC run without an external PC, and if so at what cost? <S> (apart from the PC price, obviously). <S> The costs vary greatly depending on features (# of <S> I/O, Redundant processors, etc. <S> etc.) <S> That being said, the only thing the PLC would be able to control is the attached <S> I/O (Contactors, Relays, Alarm Lights, etc.). <S> You would not be able to do any programming of the PLC. <S> You could have a lap top computer (for instance) with a programming cable (usually USB or Ethernet) that you could use to program as needed. <A> A PLC does not need a computer to run the program. <S> 99.9% of the time a computer is connected is for programming or debugging. <S> For programming, some PLCs don't even need a computer - see this Allen Bradley handheld programmer . <S> For simple or local monitoring and control, a programmable HMI is mostly used in most industrial settings. <S> In a more complex setup such as in a power plant or a manufacturing plant, a SCADA(supervisory control and data acquisition) <S> system is used. <S> A PLC interracts with the real world e.g controlling machines, responding to user inputs such as buttons being pressed, collecting readings from sensors such as thermocouples, pressure transmitters, encoders, etc. <S> Applications running on servers such as OPC servers or historians collect data from various PLCs around the plant. <S> This data can be consumed by client applications such as HMI operator stations in a control room or by trending software . <S> The client applications can write back to the PLC through the OPC server allowing for remote control. <S> A PLC can also collect data from other PLCs through the OPC server instead of having a direct link. <S> While with hard work you can achieve the same with a microcontroller, the question is why would you? <S> You are going to be reinventing the wheel most of the time. <S> Need a specialty function such as bar code reader, high speed counter, encorders, thermocouples, RTD, 4-20ma current or voltage input/output, Timers, AC/DC inputs outputs, relay outputs, VFD control, Modbus, Fieldbus, Profibus, HART communication, etc?? <S> PLC is got you covered. <S> Just plug the <S> I/O for what you need, configure it and you are in business. <S> Try implementing that with a microcontroller. <S> Plus don't forget most industrial places won't allow your homebrew microcontroller. <S> Is it underwriters laboratories or RoHS rated? <S> No go for most places <A> A PLC as its called a Programmable Logic Control, it can be programmed with the help of Computer initially ( Advance Programmers for some PLCs computer isn't even necessary for programming).once <S> the PLC is programmed and its in run mode it doesn't need computer to be attached to it as it has its own <S> processor.you need pc attached to PLC just for debugging the program or monitoring the process if the processes are working according to plan.
| Absolutely a PLC will run without a PC.
|
Why not use monochrome LCDs instead of E-ink? Recently I've been reading about E-ink displays and the benefit over LCDs, as I understand it, is that there is no backlight in E-ink displays and thus, physical light is reflected, making reading under direct sunlight possible. However, this got me wondering, is there any difference, apart from power consumption, that would prohibit the use of monochrome, reflective LCDs (like the ones found in calculators, watches etc.) in eReaders, replacing the slow eInk screens? This would enable us to have a nicer UI with animation. <Q> Check your calculator: the blacks are good, but the whites are very bad. <S> This happens because the LCD is good at blocking light, not very good at letting it through. <S> You don't notice this in normal LCD screens because the manufacturer can just ramp up the backlight until the whites are acceptable. <S> Since eReaders are meant to imitate paper, bad whites are a big problem. <S> If you think about how LCDs produce images, this makes a lot of sense: light always passes through a polarizing filter that absorbs a lot of light, leaving only the "correctly" polarized part. <S> The result is less light being reflected. <A> Thanks to a different recent question, I found that it has been tried and is called "memory LCD" and is used in the Pebble smartwatch. <S> Sharp have addressed this by adding to the conventional thin film transistors a memory element of some sort. <S> Their power consumption for static images is very small, although not zero. <S> I think the LCDs are still necessarily glass, while e-ink displays can be slightly more flexible. <S> This is a fragility disadvantage. <A> As I understand it, the advantage to E-Ink (besides improved contrast as mentioned above) is that e-ink displays only require power while refreshing (changing) <S> the content on the page. <S> Once the image appears, it will remain indefinitely without consuming any electricity (there may be a fade time or something, but I'm not aware of one). <S> Thus the batteries in e-ink based readers can last a very long time between recharges. <S> True e-ink doesn't allow for animation, but I don't believe its initial intention was to be used as a "screen" so much as it was intended to be an alternative to disposable paper. <S> My opinion is that e-readers were the first practical use for the tech. <S> (Though, there was a cellphone a while back that used e-ink in the buttons to change them dynamically depending on whether the phone was in phone or texting mode -not <S> sure if this was out before or after the e-reader explosion) <A> E-paper is only low power when it's off. <S> Every time you update the image it draws a lot of power. <S> For example, if you wanted to make a 7.5" e-paper clock, you'd need 38 mW for 6 seconds every minute, and that is: $$\frac{365 \cdot 24 <S> \cdot 60 \cdot 6 <S> \cdot 38 <S> \cdot 10^{-3}}{3600} <S> = <S> 33.28~Wh~(per <S> ~year)$$ <S> That's a lot of energy! <S> On the other hand, there are lots of big LCD clocks on amazon, that run for years on a single AAA battery, and an AAA battery only contains 1.3 to 1.8 <S> Wh. <S> So, the e-paper eats 25 times more! <A> There are a lot of good answers already. <S> I would like to add on to them the fact that eInk screens are not inherently slow. <S> There was this Chinese company around 2010, that made eInk screens that can show 48fps videos -- however, they were not able to advertise themselves right, and they went bankrupt; their technology was bought out by Sony <S> I believe for around $1.2M, and then promptly discontinued. <S> One example of a similar quick video playback on an eInk screen is https://www.youtube.com/watch?v=24srQXX81Oc (though that's not the one from that company). <S> The idea is, that the lag that's incurred is happening because the USB interface is using the "naive" way of sending of the image. <S> The actual update speed of an eInk screen is close to 300 Hz (as measuring using an oscilloscope), but you have to update the screen in the correct order to remove the aliasing effect. <S> Therefore, most eReader companies simply flash the entire screen black, white, black, white, and display the image -- which works, but it makes the image update very slow. <S> If the USB driver is programmed right, eInk is capable of very quick updates. <S> One company that sells relatively quick eInk monitors which is not bankrupt right now is Dasung. <S> In the 3rd generation of their displays, they have been able to reach approximately a 20fps update rate (with the exact rate depending on the complexity of the image). <S> So eInk is not inherently slow: it can definitely do animation. <S> But since people are buying them the way they are already, there is not enough incentive to really put in the development to make them display animation quickly.
| The key is that normally LCDs are driven by a pulse every refresh period, and will fade if voltage is not maintained across them.
|
Why does reflection only applies to transmission lines? Why does the concept of wave reflection seem to only apply to transmission lines? For example, for a simple circuit with two resistances R1 = 50\$\Omega\$ and R2 = 75\$\Omega\$, is the voltage wave coming from the first resistance reflected by the amount: \$ \Gamma = \dfrac{75-50}{75+50} = 0.2\$ ? Then it would mean a \$(0.2)^2 = 0.04 = 4\%\$ power reflection and a \$1 - 0.04 = 96\%\$ power transfer. But then what is the incident power? I guess you could brush it off as "transmission lines and resistances are different things" but then what IS the fundamental distinction between them? You kind of have a "wave" of electrons "travelling" in a resistance, and I guess that if they hit another resistance with a different ability to let electrons "travel", then they should partially go back, hence be reflected. <Q> Reflections happen everywhere, not just in transmission lines. <S> Transmission line is a model of the physical situation, which is easy to apply to a pair of conductors whose length is comparable to or larger than the wavelength of the signal, and which is regular in cross section. <S> What determines whether reflections matter is the frequencies in and the physical size of the circuit. <S> If you have unmatched impedances then you do get reflected waves just as you describe, and either you have to deal with them or they are negligible for some reason. <S> Here are two reasons: For exclusively low-frequency circuits, the reflections reflect repeatedly and settle down on a timescale much faster than the signals change. <S> That is, each double reflection is an extra signal which is merely out of phase with the original signal, but as they get more out of phase their amplitude drops quickly enough that they can be neglected. <S> (Even RF circuits can be built this way, as can be seen from a lot of homebuilt HF amateur radio gear.) <S> As frequency increases, wavelength decreases, and the physical size of your components becomes relatively larger, and you start having to worry about avoiding impedance “bumps”. <S> This is where you start using microstrip design techniques in printed circuits. <S> In digital circuits, sharp transitions may have high-frequency components that will reflect but you don't have to worry about this as long as your clock speed is much slower than the length of your traces/wires <S> (there's a conversion via c to make that make sense, of course) because by the time the clock makes its next tick all the signals have settled down to a steady state. <S> (Note that there are no standing waves here because within the period of a single clock tick the driving signals are steps (high to low or low to high logic levels), not periodic signals.) <S> As clock speed increases, the settling time available decreases, requiring you to either minimize reflections or minimize signal travel time (so that the settling occurs faster). <A> The difference between them is that a transmission line is characterized by both a capacitance and an inductance (and usually some resistance as well). <S> In real life, the transmission of a signal involves both the generation of a magnetic field (since current is flowing) and electric fields (since there is a voltage difference along the conductor). <S> The framework for dealing with these fields are the concepts of inductance and capacitance. <S> A transmission line can be modeled as a distributed inductive/capacitive network, and it is the energy-storage attributes of the transmission line which allow it to produce the effects that it does. <S> So the reason that it behaves differently from an ideal resistor is that it is different. <S> At audio frequencies and short distances these effects really don't matter, but at either high frequencies or long distances they can become important. <S> One of the first applications to demand treatment of this stuff was the transatlantic telegraph cables. <S> Not very high frequencies, but the long lengths caused unexpected problems. <S> You can read here <S> htp://faculty.uml.edu/cbyrne/Cable.pdf for instance, for a discussion. <A> The electromagnetic effects you are talking about apply to high frequencies. <S> Normally for circuit analysis the frequency is small so reflection and transmission concepts do not apply. <A> A resistor is a lumped circuit element almost by definition. <S> If your physical resistor is bigger than the wavelength, you need to model it as something more complex than a simple lumped resistance. <S> One option might be a lossy transmission line. <A> Transmission line effects occur when the risetime of the driver is faster than the propagation delay of the wire. <S> If this is not the case, the wire typically behaves as a lumped inductance and the load as a lumped capacitance. <S> I have done a lot of modelling using SPICE and measurements of PC boards and that's what I have found.
| Transmission lines are used to model situations where the length of the line is close to or greater than the wavelength.
|
Via fences or pickets important parameters for design What is more important for EMI shielding effectiveness with respect to guard traces and via fences, the width of the copper trace that circles around the area or the distance between the vias to ground that connects to the trace and the other ground planes? Are both equally important or is one important and the other not so much? Any good web resources out there for this? Some background threads: the thick copper trace What is the purpose of holes on edge of the PCB? TYIA <Q> The short answer is that neither matter in most cases. <S> The only good reason I have for doing such a "fence trace" is to prepare for maybe adding a shielding can later (after testing if it works okay without). <S> The longer answer requires you to first explain what you are trying to achieve <S> , why you think this will work and how you think it will work. <S> In general: If you don't understand what you are doing - maybe don't do it :-) <S> A lot of time is spent copying stuff we "think" is good and often creating more problems than we had in the first place. <A> The thick trace is as the post said used for EMI or RFI shielding. <S> They are also needed in RF boards to place an RF shield. <S> http://media.digikey.com/Photos/Laird%20Tech%20Photos/BMI-S-202-C.jpg <S> The above is an image of an RF shield. <S> Now, RF PCBS have very high frequency in both the transmitter and receiver section. <S> These fast switching signals are a designers nightmare as they can produce noise on nearby tracks. <S> Suppose we have long tracks near to RF antennas, the signals on the antenna will produce magnetic effects whose influence is felt on neighbouring traces and tracks. <S> This will corrupt the data being sent on those tracks and thereby effect system performance. <S> Hence forth most RFIC manufacturers recommend a 3R rule. <S> It means other tracks should be at a distance of 3R from the antenna. <S> R is the width of the antenna track. <S> Also it is recommended to have such ground tracks on the periphery of the RF boards. <S> These thick tracks are connected to ground planes. <S> So any EMI or RFI generated is quickly grounded, thereby nullifying its effects. <A> Yes.
| The trace in itself does not help much - other than adding some distance (which you could do without the trace). The track thickness is proportional to the size of the rf shield which will be soldered to your pcb.
|
Producing electricity from heat on a small scale? Using a small solar panel like in the following picture we can produce around 0.935W of power with a peak voltage of 5.5V and current of 170mA under good sunny conditions Does a similar type of small device exist which we can turn heat into small amounts of power like in the above? <Q> Not heat per se, but temperature differences can be converted into electricity by thermoelectric devices via the Seebeck effect . <S> The proper harvesting chip can then be used to increase the voltage (which is usually in the tens or hundreds of millivolts) into something usable. <A> Indeed there are devices like that. <S> They are called thermoelectric generator. <S> The efficiency of those thermoelectric generators is quite low, in the order of 5-8%. <S> So the needed temperature difference between the hot and cold side must be quite high to get a power in the order of your solar cell. <S> For example a device from TECTEG measures <S> 40x40mm <S> and you can get 0.66 W out of it <S> (0.6V, 1.1A) <S> at a temperature difference of 50K. <S> There are high temperature generators out there which you could attach, say to the exhaust pipe of a car to get a bigger temperature difference and much higher power levels (well still not impressive numbers but slightly better). <A> Small stirling engines have been used to generate electric power. <S> If you search using the terms "stirling engine" and "thermocouple," you will probably find some detailed information.
| People have constructed small arrays of large numbers of thermocouples connected in series to generate small but useful amounts of power using various heat sources.
|
Can I cut an IC? As far as I understand, the die of a DIP package is located at the center and the rest is just the lead frame. Given that I have unused pins, can I cut the top part of this microcontroller ( ATmega16 / 32 )? Will it still function afterwards? Edit: thank you for all the answers. I have realized that cutting an IC is a delicate process and there is a high risk of damaging the chip. But I've done it anyway, shear cutters worked a treat. I decided to go for the 3 lower pins instead of the upper ones since they are further away from the ISP connector. Here is a photo of the final result (My new DIP-34 package works just fine): <Q> I've never heard of anyone trying to cut an IC package like that, but it seems very risky to me. <S> In addition to the potential for shorting bond wires and crushing the die that Lorenzo mentioned, I would also be worried about the performance of any analog subsystems like internal oscillators and flash memory. <S> Package stress can shift the performance of analog circuits -- even the normal deposition of the mold compound tends to shift currents and voltages. <S> I have worked with decapsulated ICs and wafers, and I can tell you that IC dies and bond wires are thin and delicate, and are not designed to handle trauma. <S> I'm curious to hear whether your chip still works, but I wouldn't recommend doing this with any chip you actually care about. <S> EDIT: I got curious and looked up pictures of DIP lead frames. <S> Here's a picture of some DIP-36 lead frames on a reel that I found at a wholesaler's site : <S> And here's a labeled close-up of the cut side of your package: <A> How do you intend to do this butchery? <S> Unless you have very specialized tools, a Dremel cutting disk or something like that could generate a lot of static charges. <S> Well enough to kill the chip! <S> Moreover, mechanical stresses could damage the internal bond wires, or even the die. <S> Let alone you would have the bond wires to the cut-off pins protruding flush from the cut side (8 of them), maybe shorted together due to harsh mechanical stresses during the butchering action. <S> People needing to reverse-engineer a chip do this kind of things, but they use much more "delicate" measures. <S> Moreover, they want to expose the die, so they "cut" off the upper part of the package. <S> In particular see this link about decapsulation of the chip or this video showing LASER decapsulation . <S> Google for "chip decapsulation" <S> and you'll find tons of references and you'll understand why it is a costly process if you want your die to survive! <S> People pay big bucks to reverse engineer chips (both for legitimate and criminal purposes). <S> Legitimate purposes comprise failure analysis ("Why our top notch IC failed unexpectedly?!? <S> Let's crack it open and see what happened!") or retrieving lost designs ("OK, we acquired this little IC design house with these excellent parts. <S> But, wait! <S> Where are the design sheets of the groundbreaking HQC954888PXQ processor?!? <S> Who fired the design engineers who knew?!? <S> " - Yes these things happen!). <S> BTW, Did I mention all these methods are delicate ?!? <S> Side cutters are not what I could call delicate . <S> When I was a boy I remember cutting a (dead) IC to see the die using a big side cutter: it splintered wildly! YMMV! <A> Such things have been done at various times for various reasons. <S> There is a substantial likelihood of breaking the hermetic seal on the package exposing the chip to air and moisture, which could greatly hasten failure; I know of no means of inspecting a chip to determine if damage has occurred. <S> If one can accept a high likelihood of rendering a chip immediately unusable and uncertain reliability after that, such a trick might be usable if there is some particular reason you need to use a particular package which is too large for your requirements (e.g. if a part had 15 consecutive I/ <S> O pins, it might be possible to solder the legs of the chip directly to the legs of an LCD without using a PC board). <S> Such designs tend to be rather hokey and unreliable, so cutting the chip might not make things too much worse. <A> There is no hermetic sealing involved like metal and ceramic packages as the plastic moulding is homogeneous and does not contain an open space that is brazed, soldered or welded closed. <S> The thickness of plastic required for protection is very little, less than 1mm on modern thin flat packs, on a 40 pin DIP <S> it is generous in all directions. <S> The biggest danger is cracking the casing close to the bonding wires and this is most likely to occur if a pincer or shear method is attempted. <S> Using low speeds with a coarse abrasive cutter to reduce vibration or using a fine abrasive or abrasive water jet to cut slowly there should be little chance of mechanical or thermal damage. <S> Using water or alcohol spray, flood or immersion would solve cooling issues in high speed cutting and mitigate possible static build up though a humid work environment might be enough. <S> A typical 40 pin DIP IC might tolerate 7 or 8 pin pairs removed safely from each end if the internal die size is not unusually large. <S> In general the plastic ICs are very robust and most static protection on mature components is quite robust. <A> How barbarous! <S> Even though it was to be expected the chip would still work (provided the surgery is done properly) why haven't you opted for a non-destructive method like a socket adapter or build yourself one using a flat-cable between 2 sockets of different sizes, for instance? <S> While your method obviously works it irremediably damages the IC and makes replacement [almost] impossible.
| If one doesn't get too close to the chip cavity such techniques would be likely to short out an unknown number of adjacent pins but otherwise could work if one uses a cutting device which doesn't generate excessive voltages.
|
How to change rotation direction of 3-phase electrical machines? I was taught that if you want to change the direction of a three phase rotating machine that is rotating in forward direction, you interchange the phases. Since the phases has the same features (voltage and current), what is responsible for making the machine to rotate in reverse direction, when the phases are interchanged? <Q> The windings in a 3 phase motor, when activated by a 3 phase supply produce a rotating magnetic field in the rotor area of the motor. <S> Swapping B with C does exactly the same thing as does swapping A with C. Think of it like a triangle with corners called A, B and C. <S> If you swap any two corners and follow the points A, B and C you'll go in anopposite direction. <S> Swap two more corners and you're back to the original rotation. <S> This is what it looks like. <S> The black arrow is the flux produced by the three phase windings: - <S> Clearly, if yellow phase were swapped with blue phase the rotation would be opposite. <A> Each phase has the same voltage in a sinewave, but 120 degrees out of phase. <S> The question then becomes which phase leads the other. <S> This is what determines the direction of the motor. <A> The phases have a phase shift of 120 degress - called electrical phase angle, meanwhile the windings on the motor are also shifted by 120 deg - mechanical angle. <S> In a such way, when the current passes trough windings the rotating magnetic field is formed, which is the sum of all three vectors. <S> This is the principle of induction motor that Nikola Tesla made 130 yrs ago. <S> If you simply swap two wires, the magnetic fieled changes the direction of rotation.
| Swapping phase A with phase B re-orders the fluxes so that the flux rotates in the opposite direction.
|
2 led on latching pushbutton NO arduino I am looking to push a button and one led comes on when i push the same button again the first led goes off and the second light comes on. alternating lights each time the button is pressed. one light should always be on. I was hoping to use a microswitch as the button i want to use has a microswitch that i was going to switch. Would this be a dpdt? Does that exist in a latching pushbutton. Any other circuit ideas that would work? I appreciate the input <Q> An alternating (push-on, push-off) pushbutton switch would be the easiest. <S> It needs to be SPDT (or better). <S> There are plenty available. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> If you want to connect it to an MCU or other logic, then R2 can be used to assure a valid '0' logic level, otherwise you don't need R2. <A> Another possibility if you just want to use a cheap SPST tact switch: simulate this circuit – Schematic created using CircuitLab <S> If power is applied with a reasonably fast rise time, the circuit will power up with the Q output low (D1 on) and /Q high (D2 off). <S> That can be reversed by tying the D input to +5 rather than 0V. <A> If you don't have push-on, push-off switches then you can implement the following circuit using mostly digital components. <S> The input stage is a classic cross-coupled NAND de-bounce circuit that will get rid of any glitches coming from pressing the button. <S> Finally you can use the flops complimentary outputs to drive your LED circuit. <S> Depending on the flip-flop you use, you may not need the output transistor stage. <S> Note: All values are approximate. <S> I just used the default circuit wizard values. <S> simulate this circuit – <S> Schematic created using CircuitLab
| This will work because the 74LVC1G74 has a Schmitt trigger clock input, which allows a simple RC to be used to debounce the switch. The second stage is just a basic D-type flip flog configure as a T-Type (Toggle) flip-flop.
|
What do the 3 symbols (circle, square, triangle) in the USB Type-A plug represent? What do the 3 symbols (circle, square, triangle) in the USB Type-A plug represent?Is it power-/data-related notifications or just universal identification for USB? <Q> They don't seem to have much meaning from an electronics point of view and a few sites I checked such as Famous Logos seem to indicate it's more of an artistic impression: <S> Trident in the USB Logo <S> The USB logo was said to be modeled to mimic the trident of Neptune, the mighty Dreizack. <S> Although the trident before may symbolize power and authority, the USB trident is more commonly attributed to the technological ‘power’ one can get from attaching the USB to the computers and other devices. <S> Shapes in the USB Logo <S> It also denotes how interconnected the world has become, thanks to the technological innovations that the USB has imparted. <A> I don't have a source, but I recall an explanation when USB was new that the different shapes represent the different device types that USB could connect to. <S> This emphasizes the universal in Universal Serial Bus. <S> Just as an example, USB 0.8 already supported output devices such as printers, HID devices , and <S> I/O devices such as Zip drives . <A> This is just universal identification for USB. <S> From "Icon design recommendation for Identifying USB 2.0 Ports on PCs, Hosts and Hubs" <S> : "The icon (...) may be used to label any PC, host or hub USB port (...) <S> that supports USB 2.0 performance". <S> http://www.usb.org/developers/docs/icon_design.pdf <S> [ http://web.archive.org/web/20170630212339/https://www.usb.org/developers/docs/icon_design.pdf ] <S> This document deals specifically with the 2.0 variant of the icon (with a plus), but it explains that icon means USB connectivity in general, not just particular plug or socket.
| The shapes at the tip of the three-pronged spear (triangle, square and circle) in the USB logo are placed there to signify all the various peripherals that can be attached if the standard devices are used.
|
Starting current of an induction motor How to calculate the Starting current of an induction motor if I have the power in kilo watts and the voltage? I have looked up formulas , but I got confused. I calculated the full load current by dividing the power by the voltage (p=VI). I'm not sure about the full load current calculation as well. Also I know that the starting motor current is higher than the full load current, is that correct? <Q> The number you are looking for is called Locked Rotor Amps (LRA). <S> This number is usually also on the spec plate attached to the motor, along with the voltage, frequency and running current. <S> For What It's Worth, the LRA current often is NOT directly related to the running current. <S> Two different motors with similar specs can have radically different starting current. <A> There is no way to calculate the Starting Current or Locked Rotor Current (LRA) without more information! <S> Single-phase or three-phase? <S> NEMA Motor Design B, C or D? <S> What does academic education's sake mean? <S> A voltage of 15V with a power of 132kW is meaningless for an induction motor. <S> You just can't make up numbers. <S> You are also using <S> \$P = <S> V\ I\$, which is DC power. <S> You'd be better off looking up a motor nameplate and going from there. <S> Take a 150hp, 1789rpm, 460V, Design B, Code G, <S> 3-phase induction motor. <S> So rated current is 163A, with a power factor of 0.897 lagging and an efficiency of 96.2%. <S> Code G gives you locked rotor kVA on a per hp basis. <S> Locked rotor kVA will allow you to calculate LRA. <S> Code G = <S> 5.6 up to but not including 6.3. <S> Worst case = 6.3. <S> $$150hp \times <S> 6.3 = 945 kVA$$ <S> $$ S = \sqrt {3}\ V_{Line}\ I_{Line} <S> $$$$ <S> I_{Line} = \frac {S} {\sqrt {3}\ V_{Line}} = \frac {945 kVA} {\sqrt {3} \times 460V} = 1,186A $$ <S> LRA will be between 1,102A and < 1,186A vs 163A or 676% to 728% of full-load current. <A> If you don't have the specifications for the actual motor, the best way to estimate the starting and full load current is to look up published specifications for a motor that is similar. <S> The starting current is usually much higher than the full load current, up to 600% and sometimes higher. <A> The start current depends on the motor start type. <S> DOL direct on line from 5 to 9 times motor current. <S> S D star delta 4 times soft starter from 2 to 4 VSD variable speed driver from 0 to I
| You need to check the spec sheet for the motor.
|
"Beep" when testing VCC and GND with the multimeter Sometimes I use my multimeter solely for testing if there is a contact between two points. However, sometimes, when I measure between VCC and GND on some of my PCBs, I hear a short "Beep" and then it stops. Therefore I assume that there should be a short-timed connection between these two points (but it should not). But where? <Q> Sounds like capacitors to me. <S> Since the multimeter is most likely verifying continuity with a DC supply, an uncharged capacitor will appear like a short for a brief moment. <S> Also found this at https://learn.sparkfun.com/tutorials/how-to-use-a-multimeter/continuity : <S> Continuity and large capacitors: During normal troubleshooting. <S> you will be probing for continuity between ground and the VCC rail. <S> This is a good sanity check before powering up a prototype to make sure there is not a short on the power system. <S> But don’t be surprised if you hear a short ‘beep!’ <S> when probing. <S> This is because there is often significant amounts of capacitance on the power system. <S> The multimeter is looking for very low resistance to see if two points are connected. <S> Capacitors will act like a short for a split second until they fill up with energy, and then act like an open connection. <S> Therefore, you will hear a short beep and then nothing. <S> That’s OK, it’s just the caps charging up. <A> What you hear is most likely the capacitance between the VCC and GND which quickly gets charged as you measure the circuit. <A> However, if it is continuous, then this is not necessarily indicative of a short circuit. <S> I have several FPGA boards (large Virtex 6) with Vccint supplies of 1.0 V, and and the Vccint supply rail on these read as shorted to ground by the continuity checker, even though they are not. <S> My guess is that the transistors that make up the FPGA core are leaky enough that they let through the entire test current that the continuity checker applies with very little voltage drop. <S> After all, these FPGAs can draw 10 to 20 amps on Vccint when in operation.
| If the 'beep' is short, then it is probably the continuity tester charging up the power supply filter capacitors.
|
Any way to monitor current sourced by USB? I need an easy way to monitor the current being taken from a USB port on a PC. Is there any s/w that can do that? The alternative is wire cutting, which is a last resort. <Q> The problem about software measuring USB current is that USB current usually is not measured by the host. <S> The USB standard defines that each client should draw not more than 100mA when connected to a host. <S> If it needs more, it requests more, and if the host is fine with that request, the device is allowed to draw more. <S> The host knows all devices connected to a bus (i.e. a bus-powered hub plus four clients) and denies a request of a device, if that would exceed the overall current of 500mA (or 900mA for USB3). <S> Using Windows, you should find the requested current somewhere in the device manager in the properties of the USB device. <S> But this is a rather theoretical mechanism. <S> A host has not the facility to measure currents nor can it force a device to stop drawing current. <S> Usually, there is just a current protection circuit which disconnects the USB power from the +5V rail when the total current drawn exceeds 500mA. <S> Often, you will even not find this, and USB is directly connected to the +5V rail. <S> This is the reason why 2.5" USB hard disks work. <S> They need more than 500mA, but they simply try to draw it. <S> If this does not work, there's often a Y-cable, with two USB connectors plugged into the host. <S> The second connector has no data lines, and simply draws some current. <S> Long story short <S> : There is no way to get measured current information from the host, so you have to measure it yourself. <A> <A> No such software feature (I would be glad to know why you require this info from a device).Multimeter with a 'hacked' cable is the best way. <S> Buy an extender, and make sure you only cut the power line, and pass it through the multimeter's current sensor. <S> It is also possible to use a DC current probe which measures the electric field generated by the supply. <S> You will still have to separate the power line from the cable (but not cut it). <S> Please note that using an extender may cause disruption when communicating with the device, depending on the extender's quality and type of device and USB class. <A> I hate to peddle products, but I love tools so: <S> Get one of these, search for USB current meter. <S> These tools are cheap and available wherever cheap Chinese products can be found. <S> They measure voltage and current, and run 'in line' on a USB cable. <A> A good method is to locate the +5V feed to the USB host IC (typically these are part of the chipset on newer machines) and put the .1 ohm resistor there. <S> As the SD voltage is well documented its a matter of reading parameters back from 0x01 and then applying the appropriate calibration factors. <S> Also if the SD is drawing more than 200mA continuously then it is broken!! <S> For USB <S> only 0.01 ohms is better as it means most devices should be fine with the .08V drop under load.
| Probably the simplest solution (which can involve some wire-cutting) would be to get a USB extension cable, remove a couple of inches of its jacket, and then either use a milli-amp level clamp on DC ammeter, or cut the power lead, and put a ammeter in series.
|
Is there a fundamental limitation on how rapidly (with voltage) can a diode ’switch’ ? If so, can you pinpoint its origin? Is there a fundamental limitation on how rapidly (with voltage) can a diode ’switch’ ? If so, can you pinpoint its origin?The diode here is a 1N914 <Q> A diode is "on" when there are charge carriers in what is normally its depletion region, and "off" when the depletion region exists. <S> Therefore, the fundamental limitation on switching speed is how fast those carriers can move into or out of the depletion region. <S> This relates to the mobility of the carriers and the magnitude of the E field across the region. <A> There is most likely a parasitic capacitance in the diode which limits the switching time. <S> If it's too short, then the signal will be distorted. <S> This can be found in its datasheet: <S> http://www.vishay.com/docs/85622/1n914.pdf <S> Reverse recovery time = <S> 4ns <A> The legs of the diode have inductance (the current will flow in a loop;-) and the depletion region will have capacitance. <S> There can also be resistance in the legs. <S> These, as a minimum will slow down the switching transients . <S> (There are other effects as well which can further delay the switching).
| The capacitance of the junction itself, along with any stray (parasitic) capacitances put a limit on how fast you can cause the E field to change in the first place.
|
A low cost method to perform Eye-Pattern Testing on 100 MBit and 1 Gigabit Ethernet Transceivers I'm looking for a low cost method to perform Eye Pattern Testing on 100MBit and 1 Gigabit Ethernet transceivers. I do not own a BERT and I have a 4 channel 500MHz DSO available. <Q> Both 100 Mbps and gigabit ethernet over twisted pair require about the same amount of bandwith, so a 500 MHz scope should be good enough to get an eye diagram for both standards. <S> However, if you are doing gigabit over fiber or SGMII, then this is not the case and you will need a faster scope. <S> Both 100 Mbps ethernet and gigabit ethernet run at a symbol rate of 125 MHz, so most of the signal is primarily from DC to 62.5 MHz. <S> A 500 MHz scope provides 8x that bandwidth, so you should get a very good picture. <S> It is possible to subtract two channels with standard scope probes, but if they aren't exactly matched, you will get common mode to differential gain that can distort your eye measurement. <A> If you don't need to do automated tests, you can even use a plain old analog oscilloscope, and your 500 MHz DSO should be more than enough. <S> Just hook it up to your ethernet connection using two channels (100 Mbps) or four channels (1 Gbit) and flood-ping the connection for a quasi-continuous signal ( <S> e.g. # ping -f 192.168.1.something). <S> Here's an example picture I took while diving into 10base2 (coax), but 100base-TX or 1000base-T should work in a similar fashion. <S> The scope is a vintage Tek 454A (150 MHz). <S> It's actually good enough for guessing the quality of the eye pattern. <S> I guess even connecting your probes' grounded clips to one of each pair's wires should work because the ethernet transformers offer floating lines. <S> (Picture from here: Effects of impedance matching between 50 and 75 Ohm coaxial cables for 10 Mbit/s, Manchester-coded signals (20 MHz) ) <A> Eye pattern testing needs a scope. <S> If your scope is too slow get a better scope. <S> If that isn't "low cost" then rethink what you need (or want to do) to suit a lower budget. <A> You won't get a Bit Error Rate value out of a scope unless that is a feature. <S> You won't get a Y/N test value out of a scope unless that is a feature. <S> And you won't get an Eye Pattern out of a scope unless it has an Eye Pattern trigger setting, or a Window trigger setting. <S> A Window trigger setting is fairly common now: does your scope have that feature?
| One thing you may want to invest in, however, is a good quality active differential probe so you can make accurate measurements.
|
Voltage drop on motor controlled by arduino via transistor I am using a transistor (TIP 122) to control a dc motor using arduino. Although the power source I use is measured at 6V, I only get 5V at DC motor(M1) when I use the transistor. Here is the schematic: Is this voltage drop normal or do I miss something? <Q> Your "transistor" is not actually a transistor but a Darlington pair according to the datasheet extract Dzarda posted, which means it has unusually high gain (hFE=1000) <S> and they quote saturation voltages at Ic/Ib=250. <S> The downside of a Darlington is higher Vce than a singlo transistor, since Vce cannot fall below Vbe of the second transistor, or about 0.6 to 0.7V. <S> But note the Ib values : 12mA for Ic=3A, and 20mA for Ic=5A. <S> That's quite a bit higher than the 5mA you can get from an Arduino pin through a 1k resistor. <S> So there is some scope to reduce Vce by increasing base current (R1=470R or 330R) <S> but if 0.6V is still too much, then either: <S> replace the Darlington with a single transistor (probably with a second transistor to increase Ib. <S> Saturation is usually about 0.2V at Ib = Ic/10, so if the motor takes 1 Amp you need Ib=100mA) use a MOSFET as Dzarda suggests <A> The datasheet says the following: <S> Also, on page 3 the graph labeled" Figure 2. <S> Base-Emitter Saturation Voltage and Collector-Emitter Saturation Voltage " <S> So, depending on the operating conditions, you can get up to 4V of drop across the CE terminals (during saturation ~ the "ON" state). <S> Such high drop is really not suitable for 6V of supply voltage. <S> Get a MOSFET, they behave much more like variable resistors. <A> When the base of a transistor is made high then it should behave like a short circuit. <S> But, unfortunately most of the transistors have a little voltage drop. <S> So it is very normal according to your circuit. <S> You can use L293d motor driver chip. <S> The voltage drop will be less than 1volt.
| Some voltage drop there is normal; you want to saturate the transistor to minimise the voltage drop, and to increase that saturation you need to increase the base current. BJT transistors have intrinsic drops in them originating from their construction. This voltage drop is indeed normal.
|
dimming led with photoresistor I want to dim a led in a circuit if there's less light .However, the Photoresistor I'm working with reduces the resistance when there's more light .How can I achieve the opposite effect on resistance ? <Q> I believe this method using a transistor should work well for you. <S> http://electronicsclub.info/transistorcircuits.htm#sensors <A> Perhaps this may help you: simulate this circuit – <S> Schematic created using CircuitLab <S> As someone specified in the comments,your LDR increases resistance in low light and decreases it when there is more light,this is what you need. <S> However,it doesn't dim the LED. <S> The schematic illustrates the concept of dimming a LED using PWM(Pulse Width Modulation) with the help of a 555 timer working as an astable mulivibrator. <S> Diodes \$D_1\$ and \$D_2\$ are there to make sure that the duty cycle can be varied between 0% and 100%,which means you have more control on how much will the LED be dimmed. <S> \$R_1\$ , \$R_3\$ depend on your LED and LDR specifications. <S> Keep in mind that the duty cycle controls the brightness,while a high frequency makes sure that the eye does not feel uncomfortable seeing the flickering. <S> Try setting it to somewhere above 100 Hz. <S> Also,the 555 outputs a voltage approximately equal to the supply voltage and a current of a few 10s of mA,so remember these when you select a value for \$R_3\$ <S> and when you decide upon a power supply(battery). <S> D(duty cycle)=\$\frac{R_1}{R_1+LDR_1}\$ <S> f(frequency)=\$\frac{1,44}{(R_1+LDR_1)C_2}\$ <S> The included schematic is a variation on this one: image Source of information: site <A> This would not be very reliable though, as CdS photoresistors can be slightly unpredictable at times.
| From a purely theoretical standpoint, you should just be able to put the photoresistor in series with your led. That way, when there's less light, the resistance across the photoresistor is high, increasing the voltage drop across the photoresistor and limiting the current through the led.
|
Fuse position in relation to load and switch Where should fuse be in relation to the power, switch and load? Any suggestions on a better approach or tips on the matter would also be helpful. POWER > [FUSE] > SWITCH > LOAD POWER > SWITCH > [FUSE] > LOAD <Q> The fuse should always be the first thing a power supply hits when it gets to a circuit. <S> The reason is pretty simple. <S> In the event of a fault that blows the fuse, the power is isolated to where it entered the circuit, thus the whole circuit is protected. <S> Using other configurations could allow the supply voltage into other parts of the circuit unexpectedly. <S> There are situations where it's good to fuse both the power supply and the load, but that's another question. <A> If the switch itself fails, then there will be no power coming out of the switch, unless you are suggesting that the switch would fail in the on position, ... <S> the answer to that would be to isolate the source of power, & eliminate it, ... the odds of this happening would be quite rare, because if there is/was a powerful enough surge to cause a switch to fail, it would melt the switch itself, & cause the wiring back to the power source to also short out, resulting in an electrical fire, ... <S> understand that the 2 wires that go to the switch are not a common, & ground, ... they are the same power side of the source, ... <S> which makes your question a moot point, ... all a switch does is interrupt the power coming from the source, by flipping a switch “on” <S> you are sending the power from one side of the switch to the other side, like putting a shut-off valve in a pipe of water, turn the valve off <S> then there is no power coming out of the other side of a switch, shut the water off, and the flow of water ceases, ... <A> That way, with the power switch off, both terminals of the fuse are "dead", so there is no shock hazard while changing the fuse, providing the switch is off. <S> If the fuse is before the switch, it will always be "hot", and will potentially be a shock hazard. <S> For plug-in equipment the order is less important, as you can unplug the equipment while changing the fuse.
| In most cases, I would prefer to put the fuse immediately after the main power switch.
|
Panelization (& Depaneling) a Metal Core PCB What is preferred way to panelise a Metal Core PCB (MCPCB) - V-scoring or Tab-routing? The engineering challenge I am facing is that the boards are meant for production (1,000 qty in the initial stage) and unfortunately the most economical SMT Assembly house that I am in touch with cannot depanelise the boards for us. So the option is either to move onto a more equipped assembler (they are twice as expensive(!)) or depanelise the PCBs on my own. Some notes on the board design: It only has LEDs. No resistors or capacitors. The LEDs are 2.3 mm away from the board edge. Overall PCB thickness is 1.6 mm. Boards are rectangular, mostly. PCB is 25.5 mm x 21.25 mm. Panel is 5 x 8. Considering the above, is it a better option to V-Score or Tab-route? What method will allow me to minimize board stresses? And furthermore, what is the recommend way to depanelise a MCPCB (goal being cost-effectiveness & minimized stress on the components?) Note: I understand that at a higher volume, I will need a better and more automated way to handle this. However, for now, I am mostly concerned about the 1,000 quantity. I am also open to the idea of redesigning the board. An idea that I had after typing this question: I should design the panel to be tab-routed. After assembly, I could use a manual milling machine to break apart the PCBs. Will a milling machine cause stress on the components/PCB? I have access to several milling machines and cheap labour. This is not a big issue. <Q> All MCPCB panels I have seen have used a combination of routing and v-scoring (see picture). <S> Small drills are too brittle to drill mouse bites in aluminum. <A> My preference would be to V-score. <S> You can then either use a jig to break the boards apart or, if your volume justifies the cost, purchase a purpose-built de-panalize machine. <S> We don't have one of those specialized machines, so we use a simple jig. <S> This is nothing more than an old hacksaw blade that has been sharpened along the edge opposite the teeth. <S> The blade is held in a vise and the sharpened edge accurately finds and holds into the V-score. <S> A small amount of pressure is all that takes to snap the board. <A> Use vcut. <S> I did, worked very nice. <S> I would put two boards back to back,so that not straight side for both of them would be towards outside. <S> Also probably it would be nice to add 5mm margins on right and left for the conveyor.
| V-score must be on both sides.
|
Can a relay failure mode be like that? I was fixing my dishwasher control board, and diagnosed a bad relay. Its coil is still within specifications, but the relay will not close its contacts. It is an easy fix ok, but my question concerns another subject. What really caught my attention was the physical aspect of the relay package. As you can see in the image just below, it has black mark that erased part of its silkscreen and its center circle is punctured. While all the other ones on the board are like this: As you may have noticed, this is the only relay which was produced on a different week (29th instead of 32nd) on the board. My question is the following: does the black mark and the puncture on the bad relay points to an act made during manufacturing or is it its normal failure mode? Edit: Per Dwayne request, I have opened the relay cover: Apparently, the bottom contact is not able to reach the higher one, which could indicate erosion as Dwayne suggested. There is a briefly video showing the movement of parts during switch on mode: https://youtu.be/8EBsf52iyrk <Q> The type shown is a flux-sealed type. <S> This is because it allows contaminants caused by the wearing contacts to escape during the relay life that would otherwise be trapped inside. <S> Presumably the relay that wore out was switching higher current than the others, so it was deemed important to not only open the vent, but to mark it with a Sharpie so that inspection could check it. <S> Here's a section from a different datasheet from the same Taiwan-based manufacturer: <S> This may be indicative of a problem that the appliance manufacturer has been having and subsequent recommendations from the relay maker. <A> The missing silkscreen looks like a manufacturing issue rather than part of any failure. <S> It would be informative if you were to open the relay up and examine the inside. <S> There are a couple of common failures. <S> 1) the contacts have eroded because of arc. <S> 2) the plastic frame supporting the contacts has over heated and warped such that the armature doesn't make connection to the contact. <A> From my perspective,it looks like the hole was covered with some kind of tape to protect the inside of the relay. <S> For some unknown reason, the tape was removed, and the silkscreen under the tape was removed with it. <S> This should have nothing to do with the relay failure. <S> If the contacts don't close, and the coil is OK, this means that the "plunger" is stuck in place (maybe corroded in place?).
| It is frequently recommended that such relays be vented after the soldering and cleaning operation (if any) in order to extend the life of the relay.
|
What are coupling and decoupling capacitors? I have come through many places stating capacitors as coupling and decoupling capacitors, but I can't understand what is meant by coupling and de-coupling capacitors? Can anyone explain me what they are and how do they differ from normal capacitors?? <Q> They are no different from normal capacitors. <S> The Decoupling and Coupling refers to how the capacitors are used, not what they are made of or anything. <S> A decoupling capacitor is used as a mini battery or energy reserve. <S> By placing it near an IC's power pins, it helps keep the power line steady, avoiding the minor fluctuations and ripple that exist in power circuits: <S> A decoupling capacitor is a capacitor used to decouple one part of an electrical network (circuit) from another. <S> Noise caused by other circuit elements is shunted through the capacitor, reducing the effect it has on the rest of the circuit. <S> An alternative name is bypass capacitor as it is used to bypass the power supply or other high impedance component of a circuit. <S> Decoupling capacitors are typically in parallel with an IC or circuit. <S> Coupling capacitors on the other hand : <S> In analog circuits, a coupling capacitor is used to connect two circuits such that only the AC signal from the first circuit can pass through to the next while DC is blocked. <S> This technique helps to isolate the DC bias settings of the two coupled circuits. <S> Coupling capacitors are typically in series with the signal. <S> Both types are typically common non-polarity-specific ceramic capacitors. <A> Coupling and decoupling capacitors are just normal capacitors like any other - it is their application that is being described, not their type. <S> A quick example: simulate this circuit – Schematic created using CircuitLab <S> This circuit is a simple amplifier, taking the signal at the Input node and removing any DC component, multiplying its voltage by -10 (i.e. inverting it with a gain of 10) and adding a 2.5 V DC bias to the Output . <S> Here, C1 is a decoupling capacitor. <S> It decouples the AC from the power rail of the opamp - that is to say it reduces any ripple that might be present on the power rail to stop it affecting the opamp's performance. <S> Additionally it reduces any ripple caused by AC current draw in the opamp affecting the stability of the voltage rail. <S> You can think of it doing this in two equally valid ways. <S> You could say that C1 stores a small amount of energy that can be locally drawn from it to satisfy short-term current demands from the opamp without affecting the power rail voltage by drawing from V1, which may have a higher source impedance. <S> Alternatively you could consider C1 to be a relative short circuit to AC voltages, but a relative open circuit to DC. <S> Hence C1 is "shorting out" the AC on the power rail to ground. <S> Decoupling capacitors tend to be physically located close to the IC they are intended to decouple to avoid the effective of parasitic inductance and resistance of long traces affecting their ability to supply current peaks. <S> C2 is an AC coupling capacitor. <S> It only allows the AC component of any signal at the input to pass through to R2 and hence the amplifier. <S> It blocks any DC, allowing us to avoid amplifying any DC element from a previous stage. <S> This is often useful in instrumentation amplification, audio amplifiers and signal conditioning. <A> Coupling means linking, decoupling means unlinking. <S> It's a function, not a device type, and can be implemented with many different types of caps. <S> Coupling capacitor provides a current path for a (useful) signal between source and destination, like stages in a radio. <S> Decoupling capacitor provides a path for (useless) signal to ground, typically on power rails.
| Capacitive coupling is also known as AC coupling and the capacitor used for the purpose is also known as a DC-blocking capacitor.
|
MOSFET with *actual pin* for body I have always thought that MOSFETs have four pins [see wikipedia ], one of them connected to the body (i.e. substrate). However, when trying to order some, I have been completely unable to find any with a separate connection for the body; all the countless ones I checked had it already internally connected. It would be really nice if someone knew some way (ie. nomenclature or something) to differenciate those! In other words: I am asking for an efficient way to search for MOSFETs where the body is not internally connected. The generally applicable question above is more interesting of course but in case I have missed any possible solutions I will also describe my specific problem: I am designing a quite accurate analogue amplifier and a sample and hold subcircuit. The sample and hold circuit needs an analogue switch with low leakage (the next stage has high input impedance and the usual leakage of a few nanoamps gives unaceptably high voltage errors and drift). I had planned to either use an IC or build a similar cicuit to that shown in the lower right corner of the attached schematic. The trick with that circuit is that Q1 has almost no voltage drop across it when the switch is closed, so it also has almost no leakage. Now the problem I’ve encountered is that the brute force approach of checking datasheets (on the farnell.com webshop) of either MOSFETs with 4 or more pins or analogue switches has not yielded any results after more that 2 hours. The problem with MOSFETs is that they have several pins connected to the same thing (e.g. drain) and all analogue switches I’ve seen have too much leakage current and generally bad documentation. Thank you for your time [English is not my native language; please forgive my blunders or — much better — edit them] EDIT: Whilst the part suggestions are helpful for my specific case, I would also be interested in general terminology as this is more likely to be helpful to others. <Q> The parts on that schematic are very low capacitance (and, unfortunately, that generally means relatively high 'on' resistance) compared to the otherwise nice ones that Ignacio mentions in his comment. <S> The switch is designed to have low charge injection since that directly affects the accuracy of the nulling. <S> You might consider something like the <S> ADG5236 <S> in a modern design, which has 0.6pC of charge injection, which is only 60nV on a 10uF capacitor. <S> Or use an amplifier that has the autozero circuitry internally, but I see you're actually working on a sample-and-hold circuit. <A> The 4 pins shown inside the MOSFET symbol are a representation of the physical structure of the MOSFET. <S> I have seen low-current MOSFETs that DO have the substrate come out as a separate lead <S> but I haven't seen any of those available for several decades. <S> Doesn't mean that they don't currently exist - I just have never needed to find any. <S> Most people use J-FETs such as J112 (N-channel) or J172 (P-channel) for doing the kind of switching that you are trying to do. <A> Take a look at the ALD1115 or ALD1105 from ADVANCED LINEAR DEVICES, INC.It'a a complemantary MOSFET N/P pair. <S> V+ is connected to the substrate, which is the most positive voltage potential. <S> V- is connected to the most negative voltage potential <A> 4 terminal MOSFETs are getting hard to find. <S> A former Micrel P-channel family MIC94030/31/50/51 is now made by Microchip and seems to be in production. <S> https://www.microchip.com/wwwproducts/en/MIC94030#additional-features . <S> Also check out the 4007 FET array IC <S> e.g. <S> https://datasheet.octopart.com/MC14007UBCPG-ON-Semiconductor-datasheet-531527.pdf <S> It has 2 N channel MOSFETs with a shared substrate pin and 2 P channel MOSFETs with a separate shared substrate pin. <S> The P and N gate connections are tied together in pairs.
| However, for the vast majority of MOSFETs, the substrate is an integral part of the MOSFET and can't be separated from the source.
|
Digital signals have two states or interger values Some people have the concept that digital signals are in the form of 0's and 1's.But in a book i got the concept that digital signals can have integer values. Which concept is correct? <Q> You are mixing up the ideas of digital signals with binary signals. <S> It might have 2 possible values, or 3, or 10, or whatever. <S> A binary signal is a specific case of a digital signal that takes two different values. <S> A ternary digital signal can take three different values. <S> In communications, we often use complex modulation schemes that can take one of many different values in each baud interval. <S> For example, quadrature amplitude modulated <S> (QAM) systems might allow 16, 64, 256, or more different values. <S> A clock can have a digital display without any binary logic being involved in its design: (image source: theclockgallery.com) <A> \$n\$ bits (either 0s and 1s) can be combined to code intergers in then range \$0..2^n-1\$. <S> So both statements are true. <S> That's just like in the decimal system <S> several digits (either 0s, 1s, 2s, .. or 9s) can be combined to code integers in the range \$0.. <S> 10^n-1\$. <S> Note that it is not possible to code any interval of real numbers by a finite number of bits/digits. <A> A digital signal is measured in volts with a logic 1 typically being 3.3 volts or 5 volts and logical zero being 0 volts. <S> So, a digital signal can be regarded as having logical values (i.e. 0 or 1) but also can be regarded as having real values such as 0V and 3.3 volts. <S> A combination of digital signals can be regarded as a binary number of several digits in length. <S> Under these circumstances the basic interpretation of the binary value is that of an integer <S> BUT, the designer of the "system" can be representing non-integer values such as fractions or any other conceivable counting system.
| A digital signal is one that takes only discrete values, or, in the real world, one in which we distinguish only a discrete set of values.
|
Alternatives to screw terminals, breadboards for prototypes? Often I want to connect components that operate at less than 5v (I mention this as it may have a bearing on the gauge of the wire?) But have an easy way to disconnect. Screw terminals are nice but they can be slow when there are multiple wires. Breadboards are too fragile for field testing. I was thinking of using RCA audio video jacks and plugs, but they seem so big... Is there something similar but smaller? I'm looking to connect things like sensors and breakout boards. <Q> I like screwless terminals: <S> Wago 2060 series: <S> Wago 233 series: <S> These just require a simple push down of a screwdriver to insert or remove cable. <S> Alternatively if you don't mind screwing the terminals in once, but then want easy disconnect / reconnect, try pluggable terminal blocks: <S> These are also available in screwless types. <A> I use multi-position dupont headers to connect/disconnect multiple pins at once on a PCB or breadboard. <A> I tend to use standard machine-pin socket strips like those used for IC sockets. <S> They are inexpensive, small, very reliable. <S> My connection wire is standard 24 AWG solid copper wire. <S> The wire I use is from multi-pair telephone cable (25 pair all the way up to 1000 pair) that I get from some of the Telco guys that I know. <S> But solid-conductor CAT-5 cable is exactly the same wire and works just as well. <S> These are available from eBay, Amazon, many other suppliers. <S> The search string that I used just now in eBay was "machine pin (socket, strip, breakable)" and one of the items that showed up was 10pc SIP Socket 1x40 40p <S> Pitch=2.54mm Female Screw machine round hole/pin RoHS for US $5.80.
| The advantages of using those machine-pin sockets is that they come in strips that match the spacing of the Veroboard (Stripboard) that I often use for making little doodads. For easy-to-make cable, IDC ribbon connectors are nice, as you don't have to strip the cable, just insert it into the connector and compress gently with a vice. These might be LED displays, or DIP switches (with pull-up resistors) or whatever.
|
Inserting Capacitor into CIrcuit causes LED to fade - Why? My components are 2x 1.5 V batteries 25V 2200uF capacitor 3v Led copper cables My circuit looks like the following. simulate this circuit – Schematic created using CircuitLab My understanding here is that as the two batteries are in linked in series, we now have 3v for our circuit. When completing the circuit the LED starts bright then slowly fades and fades until there is no light at all.Also interestingly if I dissconnect the batteries, wait a minute, and reconnect them completing the circuit, the LED stays off - It does not start bright and fade again. What is actually happening here? Is the capacitor consuming all the power?If I left this circuit complete for a while, would the capacitor gradually consume all the power until it reaches its 25V and then suddenly release 25V instantly? (blowing the LED of course) I actually ran this test because I wanted to try to fill the capacitor up, and then dissconect the batteries hopeing to see the LED stay alight for a while running from the capacitors consumed power.(if this is even possible, perhaps my understanding is not correct) <Q> As cowbydan stated, placing the capacitor in series to the LED will block DC currents. <S> To achieve the desired effect of a glowing LED after removing the batteries you need a circuit similar to this : simulate this circuit – Schematic created using CircuitLab <S> The capacitor needs to be in parallel to the LED and the polarity of the capacitor needs to match the polarity of the connected battery. <S> The resistor R1 is not mandatory in your particular application <S> but it reduces the current which the LED consumes. <S> A larger resistor value will increase the time the LED glows after you remove the battery but will also decrease its brightness. <S> Just test it with some different values. <S> Choosing a LED with a lower voltage rating would require a resistor in series to it to reduce the voltage. <A> Capacitor works like a toilet tank: it keeps the water flowing, until it fills. <S> Then you can discharge it (flush). <S> After you flushed water flows faster, but slows down. <S> Capacitors do similar thing with electricity. <A> Your capacitor is connected in series with the LED instead of in parallel with the anode. <S> The "fading" is the AC coupled impulse from connecting the battery to the capacitor. <S> Capacitors block DC current, so you are starving the LED for current. <A> Nominal 25V on the capacitor means it can tolerant up to 25V input Ithink. <S> What happen to the capacitor is that it store the electricity,not consume, until it is charged up to 3V in the opposite directionto the batteries, meaning that the longer tail of the capacitorbecomes <S> 3V. <S> So then the voltage drop between the LED gradually(thespeed depends on the capacitance of the capacitor) becomes 0V and theLED. <S> Remember, the voltage itself does not tell how much current the device can source and light up the LED. <S> Please connect resistors BTW. <A> A capacitor acts kind of like a break in the circuit, so no current could flow through your circuit. <S> How is it then, that your led lights up for a short time? <S> A capacitor has other characteristics, when you apply DC to it, it starts to charge. <S> Charging means, that is slowly attempts to reach the supply voltage. <S> (3V in your case) <S> the 25V on that capacitor is the maximum voltage you can apply to it before it blows up. <S> So because your capacitor stores electrical energy(charge), when you charge it, it lets current flow, this current causes the led to light up. <S> But as the voltage on the capacitor increases, the less current flows, and the led will fade. <S> Why doesn't this happen after disconnecting and reconnecting? <S> Because the capacitor kept its charge. <S> Capacitors don't magically discharge, when they are charged they act like small fast-depleting batteries. <S> You could discharge your capacitor by shorting it with a small value resistor(not with a wire, as that could cause it to be damaged). <S> Then the led would start fading again. <S> Why doesn't your LED light up again when you disconnect the battery? <S> Because you leave the other end of the led disconnected. <S> If you would connect it to the capacitor with correct polarity, it would light up. <S> (it would need reverse polarity, because currently the positive side of the capacitor is connected to the negative side of the LED.) <S> BUT DON'T DO THIS <S> WITHOUT A RESISTOR, limit the current flowing thorough your LED. <S> Also see @Grebu 's answer for how to make the circuit behave as you first expected it to.
| When you remove the batteries and INSTANTLY connect the LEDwith the LED on the other side, the capacitor might sourcecurrent for a little while, but the electricity stored in thecapacitor might be too small to source enough current to LED you can notice on eyes.
|
How to convert 220V AC @50 Hz to 400V @ 20KHz? Sorry, I may be asking simple question but I'm not specialized in electronics. What I want to do is to increase the voltage from 220V AC to 400V AC. Also I want to increase the frequency from 50Hz to 20KHz. If I can adjust the voltage and frequency, that would be a privilege (I mean the output voltage could vary from 300V to 400V and the frequency from 15KHz to 20 KHz). I know I'm supposed to use transformer to increase the voltage and rectifier/inverter to increase the frequency, but I was wondering if there are any other simple solutions? And how to design and built the circuits? The current here is not important since I'll be using this voltage to generate electric field. <Q> You ought to consider converting to DC then converting back to AC because directly trying to change frequency A into frequency B is too hard to do. <S> That's what I would do. <S> Consider rectification of the incoming AC and smoothing with a capacitor. <S> This will give a DC value of 311 volts. <S> Next, using a MOSFET H bridge driver and a 2:1 step-up transformer you should be able to re-create 400V RMS at 20kHz. <S> For your own safety I would also consider isolating the incoming mains AC via a 1:1 isolating transformer. <S> Another method is to start from a lowish DC voltage (as supplied safely from a power supply) and use a MOSFET H bridge driving a step-up transformer to give you 400V AC. <S> If your power supply is 24V then you'll need a 24:1 step-up transformer. <A> You should be able to use a signal generator to produce the 20kHz, amplify it with an audio amplifier, and step it up with a tube (valve) <S> output transformer (in reverse) to 400VAC. <S> For example, these Hammond transformers. <S> A 10K primary impedance to 4 ohms implies a turns ratio of sqrt(10^4/4) = <S> 50:1, so you'd need to drive the 4 ohm winding with 8VAC (or the 8 ohm winding with 16VAC). <S> They're capable of 30W which is about 16V at 8 ohms, so they should work. <A> with transformers you can manipulate the current/voltage but you can't change the frequency. <S> james
| the way it is done is by using an electronic circuit to convert to a dc voltage, then another electronic circuit using a MOSFET/Transistor H bridge to emulate AC using Pulse width modulation, you can then use an inductor capacitor filter to make it into a proper sine wave.
|
Microchip programming without a -kit? I might be mislead by some pictures of circuits i've seen, but is it possible to program a microcontroller (e.g. pic18) from a computer without a kit (e.g. pickit), but just with a self build circuit and software? EDIT1: If it is possible, it would be great if point me in a direction where I can look for instructions on how it's done. <Q> Just to program a PIC, many devices can be used. <S> The official Microchip Programmers section of their website lists quite a few devices, most aimed at the professional market. <S> The PICKit3 can program and also do hardware debugging for many PIC IC's, which will save you countless hours of frustration. <S> For more serious work, an ICD3 in-circuit debugger does all of the previous, is faster, supports more devices, and is considered a "production-level" programmer. <S> For really serious work, a RealICE in-circuit emulator does all of the previous plus emulation of most PICs, allowing you ultimate freedom. <S> Of course, that comes with a steep price tag. <S> As for non-Microchip offerings, there are many. <S> My first programmer was a PICAll parallel-port kit. <S> @Wouter Van Oijen next tempted me with his Wisp programmer, but time was limited and computer failures halted it. <S> Then I used a usbpicprog from @Frans Schreuder for awhile after a new computer build excluded the parallel port. <S> I finally was "forced" to get an ICD3 for fast debugging and that has remained the tool of choice. <S> There are likely many more, and simply googling "PIC Programmer" returned 1.9 million hits. <S> As others have said, one of these programmers are needed for programming a blank PIC. <S> Many PICs can be initially programmed with bootloader code however, which makes them no longer require the initial programmer. <S> Instead, once initially programmed with the bootloader, they are connected to either a serial or USB port, and software sends the .hex code to the PIC over that connection. <S> The bootloader's job is to receive that data, and program it into the remaining code space. <S> There are many links to PIC bootloader info and tools at the Microchip Forum , including AN851 <S> which discusses the nitty-gritty details of how the bootloader works and the serial method for communication. <A> The Microchip Curiosity cost $20, and allows you to program a bunch of different devices.www.microchip.com/curiosity. <A> There are two ways to done this <S> You use proton-IDE development software which come with boot loaderfirmware file for each PIC controller. <S> You have to programboot-loader in target PIC using original programmer after that youcan program PIC using USART TX and RX <S> pin directly through serialport. <S> But using this method you do not able to use the option ofhardware serial communication... <S> Not to worry Proton IDE provide yousoftware serial option from which you can use any pin for serialcommunication. <S> There is a programmer PCB available on internet <S> brenner8 you can canmake your own programmer. <A> To burn HEX files(Program) on PIC18 you need another PIC MCU which takes data from USB/Serial Port and translates it for the Target MCU. <S> To enter programming mode on target MCU certain voltage is required on reset pin <S> Though low voltage programming is now a norm <S> As mentioned before, you need another PIC MCU - hence the bootloader. <S> There are lot of DIY PICkit clones tutorials. <S> But you need to program a PIC for it. <S> So, it is a deadlock if you don't have a PIC programmer kit on hand. <S> Maybe borrow it
| You could use a development board that has a built in programmer, such as "curiosity".
|
Ignore Pulses Less than a Given Width in a Pulse Train Let's say I have a 5V pulse train that varies between 0 and 75000 pulses per second. Pulse width, let's say, is 5 microseconds. How could I calculate or determine the best way to filter out all pulses less than 4 microseconds in width? <Q> This circuit should do what you want: <S> When a pulse comes in on the lead marked IN, it starts the first 74221 monostable (there are two in the same package) which is set for 4 µs. <S> The output of the monostable \$\small \overline{\text{Q}}\$ pin will be 1 until it is started, then it goes to 0. <S> So during the 4 µs period, the AND gate (74HCT11) is inhibited <S> so there is no output. <S> After 4 µs, the AND gate is enabled again, so the rest of the pulse (if longer than 4 µs) goes through to OUT. <S> See the timing diagrams below. <S> Since 4 µs has been cut off the beginning of any valid pulse, the second monostable is started on the falling edge of the input pulse (but only if it is longer than 4 µs), and the output remains high to add an additional 4 µs to the end of the output using the OR gate (74HCT32). <S> Thanks to stefandz for pointing out the need for this additional functionality. <S> The buffer marked DS1100Z at the bottom <S> is actually a delay line with a delay of 100 ns; this is to compensate for the propagation delay in the 74123 from trigger to output. <S> Note <S> because of the tolerance of the capacitor, this timing could be off by 10%, so the resistor should be tweaked as necessary. <S> By using monostables, it is trivially easy to modify the timing value from 4 µs to something else just by changing a the resistors and/or capacitors. <S> Power pins (Vdd and Vss) and decoupling caps are not shown. <S> I was originally going to use a 555 timer, but it turns out the 555 is not supposed to be used for pulse widths less than about 10 µs. <S> So I turned to the 74221, which can generate pulses down to the ns range. <A> simulate this circuit – <S> Schematic created using CircuitLab <S> The middle box in the circuit above is a six-bit synchronous-reset counter; every clock pulse will either reset it to zero (if RS is low) or advance the count (if high). <S> As shown, the circuit will reset the counter on each cycle where the out matches the synchronized value of the input, or increment the counter if they don't match. <S> If there are 48 consecutive cycles where they don't match, the Q4 and Q5 of the counter will both be high. <S> On the next cycle, the counter will be reset (regardless of what the input does) and the output will change state. <S> If the clock is 10Mhz, This circuit will filter out both high and low pulses shorter than roughly 4.9us, and will round all pulse timings to the nearest 100ns. <S> There are many ways to vary the circuit to implement various kinds of filtering, but the key point is that the input is synchronized to a 10MHz clock and everything else in the circuit runs off the same clock. <A> I'd prefer to put this in a comment but cannot. <S> Since no error spec was given, is it possible, to switch from a time domain problem to a voltage again, by integrating the pulses and using a comparator...? <S> The 0-75kHz range is inconsequential <S> I think and we only need care about the pulse width, ~4us. <S> If the OP can get a reasonably linear rising edge this might work...? <S> Cheers
| In many cases, the simplest approach is to use a synchronous logic circuit which samples the incoming signal at some rate (e.g. 10MHz), ensures that it's synchronized to that clock (passing it through a couple flip flops is a typical way to do this), and then applies whatever logic is needed in purely-digital fashion.
|
Resistor will heat up on what amount of current? I tested a 470 ohms resistor with 35mA DC current flowing and my resistor is heating up. On my final design I have created a voltage divider circuit using R1=10k ohms R2=220 ohms maximum input voltage is 220 Vdc maximum DC current would be 21.5mA DC I've only tested a maximum of 20Vdc as an input because I don't have available 220Vdc. I wonder if my R1=10k ohms and R2=220 ohms resistor will heat up on maximum DC current of 21.5mA Is there a way to calculate whether it will heat up or not? <Q> However, we can get a good idea of whether we are designing within the recommended specification of the resistor in question by calculating the power consumption. <S> Most cheap through-hole resistors (which I am going to assume that you are using) are rated at 0.25W <S> - they tend to look like this: <S> The power dissipated in a resistor can be calculated in many ways, but the most useful for us here is <S> \${P=I^2R}\$ <S> Calculating that for the 220 Ohm resistor gives \${P=0.0215 <S> ^2\times220=0.102W}\$. <S> You can see that this is close to the maximum rated 0.25W, <S> but well enough within for the temperature rise not to damage the resistor. <S> Now let's examine the same for the 10kOhm resistor: <S> \${P=0.0215 <S> ^2\times10000=4.62W}\$! <S> This is way above the power rating for this resistor, and it will very quickly heat up, glow, and then burn off the resistive element, releasing smoke and causing your circuit to fail. <S> So how do we fix this? <S> There are two options. <S> We could choose a 5 Watt resistor so that the power consumption was within limits. <S> This will still work, but the 5 Watt resistor will get too hot to touch and will need to be mounted so that it is exposed to airflow and away from wiring and other components so that it cannot damage anything else. <S> We could increase the values of the resistors used. <S> If you chose a 470k resistor to replace the 10k resistor you are currently using and a 10k resistor to replace the 220r resistor, your divider ratio would be almost the same (you can calculate this yourself) but the power dissipation in the 470k resistor would be only 0.098W - well within specification again. <A> The important resistor for heating up is the 10k resistor. <S> Current is 21.5 mA and this will cause a power of 4.63 watts in the 10k resistor. <S> I would recommend a 10 watts resistor for 10k <S> OR, if you can use 100k and 2k2 then consider doing that. <S> Using a 100k resistor means the power will be slightly below 0.5 watts so you might get away with a 0.6W resistor. <S> You can always put two 50k resistors in series - they will share the power. <S> You could also put two 200k resistors in parallel and achieve the same result. <S> Choosing a resistor that is as high as possible without compromising performance is the name of the game. <S> As we do not know what the potential divider feeds this upper limit cannot be calculated/estimated. <A> You are talking about burning almost 5W in order to measure a voltage. <S> You need some way bigger resistances, I'd say at least 1M and 22k. <S> If your micro-controller has a reliable, exact impedance on the measurement gate, you could simply use that instead of R2, along with an R1 suited to the value.
| The temperature rise of the resistor will depend on many things - its thermal impedance to air, what it is soldered to, what type of resistor it is and how much airflow there is across it.
|
Accounting for temperature changes in circuit design In my last post about a simple circuit: +12V -- R1 -- LED1 -- LED2 -- LED3 -- ground A user said: ...you should account for temperature changes and variation between parts. Not all parts (even of the same part number) will have the same Vf, even at the same temeprature, and your circuit design needs to be robust enough to account for that, not carefully tuned to the exact nominal behavior of a part type. Practically speaking, using my simple circuit as an example, how does one account for temperature changes and variation between parts? Would simply using a 150Ω resistor in series with the three LEDs not work? Edit: The circuit will be operating in temperatures of around -10°C to +150°C <Q> The forward voltage of the LEDs will drop significantly with a temperature increase of 125°C, perhaps 0.7~0.8 volt for a string of 3 (check the datasheet for the particular part). <S> That will mean that the current will increase by maybe 25% at high temperature. <S> Since the allowable current probably drops to zero at 150° <S> C Ta <S> this is the opposite of what is desirable (will tend to kill the LED even more readily at high temperatures). <S> On the other hand, 25% will not be all that visible a change in light output. <S> Bottom line is that temperature is not too important to visible light output if you have at least 1 volt per series LED across the resistor and temperature change isn't insane. <S> Light output also changes with die temperature, so the current isn't the only factor. <S> /K which is 1% for 100°C change. <A> As so often: it depends... <S> Your circuit is NOT robust if the sum of the forward voltages of the diodes is close to the supply voltage. <S> Two examples: <S> Eg. <S> 3 blue LEDs: <S> \$V_f\$=3.7V, sum is <S> 11.1V. Current is (12V - 11.1V) <S> / R = 0.9V / R. <S> An increase of \$V_f\$ by only 0.1V would cause a current of (12V - 11.4V) <S> / R = 0.6V / <S> R. I.e. a decrease of 33%. <S> That's a lot. <S> Eg. <S> 3 red LEDs: \$V_f\$=1.8V, sum is <S> 5.4V. Current is (12V - 5.4V) / <S> R = 4.6V / R. An increase of \$V_f\$ by 0.1V would cause a current of (12V - 5.7V) / R = 4.3V / R. I.e. a decrease of only 6.5%. <S> That's not so much. <A> (note everythin in degrees celsius) <S> I searched for LED Vf over temperature, and some can get 30% reduction of forward voltage over \$100^\circ C\$ 5,56 V instead of 7,98 V (2,66V nom. <S> Vf) gives 26 mA for normal temp and 43 mA for 100 degrees rise. <S> That is worst case. <S> (assuming no temp change or constant temp in resistor). <S> Resistors have tempcos in the order of 3000ppm/C and less (many have 250ppm <S> /C) so say in the case of a resistor with 250ppm, the resistor is going to increase with 3,75 ohms over \$100^\circ C\$, basically nothing compared to the Vf. <S> So for me 100% difference equals no regulation at all. <S> I would use a thermally compensated current mirror for best regulation
| You can typically ignore the resistor change in temperature - even a crummy resistor will not change more than 100ppm
|
Why is 433 MHz used widely in RF modules? I was planning to interface an RF module to my PIC16F877A microcontroller and was exploring the web. I came across many modules which use 433 MHz as the standard frequency. Why is it so? Can't we change the frequency as per our requirements? <Q> The usage of frequencies is restriced by authorities in each country. <S> The 433 MHz ISM band is free to use in many countries and thus very popular. <A> For example it is license-free in all European countries. <S> This is nice, since applying for a license is bureaucratic, has to be done nationally, involves a yearly fee, and is restricted to a geographic area. <S> However, the European Union has tried to harmonize the use of radio frequencies, adding some restrictions to the 433MHz band: "Short range devices" (generic radio) using 433.050 to 434.040 MHz are not allowed to use an output power greater than 1mW (or 10mW in case they use 10% "duty cycle"). <S> They are allowed to use 10mW from 434.040 to 434.900. <S> National exceptions to this still exist, and unfortunately radio amateurs are excluded from these power requirements. <S> And in other countries in North America and Asia, you can't use 433MHz at all. <S> In some countries it is a restricted band for RFID container identification systems only. <A> Taking into account that whole automatic branch uses 433MHz <S> I don't recommend You to use this frequency. <S> I have done my engineering project with this modules: <S> http://www.ebay.com/itm/433MHz-Radio-Transceiver-Transmitter-Sender-Module-Remote-Arduino-/252184498733?hash=item3ab75e122d:g:MyAAAOSw2xRYWe46 <S> so I know what I'm talking about. <S> If You want to save Your time, use any other frequency, for example 868MHz or 2.4GHz. <S> 433MHz is full of noises. <S> For instance if Your neighbor uses wireless thermometer be sure that You can receive nothing.
| This is because traditionally, the 433.050 - 434.090 MHz band could be used without license in many countries.
|
How to lower the RPMs in small a DC motor I make Christmas ornaments for a living. I have an idea that is a tube that is 18" tall, 6" diameter. I need it to slowly spin at around 5-10 RPM. Please keep in mind that I need this to be as cheap as possible. This design is versatile and can accommodate any method. It will spin easily because it will be spinning on a needle point, and there will be a 2" high hollow base for any parts. I have plans for using gears or pulleys, but I was hoping that I could alter the speed of the motor somehow instead. Thanks for any advice and please keep in mind that I need to do this as cheap as possible. <Q> Theoretically, it's possible, but in reality, you won't be able to without your own control circuit, or doing something that might damage your motor. <S> The reason for this is because standard DC motors will require a minimum amount of power to operate. <S> Here's a section of a datasheet for a 3V-4.5V DC motor: <S> At the graph in the bottom, you see that the motor speed (in RPM, symbol N), there's pretty much no way you're getting it down to 5-10RPM, unless you can change physics. <S> A couple of things you can do: <S> Use gears to change ratio of speed, which is what you're going to do. <S> This is probably the most simple, cheapest, and safest option, in my opinion Use a stepper motor, which are commonly used for high-torque, low RPM applications <S> Things you shouldn't do <S> (you probably already know this, just leaving this here for others): <S> Use some sort of physical restriction to slow it down (i.e. weights). <S> This is bad. <S> It could burn out your motor, and put a lot of stress on your power supply (if it's not mains), and even if it does work, you're going to be running very close to stall current for a long duration of time, which is wasting A LOT of power. <A> Goofy suggestion; if it is that tall with that large of a diameter, and it's rotating on a pinpoint, could you just put a light inside it with radial airfoils at the top of the cylinder and let it rotate solely powered by convection currents of the air heated by the lightbulb? <S> (In the late 70's when I was a kid, I had a Star Wars light in my bedroom that operated this way. <S> It was soooo awesome...) <A> As you mentioned 5-10 RPM, I advise to go for a small gear-set rather than any control circuit (I can't guarantee <S> but it might not be possible at least for a low price).
| Find some sort of PWM control circuit to slow it down, although you probably won't be able to get it down to 5-10RPM Gear-set will be inexpensive and will be easily available at robotics or hobby shop.
|
Operating an SD card module with only two pins My standard SD card module uses four pins: SDCS, MOSI, SCK, and MISO. However, I can only dedicate two pins of my ATtiny85 to operate it. Is there a way I can do this without using more ICs, such as for example a second, bigger microcontroller? Keep in mind that: I only need to write to it. I can do as much testing as necessary at start, but then it has to work on its own with only two pins. I can add one or two discrete electronic components, as long as they're few and small. The other pins are taken by a GPS module, which uses serial (RX-TX), and a crystal. <Q> Scenario 1: <S> You still need to read the file allocation table from the SD card unless: you use your own RAW SD card format <S> Then you don't need the MISO pin. <S> So instead of four pins for the SD card, you need three. <S> It is possible to set a fuse in ATtiny85 that will turn the reset pin to a regular I/O pin. <S> Now you have three pins you can use to talk to the SD card. <S> You won't be able to use an ICSP programmer after you do that. <S> Scenario 2: Share SD card pins with GPS. <S> Connect the RX pin with SCK. <S> When you talk to the SD card, the GPS will receive garbage and will ignore it. <S> When you talk to the GPS, keep the CS pin high and the SD card will ignore it. <S> Connect the TX pin via a 10k resistor to the MOSI pin. <S> When you talk to the SD card, use the MOSI pin as output. <S> Communication won't get disrupted by the GPS, because it's behind the resistor. <S> When you need to listen to the GPS, keep the MOSI pin as input and CS high. <S> The SD card will ignore stuff coming from te GPS on that pin. <S> Scenario 3: <S> A combination of the above Scenario 4: Just use ATtiny84; it's almost the same as ATtiny85 with more pins and the same footprint in a QFN package anyway, if you care about size. <A> This will likely not work using a reduced SPI interface. <S> You might be able to use an I2C to SPI bridge chip, but the parts are not cheap and likely 'big' for your design. <A> Simple method: This type of SPI bus can share pins with other SPI devices. <S> MISO, MOSI, and SCK are shared, and each component will need its own CS line. <S> Do you have other SPI devices in your design that can share the SD card's bus? <S> Other method: <S> On some SPI devices the CS line can be tied low so that the bus is always enabled. <S> However, most require a down-edge on the CS line to mark the beginning of data transfer, and an up-edge to signal the end of a command. <S> If you can tie the CS low, then that omits one pin. <S> But are you truly only writing? <S> There are generally read operations as part of the overhead, if only to verify that the SD card is available/seated/etc. <S> The SCK and MOSI are always necessary. <S> It just might work :) <S> But if your device needs the CS toggling, then I don't see a straightforward way to have what you want. <A> Ditch the crystal. <S> The internal oscillator is plenty accurate for sampling a 9600 baud serial signal from the GPS, and you're mastering the clock on the SPI interface, so <S> timing isn't critical there either. <S> If you're looking for an accurate wall clock timestamp for logging, it's hard to beat a GPS signal. <S> However, even without that, internal oscillators are usually "good enough," unless you're doing a precision autopilot or something like that.
| Yes, you can use it to correct drift. If you are only writing then you can omit the MISO line.
|
How can embedded systems estimate their battery status so precisely? As I understand it, the terminal voltage of batteries changes a little on charge/discharge, but these changes are minimal compared to other effects (temperature, minor manufacturing differences, recent charge/discharge history, etc). But even the oldest mobile phones could show a charge icon. And it works correctly even in the case of a battery change. How is this possible? <Q> There is one thing which is obvious once stated, but not until then. <S> Your phone tells you it has "37% Charge Remaining". <S> How do you know that's accurate? <S> It's probably not. <S> Then it presents you with its best guess. <S> Over time, it can build up a reasonably accurate profile for the battery and use that to improve the estimates. <S> But it is usually an estimate. <S> In my experience of developing battery based systems (with smart batteries, dumb NiCad, and everything in between) <S> the only times you are confident of the charge level are 100% and 0%. <S> Usually, a smart battery will let you know when it's fully charged, and with a dumb one you are probably doing some calculations with current and temperature. <S> That takes care of the 100% case. <S> The 0% case is where the sneakiness comes in. <S> Whatever the battery chemistry, there is often a distinctive pattern in the discharge curve as you approach voltage collapse. <S> But allowing a battery to go into deep discharge is generally a "Bad Thing" (TM). <S> So firmware looks for that pattern and decides when the battery is at a virtual "0%". <S> Then it shuts the system down so that there's enough residual charge in the battery to avoid deep discharge and, more importantly, a sudden loss of power. <S> This allows a graceful shutdown. <S> If this seems a little unlikely, let your phone "run down" and shut itself off. <S> Then turn it back on again. <S> If the battery were truly at 0%, it could not boot and power up the screen to tell you it needed charging. <S> The 5% (or <S> perhaps 10% depending on the precision of the measurements and the batteries tolerances) <S> warning is also often somewhat artificial, again representing a point on the discharge curve when the firmware starts thinking "Going to shutdown soon". <S> Ironically, this is the level at which someone in marketing insists that you turn on that bright LED to tell the user they are about to run out of battery power. <A> As you mention, the voltage changes a little bit on charge/discharge. <S> Millivolt-level measurements are reasonably straightforward, and every battery chemistry <S> I'm familiar with has a voltage change of at least a few hundred millivolts between "full" and "effectively empty". <S> Most battery discharge curves are linear, at least over the range that most devices use them. <S> Because of this, you can get a rough estimate of the remaining charge by remembering the last voltage peak (corresponding to full charge), knowing the voltage level at shutoff, and interpolating between them. <S> For more precision, you can either program the device with the typical discharge curve for the battery chemistry you're using, or have the device measure it during a "conditioning" charge-discharge cycle. <A> The "charge icon" represents the State of Charge (SOC) of the battery - which is normally a percentage figure. <S> Different battery technologies are managed in differing ways... <S> Some have a sloped discharge curve - <S> you know that a given voltage at a given temperature represents a given SOC. <S> Others are less helpful (eg lead/acid) and have a very flat discharge curve, in that they provide X volts right up until the point of expiry, <S> then pretty much 0 volts thereafter! <S> These require a level of input/output counting - and recalibration at the 0%/100% levels. <S> Most consumer devices offer a fairly crude SOC - but it is also dependant on the State of Health - which represents the state of the battery over its lifetime. <A> Here is an example of a coulomb counter: http://cds.linear.com/docs/en/datasheet/4150fc.pdf which can be used to fairly accurately measure the charge used in real time of a specific battery, in this case a Li ion 1-2 cell or 3-6 cell NiCd or NiMH batteries. <S> It accomplishes this by simply measuring the current across a very small (micro ohoms) known resistor and then using that over time to derive mAHrs consumed,
| The software may be doing some estimating based on average current draw since it was fully charged, average time between charges, and of course the discharge characteristics for the specific battery.
|
120v 1,500w heater: is the temperature control knob most likely a standard potentiometer? Are the temperature adjustment knobs on most high-power AC (infrared or radiant) heaters just standard potentiometers, the same that would be found in low-power DC devices? I'm asking about the knobs that go from "low" to "high", not ones that list a specific temperature (like "76F"). More information (in response to comments): I haven't yet opened the actual heater I'm referring to (it's difficult), but coincidentally I chanced upon an already-opened radiant heater and took a picture of the back of the knob and the internals. What do you think it is? Is it safe to assume that a similar device is controlling my 1,500 watt IR heater? It's difficult for me to open the 1,500 watt unit, otherwise I would have done so already. (I tried to post links to the heaters, but it wouldn't let me because I don't have enough reputation). UPDATE: I finally took apart the IR heater that I was originally referring to. Sorry it took so long. It wasn't easy. Here is a picture: I tested the resistance on the 2 contacts, and it starts at 260K at the lowest setting, ending at around 80ohms at the highest heat setting. <Q> I don't think so. <S> I think they are usually more like a thermostat for central heating and air conditioning. <S> They mechanically adjust the operation of a bi-metallic device that opens and closes an electromechanical switch. <S> EditIn order to have more than some conflicting opinions <S> , you might post a picture of the type of device that you are asking about. <S> Can you determine if there is some kind of electronic power control circuitry. <S> Is this a plug-in portable heater of some kind? <A> It's a potentiometer that adjusts the firing angle of an SCR. <S> An SCR can be used as an inexpensive controller for a heater, by adjusting the firing angle you are controlling how much power is delivered to the heating element. <S> SCRs only work on half the cycle. <S> To gain a bit of efficiency, but also complexity a triac can be used. <S> It will work like an SCR, but on both the positive and negative cycle. <A> Yes, but not in series with the heating element, but rather to control the switching of a Triac. <S> http://www.learnabout-electronics.org/diodes_07.php gives an overview how these circuits typically work.
| It seems to me that any heater that is controlled by a "high-low" knob is unlikely to have anything but an on-off control scheme.
|
a microcontoller pin stuck permanently at 0 Is it possible in general to have a pin of any uC stuck at 0, including when the power is off? Particularly I'm interested in stm32f3 <Q> Yes it is possible, even likely. <S> Sometimes the circuitry is more elaborate, but often there are simply reverse diodes to power and ground. <S> This means that when the power voltage is 0, the protection diode of a pin will conduct if the pin voltage would otherwise exceed the diode turnon voltage, around 600 mv. <S> Since that is a logic low level for just about any digital input, pins of unpowered micocontrollers on the same ground will read as low. <S> In general it is not good to allow too much current to flow thru the protection diodes. <S> If the diodes are beefy enough, then you can sometimes power up or partially power up the micro by forcing a I/O pin high. <S> However, expect it to act flaky. <S> Power current won't be flowing thru all the intended paths, and the power voltage will be one diode drop below whatever you are holding the pin at. <S> This also raises the whole power net the micro is connected to, which can have other unexpected consequences. <S> If the power net draws too much current, the diode will blow out. <S> Now the pin will be well above the power voltage of the micro, which probably damages a few more things in the micro. <S> Another issue is SCR latchup when real power is applied normally. <S> Due to how the chip is constructed and how the substrate is biased, current flowing into a pin while power is coming up can cause a sortof SCR latching effect. <S> This will draw lots more than the usual current of the micro, which can damage the micro, the power supply, or both. <A> Without more detail I have to make some guesses. <S> When the power is on and you are expecting a logical 1 but are measuring a logical 0, here are some typical errors: Forgetting to configure the pin as an Output. <S> For the ARM architecture <S> : Forgetting to enable the pin to function as GPIO. <S> For the ARM architecture: Forgetting to enable clocks to the port. <S> Improper voltages one of the power rails (Some fancy micros have multiple rails/internal regulator/etc. <S> Be sure to read the data and verify that all voltages are square with a meter). <S> The pin or entire microcontroller have been damaged. <S> Make sure the code is actually running (set a breakpoint in main and check with a debugger). <S> When power is off: The voltage (measured to the part's ground) is floating (very high impedance) so will likely read zero with a meter. <S> This is the expected behavior <A> If it is apparently connected to Vss with power off and it is a GPIO <S> then it is probably damaged and internally shorted. <S> You will probably notice an increase in supply current if you try to drive it high with power on.
| Most pins have overvoltage protection circuitry on them to keep small capacitive discharges from damaging the chip.
|
Using frequency to turn a circuit on I would like to run 3 circuits and turn them on based on a frequency input from an audio source. I would like to turn on a circuit at a mosfet gate for example with tone A at 100Hz tone, B with 1kHz, and C with 10kHz. I this this may be possible with 3x band/low/high pass filters of some find but in my modelling I seem to have residual talk from the different channels/frequencies.Is there a way to achieve this with simple analog electronics? <Q> This is a fairly simple task for a DSP (Digital Signal Processor) such as the Microchip dsPIC family. <S> The DSPIC33FJ32GP102 for example, with 32KB of flash and 2KB RAM, costs $3.19 in single quantities in a simple to use DIP package. <S> The most efficient way to detect tones like this is to use the Goertzel algorithm . <S> Microchip provides a library for the dsPIC processors for detecting DTMF frequencies which I have successfully used in a project. <S> It uses the Goertzel algorithm to detect two simultaneous tones, selected from 16 frequencies spaced fairy close together (a few hundred Hz). <S> So your situation is even simpler since you only need to look for one tone (or you can use it as is for DTMF). <S> The full source code for the library is provided <S> so you can modify it per your needs, including Goertzel.s. <S> As set up, the library uses a tolerance of ±1.5% to validate the frequencies (±1.5 Hz for the 100 Hz tone, ±15 Hz for 1 kHz, and ±150 Hz for 10 kHz); and 40 ms minimum to detected a tone. <S> These parameters should be fairly easy to modify. <S> The 1.5% percent is would be necessary if you were to stick with DTMF tones, since they are fairly close together (hundreds of Hz), but if you were to use your propsed 100 Hz, 1kHz and 10kHz <S> then ±10% should be doable. <S> Here's a project someone did to detect ambulance sirens using a dsPIC. <S> (It used FFT instead of Goertzel but still an interesting read.) <S> Note that if you don't already have a circuit for generating the tones, you can use a second dsPIC <S> for that. <S> Microchip has a DTMF send library in addition to the DTMF receive which you could modify (either to use as is for DTMF, or modify for a single tone). <A> Consider using a frequency to voltage converter: - Then adding window comparators to produce enable outputs at the three frequencies needed. <S> The values in the circuit above may not be ideal for the frequency range you are looking at so some tweaking may be necessary. <S> There are other ways of converting frequency to voltage <S> so I'd encourage you to google the possibilities (maybe the LM2917 or the ADVFC32 . <S> The AD part can cope with a range from virtually DC to 500 kHz. <A> It would likely be easier to do this with a DSP, but in the spirit of the question there is a simple discrete solution based on the architecture you described above. <S> I am not completely clear <S> what behavior you are looking for at the in-between frequencies <S> but I will assume you want exactly one of the circuits on at all times. <S> Therefore I suggest the following tweak on your plan: By having only two filters and comparators, I can then post-process with logic gates to get the desired behavior. <S> The envolope detectors are just these . <S> Best of luck! <A> They incorporate multiple frequency generators clocked to a (typically) 3.579545 MHz crystal. <S> They've gotten harder to find since there are more modern ways of signalling remotely, but the surplus shops still carry DTMF encoders and decoders. <S> I see Jameco has the TCM5089 on closeout for $4.95. <S> An example of a corresponding detector would be the SSI202 from Silicon Systems. <S> I believe it was multiply sourced. <S> There were also versions of the generators that were designed to be controlled from a microprocessor as opposed to a keypad. <S> Going a bit further, I'm sure that there is code out there for the popular microcontrollers to do the same thing, <S> but I've never had to use it.
| If you don't need to use specific frequencies, consider using DTMF (Dual Tone Multi Frequency) ICs used for telephone signalling.
|
What is the purpose of a pull-up resistor in a microcontroller? I'm reading about the AVR microcontroller. In a chapter on I/O ports I've stumbled accross a concept that I have trouble understanding: the pull-up resistor. Here is a quote from the textbook: PORT register role in inputting data: There is a pull-up resistor for each of the AVR pins. If we put s into bits of the PORTx register, the pull-up resistors are activated. In cases in which nothing is connected to the pin or the connected devices have high impedance, the resistor pulls up the pin. See figure 4-4. If we put 0s into the bits of the PORTx register, the pull-up resistor is inactive. And the associated diagram: Now, bear with me; it is my understanding that we control the data direction of the ports by writing 1s or 0s in the DDRx register. So if I want to read data from a port I clear the DDRx register (0s) and get my data from the PINx register. Conversely, if I want to write data I set the DDRx register (1s) and write to the PORTx register. Okay? So the book gives assembly-code examples of how we activate the pull-up resistors of a port. We do this by writing to the PORTx register without setting the DDRx! What is the function or desired effect of doing this? It is not clear to me, even after having read half of the book. <Q> A pull-up resistor does two things: <S> Prevents the pin from floating Floating CMOS inputs can result in increased power consumption, or in some cases even destruction of the device. <S> A pull-up holds the input to a known good state. <S> Defaults the input to a high value <S> This is useful when dealing with open-drain outputs that work in a wired-OR/pull-down fashion such as interrupt lines, or even with simple buttons. <S> It also causes the input to source a small amount of current for detection purposes, but this usage is much less prevalent than the previous two. <A> For example a switch may connect the pin to ground when it is closed. <S> When the switch is open, we need to connect the pin to a logical 1. <S> The pull-up archives this. <S> The pull-up could be external but using a micro with the possibility of internal pull-ups saves cost and board space. <A> There is something called a datasheet and it (and application notes and reference manuals from the manufacturer or IP owner in the case of ARM) should always be your first point of reference. <S> The pull-ups are described as so in the full datasheet: <S> As you can see, the pull-up is automatically disabled when the output is enabled or the global pull-up disable is active.
| The pull-up is used to keep the input from floating for certain input types.
|
I need load capacitors on crystal? Using external PLL clock Multiplier ICS501A The crystal is http://www.txccrystal.com/images/pdf/ab-automotive.pdf I need load capacitors on crystal ? <Q> However I would put the locations for the capacitors on the PCB but leave them unstuffed (i.e. don't populate any capacitors). <S> If for some reason you do need extra capacitance or you have to change your crystal supplier to one that needs more capacitance <S> then you are covered without having to spin the PCB. <S> The sort of problems you might have is that the frequency is slightly incorrect (eg a bit high) or the oscillator does not start reliably. <S> In those cases you may need to experiment with adding capacitance. <A> Yes, typically. <S> With the clarifications to the question, and responses from others, it appears that the specific IC crystal driver in question contains sufficient load capacitance and/or compensates for a 12pF load. <S> However, I strongly agree with @SpehroPefhany as he writes eloquently about this topic: <S> In my opinion, it would be prudent to put a couple 0402 caps in the schematic/layout anyway <S> (marked DNP - do not populate), just in case you have to use a crystal with a higher load specification at some time in the future. <A> The formula is right on the ICS501A datasheet . <S> Since your crystal datasheet says the default load the crystals are designed for is 12pF, then you don't need them (unless the load capacitance of the crystal you bought is other than the default 12pF, in which case use the formula above). <S> If the crystal was designed for less than 12pF <S> then you probably shouldn't use it. <S> In my opinion, it would be prudent to put a couple 0402 caps in the schematic/layout anyway <S> (marked DNP - do not populate), just in case you have to use a crystal with a higher load specification at some time in the future. <S> To tell what crystals you have (or should order) refer to the part numbering system for this vendor:
| Since the load capacitance required for the crystal and the ICS501A datasheet indicates that zero is required for a 12pF crystal you don't actually need any additional capacitance.
|
Driving LED with PIC 5V I have always been taught to driver an LED using an MCP using the following method (Driving the pin high) as shown in the diagram below: However I have recently seen LED's being driven using the following method as shown in the diagram below. I assume in this method the LED is driven when the digital pin is set to low. Which method is best practice and why? <Q> The source currents and sink currents can be different for a device, also the internal voltage drop for both cases can be different. <S> For the used PIC16F1847, you can see on the datasheet page 355 that the sink current is 8mA at 5V and the source current is only 3.5mA at 5V, these values also change in respect to the supply voltage, so you should be aware of that in your design too. <S> The next thing you might want to consider is, that the voltage drop can be different and thus the heat generated in the MCU. <S> In your case the output high voltage is guaranteed to be more than \$V_{DD} - 0.7V\$ and the low voltage is guaranteed to be maximal \$0.6V\$. <S> So for sourcing current the voltage drop might be higher and thus your MCU will get hotter - it might be a limiting factor or not, <S> depends on the currents you are looking at. <S> Some devices also have a total limit for sinking and sourcing currents which might differ also because the number of pins used to supply voltage and ground to the device can be different. <S> Microchip is actually providing a more detailed graph on the behaviour of the pin source and sink capability beyond those numbers mentioned before on page 400 . <S> There you can also see what influence the temperature has, as well as how much of a voltage drop you get at different currents. <S> For this device I'd say it copes much better with sinking currents than with sourcing them, so the second configuration might work better overall. <A> It is possible that the first circuit does not work depending on the internals of the MCU. <S> Usually, a pin can source or sink a current. <S> In this case, it does not matter, which circuit you choose, only the logic will be inverted. <S> This sketch may give you an idea how this works inside the MCU: <S> simulate this circuit – <S> Schematic created using CircuitLab <S> Depending on the state of the output, one of the LEDs will always be on. <S> But a pin could also be an open-collector output, which can be sketched like this: <S> simulate this circuit <S> An open-collector can only sink current, so the LED circuit works only in the direction shown in my sketch. <S> I'm familiar with Microchips PIC18F2550/2455/4550/44555 family, which have the RA4-"feature". <S> While all outputs are CMOS outputs, RA4 is an open drain output and I guess everybody using this MCUs once forgot that. <S> However, an open collector/drain output also has the advantage of switching voltages higher than the MCU supply voltage. <S> The mentioned MCU can switch up to 8V on RA4, even if itself is only powered by 3.3V. For your PIC16F1847, check the tables on pages 13-16 of the datasheet . <S> All <S> I/Os are of type "CMOS", but you'll find pins which will be "OD" in I²C mode. <S> But this is by general I²C design. <S> So, it does not matter which direction you choose for an LED at your MCU. <A> Sink or Source? <S> Which one should you use? <S> In most cases it is a matter of personal preference. <S> To turn on LED 1 you need to set the PO register bit to a zero. <S> To turn on LED2, you set P1 to a logical 1. <S> To many developers, setting a pin to a 1 or high seems more natural for turning something on, so you might want to use the microcontroller pin as a source. <S> One case you might need to use one driving method over another is when the maximum source and sink currents are not the same, and only one method will be able to handle the current needed. <S> If the pin you selected is an open drain type, you will need to sink the current. <S> Open drain outputs do not have an internal transistor to Vdd, so the pin can’t supply current. <S> Some microcontrollers have a few I <S> /O pins that are open drain. <S> http://www.w9xt.com/page_microdesign_pt4_drive_led.html <S> Hope this helps
| I don't think there is a best practice in general, but it has to be decided based on the particular device and design constraints you face.
|
What does "no clean" solder actually mean? I bought some solder that says it doesn't require cleaning. The description specifically says "Eliminates the need and expense of cleaning". But there's still a lot of some substance left on my board that I can't easily clean off. What is this substance? Is it a problem? Is there some way to clean it off besides soap and water? <Q> Soldering requires flux to dissolve oxides and to promote wetting. <S> Rosin (made from tree sap) is one flux material that has long been popular, and comes in various strengths- RMA (Rosin Mildly Activated) or RA (Rosin Activated). <S> Kester says you can leave the flux on the board under fairly benign conditions and experience bears that out (it only becomes active = corrosive) at elevated temperatures, however most manufacturers will clean the board for cosmetic reasons and to allow inspection. <S> Cleaning often involves the use of petroleum solvents- <S> for example by vapor degreasing or just scrubbing. <S> No clean fluxes allegedly don't need to be cleaned and can be left on the board, however many of us have had problems with no-clean processes having relatively conductive residue. <S> The residue is ironically extremely hard to remove, much more difficult than the two above-mentioned processes, more like 'can't clean'. <S> Think twice about this kind of flux if you're thinking of sensitive analog boards that have high impedances. <S> Even circuits you may not think of as being analog such as RTCC chips with an external crystal may be affected. <S> Safest for sensitive boards is rosin flux followed by a thorough cleaning process. <A> It doesn't apply so much to the solder, but to the flux incorporated into the solder. <S> What is left is e.g. resin and for most applications it doesn't matter that it is still there. <S> So what is then the other kind of flux you may ask? <S> It is much more aggressive, and may damage the material it is left on or the solder or components. <S> However even no clean flux often has enough "low" resistance that it might influence sensitive circuits, so in case you can live with a few hundreds of megohms resistance between anything, leave it on. <S> If that is too low, clean it up. <A> The substance left behind is flux, which cleans the metal pads on the board when heated in order that the solder has a clean surface to bond to and you get the best possible quality joint. <S> The "no-clean" aspect means that leaving this in place will not damage the board. <S> Other flux types can typically be very corrosive, and over time may etch through tracks leaving the board non-operational. <S> No-clean is useful in prototyping as it removes the need for cleaning, although for aesthetic or "I don't want this sticky stuff on my board" purposes, you may still want to. <S> Normally no-clean flux is not water soluble (there is water soluble flux available, but it is not no-clean...). <S> I usually use a dedicated flux cleaner (Fluxclene is one brand, but many are available). <S> Alternatively, isopropyl alcohol works well.
| It means that it is not necessary to clean any of the stuff up that is left by it. Aqueous clean fluxes have been developed that can be cleaned without solvents- using just hot water and detergent.
|
Voltage Supervisor for low battery I recently got an electronic engineer to make a design of a circuit for me. He completed everything except for the fact that he never included in the design a way to detect when the battery was running low. I asked him to include this but he just claimed he couldn't do it for whatever reason. So now I'm trying to figure out myself how to add this to the existing design. By browsing answers to similar questions I came across this question: Low battery detection the first answer mentions voltage supervisors and from what I've read it sounds like the ideal solution to my problem, the thing is that I'm not sure which one would be the correct voltage supervisor to detect when a 3.7 volts battery is low. I've been looking around and from what I've found I think the NCP301LSN20T1G Voltage Supervisor would be the appropriate one to use, but I'd like to make sure I'm not making a mistake here. My background is in programming not in electronics so I apologize if this is somewhat of a innappropriate question for this site. Thanks for any help! <Q> If batteries are improperly treated, they can puff up, heat up, and outgas. <S> This sometimes leads to fires if the battery is big enough. <S> It is important for all batteries to measure for undervoltage, overvoltage, under/over current, and improper temperature. <S> I generally recommend using a specific battery supervisor to deal with what you can. <S> There are so many cheap ICs specific to battery monitoring and it generally saves you battery lifetime as well. <S> The IC can do a great job of stopping battery drain after the cutoff as well as giving the proper conditions during charging. <S> This comes a little down to if the charger also needs to be on the device, but if not, there are very small devices for protection without charging(look at QLCSP packages). <S> What happens when your micro gets too low in voltage and the battery keeps draining? <S> What about when your code hangs for sampling? <S> There are also cases where there is a short under the micro and current draws from the battery at well over the specified discharge rate. <S> Lithium batteries can only be discharged at generally <S> 1C. Sometimes .5C and sometimes up to 2C. <S> In these cases you want that separate IC to be your buffer. <A> NCP301LSN20T1G has a treshold voltage of 2.0V, while NCP301LSN36T1G has 3.6V. <S> I guess 2V is too little for monitoring 3.7V battery. <A> You could use the onboard programmable voltage reference and comparator and compare reference to devided supply voltage. <S> No extra parts required except resistor devider. <S> You could also do this with the capture/compare pwm module. <S> Probably been done before, may even find code for this if you know what to search for.
| You can use a micro for battery monitoring, and in fact it is becoming more common, but I won't use one for more than monitoring temp.
|
Two voltage regulators in series vs in parallel What is a better idea - to connect two voltage regulators in series or in parallel? I don't need much current (max 300-400mA). I need both voltages. Transformer output is about 9V. U2 gives 1A max and U3 800mA max. <Q> The important difference here is where the power is dissipated. <S> For both circuits it can easily be calculated: <S> Parallel: \$P_{U2}= <S> ( V_{IN} - V_{OUT} ) <S> × I_{OUT} = <S> ( 9 - 5 ) × 1 <S> = 4 <S> \text{W}\$ <S> \$P_{U3}= ( V_{IN} - V_{OUT} ) <S> × I_{OUT} = <S> ( 9 - 3.3 <S> ) × 0.8A <S> = 4.6 \text{W}\$ <S> Total power = 8.6W <S> Series configuration \$P_{U2} = <S> ( V_{IN} - V_{OUT} ) <S> × I_{OUT} = <S> ( 9 - 5 ) × ( 1 + 0.8 ) = <S> 7.2\text{W}\$ <S> \$P_{U3} = <S> ( V_{IN} - V_{OUT} ) <S> × I_{OUT} = <S> ( 5 - 3.3 ) × 0.8A = <S> 1.4W\$ <S> Total power = 8.6W <S> The question is where can you dissipate these amounts of power most comfortably, which regulator. <S> The higher the dissipated power, the bigger heat sink required. <S> For both solutions, the total dissipated power is identical. <S> Notice that for the series configuration your 5V regulator must be able to do almost 2A, whereas in the parallel configuration both regulators have to cope with "only" about 1A. <A> If the 3.3V regulator can function wih the minimum output of the 5V regulator as input, AND the 5V regulator can supply the sum of both currents, both options are open. <S> Note that in the two alternatives the dissipation will be divided over the two regulators differently. <S> At 1A and 0.8A you will need some cooling on both regulators, which you must calculate for the maximum input voltage (highest possible line voltage, lowest possible transform-down factor, lowets possible drop over the diodes) and the lowest possible output voltage. <S> (jippie's calculations can be used as starting point, but the worst case figures will be a bit more worse.) <A> Again assuming these are linear regulators, I think the disadvantage there is the first regulator will have to be sized to supply the current and power dissipation needed to support the second regulator. <S> So you might be able to use a small part for the second guy but just end up paying for it on the first regulator. <S> Given the choice I'd do it in parallel personally. <S> Now if you were using a switching regulator for the first regulator and a linear on the second then there would be some efficiency gains you could make by having them in series like that. <S> With the first regulator stepping the voltage down for the second. <S> You still need to provide enough current from the first regulator but now the power your second regulator has to dissipate as a linear is much lower. <A> For lineair voltage regulators it is true that a distributed or centralised configuration does not influence the efficiency. <S> However, note that this is not true for switch mode regulators. <S> The efficiency will stay the same centralised, but be lower in a distributed configuration. <S> Let's assume a switch mode regulator with 95% efficiency. <S> I will also assume that every regulator has a seperate available power in the distributed configuration(your image implicits that only the 3.3V regulator has an available output): <S> $$Psource = \frac{Pu_2}{0.95} +\frac{Pu_3}{0.95*0.95 <S> } = 8.188 <S> \\$$ <S> We need to reverse engineer what the total required source power should be in the distributed case. <S> For the required power to Pu2, we have to compensate for the efficiency of 1 (the 5V) switch mode regulator. <S> For the required power to Pu3, we have to compensate for the efficiency of both switch mode regulators, since this fraction of Psource needs to travel through two switch modes to reach Pu3. <S> The efficiency is $$\eta = \frac{Pu_2+Pu_3}{Psource} = <S> \frac{5 + 2.64}{8.188} = <S> 93.3\%$$ <S> Of course, it doesn't degrade by that much in this case, but in a longer power chain, with more switch modes, the efficiency would be much lower and higher powers would make that even more significant.
| Assuming the second regulator can operate off of the lowest voltage you'll get out of the first then you could do it in series.
|
how to convert UART voltage from 5v to 3.3v? I have PIC18F4455 connected to spark core wifi chip. I send data from PIC18F4455 to the spark core by using UART. The problem is the output data of pic18f4455 equals to 5v, and the spark core accepts only 3.3V. My question is there any way to convert this data to 3.3v ( softwar in the PIC18F4455 or hardware) ? Ali <Q> UART is unidirectional, so you can use unidirectional level converter like this: <S> Alternatively, you may use 5v to 3.3v bidirectional level converter. <S> For each wire, you need to build the converter like this one: Since UART has two wires (TX and RX), we need two set of the converter. <S> There is sparkfun board has 4 pins on the high side and 4 pins on the low side. <S> Since it is bidirectional, it works for UART, I2C, etc. <A> It would have been nice if you had provided some datasheet. <S> Most modern microcontrollers have some or all pins being 5V tolerant even if they are being supplied from a 3.3V source. <S> What this means, is that you can send 5V into the GPIO and it will be ok. <S> Sometimes you just have to spend the extra work to find the answer ( <S> and it's not that hard either). <S> First thing you need is the datasheet. <S> Great <S> now I know what the microcontroller is. <S> But does it have 5V tolerant IO ? <S> I don't know. <S> Lets find the datasheet. <S> First page (bottom left corner). <S> So almost all are 5V tolerant. <S> Which ones do you need ? <S> I don't know. <S> You can look it up yourself now. <S> Hopefully you can see, that a bit of Google goes a long way. <S> Even if you search wrong, if you have a good sense of what you would like to do, reading through the pages, can sometimes direct you in the right direct. <S> Derp <S> If I had read slower, I would have seen that the second screenshot was the same summary (although not complete datasheet), so I could have figured out that it was 5V tolerant by the second picture. <S> I would still need the full datasheet to find out which pins are 5V tolerant and which ones aren't. <A> You need employ voltage level shifters. <S> I prefer 74LVC125, 74HCT125 ICs. <S> http://www.ti.com/lsds/ti/logic/voltage-level-translation-overview.page <S> Hope <S> this helps,,,, <A> You can do this with two MOSFETs (2n7000, for example) and 4 10k resistors. <S> You can find an example schematic here . <A> Try to use resistor divider for MCU's Tx. <S> In the most cases Rx line of 5V transmitter (your MCU) will accept 3.3V signal level.
| You can use a logic level converter to translate the 3.3 volt signal to 5 volts and the other way around.
|
Could most AC devices run off of DC rather than AC? To be clear - I have absolutely ZERO intention of ever doing this. But when I learned what a rectifier does (flip the negative portion of the voltage into positive), it occurred to me that it ought to be able to accept DC as well (it would just have nothing to "rectify" beyond the polarity of the source voltage). Is this correct? If so, in what cases would it NOT work? <Q> Short answer : <S> No, most AC devices could not run off DC. <S> In-depth answer <S> : There are very specific cases where this will work. <S> If your input circuit is a diode rectifier followed by capacitors, after which everything in the system is expecting DC, then you should be able to feed DC into the circuit. <S> You should even be able to ignore the polarity of the DC input. <S> If you have any transformers at all in the AC path, they will saturate, which will at best blow a fuse, and at worst damage something else in the path. <S> If there's a power factor corrector on the AC input, it's imaginable that it will work off DC, and it's imaginable that it won't. <S> My bet would be that it won't. <S> Even in the best-case scenario, the losses in the diode pair being used will be a little more than twice the losses if you were running straight AC into them, because only one pair of diodes is all the current that was previously being seen by both pairs. <S> (All this assumes single-phase. <S> Three-phase is comparable, but with a 3x multiplier instead.) <S> So unless the diodes have a large amount of overhead built into them, they're likely to overheat and fail. <A> Depends on the design of the power supply. <S> A linear power supply typically starts out with a transformer across the input, for instance: <S> Transformers only work on AC, so a device using this type of power supply wouldn't work at all on DC. <S> (You'd just end up shorting out the input, and possibly burning out the transformer in the process.) <S> Switching power supplies are another matter. <S> However, this is highly dependent on the exact design of the power supply, and I certainly wouldn't recommend it as a matter of course. <A> If the device uses a transformer to step down the voltage before rectifying it, it won't work on DC as the transformer does not work on DC. <S> If the device uses a CR dropper (some low power mains connected devices that do not need to be insulated from the mains), it won't work on DC as the capacitor blocks DC. <S> simulate this circuit – <S> Schematic created using CircuitLab <S> If the device uses a voltage doubler (multiplier) then it won't work on DC since the voltage doubler needs AC to work. <S> simulate this circuit Switching power supplies with active PFC may or may not work on DC depending on the specific PFC chip that is used. <S> Switching power supplies without a voltage doubler or active PFC may work on DC, but it would still depend on the power supply itself, but simple ones should work. <A> Some AC power supply circuits have X-Cap discharge circuits which detect the absence of AC at the input and attempt to discharge the X-capacitor across the line. <S> Others have power factor correction circuitry or active bridge/bridgeless circuits which expect a rectified AC waveform at the input. <S> In those cases, feeding the supply with a DC voltage could cause a failure/fault or erratic operation. <S> If there's no circuitry that specifically requires the full-wave rectified signal then you should be OK to feed the path after the rectifier with DC. <A> AC devices like your washing machine, dishwasher, refrigerator and fans can't work off DC. <S> Your air conditioning maybe can if the description includes the word "inverter", otherwise no. <S> These devices typically run on mains-connected AC motors. <S> Wrong voltage or frequency, and they won't work. <S> Old-style printers also used to have mains-connected AC motors. <S> Running on 50Hz AC power, they had a page speed 5/6 <S> what was specified for 60Hz. <S> Running on DC, assuming they didn't burn up, they'd have a page speed of zero.
| Many switching power supplies do use a bridge rectifier as the first component, so supplying them with DC at an equivalent voltage might work; they usually aren't dependent on the input being discontinuous.
|
what is the difference between tplace and tdocu layers in eagle pcb? It seems that they both show graphics on the PCB. However, it is not clear which is used when. <Q> In the guts of Eagle, there is really no difference. <S> The difference is by convention what each layer means and how it is used. <S> The intent of tPlace (and bPlace) is stuff that is directly drawn in the silkscreen on the final board. <S> Actually which layers contribute to the ultimate silkscreen graphics is a function of how you set up the cam processor job to generate the silkscreen gerber file. <S> Usually tName, tValue, and tPlace will contribute to the top silkscreen output, but you're not forced to use that convention. <S> The intent of tDocu is what the name says: documentation. <S> This is generally not written to the silkcreen, but may appear in board drawings and the like. <S> Again, it's your choice how to use these layers, but using them as intended makes things easier. <S> You could write tDocu to the silkscreen Gerber file, and use tPlace only for board drawings, but that would just invite confusion and errors. <S> tPlace usually comes from two places. <S> It is used to show the outline and other fixed geometric characteristics of parts in the package definition of parts. <S> It can also come from explicit things drawn in the board editor. <S> For example, you might write the product name, date, etc, in a blank area of the board. <A> I put on tDocu what I want to be visible when I put a copy of the PCB in a document. <S> For instance, sometimes I have no room for the component designations and/or values on the PCB, so I put them outside the PCB, with an arrow or line to the component, all on the tDocu layer. <S> I obviously don't want that info on the silkscreen, but I do want it in the documentation. <A> Usually, you put just tPlace and tNames into the silk screen, as they give you the outlines and names of components. <S> tValues can be used for easier soldering by hand / documentation, but mostly is not used because of space restrictions. <S> tDocu is usually not used for the silk screen. <S> It could contain dimensions for a workshop which should build a case for you, or instructions for assembly like "do not mount this part". <S> You may put it into the schematic, but the board manufacturer usually does not want to read your schematic, just the board. <A> tDocu is used for documentation, such as mechanical dimensions. <S> You can learn more about Eagle layers by going to the following link: https://learn.adafruit.com/ktowns-ultimate-creating-parts-in-eagle-tutorial/creating-a-package-outline <A> Normally, tplace is the layer that you output to board fab house when you want to make the pcb, and tdoc is just for yourself with details info on the components. <S> In simple words, tplace has less information while tdoc has many information too many that sometimes you don't want it as silkscreen, but it is still depends on the library that you are using.
| tPlace is a layer used for visible lines (for example, component outlines) that will be laid as silkscreen in the manufacturing process.
|
For a 4 layers PCB (with ground plane), covering with ground polygon on Layer 1&4 necessary? For a single or double layered PCB board, usually I will cover all the empty spaces in the layout with Ground. This is the 1st time I am designing a 4 layer PCB layout. Layer 1: top signal (high speed) Layer 2: Ground plane Layer 3: Power plane (5v, 3.3v, 1.8v) Layer 4: bottom signal (normal speed) Since now I already got a dedicated Ground plane (Layer 2), my question is: After finished all the routing, for Layer 1 & 4, should I still cover all the emptied space with Ground as well? <Q> It is a good practice to provide Ground Planes into the Top layer, and Bottom Layer. <S> If you can't accommodate in the Top/Bottom layers, Make sure that you make a Top-Bottom Via which connects in the internal plane. <S> This reduces the current return paths. <S> Generally Via's are placed on the corner and wherever free space is available. <S> TI has great design guidelines. <S> https://www.ti.com/lit/an/szza009/szza009.pdf <A> Answer is yes, if you can. <S> It won't harm anyway. <A> You have a few obvious options with pour- any of the supply rails, including ground, or nothing. <S> Since you have a bunch of supply rails a power pour would get complex.
| I would say the ground pour is okay, but increase the clearance gap beyond what you normally use, to improve manufacturability, since the benefit is limited.
|
Is there a virtual ground in this op-amp? Consider an ideal differential operational amplifier whose circuit looks like this, Now in this circuit diagram it is given that, the negative terminal is at 0v. But if I give a sine wave as input to this op amp whose frequency is high and capacitance of the capacitor is 1.I think almost can't be such a high voltage drop across the capacitor to make the negative terminal at 0v. If so, is there a virtual ground in this circuit. If yes, please explain me how?? <Q> Assuming the op amp is ideal, the virtual ground will be maintained. <S> The ideal op amp has infinite gain and is infinitely fast. <S> However, any real op amp will not have infinite gain. <S> It will not be infinitely fast. <S> And more than likely it will have some limited output slew rate. <S> EDIT: <S> Another important thing to consider is that a practical op amp has limited output voltage range. <S> You will likely see the output signal clipping terribly for high-frequencies. <S> So, using a real op amp, the op amp will not be able to keep its negative terminal at 0 V at high frequencies. <S> You can see this by connecting a square wave at the input of the differentiator. <S> Just after the rising and falling edges, you will likely see the op amp's negative terminal jump in the direction of the edge of the input square wave. <S> I.e. if the square wave is transitioning from low to high, you will see a positive spike at the inverting terminal of your real op amp, and a negative spike on the high to low transition. <A> The concept of "virtual ground" implies that the Opamp must be capable of maintaining the "virtual ground". <S> So assuming the opamp is ideal: the - input will always be virtually grounded, no matter what (ads I'm also assuming the R and C to be ideal). <S> But in practice, you're right, the opamp will have limitations so under certain conditions it will not be able to keep up and the - input will not be at 0V anymore. <A> Please realize that "virtual ground" does NOT mean "ground (0 volts)". <S> The term "virtual" is just an indication that the voltage at the inverting terminal is so small (Vout/Aol) that it can be neglected (set to 0 volts) during calculation. <S> That means: This voltage is never 0 volts but we are setting it (during analyses) to zero. <A> The op-amp is able to make that pin a virtual ground because of the feedback configuration you have. <S> He will drive a signal through that resistor to try to cancel out whatever signal comes in the negative pin. <S> You can check this quite long video out if you have some time, probably the first half of it will be enought for you to anwser your questions. <S> Video Link
| In the situation that you sketch: high frequency, high value of the capacitor, as long as the opamp is able to keep it's - input at ground potential, it will be a virtual ground.
|
what happens when both anode and cathode voltages are same for a diode? In a circuit if the ideal diode has both the cathode and anode voltage same, will it conduct or not? Similarly, in a constant drop model if the voltage drop is exactly equal to 0.7 will it conduct or not? <Q> If the voltages at two points are exactly the same, you can put any passive element between them and no current will flow through that element. <S> So you could put a wire, a resistor or a diode there, nothing will change. <S> If one point is exactly 0.7V above the other <S> and you put a diode in between in the forward direction with a stated forward voltage of 0.7V <S> some current will flow. <S> A Diode is specified at a certain current, be that 0.1mA, 1mA, 10mA or 50A, so if you put that known voltage across it, and the diode is exactly as specified, a current very near that specified current will flow. <S> If you make the voltage a little lower a lower current will flow, if you make it higher, a higher current will flow. <S> Look at this little plot: <S> (source: richardson at csserver.evansville.edu ) <S> You can see that at 0.7V this diode (random plot I found from a guy that did a test on a diode) conducts about 15mA. Which seems to be about its first regular operating point, so it serves your question well enough. <S> Then if you make the voltage 0.6V, you can see still about 1mA will flow. <S> But if you make it 0.8V it will go off the plot. <A> This is actually a good question, and should not have been downvoted. <S> The answer is that it could be any (forward) current (including zero)- <S> you cannot tell what the current is from the voltage. <S> Same as with the ideal wires we draw on a schematic. <S> That is a consequence of the 'ideal' assumption- <S> it's not a physical reality. <S> If you are trying to analyze a circuit with ideal diodes you have to treat them sort of like wires that are there if the voltage drop across them would be in the correct direction if they were removed. <S> The only time this comes up in reality is with a superconducting wire- if there is zero volts ( exactly zero volts, not too low to measure) then there could be +/- <S> any current through the wire (up to some limit in reality). <A> When thinking about discontinuities such as you encounter in an ideal diode, it's useful to think about approaching the discontinuity from the left or from the right. <S> If you are approaching 0V from the left (0-), resistance is infinite, and there is no current. <S> If you are approaching zero volts from the right, resistance is zero, but there is still no current, as there is no potential difference between anode and cathode. <A> If both side of diode are connected with same terminal and having same voltage value then there will be no conduction hence no current however if potential difference is equal to or greater than conduction threshold I.e 0.7 for germanium <S> then there will be conduction I.e if anode is connected with 1.7+ve and cathode is <S> 1 v +ve then diode will conduct but both +ve voltages should be from different batteries same phenomenon is used in comparator which is used to make a cutoff circuit for battery charging <A> but it is not true in all cases .. <S> yes the diode (in a circuit) can be on if also there is same voltage across both terminals.!Refer the circuit in the figure given below where the diode is ideal and <S> the current through diode is 1A case where it has same voltage on both terminals. <S> This question was designed by IIT Madras professors in GATE exam 1997 ( https://i.stack.imgur.com/NxqiE.jpg )
| When Ideal diode is connected to the same voltage on both terminals then there will be no current ..
|
How to amplify voltage using op-amp I want to measure a motor's load by it's current draw using Arduino, so I made this diagram: The Motor is controlled by a L298 H-bridge. My questions are : The motor's rotation can be reversed, so the voltage on resistor R5 can be reversed, how the LM358 to deal with this? how to modify the diagram to implement this? Is there any other errors on the diagram? Any suggestions are appreciated. <Q> Your schematic will not work, because the voltage polarity in motor can reverse. <S> I suggest use two op-amps as differential amplifier. <S> This is the example circuit. <S> With this circuit, for the first op-amp, keep R3 = R4 and R2 = R5, and the output voltage: \$ \Large V_{out} = <S> \frac{R_5}{R_3} \times <S> V_r \$ <S> For the second op-amp, keep R7 = R8 and R6 = R9, and the output voltage: <S> \$ \Large V_{out} = <S> \frac{R_9}{R_7} \times V_r \$ <S> Vr is the voltage in R-sense. <S> Vout can not be negative. <S> So you can detect polarity by measuring output voltage of first and second op-amp. <S> In any directions, one op-amp will give voltage near zero, and the other op-amp give voltage measurement of R-sense. <A> You can indeed make your own circuit for this but that requires some knowledge of opamps and how to use them. <S> Therefore I would like to suggest to use a small module like this 5A Range ACS712 Current Sensor Arduino Eletronic Module <S> it uses the Hall effect to measure the current. <S> It is cheap and should be suitable for your needs and also it is easy to use with an Arduino. <S> The motor current pins are also isolated from the interface pins so you can use it with a shared supply or separate supplies just as you need. <A> Thanks a lot to you all. <S> I found another solution, hope this can avoid to measuring reverse voltage. <S> :
| You can adjust value of R in op-amp to amplify the voltage of R-sense in order to suit the ADC of microcontroller.
|
Difference between battery and capacitor? Can capacitor acts like power supply, in which situations? How related are charge/discharge time of battery and capacitor? Why battery has longer discharge time compared to capacitor? Why we cannot for example use big capacitors in our mobile phones instead of batteries? <Q> But the way they store electrical energy (charge) is different, which leads to different characteristics and hence different use cases. <S> A capacitor directly stores charge on what is essentially two plates of conductors. <S> The fact that the charge is stored in conductors makes it readily accessible (low impedance, quick to react to changes), but the fact that its storage is essentially a 2-dimensional pair of plates severely limits the amount of energy that can be stored. <S> (Higher-capacity capacitors use a 2.5-D storage at the expense of much less conducting plates). <S> A capacitor stores charge, which means that when the capacitors discharges (delivers current), its voltage drops (linearly when the current is constant). <S> A battery stores energy in chemical reactions. <S> This means that energy is stored in a 3D volume, so much more energy can be stored, but as ions don't change their speed as quickly as electrons, a battery can't respond as fast to changes of current as a capacitor. <S> Chemical reactions are never perfectly reversible, so a battery wears out, much quicker than a capacitor. <S> But a chemical reaction has a fixed 'activation voltage', so the voltage of a battery stays (more or less) <S> the same while it is discharged. <S> Hence batteries and capacitors have different use cases, that seldom overlap. <S> If you need high capacity = <S> > batteries fixed voltage = <S> > batteries <S> quick response = <S> > <S> capacitors 'infinite' (component) lifetime = <S> > capacitors <S> In fact batteries are often too slow for electronics, but capacitors would not be able to store enough energy, so in practice you often want high capacity + quick response = <S> > <S> use batteries + capacitors <A> Wouter's answer is quite good. <S> I would add this chart: <S> Energy density is how much energy can be stored in a given weight of product. <S> Power density is how quickly you can get that energy out. <S> So you can see that aluminum electrolytic caps can deliver orders of magnitude more power than any battery technology on the chart, and the energy stored by batteries is orders of magnitude higher than aluminum electrolytics. <S> Ultracaps are somewhere in between. <S> The power density of the capacitor is limited by the ESR. <S> Most capacitors can survive a dead short being placed across them (at least once), but the total available current is limited largely (though not entirely) by the interconnections within the capacitor itself. <S> Also, the voltage discharge curves are different. <S> A lithium ion battery tends to keep its voltage relatively constant until it's almost completely discharged. <S> A capacitor under constant power load, on the other hand, drops in voltage rapidly. <S> Suppose our load has a drop-out voltage of two volts. <S> The lithium ion battery will support that load until it's almost completely discharged; a bigger concern is discharging the battery so far that it destroys the battery. <S> The ultracap, however, will drop from 3V to 2V and still have almost half the total charged energy still in the capacitor, unavailable to us because of the drop-out voltage of the phone. <S> So not only is the total energy density of the capacitor much lower than that of the battery, we can't even use all the energy that's there. <S> So we can't effectively use capacitors in our cell phones because the phone would either last a tenth as long (probably less), or it would be ten times as large (probably more). <A> Other answers talk about practical use of capacitors for energy storage, but in theory, capacitors and batteries are very different. <S> An ideal capacitor is a circuit element with the property that the voltage across its terminals is proportional to the integral of the current that flows through the device: https://en.wikipedia.org/wiki/Capacitor#Current.E2.80.93voltage_relation <S> A battery, on the other hand, is a good approximation of a small-valued resistor in series with an ideal voltage source . <S> That is to say, the voltage across a battery's terminals is mostly independent of the current.(except for the small, proportional dip due to the internal resistance.) <S> https://en.wikipedia.org/wiki/Voltage_source
| Capacitors and (rechargeable) batteries can both be used to store and retrieve electrical energy, and both are used for this purpose.
|
Method or function to determine if pointer is to address in flash or RAM? I'm working with an ARM Cortex M4 microcontroller that has a DMA, or peripheral DMA controller. One requirement of the DMA is that it cannot access pointers to addresses that exist in flash, but only pointers to addresses that are in RAM. Is there a way to determine if a particular pointer points to flash or RAM? If not, I think I need to actually initialize a buffer in RAM then strcpy or something like that to transfer what is in flash into RAM so the DMA can read it. Does anyone know of a better way to do this so as not to waste CPU time if there is no way to tell if the pointer points to flash or RAM? This is on an Atmel SAM4S. <Q> In most cases your linkerscript will provide these addresses, so you don't need to type them in yourself <S> (details will depends on yourlinkerscript). <S> Note that wehen you use the linkerscript <S> , the values won't be known at compilation time, so the compiler cannot optimize comparisions against know pointers. <A> Main problem with checking whether a pointer is in specific range is unfortunately the C standard itself. <S> Pointer arithmetic has a defined behaviour only if performed on pointers of the same type within the memory range of the same object (i.e. within the same allocated array range). <S> A the comparison operators are defined as arithmetic operations, this restriction apply to them as well. <S> A workaround for this problem would be casting the pointers to the uintptr_t type defined in stdint.h , which is an integer type guaranteed to hold a pointer value. <S> And then perform your comparisons. <S> Now to the part of obtaining the right boundaries. <S> Typically a C project would contain some kind of linker script defining memory regions of the specific architecture. <S> Commonly it will include lines similar to the following: MEMORY{ FLASH (rx) : <S> ORIGIN = 0x00000000 <S> , LENGTH = 0x40000 <S> SRAM (rwx) : <S> ORIGIN = 0x20000000 <S> , LENGTH = 0x8000} <S> then, in the same script the following definitions can be added: _flash_start = ORIGIN(FLASH); _flash_end = ORIGIN(FLASH) + LENGTH(FLASH); <S> And then in C code these symbols can be accessed using: extern int _flash_start ; <S> extern int _flash_end; <S> And then a tricky part: <S> The address of _flash_start will correspond to the flash starting address, and the address of _flash_end will correspond to the flash end address. <S> I.e. <S> the &_flash_start and &_flash_end are giving you the desired range. <A> If your MCU follows the ARM Cortex conventions, you can look at the topmost nibble of the address in question: intinflash_p(void *addr){ uintptr_t addr_int = addr; unsigned int addrtype = <S> addr_int > <S> > 28; // 0 = flash, 1,2 = ram, 4 = periph, <S> e = system return (addrtype == 0);} <A> You can cast the pointer to an integer, then compare its value to the flash address space as defined in your MCU's memory map. <S> For example, if your flash memory is at addresses 0x10000000 <S> - 0x1001ffff, you could do: void DMA_Function(uint8_t *ptr){ uint32_t ptrAddress = <S> (uint32_t)ptr; <S> if (ptrAddress >= 0x10000000 <S> & <S> & ptrAddress < 0x10020000) <S> //The address is in flash else <S> //The address is not in flash ...} <S> Of course, in actual code it's better to use constants instead of hardcoded addresses -- FLASH_START_ADDR and FLASH_END_ADDR, for instance. <S> If you want to be extra-flexible you can define linker variables for the flash addresses, which keeps the addresses out of your source code altogether.
| You know the memory map of your microcontroller, so you can simply test your pointer against the start and end RAM addresses.
|
Conductive body of flashlight I have a flashlight that seems to use the inside of the metal body to conduct the negative terminal of the LiPo battery inside. The outside isn't conductive - likely anodized. Would there be adverse effects if the whole body was conductive, i.e. make both the inside and outside conduct the negative terminal? I'm guessing the user wouldn't receive shocks given the low voltage. The flashlight looks like the following (source: opticsplanet.com ) <Q> You are talking about DC, so there is really no skin effect or the like. <S> If you scraped off the coating there won't be dangers for the user holding the flashlight. <S> The voltage drop along the case is ridiculously low since the resistance is probably on the milliohm range and the internal batteries+circuitry (even assuming a boost converter of some sort) won't generate more than a few volts maximum. <S> 1 <S> Moreover the body of the flashlight is probably some aluminium alloy, already fairly resistant to corrosion, and some models are made with no protective coating at all, so the conductive surface is exposed to the user. <S> 1 <S> Ok, theoretically I could imagine some idiot el-cheapo manufacturer using a string of some 40 LED in series and using a ~150V output boost converter to power the string, but I still have to see that :-) <A> Note that in order to receive a shock there needs to a return path through your body. <S> Even if that flashlight used 1000 V inside it would be safe ! <S> Why ? <S> Because it is completely self contained, if you hold it in your hand there is only one connection to the flashlight. <S> This is why mains connected appliances are dangerous, they have a return path through ground. <S> Yes, the ground your standing on ! <S> It can be conductive enough (even including your shoes etc.) <S> for you to feel the current flow. <S> If you were able to hover a small distance above the ground, you could safely touch any mains wire as there would be no return path. <S> Since electricians cannot hover either, rubber isolated shoes and gloves help to provide the required high resistance. <S> In the flashlight case, the flashlight has no connection to ground so there can be no return path. <A> I cannot see any way for contact with the positive end of the battery.
| The whole body of the flashlight is conducting the DC, the external varnish is only for corrosion resistance and "look and feel". I am not a EE, but I have a very hard time imagining a scenario where having the outside conduct to the negative terminal a bad thing. In order for you to get a shock the current must be able to flow into and out of your body.
|
How to connect these pads I have trouble connecting a THT HDMI Connector to a pcb: The HDMI Connector I'm talking about is this. The holes are too close to go in between them: (The blue line is 0.15mm thick) Is this usual (such close and small holes)? Should I be using a pcb manufacturer who can produce thin pcb traces? (like 0.10mm?) Or just route the trace other way around? <Q> Options (in order of my preference): Route such that you don't have to do that. <S> Make that pads octagonal. <S> Make the pads as thin as possible. <S> Go to thinner traces (if possible). <S> Utilize additional layers. <A> Though you may have clearance issues - the gap between pad and trace seems much narrower than the trace. <S> I have used a similar (not identical) connector in the past. <S> This is how I ended up routing it in order to get away from the issue of trace thickness. <S> The traces in my drawing are quite large as it was a 0.8mm thick 2-layer board and the traces needed to be wide enough to get a roughly 100Ohm impedance. <S> Seems to work fine <S> - don't know about high res as I was using 1280x720. <S> For 1080p the clock frequencies may be higher and other issues may arise. <A> The pitch of the pins in one row is 1mm, as it is for your HDMI connector. <S> However, this need a PCB manufacturer who can produce really small structures. <S> With the pad size from your drawing, a 4mil track has a clearance of 3mil to the pads, which can not be produced by each manufacturer. <S> May be, you can reduce the pad size (but not drill size) to get more space between the pads, but again, manufacturers have limits on the minimum size of the pad (with respect to the drill size) <S> (And again: Check what the manufacturer can do) <S> Another solution is to change to an SMD connector. <S> A pitch of 0.5mm is quite common today.
| Often, the pad size is smaller on the inner layers, so routing may be easier there. The only difference as far as I can see is that yours is horizontal and the one I used is vertical. You may indeed route tracks between the pins of one row to the other row, as I saw it on a graphics card on my desk. In terms of width, 6mil traces are quite common nowadays (roughly 0.15mm). So, this is really tiny stuff, and it depends on what the manufacturer can do.
|
LM317 - Caps necessary on 9v Battery? I am designing a circuit which uses the LM317 variable voltage regulator to power a device from 1.25v-3.7v. The device powered by the LM317 will accept +-0.2V from the output of the LM317 and takes about 100mA. The device that will be powered is a small DC motor. If I am powering the LM317 with a 9v battery, is it required that I install parallel capacitors on both input and output? <Q> According to the datasheet (p10) <S> the input capacitor is recommended (I would translate that as required) when the chip is not near the rectifier/filter-capacitor. <S> You don't have a filter capacitor, and a 9V battery has a relatively high impedance, so <S> I strongly suggest you include the 100nF input capacitor. <S> Again, according to the datasheet, the output capacitor is not needed but will improve the transient response. <S> You motor won't care, so <S> I'd leave that one out. <S> (But it won't harm to leave it in.) <A> It's always a good idea to install both capacitors. <S> Particularly since there is no guarantee on how long your battery wires will be. <A> So it totally depends on your application & environment. <A> Looking around the net you can find values for the internal resistance of 9V batteries of around 1 to 2 Ohm. <S> Which fits nicely to the picture of 6 1.5V cells in series, where you can find values of around 0.2 Ohm of internal resistance. <S> At 100mA there will be a voltage drop of 0.2V, shouldn't be much of an issue. <S> Generally batteries don't like spiky currents and a reasonably sized capacitor (1µF or something like that) near the LM317 input will probably help to reduce the strain on the battery a bit. <S> The internal resistance and wire resistance together with the input capacitor will form a low pass filter which will smooth the spikes the battery will see. <S> Also the datasheet suggest that the output capacitor will improve transient responses, which might be beneficial for your application. <S> (a motor gets switched on and off, or does it run always?)
| Well it depends, As battery source is already DC so we won't need filtration capacitor but decoupling capacitor maybe needed because of long wires, external noise etc.
|
Can all surge protectors wear out, and how would you know if this is the case with the surge protector you have? This question follows from this other question where the OP mentions that: I know MOVs inside surge protectors degrade over time Based on this it seems that surge protectors eventually deteriorate past a point where they do not provide (expected) protection against power surges. The questions I wanted to ask about this: Is it correct that surge protectors degrade, and if it is, what causes this? Is there a rule of thumb for determining how long a surge protector can last before needing to be replaced? Are there ways to determine if a surge protector is old (or otherwise faulty, for that matter)? <Q> It truly depends whether your surge protector contains MOVs or not. <S> The wear mechanism for a MOV is that the clamping voltage DECREASES slightly every time the MOV is required to clamp a transient. <S> Eventually, the clamping voltage decreases to the point where the MOV starts to conduct on the peaks of every AC cycle. <S> The MOV will then burn up. <S> FWIW - the early cube plug-in surge protectors manufactured by RCA had a clear plastic window on the side that showed the red MOV inside. <S> A label on one side of the cube said something along the lines of; "If it's black, take it back." <S> More modern surge protector power bars have thermal cutouts mounted between the MOVs. <S> If a MOV flames, the thermal cutout interrupts the incoming power. <A> You could test an unknown MOV on a megger or anything that applies a high voltage at a low current. <S> A normal DVM applies a very low voltage on its ohm function so it won't reliably tell you if the MOV is on the way out. <S> It will of course tell you if the MOV is shorted. <S> I have seen fuses with neon lamps across them placed in series with an MOV. <S> When the MOV blows, the fuse blows stopping a fire, and the neon lights up indicating that the MOV is gone. <A> Quoting this Leviton article : <S> MOV life is largely dictated by thermal stress <S> Exposure to surges cause heat-ups and cool-downs of the device, as well as (depending on the nature of the surge) incremental damages such as electrical puncture and thermal cracking <S> These incremental damages lead to non-uniform heating when additional stresses are applied, which leads to thermal runaway and device failure <S> A surge protector that is connected to the mains should be considered 'on the clock' - once you get past the manufacturer's recommended replacement time period, you're on your own. <S> Unless you have access to a surge generator <S> you won't really be able to test if the MOV is still 'good', and since you could be in a 'one-and-done' situation (the next surge gets clamped but takes the MOV out) <S> , it's not really worth testing it. <S> You could (theoretically) replace a questionable MOV with a comparably-rated one if you just want protection and don't care about dealing with manufacturer's warranties. <S> They're available from a variety of suppliers - energy-handling and voltage clamping level are the key spec items to look out for. <S> The safest thing to assume is that if the surge protector is older than the manufacturer's equipment guarantee, assume the MOV isn't in there at all (i.e. there's no protection).
| Repeated surges will degrade a MOV over time by reducing the clamping voltage like Dwayne Reid said.
|
Can I combine 3x 1000ma power supplies (wall warts) to get a 3amp supply [answer: no] I have a device that requires 3A, 9V. I also have three 1A power supplies (wall warts). Can I cut the wires of these power supplies, reconnect them all together in parallel, and use them all as a single 3amp 9v power supply? <Q> Chances are that they will have slightly different output voltages, and the one with the highest voltage will be supplying most of the load and will be overloaded. <S> Just buy a suitable 3A supply. <A> Yes, you can do that because 9V AC adapter usually has 15V voltage reading when not loaded, and when you connect them together in parallel, your load will act as a voltage regulator for all three AC adapters. <A> There is a simple solution explained on following page: here <S> Take a look at figure 7.8 and 7.9 <S> i think if you make a combination of those it might work.place a resistor and diode at the positive output and connect them parallel
| Just make sure to add a diode to each output to prevent burning out other 2 AC adapters when first one is plugged in, while the two others are not.
|
Suppressing contactor coil inrush, is this possible? http://www.kvc.com.my/EnterpriseChannel/SharedResources/Datasheet/0/?ProductId=1000066755&Filename=SCHNEIDER-LX4-FH024.pdf I am trying to operate a 24VDC coil with an inrush of approximately 30A, and a holding current of only 250mA. To avoid needing a 750W supply for a holding current of less than an amp, I attempted to use a 4 ohm thermistor to suppress the inrush current down to about 5A and allow me to use a much smaller 250W supply. Unfortunately I'm thinking this might've been flawed logic. I was thinking the trick was to simply suppress the inrush current, but now I'm thinking maybe that inrush current is critical to closing the contactor. I tried testing the circuit as designed, but the contactor is not closing. The thermistor worked in the sense that my 10A breaker is not tripping, but I can not operate the coil. My assumption is it is not getting enough initial power to close. My question is, are coil inrush currents something that can be suppressed? If so, I'm assuming there is a more correct way to do so as my idea does not seem to be functional. <Q> You don't want to suppress the inrush, but rather, find a different way to supply <S> the inrush current — it is required for the contactor to operate properly. <S> It needs about 30 A for up to 50 ms, or about 1.5 C. <S> If you are willing to allow your supply to sag by, say, 6 V, then you need about 1.5C/6V = <S> 250mF of capacitance to supply the short-term current. <S> You can use a low-value resistor, thermistor, or inductor between the power supply and the capacitor in order to isolate the power supply from the surge. <A> Generally speaking, contactors of this type have two coils - one is used for pulling, the other used for holding. <S> The large pull-in current is required. <S> If your source can't supply that large current, the contactor won't pull in properly. <S> You can try adding a large capacitor in parallel with the voltage source. <S> Choose the capacitor value based on a voltage drop of about 30% over 50 ms or so. <S> The contactor should be sealed in about that amount of time. <A> Hold on here. <S> You are fixing the wrong problem. <S> First, are you telling us a 6W contactor is tripping a 10A circuit breaker? <S> If so, what type of circuit breaker is it, thermal, magnetic, trip curve etc. <S> That or the circuit breaker is defective. <S> Inductive loads typically have what are called C or D curve breakers. <S> They allow large inrush currents for a few seconds before tripping. <S> If you have a load behind that breaker in parallel with the inductive load, and it needs faster protection, then give it its own fast breaker/fuse independent of the contactor and other inductive loads. <S> Power supplies can easily handle the surge though the voltage will momentarily dip. <S> What type of power supply is it? <S> The inrush should only be a few milliseconds and not trip circuit breakers or overload your supply. <S> I'v built a few control cabinets using 24VDC contactors and relays driven from nothing but a 60W 24V power supply. <S> Never had a problem or blew fuses/breakers.
| You might have a circuit breaker with a short curve that is reacting way too fast to your loads inrush current. Breakers must be spec'd to hand inrush loads.
|
Ways to measure current in picoamperes I need to check the low power consumption of a microcontroller in the range of picoamperes . I only have a multimeter capable of measuring milliamperes and as such it shows 0. Is there an easy and precise way to measure picoamperes? <Q> Power the micro-controller with a capacitor, charged to a known voltage. <S> Wait an appropriate amount of time, then measure the voltage. <S> Calculate the current from the delta-V and the C. <S> (Don't measure the voltage continuously, unless you have a meter with a high-enough impedance, because that might draw extra current.) <S> You will need a capacitor with known capacitance, but in a pinch you could measure a capcitor in the same way by discharging it through a known resistor. <S> As the comments point out, other current paths might contribute to the discharge of the capacitor (including self-discharge). <S> You could repeat the measurement with the UC removed and see what value that gives. <S> Then you might think about whether you can realisticly avoid such 'other' currents in your design. <S> And don't forget your batteries self-discharge and/or ageing! <S> If you aim is too 'see' the power-down mode of the chip in action you could use the capacitor, build a simple circuit that periodically connects it to the power supply (if possible synchronysed with the uC's activity cycle, must have a realy low leakage current!), and watch the C's voltage on a scope <S> (the scope impedance must be higher than the UC's current consumption, or you might even use AC coupling if the uC"s activity cycle is short enough). <S> This way you can verify both the time-wise division in high and low current consumption, and the currents in both modes. <A> The leakage of the capacitor is not as important in this case. <S> For example, if you think the supply current should be no more than 10nA <S> then you can use a resistor of value 10M 1% in parallel with a 1uF ceramic capacitor. <S> That will give you 100.0mV for 10nA (so the burden of the ammeter is 0.1V, which should not overly affect the circuit- raise the input voltage up a bit to compensate for the drop if it bothers you). <S> Then look at the voltage across the 10M resistor using a voltmeter with high input impedance, such as the Agilent 34401 in >10G input resistance mode. <S> The bias current of the meter will influence the reading, but it is less than 30pA (0.3%) at room temperature. <S> The 10M/1uF combination filters out spikes unless they are happening at very low frequency (if, for example, your processor wakes up once every 10 seconds and draws <S> 0.5mA for 100usec it won't work very well). <A> The power or current consumption of a microcontroller can be very irregular depending on the µC's state. <S> For example: 1pA for 999 ms and then 1uA for <S> 1 ms. <S> On average that would be 1.001 nA. <S> If your multimeter would do a measurement every 100ms, it would never measure the 1.001 nA ! <S> In this case you need to use a resistor in series with the supply and an oscilloscope to measure the voltage across the resistor to "see" the actual current over time. <A> Most oscilloscopes specify their channel input impedance. <S> It tends to be about a Gigaohm. <S> If you put the scope in the ground path of the uC (most scopes connect channel ground to earth ground, and you may not be able to place an earth ground on the VDD of the uC) <S> you will be measuring the voltage across this resistor, and therefore the current being used by the uC, in real time. <S> That should give you fairly accurate measurements (1mV => 1pA). <A> Let's look at the issue of whether the battery "cares" - ie would a load in the pA range affect battery lifetime significantly? <S> Spoiler: <S> No. <S> Even measurements capable of 1 nA resolution are more "precise" than are needed in practice. <S> The very best primary (non rechargeable) Lithium batteries have useful shelf lives of around 20 years (with maybe 30% - 70% capacity loss) without more than sensible attention to temperatures etc. <S> Typical examples are 20 years is <S> about 175,000 hours so 10 mAh of loss over that time is equivalent to a current of 10/175,000 mA or <S> 10,000,000/175,000 = 57 = 57,000 pA. <S> So measurement of pA is completely unnecessary for any battery size liable to be used. <S> For example, a 50 mAh battery with say 50% lost to shelf life after 20 years (a good trick if you can do it <S> ) would allow 25 mAh for the load or a mean current of 142,500 <S> pA = 142.5 nA = <S> 0.1425 <S> uA. Measurement to the nearest nA of <S> mean load current gives you around 1% accuracy - which will allow a vastly more precise estimate of battery life than you will find in reality. <S> Practical variations will swamp such attempts.
| One simple method I've used is to put a resistor in series with the power to the micro and parallel it with a capacitor.
|
3.3v from 5v Arduino digital pin I have an ESP8266 that I've got connected to my arduino and communicating quite well with... Now I'm looking at options to run my conifig via battery, so need to find ways to shutdown the ESP8266. Easiest way I have read is via the broken out CH_PD pin that is normally tied to 3.3v. However, further reading suggests that the TX/RX pins are 5v tolerant, the CH_PD is NOT.So what would be the best way to power the CH_PD from a digital pin. Options are Connect the Arduino digital pin to: Voltage divider using resistors Transistor switch? small 100mA 3.3v regulator I have no idea how much the CH_PD pin draws in mA... I assume very little.I've used voltage dividers for signal, but not for constant ON applications like this would be. Thoughts? Thank you! <Q> The cheapest way is to use a voltage divider consisting of two resistors. <S> These have a VCCA and VCCB: Set VCCA to 3.3V, and VCCB to 5.0V, and the IC will translate signals between the two VCC domains. <A> Place a pull up resistor from 3.3v to the pin. <S> Then connect it any digital pin. <S> Set the pin to a low state. <S> Then turn the pin from an input to an output to pull the pin low. <S> Set the pin back input to pull the pin high. <A> I would use three diodes in series to drop the voltage. <S> A standard silicon diode has a voltage drop of ~0.6V, so if you chain three the voltage is dropped from 5V - 5V - (3 * 0.6) which is 3.2V. <S> I hope this helps!
| An easier way is, your arduino has a 3.3v rail. The most robust way is to use a level converter IC (SN74LVC1T45 or similar).
|
Injecting UUIDs into ROM during production I'm brand new to electronics and was wondering if someone could explain to me how individual MCU/MPU-powered electronics units can be assigned unique identities on the factory line. For instance, lets say a particular device is being built. This device has an MCU/MPU (still don't fully understand their difference) that has a CPU, ROM to hold a binary/RTOS and RAM for running that binary at runtime. A control program is flashed to the ROM at some point during production. Say this device has the need to be given a UUID that can be read from memory when the control program starts up. Obviously, each device needs a different (unique) ID. And so I would imagine that the MCU would undergo two different phases during its production build: an initial flashing of the control program to ROM, followed by a second flashing that "appends" (without overwriting, that is) a device-specific UUID to a specific address in ROM. The control program would then be hardcoded to look for the value (UUID) stored at this address at startup. Am I on track here, or is there a more efficient/different/standard way of accomplishing such a task? And I guess I would generalize it beyond a UUID and ask the same question of any situation where all units share a binary (the control program) but then also have their own unique information that must be present in ROM at startup. <Q> Production programmers generally have an option to serialize the image written to the memory: each individual product is flashed with data that is different, for instance by incrementing a specific data word, but more complex operations are also possible. <S> Another option is to buy a chip that itself has a unqiue number. <S> This is for instance done for Ethernet addresses, which are assigned by some authority. <S> Check for instance <S> Microchip's "Unique ID Chip Products". <S> Dallas/Maxim 1-wire products can use one shared (1 wire) bus for (virtually) any number of chips. <S> To make this work, each such chip has a unique serial number. <S> The simplest form of these chips has nothing more than this ID. <A> The way you describe is a valid one, at least it's one we use in our projects. <S> First we flash the whole program which contains an initial set of values, so the program will run fine. <S> During calibration the serial number (UUID) of the device will be set, along with the other calibration factors. <S> For this we reserve a flash page at the end of the flash, so an update of the program is possible without erasing the calibration constants. <S> For this to work, of course, you need some way of communicating with the controller and a program part which will do the writing to the flash. <S> If your product is not designed to have that, you have to inject that data during the initial flashing. <S> For that you can change the hex file on the fly for each (the format is rather easy) or use capabilities of the flasher to include an automatically incremented serial number or something like that. <S> The capabilities of the flashers are also quite different - for example, Segger produces some with quite good production programming capabilities. <S> If you just need a way to identify a device without a requirement for what that UUID has to look like, microcontrollers often have some device info in them, among others an ID. <S> Whether that is usable has to be determined for every microcontroller type you use, as there is no standard that I am aware of. <S> For example the STM32F401 (a device I'm currently working with) has a 96-bit Unique Device ID which can be read by the CPU and with JTAG. <S> (more details in the reference manual ) <A> There are devices for such purpose, for example this is the page for Maxim integrated for their PCB ID AND AUTHENTICATION products, which provide a factory-programmed, 64-bit unique ROM ID <S> and I'm sure that there is other manufacturers that provide similar products <A> These devices are small footprint I2C devices that you purchase ready to populate on your board like any other part. <S> No special steps at manufacturing time are required. <S> Simple I2C access can be used from your microcontroller and may not consume any additional resources on your board or MCU pins if you already have one or more other I2C devices on the board. <S> The parts from Microchip are primarily aimed at the Ethernet marketplace to supply the MAC Address for your device. <S> Nothing prevents you however from using the unique identifier in other ways to serialize your product or to synthesize UUIDs from the code in the serial EEPROM. <S> Microchip commits a portion of the EEPROM device to hold the identifier and locks out the erasure and programming of that portion of the part. <S> The rest of the EEPROM cells can be freely used of various other configuration data or calibration constants. <S> The part that I am using in my current design is the 24AA025E48. <A> In addition to all the answers posted, some devices contain two separate memory: one large flash/EEPROM for the program and another smaller memory (typically just around 100 bytes or so) for data. <S> For such devices you'd store the UUID in the data EEPROM. <S> They can be either programmed separately (I've seen devices where serial number and calibration data are flashed just before shipping to customers) or during the production run (you'd need a program, typically just a Perl script, to generate the UUID then pass it to the programmer).
| Another ideal solution to this problem is to use one of Microchip's Serial EEPROM parts that come with a unique identifier programmed into them.
|
A practical integrator that does not behave like a low-pass filter? Op-amp integrators and some common integrators actually are low-pass filters in practice. So if a signal is DC, then it does not integrate but only multiplies by some amount plus some transient response. Now of course integration over DC cannot be done for a long period of time, as this would definitely break the circuit. But for a limited time, is there any integrator that does proper integration for DC and some range of frequencies? <Q> This circuit: simulate this circuit – Schematic created using CircuitLab will do exactly what you want. <S> Many times a designer will place a resistor in parallel with C1 to limit the gain at DC. <S> If you don't want this behavior you can simply leave it off. <S> Just be prepared to deal with your output hitting the rails in some circumstances. <A> I suppose I know what you mean - and you are right. <S> For an in ideal integrator we require a phase shift of 90 deg between input and output for ALL frequencies (including, for example 0.1 Hz). <S> Because this phase shift requires a 20dB gain roll-off also for low frequencies (down to DC) <S> the corner frequency would be in the vicinity of 0Hz <S> (resp. <S> infinite gain). <S> This is a non-realizable requirement for a realistic opamp. <S> As a consequence, integrating a DC voltage does not result in a linear output voltage increase but in a function known from the step respoonse of any RC lowpass (1-exp). <S> However, the first part of this function is very close to a linear increase. <S> As another option you could use an OTA ("current" output) to charge a load capacitor. <S> Hower, in principle, there is the same limitation: There is no ideal OTA. <S> Each real device has a finite output resistance forming an RC lowpass in conjunction with the load capacitor. <S> Summary : It is not possible to build an ideal integrator. <S> But that`s no surprise because there are no ideal electronic circuits. <S> UPDATE : Of course, as another problem - a capcitor in the feedback path cannot provide the necessary dc feedback for stabilization of a suitable operating point. <S> Therefore, any practical opamp based integrator circuit needs a feedback resistor in parallel to the capacitor. <S> This results in a larger corner frequency of the lowpass function. <A> Short answer - no. <S> There is no such thing as an amplifier with absolutely zero bias that can produce a perfect integrator. <S> Longer answer. <S> You determine what rate of drift is acceptable, you determine what your minimum cutoff frequency for a high pass filter, and you design from there, probably using some sort of self-zeroing amp like a chopper to minimize drift. <A> As a thought experiment, build a digital system (A/D -> microcontroller -> D/A) and try to program the ideal behavior. <S> It's true that execution speed represents a delay so we could substitute an FPGA. <S> Let's have the delay approach zero, since this is a thought experiment. <S> My guess is there would be some code added to handle some desired behavior (like being able to instantly reset the integration), and then that code will reveal what it is you really are trying to get this circuit to do.
| Yes, but you have to be very specific about what your requirements are.
|
Can a charged 120v high voltage capacitor really kill you? recently I have been hacking few psu and have to deal with some high voltage caps. It sort of scared me, but thinking about it, what is the chance of it really killing me. Is it safe to touch one terminal of a charged and opened 120v cap? I mean the other terminal is opened, and connected to nothing, so there is no current flow, so it should be safe. Touching 2 terminals of a charged cap with one of your finger will give you a shock in your finger, but since no current go through your heart, it will not kill you. am I correct? The only scenario a charged cap could kill you is when you touch one terminal with one hand, and other terminal with other hand, and the shock go through your heart. but still, what is the chance of that tiny 120v killing you if you are a health person. I think doctors use high voltage to save people. Is a tiny 120v charged cap really that intimidating? <Q> You are right that 3) is the most risky situation, and I ( <S> and I think most other contributers here) have experienced 2) (not with that sissy 120V <S> you americans use, but with the european 220V that real men use...) and survived with only a tinkling sensation, and in theory 1) should be harmless. <S> But that depends on the situation being exactly what you think it is. <S> And we never make mistakes, do we? <S> There never are any unexpected leakage paths, especially not across you skin because you were sweathing from concentration? <S> I can cross the street in front of my house with my eyes closed for 10 times <S> and I will (probably) survive unharmed. <S> That doesn't realy make it a good idea to do it an 11'th time... <A> It also depends on the size (charge) of the cap, not only the voltage. <S> In PSU and other equipment used to provide a smooth DC output from an AC source, large (high farad) caps are used. <S> Best is to try to drain them a little bit slow with a resistor, not touching the terminals with bare hands (use a non conductive pliers or similar). <S> Other place with high voltage caps are in cameras, the flash mechanism use 100-200µF caps charged with 200-300 volt. <S> An defibrillator can give up to 360 Joules of energy ( http://www.resuscitationcentral.com/defibrillation/biphasic-waveform/ ) <S> The energy stored in a cap of 4700µF and 230 Volt (found in one of my PSU) would be around 125 Joule according to the calculation on this page ( http://hyperphysics.phy-astr.gsu.edu/hbase/electric/capeng.html ) <S> So, I recommend not to go with question #3 on the terminals. <S> The energy (~60 Jouls for 120 volt) might not kill you, but it will be very unpleasant. <S> Note: The top voltage of an cap is often 1.41 times the voltage rating due to the top voltage in the AC-system. <S> 120 an 230 is the average. <S> Note2 <S> : Caps can be filled with even higher voltage if an voltage boosting circuit is present. <S> Like the one in the camera flash (driven by a 3,7 volt battery) <S> ( http://electronics.howstuffworks.com/camera-flash3.htm ) <S> Note3: <S> Long ago when I went to school and learned electronics, a practical joke was to charge a small cap with say 100 volt and throw it to someone with a -'hey, catch'. <A> When dealing with killer caps the figure you want to talk about is energy . <S> For a capacitor you can calculate stored energy as: $$E=\frac{1}{2}CV^2$$ An input cap in an ATX supply is in the range of the mF, while voltage is approximately 170VDC. <S> That adds up to 144J. <S> And yes, 144J is enough to kill you, <S> since voltage is above 50V that is the minimum to start serious conduction in the human body. <S> When working with (possibly) dangerous equipment always keep your left hand behind your back, and wear rubber footwear. <A> It's useful to do a bit of risk analysis. <S> Discharging it through the body carries a greater risk, but realistically, you will probably be startled but fine. <S> Keep in mind that universal power supplies will often boost the voltage to about 300 V in its first stage, to have a smooth, well defined DC voltage to work with. <S> The power stored in the capacitor will relatively quickly be dissipated through the DC/DC converter and the capacitor's voltage will stabilize at the DC/DC converter cutoff voltage, and will then very slowly discharge through whatever leakage path are in place. <S> The purely electrical risk analysis will be the same. <S> The bigger risk in this case is actually your reaction during the shock. <S> Startled as you are, you may do any number of more or less dangerous movements. <S> Maybe you will jump backwards and hit your head. <S> Maybe you will charge your arm toward the exposed 230 V mains wire you have lying around the bench. <S> Maybe you will pull out the oscilloscope from the shelf and have it fall over your head. <S> You get the idea. <S> You can practically treat the capacitor, on its own, as being non-lethal. <S> The more pertinent issue is to develop a careful more attitude to safety than thinking "this setup is safe, so I don't need to worry. <S> " What if you didn't turn off the power switch this time? <S> What if you left that temporary test wire in place and forgot about it? <S> What if you're making an assumption about the circuit that is not true, or the circuit is broken and doesn't work as expected - perhaps being the reason why you're debugging it in the first place. <S> You have everything to gain and nothing to lose from embracing a paranoid attitude about electrical safety. <S> Always measure twice, every time. <S> Never assume that a circuit is safe or discharged. <A> If you've got a charged cap, it will be most likely be connected to some circuits... <S> Or in the progress of unassembling it, you'll be touching it - perhaps with some other instruments. <S> Its easy to construct a path to connect 2 different parts of your body with the 2 pins of the capacitator in this way... <S> So the short answer would be "yes", i think. <S> (And most of the time, you might be lucky.)
| Purely electrically, discharging a 120 V capacitor through your finger is very unlikely to immediately kill you, but likely to give you a burn mark. Remember, accidents happen when you don't expect them.
|
control multiple leds using only 2 connection wires i want to control 5 led bulbs using just 2 wires .depending on some condition i want to turn a led with a specific color from 5 led set and only one led should on at a time. here is a small explanation . in my house we use water tank .if water level is max i want to show it by turning on specific color led.if water level is fine ..weak.. i want to show another color led on the motor switch .but distance between motor switch and tank is very big so i can't really use 6 wires for control 5 leds. so what I'm asking is is it possible to control 5 leds just using 2 wires ? i'm thinking about pulse technique.for example if level is max i send a specific pulse/bit pattern so using small circuit determine which led should turn on. but for that i think i need 3 wires( 3 wire is also ok but led amount can be vary -10 led may be) .what is the cheapest and easiest way to do this ??i'm really new to electronics. if i can do this without using bit pattern it's lot better because detecting bit patterns quite complex to me. thanks <Q> You could send an analogue signal over the two wires to power and signal an LM3914 Dot/Bar Display Driver. <S> https://www.sparkfun.com/products/12694 <A> Make use of a serial in parallel out shift register,see the logic of shift register in the fig simulate this circuit – Schematic created using CircuitLab <S> It needs only one wire from your MCU to the led array and rest <S> can be built up near the array itselfYou can use 74HC595 shift register if no of LEDs are less than 8 ,you can find bigger shift registers if you search Hope this helps <A> I would also carry power (for electronics and LEDs) over the same 2 wires and transfer the data (to select the LED that needs to be on) by superimposing an AC signal on the DC (which carries the power). <S> It would probably take me a couple of days to come up with something working. <S> But I've been working on electronics for 30 years. <S> Since you're new to electronics maybe you should aim a little lower ? <S> Using more wires is a much simpler option. <A> Use 3 wire to send several audio frequencies using IC 555 , then detect with audio filter. <S> Or use 3 wire to send several voltage from resistor-divider, then detect with comparators. <S> Note: 3 wire: signal, positif supply, & ground <A> A very simple and standard way would be to send the data using a serial RS-232 connection. <S> If the distance is long, then use proper RS-232 drivers. <S> Only two wires are required (ground and signal) assuming power is available on both ends. <S> Easy to debug using a PC with a serial-to-USB cable. <S> No real limit on the number of LEDs you can control- with a couple hundred bytes <S> you could individually control more than 1000 LEDs, if it's just a bar graph then 2 bytes is enough.
| This is very well possible with only 2 wires, some electronics are needed on both sides of the wire.
|
Voltage drop across LED in open circuit I've searched the forums but can't find an answer for my issue. I've got a simple LED circuit powered by 5V DC. When the switch is closed, I've got 2.8V across the resistor, 2.2V across the LED, and 0V across the switch (as expected). However, when the switch is open, I get 3.45V across the switch but no other noticeable readings (0V across resistor and 0V across the LED). Where did the other 1.55V go? If I shunt across the LED, I get the expected 5V across the open switch connections. How is there a voltage drop across the LED in an open circuit and why can't it be measured with a DMM? simulate this circuit – Schematic created using CircuitLab <Q> It comes down to the LED still conducting current when it is not illuminating. <S> Take a look at this characteristic from an OMRON LED. <S> It's very rare to see stuff like this in data sheets: - <S> This shows the volt drop (about 1.3 volts) across an LED when 1 uA is flowing <S> and it's not unreasonable to expect all LEDs to behave within a ball-park or two of this. <S> If the meter's input resistance is 10 Mohm then there is about 0.345 <S> uA flowing and there will be probably over a volt dropped across the LED <S> should it be the device in the picture above. <A> It has to do with the internal resistance of your multimeter. <S> The high impedance on the multimeter input is basically creating a path to ground when you measure the open switch. <S> So therefore when you make your measurement, it is the equivalent of adding a high value resistance( in the order of 1 to tenths of megaohms depending on your meter ) in parallel across from where you are taking the measurement in this case the open switch. <S> simulate this circuit – <S> Schematic created using CircuitLab <A> Here is a circuit with a generic blue (or white) <S> LED SPICE model inserted for the LED and 10M to represent your DMM. <S> .model <S> QTLP690C D(Is=1e-22 Rs=6 <S> N=1.5 <S> Cjo=50p <S> Iave=160m Vpk=5 <S> mfg= <S> Fairchild type=LED) <S> The simulated voltage drop across D1 is similar to what you measured at ~1.4V (with an LED of a longer wavelength such as green, yellow or red it would typically be much less than ~1.5V with 350nA flowing). <S> simulate this circuit – <S> Schematic created using CircuitLab <A> When you measure the switch voltage, although the switch opens, you make a closed loop circuit, so you can read the voltage on the multimeter itself (3.45V). <S> When you measure the resistor voltage or LED voltage and the switch opens, the circuit is open. <S> There is no a close loop circuit, so there is no current and no voltage across the multimeter.
| So you are seeing a volt drop across the LED due to the current through the meter's inputs when placed across the open switch. You could assume the multimeter is a resistor with very big resistance (several Mega Ohm).
|
How to make freeRTOS working on stm32f4 I'am trying to run a RTOS on my STM32F407VGT6 board.I downloaded the demo CORTEX_M4F_STM32F407ZG-SK from freeRTOS website and flashed the code using IAR IDE, however the leds are not blinking as expected.while debugging the program i found that the program crashes here: vPortStartFirstTaskldr r0, =0xE000ED08ldr r0, [r0]ldr r0, [r0]msr msp, r0cpsie icpsie fdsbisbsvc 0 // The program crashes here!!!! I made some research in freeRTOS FAQ , the section "The application I created compiles, but does not run" seems to treat the same issue but #define vPortSVCHandler SVC_Handler#define xPortPendSVHandler PendSV_Handler#define xPortSysTickHandler SysTick_Handler exists in FreeRTOSConfig.h file.Does anyone faced the same issue? or the RTOS that I'am using is not the right one? <Q> If your code is 'crashing' on that line, then it is most likely you don't have the FreeRTOS SVC handler installed. <S> I note you included the line: <S> #define xPortPendSVHandler <S> PendSV_Handler <S> Which will replace a CMSIS standard name (PendSV_Handler) with the FreeRTOS name, but that is assuming your vector table is using the CMSIS standard name - check that is the case, and that nothing else in your application is replacing the vector table with a different one by re-writing the vector base address register. <S> By the way - FreeRTOS has a very active support forum - always beats me why people ask FreeRTOS questions in any other place than the place specifically where FreeRTOS experts are watching and ready to answer questions. <S> ARM cortex M4 products are based on ARM7 core architecture <S> Actually, this is not the case. <S> As confusing as it may seem, ARM7 microcontrollers use an ARMv4 core, whereas Cortex-M4 microcontrollers use an ARMv7 core :o) <S> So that particular FAQ does not apply in this case. <A> In the FreeRTOS FAQ that you are using did check for point 5 <S> The RTOS scheduler crashes when attempting to start the first taskIf you are using an ARM7 target <S> then the processor must be in Supervisor mode when the RTOS scheduler is started. <S> ARM cortex M4 products are based on ARM7 core architecture, see this wikipedia reference and since your snippet clearly shows "vPortStartFirstTask" this completely seems to describe what is going on with your system. <A> You must remove the SVC_Handler and PendSV_Handler ISR handler in <S> stm32f4xx_it.c <S> file. <S> You can select "Auto(extension-based)" in Language section. <S> You must add the root of FreeRTOSConfig.h file to preprocessor tab of assembler section of project option window like this:
| The FreeRTOS files must be compiled in c compiler mode not in C++, it is mean that C files must be compiled as C source code and C++ files must be compiled as C++ source code.
|
Controlling electric power steering using an Arduino to emulate torque sensor I am trying to control an electric power steering rack with an Arduino. To do this I need to "trick" the EPS module that there is torque being applied when there really isn't. On the rack there are 4 wires coming from the torque sensors where the torsion bar is which go into the EPS module. I cut these wires so I could splice in and play around. I determined each wire is 5+V, T1, T2, and GND. When I connect my own 5V and GND to the torque sensor, I am able to read T1 and T2 via the two analog-in pins on my Arduino. When no force is on the wheel, T1 reads about 2.3V and T2 reads about 2.6V. When trying to steer left, T1 drops while T2 rises and vice-versa. I have a shield with 4 (100k) digital potentiometers. I figured it would be easy enough to have the Arduino "emulate" the torque sensor, so I connected the EPS module 5+V to POT1A, GND to POT1B, and T1 to POT1Wiper. I did the same for T2 (5+V to POT2A, GND to POT2B, and T2 To POT2Wiper). My Arduino sketch simply reads the analog pins for T1 and T2 connected to the torque sensor, scales them into a float ranging from 0.0-1.0, and then I tell each digit-pot to adjust the wiper accordingly. What should result is the steering be close to the same as if it were directly connected to the torque sensor. When I try applying my own 5V source to the POTs, the wiper voltage reading is correct (i.e. I tell the digi-pot to set wiper position to 128, meter reads 2.5V). But, when connected to the EPS module, the reading is off (at 128 it reads around 4V and only changes slightly as from 0 to 256). I then tested the EPS module wires. Connecting my multimeter to 5+V and GND reads 5V (expected), but also reads 5+V on T1 or T2. T1 and T2 show no voltage. Also to note when testing voltages on T1 and T2 while the torque sensor is connected to the module like normal, the voltage readings are what I get when I power and read the torque sensor directly. I have confirmed that the signal from the torque sensor is pure analog, no PWM or digital signals at all. Any ideas on what the torque sensor is doing to drive the ECU properly to get this working would be much appreciated. Thanks,Andrew <Q> Looks like you are not driving the output drivers are not strong enough. <S> Many of the sensors have low output impedance (about a kiloohm or less) and thus can provide tens of mA's of current. <S> Your 100K digipot can provide much less than that. <S> Make sure the op-amp can have the desired input and output voltage <S> (you likely want 'rail-to-rail' opamp) -- for example LM324 will only accept 0V to 3.5V input when powered from +5V. <A> To me it seems that is is driving a differential signal. <S> You could try using a Single-Ended to Differential Converter to try to emulate the signal that you are seeing with a low output impedance that will not get any loading effects from the ECU as you seem to be experiencing with the digital POTs <A> It is my understanding of most EPS sensors that the difference in voltage from T1 and T2 tells the controller two things. <S> Which direction for the motor to turn and with how much force, current. <S> The controller needs both, rather the difference in the two. <A> You are half way there. <S> The torque sensor is activated by the EPS module, but first you have to activate the EPS module by feeding it data as ignition switch, RPM data and the constant 12 volts for the DC motor. <A> Use a Ratiometric DAC with 12 bit resolution and bandwidth 3.2kHz with a digital low pass filter to generate the emulated sensor output. <S> Make sure your circuit doesn't pull more than 30mA.
| Try adding op-amps to each output in a simple buffer connection.
|
NE555 output voltage is too low I'm trying to make a simple astable circuit. It should be one of the easiest ones in history of electronics, but I can't figure out what's wrong with my design: simulate this circuit – Schematic created using CircuitLab The output voltage remains too low. About 1.5 V peak to peak. (For my application this is less important, but maybe it could be useful to note also that the calculated frequency differs from the real one of about 30 KHz.) I tried a different power supply and also a different ne555 IC.Could someone please explain to me why the voltage is so low? <Q> The calculated frequency (datasheet equation) for that configuration is about 195kHz. <S> The calculations are invalid, however, since the bipolar version of the 555 (NE555) only barely works to 100kHz. <S> You can try the CMOS version (eg. <S> TLC555 ) which will work fine at that frequency. <S> You might want to consider increasing the resistor values somewhat (maybe 3-5:1) and decreasing the timing capacitor. <S> You can verify this with the circuit you have simply by increasing the timing capacitor (say to 10nF). <A> I think that your problem might be that you are using a X10 scope probe but the scope thinks that you have a X1 probe attached. <S> The output of a NE555 doesn't go all the way to Vcc - there is an internal voltage drop of more than 1 Volt. <S> If you look closely at your scope waveform, I see an amplitude of about either 0.8V (X1 probe) or 8V (X10 probe). <S> I'm putting my money on X10 probe. <S> It is also possible that the probe compensation isn't adjusted properly. <A> The circuit is fine. <S> Here is what I suggest you to do. <S> First, change c1 to higher value. <S> Second change R2 to 1k, same as R1, this will give you 1/2 on, and 1/2 off output timing which will increase your output voltage. <A> I'm sorry, shame on me.. <S> As Spehro and Dwayne pointed out, I accidentaly move the probe switch to 10X instead of 1X, and the scope was set to 1X. <S> That's really embarassing :) <S> thanks everybody!
| The problem is that the frequency is too fast and there are more LOW than HIGH outputs, so the 555 has not totally turned on for 1/3 of the time, so it doesn't give you rail voltage output. In other words, I think that you are dealing with a measurement problem rather than a circuit problem.
|
Battery gauge – Microcontroller 3.3V using a 4.8V NiMh battery source Well I am currently working on building a battery gauge via LED. My target is a red LED to blinkif batteries are going to die and a green LED to blink if the batteries are fine. Researching on that topic different questions already have been considered and mostly referred to a link such as http://batteryuniversity.com/learn/article/how_to_measure_state_of_charge .Knowing the limitations I was planning to make use of the Voltage Method.The batteries I was planning to use were NiMh enveloop pro batteries (AA). Considering the tests on the battery (I couldn’t find the datasheet) the http://www.stefanv.com/electronics/sanyo_eneloop.html I found out that the battery mostly crosses below 1,1V before dying. Therefore I was planning to use 1.1V per Battery as a threshold or indication that the battery will die.To apply the voltage method beneficially, using the internal 1.1V reference voltage of the Adafruit Trinket Pro (according to the datasheet of atmega 328p, which can be found in the Trinket) has to be measured against the input voltage(as described : http://wp.josh.com/2014/11/06/battery-fuel-guage-with-zero-parts-and-zero-pins-on-avr/ ). However my issue is that I make use of an Adafruit Trinket Pro 3V and a Servo having one source of battery (4XAA NiMh).4.8V are provided to the Servo. A buck converter is attached between the battery and the Trinket in order to provide it with its required 3.3V. Generally using the Voltage method for a battery gauge the ADC Pin is compared to Vcc Pin as described above. However in my case the microcontroller will always receive 3.3V. Any voltage drop of the battery will only affect the servo since the buck converter will make sure to provide the microcontroller with sufficient voltage.Therefore using the voltage method I do not know how I may identify any voltage drop on the 4.8V battery source because the voltage drop will have no effect on the Adafruit Trinket. Given these circumstances is there a way to make a battery gauge making use of the voltage method or any other beneficial way? I am aware that the difference in VBAT and VCC might complicate the issue.. Information Adafruit trinket: https://learn.adafruit.com/introducing-pro-trinket/overview Datasheet atmega 328p: http://www.adafruit.com/datasheets/ATMEGA328P.pdf <Q> Since you want to use a regulator, you can't assume Vbat= <S> Vcc. <S> So you need to use an external pin to measure battery voltage. <S> The most simple method I can think of is a voltage divider tied to an ADC pin (if you want full voltage level) or an analog comparator pin (if you only need 1.1v threshold; you can use the internal reference as the other input to the internal comparator) <S> However you need to use resistor values high enough for an acceptable current draw, and low enough for adc input impedance and noise. <S> A cap across input pin may help with noise and for storing enough charge for the adc s/h capacitor noise. <S> And if you need very low average power draw, you can tie the ground side of the resistor divider to a digital pin or (better) tie the upper side to a p-mosfet whose gate is controlled by a digital pin. <S> This way you can enable the divider only while you're actually measuring it. <S> In any case I don't think you need an external comparator unless you need advanced features (super low offset voltage, for example) <S> the AVR peripherals don't provide. <A> I believe you could use a comparator with a voltage reference to output a 3.3V signal as to whether the battery is getting low or now. <S> Basically you could use a voltage divider on your Vbat to divide it down to 1/4th your Vbat, <S> so around 1.2V. <S> Since the voltage when its low dips below 1.1V, you can use a 1.1V voltage reference. <S> Connect them both to a comparator. <S> simulate this circuit – <S> Schematic created using <S> CircuitLab <S> I just threw this schematic together, so the orientation of the comparator may be wrong and I didn't even attempt the resistor values. <S> But this is the general idea. <A> This design uses two microcontroller pins, an ADC input and a digital output. <S> To make a measurement, set the digital pin to a low output, then read the ADC. <S> After the measurement digital output high to turn off the transistor and avoid wasting current. <S> RYE002N is chosen for its low threshold voltage. <S> If the threshold voltage is too high, accuracy is compromised at high battery voltages. <S> This may not be important for this application. <S> With these values, a voltage of 4.4V will apply 0.88 V to the ADC. <S> simulate this circuit – <S> Schematic created using CircuitLab
| To measure a battery voltage, you need a resistor divider and a transistor.
|
Regulating AA to 5V and achieving high efficiency I'm trying to regulate a single AA battery to 5V for charging a USB device. I know even at perfect efficiency, it won't provide much juice (1.5v * 1500 / 5v). But what is the expected efficiency for stepping up to 5v from 1.5v? Is 80pc achievable? Are there other issues one should worry about in designing application? <Q> Although there are several decent DC-DC Boost Converters available, I suggest that you try to use 2 "AA" cells if you have the room. <S> I currently use the LM2623 boost converter from TI (formerly National Semiconductor) in several products. <S> This is a pretty darn decent device that will work from a single "AA" cell. <S> In a nutshell, the LM2623 runs from 0.8V through 14V and has an on-board switch rated at 2.85 Amps. <S> The input voltage can't exceed the desired output voltage. <S> The TI product page is LM2623 <S> I'm also using the Microchip MCP1640 boost converter. <S> This doesn't have as much current capability as the LM2623 but has the decided advantage of disconnecting the output load when the chip is shut down. <S> This was very important in a couple of my projects. <S> In a nutshell, the MPC1640 starts with an input voltage greater than 0.65V but will remain running down to 0.35V. <S> The internal switch has considerably less current rating than the LM2623 at 0.8 Amps. <S> Be aware that the MCP1640 is available in 4 different variants. <S> We use the 1640 & 1640D versions. <S> The Microchip product page is MCP1640 <S> You should also have a look at the Adafruit MintyBoost project page. <S> This uses a different boost converter and runs from a pair of "AA" cells. <S> The project is useful in its own right but even if you decide to use a different boost converter, the USB interface information is invaluable. <S> The Adafruit MintyBoost project page is Minty Boost <A> A typical boost/step up switching regulator can provide 80~90% efficiency, or better, as calculated in Watts (Power). <S> P = <S> V <S> * I Efficiency = <S> Output Power / Input Power <S> A typical Alkaline AA battery has a capacity of 2500 mAh. <S> That is not at a constant 1.5V, but ranges from 1.6V at full charge to 1.2V when dead. <S> If we fudge the numbers, that's 1.5V <S> * 2500 <S> mAh = 3.75 Watt Hours. <S> At 80% efficiency that's 3 Watts Hours. <S> 3 WH at 5 Volts is just 600 mAh. <S> In an ideal circuit, you will only be able to provide 600 mA for 1 hour with a typical boost circuit from a single AA battery. <A> I bought some from sparkfun and they were working perfectly, <S> I never measured the efficiency, but I can say that they were cold, therefore no waste dissipation of energy. <S> You should buy the required power rated converter, don't buy bigger one as the efficiency matters in % of load.
| I would say yes, there are many cheap boost DC/DC converters.
|
Inverting 3-to-8 decoder with all-active option I have a requirement for an inverting 3-to-8 decoder circuit (i.e. all 8 output high except the selected one being low), but with an option to have all the outputs go low. The 74HC137 or 74HC138 is close to what I need, but it's three reset conditions all have all outputs high. Does anyone know of a real-estate-conserving solution (i.e. not a lot of components)? EDIT: Desired truth table: A B C R 7 6 5 4 3 2 1 00 0 0 0 H H H H H H H L0 0 1 0 H H H H H H L H0 1 0 0 H H H H H L H H0 1 1 0 H H H H L H H H...1 1 1 0 L H H H H H H HX X X 1 L L L L L L L L R represents some sort of reset input that enables all the outputs (lines 0-7). A, B, and C are the address inputs. <Q> Switch the 74HC245 off (into z state) for the all zeros state and put a pulldown resistor array to outputs. <A> Are inexpensive PLDs or CPLDs still available? <S> This sort of thing is exactly what they are great at doing. <S> Otherwise, I see at least 3 packages: a hc138 & 2- quad AND gates or a hc137 & 2- quad NOR gates, depending on whether you want active HI or LO for the "All Active" state. <A> Googling around I found the 74F538 which seems like it could come pretty close to doing what you want (except your "all outputs" input would be active low rather than active high) by tying together the polarity control input and one of the enable inputs. <S> Unfortunately it no longer seems to be available. <S> https://www.engineering.uiowa.edu/sites/default/files/ees/files/NI/pdfs/00/95/DS009551.pdf
| Maybe you could use a combination of 74HC138 decoder and 74HC245 bus buffer.
|
Why does my rectangle function on a FPGA look like this? I programmed my FPGA to create a simple 1 MHz rectangle function. But when I display the resulting function on my oscilloscope it shows some oscillation after the edges. At first I thought this might be the the Fourier components, but this doesn't seem to fit(eg. it's not symmetric). What creates these oscillations? I have a few guesses, but no idea which, if any, is right: some unintentional LC-circut a badly configured PID inside the FPGA crosstalk <Q> How long is the ground lead on your scope probe? <S> your scope probe should be in the X10 position and be properly compensated. <S> Remove the long ground lead that came with the scope probe and also remove the probe grabber hook from the front of the probe. <S> Grab some #22 or #24 bare wire and wrap 2 or 3 turns around the exposed metal ring at the front of the probe. <S> Tightly twist the ends of the wire loop together so as to make a stiff pigtail. <S> Solder that ground pigtail to a ground point that is as close as possible to the signal that you want to measure. <S> The ground pigtail should be as short as possible. <S> Touch the probe tip to the signal that you want to observe. <S> Now look at your scope waveform. <S> Chances are very good that it will look much better, without the ringing that you are seeing on the fast transistions. <S> In other words, this looks to be a measurement problem rather than something wrong with your circuit. <A> This is normally called ringing and is common. <S> If there is just single pulse then it is referred to as overshoot. <S> Even one or two inches of wire may create enough inductance to cause this effect. <S> Often it is exaggerated by bad grounding of the scope probe. <S> You should use as short a ground lead on the probe as possible. <S> Often I can check whether it is caused by the probe just by gripping the scope probe and ground lead tightly with my hand - <S> if the displayed trace changes then the grounding is not good enough. <S> Your scope probe may have come with alternate tips that include ways of connecting the probe to the circuitry with a shorter ground. <S> This application note from Jim Williams has some good ideas and explanations of probing problems: Jim Williams AN47 <S> As the other posters have commented the oscilloscope you are using is extremely low in bandwidth by modern standards. <S> In general I find that 100MHz bandwidth is a good bandwidth for use with circuits with clocks up to 10-20MHz. <S> In my professional work 1GHz is typical now for general purpose use. <S> Also although the signal frequency may only be 1MHz in your example the signals will transition in 1 ns or faster that can cause very high frequency effects. <A> your scope says 10Mhz right on the front; that's the 3dB bandwidth. <S> So the 1Mhz fundamental gets through without much distortion, but only up through about the 9th or 11th harmonic... <S> so the square wave will appear to have some ringing at the edges. <S> this is normal. <S> a higher bandwitdh scope would show the 1Mhz signal with crisper edges, but there will always be some ringing. <S> it's more noticeable as you approach the bandwidth limit of the instrument. <A> I believe the major cause of the edge ringing is the scope probe. <S> With regards to the symmetry of the signal, I see it very symmetrical.
| As you surmise it is caused by unintentional LC elements in the wiring being excited by the fast edges of the signal.
|
Why would you use a non-contact voltage detector if you have a multimeter? I was reading this Fluke multimeter safety manual and I came across this sentence: http://faculty.riohondo.edu/jfrala/fluke_multimeters_-_abcs_of_multimeter_safety_multimeter_safety_and_you_application_note.pdf "Non-contact voltage detectors are a quick, inexpensive way to check for the presence of live voltage on ac circuits, switches and outlets before working on them." Question 1: Why exactly is this relevant? If you are going to work on a circuit, why not use your multimeter directly to check the presence of voltage? I thought about safety but I can't see a real reason. If you are worried about safety, once you measure the presence of voltage with the non-contact voltage detector you would need to use your multimeter next anyway (and the "safety" you supposedly got from measuring it with the the non-contact detector would becomes useless). What am I missing? Question 2: Why exactly are these called "non-contact" voltage detectors? You still need to physically insert them into an outlet (or somewhere else you want to check) in order for it to work. <Q> Q2: Non-contact voltage detectors <S> don't need to physically touch the measured hardware. <S> They work by sensing the AC electric field created by live AC wires. <S> They're used to quickly see if there is something live, e.g. connected to a wall outlet, inside a device. <S> You can also use them to track where power wiring is going inside a wall etc. <S> They often also have a metal detector so you can also track wires which are not live. <S> Q1: <S> "Working on a circuit" doesn't necessarily mean "debugging a circuit" here; you might not have a need to measure the circuit electrically. <S> You might be replacing a broken plastic casing for example, and you'd use the detector to see if there's something that could give you an electric shock at the other side of the plastic before you start to fix it. <S> Obviously you shouldn't rely just on the meter for your safety. <A> Checking voltage with a volt meter may not always be convenient. <S> For example older light switches had the wires inserted in the back instead of the sides like modern ones. <S> The switch would have to be removed first to use a volt meter. <S> Also if working on a wiring junction in an electrical box. <S> The wires would have to be exposed before a meter could be used. <S> The meter is called non contact because there is no metal exposed that contacts anything electrified. <S> The tip of the meter is plastic. <S> The reason it needs to be inserted in an outlet is because the contacts of the outlet are recessed. <S> The meter has to be close enough to the contacts to sense the voltage. <S> The meter can also be held up to insulated wires and up against the side of an outlet or a light switch. <A> For a voltage reading to appear on your voltmeter, you need a complete loop. <S> If one end of a single phase supply had a wire break, you will not be able to detect that the other cable is live. <S> A non contact voltage tester can detect voltage on individual test points. <S> A voltmeter tells you if there is continuity from the supply to both test points, it does not tell you if a cable is not live.
| You'd disconnect wall fuses or kill main switches before you start, using the meter just gives you some extra protection: with the meter you might notice for example that you've disconnected the wrong fuse and the unit is still live.
|
Is it OK to leave some part out of the schematic if noted? When I make schematic drawings for my projects I tend to leave things like the power switch, fuse etc. out of the schematic. I do it because I don't feel it's an important part of the circuit, one might argue that it's not actually a part of the circuit at all. And I like keeping the schematics as clean as possible. Is this OK? Or considered bad practice? I do make a note of that I have left out, like on the image below. <Q> A schematic is an abstraction of the real circuit. <S> We use abstractions because we want to communicate something to other people (including our future self). <S> But if you want to use your schematic as input for making a PCB <S> and you want the fuse on the PCB, then it is silly to leave it out in the schematic. <S> So it all about the intented use of your schematic. <A> For manufacturing purposes, everything on the PCB should appear somewhere on the schematic. <S> Where I worked this included not just the power supply and all connectors but pseudo-components for test pads, mounting holes, etc. <S> That doesn't necessarily mean it needs to be on the same page as the core functionality, you can park it all at the end of a multi-page schematic. <A> Period. <S> Independent and complete modules that have independent schematics don't need it (ie the lcd back light is part of the lcd on the A C pins), but if it's part of your circuit it should.
| If what you want to tell to other people about your circuit does not involve the fuse, then it is fine to leave it out. If it's part of the circuit, it should be in the schematic.
|
Induction motor electrical and mechanical angle How do we reach the relation between mechanical angle(\$\theta m\$) and electrical angle(\$\theta e\$) as: \$\theta e = (P/2)\theta m\$ ?; where P is the number of poles. <Q> In a multipolar electrical machine (motor or generator), relationship between the mechanical angle and electrical angle is given by:Electrical angle = (P/2) <S> x Mechanical anglewhere: P = Number of poles <S> So: <S> In a two-pole motor (P = 2): Electrical Angle = Mechanical Angle <S> In a four-pole motor (P = 4): Electrical Angle = 2 times Mechanical Angle <S> In a six-pole motor (P = 6): Electrical Angle = 3 times Mechanical Angle etc. <S> Source : <S> http://www.researchgate.net/post/Is_there_a_relation_between_the_electrical_and_mechanical_angle Hope <S> this helps <A> How do we reach the relation between mechanical angle(θm) and electrical angle(\$θ_e\$) as: \$θ_e\$=(P/2)\$θ_m\$ ? ; where P is the number of poles. <S> An electrical machine is simply an electrical<>mechanical energy conversion device which utilises magnetic fields as the exchange medium. <S> When an electrical machine is operating as a motor, the idea is to create a traveling, rotating magnetic field, via the stator and "hope" 1 that this moving flux attracts the rotor (be it via an equivalent magnetic field or via an affinity to reduce the reluctance) <S> So a stator: <S> A 3 phase, single pole pair topology. <S> If the stator was now unrolled <S> you can now see that for 360degree electrical we have equally achieved 360degree mechanical. <S> As the number of pole-pairs is increased, the point at which an electrical cycle is completed becomes a fraction of the main mechanical cycle & this factor is the pole-pair count <S> 1 <S> hope is used because there are some prerequisites that must be met that are machine specific. <S> freq, voltage, load, supply ... <A> 1 revolution of the shaft equals 360 mechanical degrees. <S> Electrical degrees in a motor has to do with the magnetic position of the rotor. <S> One transition from "North" to "South" to "North" again equals 360 electrical degrees. <S> From this, it should be easy to picture. <S> A 2 pole motor has 1 "North" pole and 1 "South" pole on the rotor. <S> So in order for it to turn 360 electrical degrees ("North" to "South" to "North"), it needs to rotate 360 (\$\frac{360}{1}\$) mechanical degrees. <S> A 4 pole motor has 2 "North" poles and 2 "South" poles. <S> That means that 360 electrical degrees will occur when the shaft has rotated only 180 (\$\frac{360}{2}\$) mechanical degrees. <S> A 6 pole motor has 3 "North" poles and 3 "South" poles. <S> That means that 360 electrical degrees will occur when the shaft has rotated only 120 (\$\frac{360}{3}\$) mechanical degrees. <S> You can see that each time we divide the mechanical degrees by the number of pole pairs (or, the number of poles divided by 2). <S> So in general we can say that \$\theta_e=\frac{P}{2}\theta_m\$. <A> The mechanical angle is angle of rotor shaft vs stator, meanwhile the electrical angle is the angle between poles (rotor vs stator). <S> If you have one pole pair only, then electric = mechanical.
| Mechanical degrees in a motor refers to the rotation of the shaft.
|
Do all USB Type C cables support full power delivery USB Power Delivery is able to work over USB Type A/B cables which are specifically designed to support it. Since the USB Type C was designed much later, I am curious. Do all USB Type C cables support USB PD by default? And do they support a certain level, or the full 100W? Related: Does USB Power Delivery handle USB cables that are not PD-aware? <Q> Type-C cables must include CC lines, so they all support USB-PD communication . <S> The major differentiation is supported current. <S> Passive Type-C cables support up to 3A by default at any USB-PD voltage range ( <S> standard voltages for fixed sources are 5V, 12V and 20V). <S> So passive cables can carry up to 15W at 5V, 36W at 12V or 60W at 20V, if the source and sink negotiate an explicit contract for these voltage/current levels. <S> In order for a USB-PD compliant source to advertise capabilities greater than 3A (or up to the full 5A limit of the spec) the Type-C cable must be an Electronically Marked Cable Assembly (EMCA) and support SOP' packets. <S> It must respond to the "Discover Identity" VDM sequence (USB-PD spec section 6.4.4.3.1) with a cable VDO packet with bits 6..5 set to indicate 5A current handling capability. <A> No Not all USB Type-C Cable supports USB PD by default. <S> Electronically marked cable supports USB PD and "may" support upto 100W A USB Type-C cable which is not electronically marked can support upto 15W. <A> Yes they are assuming they are certified by the USB group. <S> It is noted in the USB PD 1.0 presentation that it is "compatible with USB 2.0 and 3.0 cables" <S> so they should be fine. <S> The USB-PD spec confirms they are compatible assuming they are spec-compliant. <S> The USB Type-C mechanical/electrical standard dictates the connector and the physical pinout of the connector. <S> USB-PD doesn't alter any of that but rather is an extension of the USB Type-C protocol. <S> What you'll most likely see in the future is <S> microcontrollers coming out with USB Type-C support/engines that may or may not include the USB-PD extension standard. <S> Give this article a read, it should help out
| Not all Type-C cables support the full range of power capabilities that USB-PD specifies, however.
|
Is it safe to use PC analog output card as current source? I have a very PCI analog output card which could output a voltage ranged from 0 to 5V. I need a circuit to output a current ranged from 10mA to 90mA. The load is about 45 Ohm. So is it safe to connect directly the analog output to the load and change the voltage until we get the desire current? Will it burn the card if it is not correctly connected? I am sorry that I don't have much experience in circuit building. But I read other article about using op-amp to control the output current by input voltage. simulate this circuit – Schematic created using CircuitLab I wonder if the above schematic is a correct setup to apply a current to a load? What's the advantage to the op amp for this purpose? <Q> Your schematic shows a "buffer" circuit, the opamp just copies the input voltage at it's + input to the output, provided it can drive the output to this voltage and provided the output is loaded such that it can deliver the current. <S> If you would not use such a "buffer" circuit, all the current to the load would have to come from the analog PCI card in the PC. <S> These are usually not designed to deliver much current, 10 mA will usually be problematic already. <S> So you need something to fix that, this is called a buffer. <S> You do not need the 200 ohms R1 resistor, you can connect the - input directly to the output of the opamp. <S> You say you want to control the current but <S> actually this circuit controls the voltage ! <S> Now if the load is constant, for example 45 ohms then this makes no difference as I = <S> V / R. <S> If this is OK for you, meaning that the load will always be 45 ohms, then this circuit is fine. <S> BUT 90 mA will be too much for many opamps, however there are some power opamps that can handle this you will have to look at the opamp's datasheet. <S> You can also let the opamp control a small power transistor so that the power transistor does all the hard work. <S> That would look like: <S> simulate this circuit – <S> Schematic created using CircuitLab <A> Your circuit makes no sense - feedback resistor connected to some point half way along the op-amp is the problem but, even if it were connected to the output this would be a voltage buffer. <S> If you want a ground referenced current source consider this: - <S> The voltage across R1 dictates the current thru the load (shown as a box with "current out" written in the middle. <S> However, it is a little inconvenient to have current out controlled by the voltage across R1 and so people tend to make a positive rails referenced current source that feeds R1, then your input voltage (ground referenced) controls a ground referenced load with respect to current. <S> The circuit directly above controls a current from a ground referenced control voltage. <S> Where it says Iload, this feds into R1 in the upper circuit and R3 is discarded. <S> There are plenty of different ideas for current sources as can be found here . <A> Technically speaking your circuit is fine. <S> You've build what is essentially a voltage follower, <S> i.e. a unity gain amplifier. <S> I <S> don;t know why you have a 200E resistance in the feedback; using a wire would work the same. <S> Your PCI card sees a very high impedance and does not source a lot of current. <S> The op-amp will source the current to the load, and the voltage across the 45E Load will equal the PCI card output. <S> In reality, you need to take care of:1. <S> Isolating the power supply of the op-amp from the PC power supply, at a minimum.2.
| Look at input impedance of the op-amp, output impedance of your PCI card and see how they match up.
|
Powering a LED off a 1,2 volt rechargeable battery I would like to power a LED off a 1,2 volt rechargeable battery,850mAh,energizer without any resistors.Since the LED has a forward voltage around 2 volts,working fine when connected to a 1,5 volt alakaline AA battery,it's obvious that the voltage isn't a problem.However,I am not so sure about the current.Would the LED be fried if I connected it to this battery? <Q> The danger with too high a voltage is that the amount of current that is allowed to flow will be too high for the LED's power handling and the semiconductor will melt/blow up, but this is not a problem is the voltage if too low to allow much current at all. <A> To be sure what current the LED will draw without an explicit resistor you will have to know its characteristics, and the characteristics of the battery. <S> It is likely that both will be so ill-determined (variable over time, temperature, recharging, etc.) <S> that you will get a current that can vary widely. <S> Whether this is a problem (varing brightness, maybe reduced lifetime) is up to you to decide. <A> Would the LED be fried if I connected it to this battery? <S> Depends on two factors. <S> The Battery's Internal Equivalent Series Resistance, and the IV Curve of the LED. <S> The 2V stated Forward Voltage of the LEDis likely at 20mA, the typical Forward Current for the stated expected life of the LED. <S> At 1.2V fully charged, the LED likely won't be damaged, but the brightness will be considerably dimmer than it would be at a voltage and current close to 2V @ <S> 20mA. <S> For example, super cheap led flashlights are composed of an Led (Lets say Blue at 3.4V) and a 3V Coin Cell Battery (CR2032). <S> The Battery's lower voltage and high ESR (about 20 Ohms) allow the LED to be nice and bright without needing a resistor. <S> Frankly, just sacrifice an LED in the name of scientific experimentation, and try it. <S> If it blows, you know you need a resistor. <S> If it doesn't, you are all good* . <S> A quick test of a red LED and a brand new 1.5V AA Alkaline battery shows it working. <S> How long the LED would last like would take long term experimentation to know.
| No, because when the supply is below the LED's forward voltage only a very small amount of current (hundreds of microamps, if that) will be able to flow; if the LED is visible at all it will be very dim.
|
Correct Way to Limit Op Amp Output Current I'm planning to use an AD817 op amp in the output stage of my function generator ( datasheet ).I'm worried about how the part would stand up to a short, so I ran some simulations. The simulation below sources 70mA through R3 when the output (probe tip) is shorted. This makes sense and tallies somewhat with the datasheet which gives a max current of 100mA @ 25degC, but less at higher temperatures. Since the part (according to spice) is dissipating 800mW it's likely to be hot. Although 800mW is within the max spec for this device (around 1.4W @ 25degC), I'm not comfortable with 800mW of dissipation. Which brings me to the question. Is there a best practice way to limit the output current of an op amp under short circuit conditions? Basic Amplifier: Here are some options I've tried, with comments: 1) Push-pull Amplifier to Relieve Op Amp Output Stage Works well to limit op amp output current but could deliver 10V/47 = 200mA through R3 @ 1W. The transistors would need to dissipate 500mW each. 2) BJT Based Current Limiter BJT based current limiter based on some sources I came across (see here and here ). This is more like what I'm looking for, but I couldn't make it work!. Am I correct in thinking that the current diverted away by Q3/Q4 ends up at the base of R3? Other options: 3) Reduce the gain. Reduced signal amplitude isn't desirable. 4) Limit the power supply current. Would (needlessly?) effect other parts of the circuit. <Q> EDIT - IGNORE C1 - unfortunately this is the only circuit that I could find with the Rout component shown within the feedback loop so, please ignore C1 <S> - it is not meant to be there. <S> This technique is used (with care) <S> a fair amount: - Ignore C1 and just analyse how much current the op-amp can supply to a load in the place of C1. <S> If the maximum output of the op-amp is (say) 4 volts (+/-5 volts supply), there can be no more than 53mA delivered into a short circuit. <S> On normal loads, the op-amp has to work a bit harder because the 75 ohm forms a potential divider <S> BUT, the good side is the feedback loop compensates for this. <A> You can use your method, but just add some more op-amps in parallel and increase the resistors. <S> For example, use 100R resistor to get an output Z of 50 ohms. <S> I believe this method is used in Keysight (née Agilent, née HP) <S> arb function generator output stages. <S> simulate this circuit – <S> Schematic created using CircuitLab <A> There are opamps that can drive 50 ohms (to ground) <S> BUT the output voltage will be limited to a couple of volts. <S> Usually too little for a function generator especially if you would also like to be able to shift the DC level at the output up or down (this adds to the voltage). <S> The easiest and most common choice is to implement and amplifier like in option 1), the amplifier should be designed to drive any voltage into 50 ohms. <S> Current limiting is not needed as the 50 ohms resistor will limit the current. <S> Ad option 2) <S> I think the output current never reaches its limiting value because you have the 50 ohms at the output. <S> Anyway, if you insist on current limiting I would suggest to use a more traditional solution with current sensing resistors in series with the emitters like your first link . <S> Many audio amplifiers use this type of protection. <S> Another observation: your amplifiers appear to be class B amplifiers read this if that does not ring a bell . <S> For a function generator you want low crossover distortion <S> so I would suggest at least class AB or even better: <S> class A. <S> But it all depends on your needs and how efficient you want your design to be. <S> Oldfashioned analog function generators get warm, they use a significant amount of power, that is (partly) because their endstage operates in class A !
| The 50 ohms output impedance helps as it will limit the output current.
|
How can a high-voltage transistor be in such small packaging? For example: STN0214 - Very high voltage NPN power transistor It is said to accept more than 1 kV between its collector and emitter. It comes in a SOT-223 package (3 pins plus a tab). With a dielectric strength of 1 kV/mm for humid air, cannot an arc appear between the electrodes? Or do you have to enclose the package in glue or other material with higher dielectric strength than air? <Q> Hmm, it does seem tight. <S> The pin pitch is 2.3 mm, and the maximum pin width is .85 mm, leaving 1.45 mm minimum space between pins. <S> The transistor is specified for 1.4 kV C-E, which are on adjacent pins, so that's just about 1 kV/mm. <S> As I said, that seems tight, and you'd have to be careful in designing the PCB footprint to not make this worse. <S> Usually I make PCB pads a little wider than the pins, but in this case I wouldn't. <S> Even if you make the pads the same width as the pins, then any alignment error cuts into the spacing. <S> Overall, I'd prefer a larger package with more space between pins to get somewhat below 1 kV/mm. <A> Yes, you would typically apply a compound to seal the pins after mounting. <S> Even for much larger spacing this is typically done since the leads often have sharp corners (more prone to corona and breakdown). <S> We routinely add something like Corona Dope to even rather large components (HV relays, etc) when the voltage gets up and over 1kV. <S> This provides protection on the order of ~145kV/mm and suppresses both arcs and corona discharge . <S> Surely Corona Dope is not the most suitable compound for this part, of course <S> - it's just to provide the example. <S> In any case, some sort of conformal insulating coating would be required in a system that operated the device to its maximum 1.4kV rating. <S> What would be of greater concern would be the PCB itself and the traces/pads - <S> the chip is too tight for standard low-voltage PCB materials and design standards <S> (ie: a board made with IPC specified materials). <S> For example, IPC2221A specifications indicate minimum spacing for permanently coated external conductors ( <S> ie: chip leads - assuming coated as above) as : 0.8mm @ <S> 500V + <S> 0.00305mm/V <S> additionally -- <S> > for 1.4kV this is 0.8 + 900 <S> *0.00305 = <S> 3.545mm <S> Even the internal board traces would have to be spaced further apart (2.5mm, by a similar calculation) than the chip allows. <S> So, in addition to needing to coat the component leads with an insulating compound after mounting, a standard PCB designed for low voltage circuits would not be appropriate for this component at its maximum rating. <S> You would therefore need to mount it on a board that was specifically designed for medium voltage (generally ~600-3000V) applications. <A> It is not clear what the actual minimum distance between the collector and the other pins is but it seems to be a little bit more than 1 mm. <S> Probably in a sealed housing with dry air that would just be sufficient (assuming anyone would use it near the maximum rating !). <S> BUT, the fact that the transistor can handle this voltage does not mean you HAVE to operate it up to that voltage. <S> If you operate it at for example 600 V then you would have a considerable margin before the transistor breaks down. <S> In some situations that could be nice to have. <A> High voltage primary considerations are clearance and creepage at the physical layer. <S> Clearance is the shortest path between the points of interest and the standard usually used is IPC-2221A.Creepage is the shortest electrical path on the PCBIf <S> either of these distances is less than found in the above reference then as you surmise, a compound with better insulating properties is required. <S> The above reference gives values for conformally coated and uncoated boards for surface layers. <S> There are a number of solutions to this issue. <S> This is a simple answer to your specific question. <S> High voltage has many more issues to be taken into account.
| Another possibility is to apply a conformal coating . Other considerations for medium or high voltage PCBs is the shape of the pads and traces - these must often be rounded, eliminating sharp corners where traces change direction and using rounded rectangle pads instead of sharp-cornered squares.
|
Understanding reference application of LM3404 I'm looking at LM3404 to drive a 10W LED (900mA, 9-12V) with PWM. The reference schematic they give is the following: I'm trying to de-structure the diagram, and I'm struggling with the purpose of L1 and D1. D1 is a 2A shottky diode, and due to its position I believe that it might act as protection should SW get shorted out? Why shottky and not zener? Speed? L1 is a 33uH inductor; coupled with CO1 seems like a low-pass LC filter? Would that make sense? <Q> The LM3404 is a switch mode current regulator, similar to a buck voltage regulator. <S> When the switch turns on the inductor is connected to Vin and the current in the inductor starts to ramp up. <S> That current flows through the LED and the current sense resistor. <S> When the current reaches the appropriate value the switch turns off and the inductor current starts to ramp down. <S> At that time the inductor current flows in the Schottky diode and through the LED. <S> The Schottky has a low voltage drop and therefore improves the efficiency. <S> The current sense resistor Rsns provides feedback so that the part can modify the duty cycle to maintain the programmed current. <A> The when the switch (a transistor- an N-channel MOSFET inside the chip) closes, the current rises through the inductor. <S> When it switches off, the Schottky diode conducts and the current drops. <S> By switching quickly, the current through the LED is almost constant and controlled. <S> Because it is a buck regulator, the input voltage must exceed the LED forward voltage by a bit. <S> The current through the LED is fed back as a voltage relative to ground across the Rsns resistor. <A> What you have there is a constant-current buck regulator. <S> SW energizes L1 when closed, and when SW is opened L1 empties through the LED, the sense resistor, and through D1.
| The LM3404 is a current buck regulator. The purpose of L1 is to store energy during each switching cycle and the purpose of D1 is to "catch" the inductor current when the switch is off.
|
Can this active-high scenario be achieved without an external pull down resistor If I understand correctly, few microcontrollers offer internal pull down resistors on their input pins but almost all allow for internal pull up resistors to be configured. Why exactly is that ? I understand that for a push button scenario, we can implement logic to interpet 0V = ON (button pressed) 5V or disconnected = OFF (button not pressed, internal pull up activated) But what if the input is coming from an external system that you cannot control where the following logic needs to be implemented external system is not connected (floating) on the input : should translate to OFF external system is providing 0V on the input : should translate to OFF external system is providing 5V on the input : should translate to ON In this case you need some kind of active-high setup, but for that the internal pull up gets in the way (as a floating value should not be considered HIGH). Wouldn't it be useful in such a case to have an internal pull down resistor on the input ? I could implement this by disabling the internal pull up and use an external pull down resistor by connecting the input to GND via the pulldown. But can this also be achieved in some way without using an external pull down ? <Q> Following controllers have pull-down resistors (not a complete list and <S> not every variant was looked at, so there might be exceptions): <S> STM32 family MSP430 <S> ATxmega <S> PIC24 has change notification pins with pull-downs PIC32 <S> NXP LPC800 ( <S> their smallest, so I'd say the bigger ones have it as well) ... <S> So I'd say there are a lot of options to get a controller with pull-down resistors integrated. <S> Only the very low end seems not to integrate pull-down resistors, which makes sense as they are very cost sensitive. <S> Oddly enough is that AVR chose not to integrate them into their UC3 series. <S> If you have absolutely no choice to switch over to a MCU with pull down resistors, then you could hook it up to an analog input pin and read the voltage with the ADC. <S> A floating pin should give you varying values, if it is grounded or pulled high the variance should decrease drastically and in theory the value should read a solid min or a solid max of the ADC. <S> I've not tried this in practice, but I guess you have to take multiple readings and it might not be 100% reliable. <S> If your controller has no ADC, then I'm out of my wits, I was thinking something like maybe set the pin to output low, then switch to input and read back the value. <S> But if the switch is providing 5V you will have a short, so that's a bad idea. <S> Maybe it could work when the switch is not a low resistance connection to 5V. <S> My idea behind it was to use the parasitic capacitance of the trace to store the low voltage for a short time before it starts to float at some level again and trigger the input high. <S> If the switch is connected you would read back a high. <S> But that is also quite a speculative approach and has to be tried out. <S> Still leaving a input pin floating is a bad idea in itself, so I'd say just go for that resistor or switch to one of the MCUs available with pull down resistors. <A> I am sure there will be a more complicated way of achieving this without an external pull down resistor, but a simple resistor would be sufficient in most cases. <S> The designers of the chips must make decisions on the benefits compared to the extra complexity of adding pull up/down resistors and their controlling circuity. <S> Pull ups will cover the majority of cases and where they don't, you can add your own pull down. <A> If you are asking how to detect an actual open circuit pin there is a way to do that, but you still need to add an extra resistor. <S> Toggle <S> the output pin high then low and read the value of the input pin each time. <S> If the input pin follows the high low signal then the input line is most likely open. <S> (Note that the resistor used here needs to be significantly higher then the expected impedance of the possible input signal.)
| On the pin that might have an open circuit place a high value resistor from that pin to another output pin.
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.