text
stringlengths
83
79.5k
H: Proper behavior for USB and +5V I have a batch of Sanguino 1.3a RepRap boards, with the following "bug" listed: The USB 5V VBUS is connected to the output of the 5V regulator. This is bad for the regulator and bad for the PC. Some users report the regulator getting very hot (because it is trying to power the PC), other users report the PC giving USB over current errors. Nophead recommends cutting the 5V track to the USB connector. The only downside is the board needs the 12V supply before it will do anything. We've seen this in several cases, the LED in the schematic will drop in brightness when USB is plugged in, and the voltage regulator gets really hot really fast. However, this behavior is intermittent, and I'm curious as to the cause, behavior, and how USB is expecting the +5V to behave. You can see in the schematic below in the FTDI/USB2TTL panel that USB 5V connects to the board's 5V bus, and the "Power from screw terminals and vreg" puts 5V straight onto the 5V bus without any kind of diodes. So, I can see where this is happening. Are most USB devices either powered exclusively by USB's +5V power, or they just reference ground and let 5V float? Full size schematic AI: how USB is expecting the +5V to behave According to the specs from usb.org, there can be a current from 0mA to 500mA on VBUS (+5V). Reverse currents are not allowed. Many of my older PC power units delivered only 4.9 Volt or even less on the 5 Volt lines. In that case the output voltage of the LM7805 will be higer and a reverse current flows into the PC. But this depends on the ATX power unit, and factors like temperature and CPU load (current). Are most USB devices either powered exclusively by USB's +5V power, or they just reference ground and let 5V float? Read the spec: Essentially these are the two choices you have.
H: Coin Cell Battery for Arduino/Microcontroller Excuse the lack of electrical engineering knowledge but I have an Arduino Uno microcontroller that I want to power with a coin cell battery. The project will have 6 LED lights that will flash for a few seconds every few hours. My question is, what sort of coin cell battery would I need for this project? Also, how would I connect it to arduino? With something like this? Would I require anything like resistors/transistors? Here is a diagram of what I have so far: . (Resistors are 1/4-watt 200ohm resistors) AI: The Arduino Uno isn't fit to run off a coin cell. The Uno isn't exactly low-power. It contains 2 microcontrollers running at high clock frequencies and consumes a couple tens of mA A coin cell will give you 3 V, while the Uno is designed to run on 5 V. Most important: a coin cell has enough energy to power the Arduino for a couple of hours, but can only supply this in small doses, i.e. a few mA. That won't work.
H: How to hack a body scale to be used as digital weight measure I am looking for help with hacking a typical digital (body) weighing scale to use in a custom application. Is there some internal digital or analog output in body scales to directly get the measured values? How might I go about reading this output? I thought about connecting the scale with an Arduino, Tinkerbot or Raspberry Pi for further processing, for instance to weigh other stuff and for home automation. I am not looking to build my own body scale from scratch, just adapt one to be able to extract the measured values. Body fat or similar nonsense (which cannot be measured reliably anyway) is not required. AI: Sounds not too difficult to do what you are proposing, most digital scales use 1, 2 or 4 strain gauges in a Wheatstone bridge configuration to form a load cell. This load cell will output a small differential signal which is read by an Instrumentation Amplifier (InAmp) to amplify and output a single ended signal that can be easily read by an ADC. So if you have a digital scale, it's just a question of hacking it and tapping this signal to be read by your PIC, Arduino, etc, to be used as you like (send to PC, display...) As far as I'm aware the R-Pi doesn't have analog inputs available as "standard", and it sounds like complete overkill for this anyway (unless you are using the R-Pi in place of a PC or something)
H: Analog Switch Breakdown voltage? I'm designing a select-able gain circuit using a multiplexer and an inverting amplifier. Here's an example circuit, using a multiplexer. I've read that if you provide a voltage larger than the supply voltage it can latch-up and/or damage the circuit due to too high of a voltage. My question is do these effects occur when the multiplexer is switched to off? For example, if the input voltage has an amplitude of Va = 40V, the multiplexer is supplied with a 5V source, and the third switch (10k ohm) is the only activated line? I'm trying to target voltage ranges from 50mV <= Va <= 40V with gains of 0.02 <= G <= 20 and the output voltage from the op-amp should be ~1Vpp or ~2Vpp (referenced to the virtual ground). The frequency response should be anywhere from DC to ~20MHz. If not, is there another way I can achieve this wide gain range (note: the value of R5 should be small since the circuit has to be able to handle high frequency signals)? I'd prefer to stick with only solid state components if possible. AI: Your circuit doesn't make much sense: for two of the inputs you use an amplifier as attenuator, for a third one a x1 amplifier. Only for the R4 position you use it as a x10 amplifier. Besides, why did you choose such low resistance values? For the 10 Ω most analog switches will have a significant on-resistance, even if they're as low as 1Ω: that's 10 %. If you scale all resistances up by a factor 100 you'll have the same attenuation/amplification. Analog switches with low on-resistances exist, but their inputs are limited to the power supply, and then 40 V is an issue. You say you want solid-state, but a relay may be the better performer, especially a reed relay. Low on-resistance of 150 - 200 mΩ, low off-capacitance, in the order of 1 pF, capable of switching high voltages and high frequencies. Then your configuration. I would replace R2 and R3 by a resistor divider with taps at :10 and :100. Your third relay (for :1) comes at the top of the divider, from where you also go to the x10 amplifier, whose output goes to the last relay. You'll want to protect the input of that amplifier against overvoltage with low-capacitance clamping diodes.
H: Correct pin naming of BGA and DIL chips Some ICs have their pins labelled only with numerical values and some use alphanumeric labels. I want to know what is the correct naming term for these cases. Is it ok to call all the chips with alphanumeric labels BGA (ball grid array)? And for chips with only numeric pin labels the chip should be called DIL (dual in line)? AI: Typically ICs with pins on the edges have numbered pins. That's DIL, but also QFP, DFN and even SOT23. You start at the pin 1 marker and follow the contour. IIRC PLCCs have their pin 1 in the middle of one of the sides, but normally pin 1 is one of the corners. You'll see alphanumeric pin IDs whenever you've got some kind of grid, where there could be confusion about which are rows and which are columns. Usual suspects are BGA, PGA, and variants like WSP (WaferScale Packaging), but also this one: One found this one recently, it's called a "Staggered Dual-row MicroLeadFrame® Package (MLF)". Like some BGAs where only the outer pins are used this one numbers the outer pins as "A*", and the next round as "B*".
H: Should I use pull up resistors in this configuration? I am interfacing a 3.3V FPGA to a 5V DSP. I am using this bidirectional voltage transceiver: http://www.nxp.com/documents/data_sheet/GTL2000.pdf In the diagram in page 4 they're using pull up resistors at the high voltage side and they state: The processor output can be totem pole or open drain (pull up resistors may be required) and the chipset output can be totem pole or open drain (pull up resistors are required to pull the Dn outputs to VCC). The DSP I'm using is TI TMS320C31 and will be interfaced to the FPGA Cyclone EP1C6Q240C8N. Should I use pull up resistors on one of the sides or both or I don't even need them? AI: For the outputs you configure as open-drain you'd need the pull-up. Not if you have push-pull outputs. Open-drain is typically used for wired-ORing outputs, you usually don't use them for a direct output-to-input connection. Push-pull outputs are faster because the low impedance allows for fast edges, while the asymmetrical output of an open-drain will give you slower positive edges. In the schematic of page 4 open-drains are used to allow different output voltages, depending on the voltage level the pull-up is connected to.
H: Reducing cost by eliminating microvias when designing a PCB with buried vias I'm designing a 4-layer PCB for a very small adapter from a BGA on one side to several discrete SMT connectors on the other. Due to space constraints, I cannot use through holes for some of the interior connections; they must be routed through blind vias. After some discussion with the PCB fab company I'm starting to understand a bit better why blind and buried vias cost so much money and how these complicated boards are constructed. I also appreciate that microvias add cost to the board. Is there any way to route a signal from one side of the board to the other without at least one set of microvias? My current design has three via styles: Layer 1-2 ----------+ +------+ +-------------------- | | | | ----------| |------+ +------+ +---------- | | | | ----------| |----------------| |---------- | | | | ----------+ +----------------+ +---------- Through Layer 2-4 So the trouble comes with having both blind vias terminating on the same layer from either side of the board. They can't drill those separately before the layers are laminated together, and so the top one must be bored out afterwards and filled in (at high precision and cost, as I understand it). But I need these signals the whole way through the board! Are there any tricks to working around this? Or are my design specs simply too challenging for my modest budget? AI: An alternate way to save space is to use via-in-pad. If you aren't doing that already, it might save you enough space you won't need one of your two blind via types. This was meant to be a flippant comment, since it technically answers the question, but doesn't really provide any new information. But the OP seems to think it's useful: Q: Is there any way to route a signal from one side of the board to the other without at least one set of microvias? A: Yes, use a through via.
H: How is oil-filled switchgear possible? I can't find any definitive description of how oil-filled switchgear uses the oil and manages to keep it from ignition and boiling. For example, the Wikipedia article says Oil circuit breakers rely upon vaporization of some of the oil to blast a jet of oil through the arc. which sounds rather strange. The arc will be very hot, so oil moving anywhere near the arc would likely be ignited or start boiling and neither is good for any equipment. How is oil used in oil-filled switchgear without igniting and boiling? AI: There are a few things you seem confused about. First, if you have a arc that generates a pocket of oil-vapor that is submerged in a pool of liquid oil, it can never ignite, as there is no oxygen there. With regard to quenching, basically the idea is to "stretch" the path of the arc until it breaks, and is as such quenched. There are actually high-power circuit breakers that specifically force a jet of air through the arc path when they open to quench the arc as rapidly as possible. Basically, the liquid is supposed to boil, as this provides a source of gas. Also, it's worth remembering that the phase-change from liquid to gas requires a lot of energy, and this helps absorb the heat generated from the arc. It is true that if a oil-immersed breaker cycles often, it will use up most of the oil, both through vaporization and carbonization, but the device should have sufficient oil to last for it's rated cycle-life.
H: Change in PLL settling time as a result of halving charge pump current/doubling loop filter capacitor I have a PLL that is operating unstably at some temperatures. I have been able to show that reducing the charge pump current from 128uA to 64uA ensures that the PLL will operate stably at the same temperature point where it would otherwise be unable to lock. Rather than have a software based solution I would like to achieve the same result (a locking PLL across my temperature range) by changing the loop filter components. ----+----+---- | | Cs --- --- Cp --- --- | | Rs \ | / | \ | | | ----+----+--- Please excuse the diagram, not access to imgur. Since halving the charge pump current was sufficient to stabilize my loop would doubling the loop filter capacitance Cp (shown above) provide the same result. Currently my component values are Cs = 3300pF, Rs = 6.81kOhm, and Cp = 33pF. $$ \Delta V_1 = \Delta V_2 = \Delta V, $$ $$ i_1 = 2i_2, $$ If the period of time where the charge pump is conducting (phase difference) is fixed then $$ Q_1=2Q_2, $$ $$ \Delta V = \Delta Q/C $$ As a result the doubling of the value of C with the same charge pump current is effectively the same as halving the charge pump current and leaving C fixed. I realize that this will change the loop filter bandwidth as well as impact the settling time. Is there a way of getting a rough estimate of how this will impact the settling time? I was hoping to get an answer as a delta from the existing implementation (e.g. the settling time will double.) What other impacts might such a change have to the PLL's behaviour? AI: Q Is there a way of getting a rough estimate of how this will impact the settling time? A Yes but Design handbooks or Application Notes help more than analyzers as non-linear mixer affects simple 2nd order control theory. I don't have any magic formula, but some others may have equations that fit a certain design. For example I found advice such as using Cs/Cp ratio of 10:1 good for Bode plot phase margin control once you find the best gain range. reducing phase margin of phase or increasing phase lag near unity loop-gain increases overshoot ( 0 margin = oscillator) Hence Cs/Cp ratio is useful for compensation to shift this operating point below 0 dB. Lower capture time from increased bandwidth but more phase noise. Lock time is also affected by SNR here gain of mixer is reduced with increasing noise. VCO temperature sensitivity of slope affects loop gain , which can be corrected. Capture range defined by F offset that can be acquired under worst-case and/or nominal conditions is affected by Loop gain sensitivity to temp. Capture range must be much less than worst case VCO error under all conditions to work. Total loop gain needs to be << 1 after 180 phase shift becuase when 180' shift & negative feedback (180deg) this becomes positive feedback and when close or < 1 unity gain it rings with too much overshoot, so lower gain at 180deg phase shift in the phase mixer filter is one key design criteria for minimizing overshoot. Design tradeoffs are lock-in time, over-shoot, phase noise, noise skirts, capture range, image rejection, aliasing jitter, harmonic spurious lock. Dual gain-bandwidth filters are desirable for fast lock-in time with low overshoot and then slow mode for noise rejection. SNR affects gain of channel as phase error signal becomes swamped by noise and results in lower gain of mixer. VCO can change gain with temperature, but can be compensated or stabilized with dual gain approach. Capture then lock on slow mode. Factors that affecting temperature stability of gain of loop are temperature sensitivity of VCO Hz/V per deg'C from parts such as varicap.
H: How can I tell if a particular multimeter measures AC with RMS or Average I require a multimeter measuring RMS but unfortunately know little on the subject and am unable to tell which method one uses from it's description. Its states: MAX. Voltage between terminals & earth ground: 700V AC rms or 1000V DC Fuse Protection: µA and mA: F 750mA / 250V Ø5x20; A: F 10A/250V Ø6.35 x 31.8 I appreciate it says rms in the above, however would like to ask for confirmation and also if possible help understating the other values it specifies. Full spec here Thanks AI: True RMS measurements is a property the manufacturer will be very proud about to share with you as customer. It is usually printed in bold on the meter itself. True RMS isn't printed on the meter in your example, so it won't be one. Also I own a more expensive brother of this meter and on that one it says 'True RMS' (in bold print). Third way to tell is from the specifications. Again the manufacturer will be proud to be able to share True RMS properties and I expect it listed high in the 'key features' and next to the 'ACV' and 'ACA' table headers. In conclusion: No this is not a True RMS meter.
H: Controlling an RGB LED color range from an analog temperature sensor (no Arduino, etc.) I'd like to combine an analog temperature sensor with an RGB LED so that I get a range of colors based on temperature. Low temperature blue, high temperature red, with color fade between them as the temperature changes. For sensors, perhaps something like http://adafruit.com/products/165 for the temperature sensor, and http://www.sparkfun.com/products/105 for the LED. It would be trivial to do this with an Arduino, but I'm trying to think of how to do this with some basic, low cost electronics - some way that I could make dozens of these and run them off something like a coin cell. I'd like to spread them around in an environment and get a "light map" of temperatures when viewed in the dark. I imagine doing something like this... Analog temperature sensor output from 0.0v - 1.0v translates into the blue channel input going from 3.0v to 0.0v (bright blue to dark), no output on temperature voltage > 1.0v Analog temperature sensor output from 0.75v - 1.75v translates into red channel from 0.0v to 3.0v (dark to bright red), no output on temperature voltage < 0.75v. The effect would be a bright blue light at the coldest temperature, that would eventually change to a bright red light at warmest. Any thoughts on how this could be done in a low-cost/simple way? AI: The simplest analog circuit I can come up with is this: V1 represents the temperature sensor output value. The values of R1 and R3 may need to be adjusted specially if you use other transistors (you can use variable resistors to find out the correct values then replace them with fixed value resistors). You may also need a voltage divider on the base terminal of Q1. This is the output signal analysis. This assumes you are using a common anode RGB LED.
H: Making a burglar alarm I am using a passive infrared sensor TMP006 to make a burglar alarm. However I notice that the data returned is not accurate enough. Are there any other ways by which I can improve my accuracy. Or should I use an ldr on which I shine a continous beam of IR light which breaks when the burglar steps in?What do commercial burglar alarms use to detect motion? AI: The TMP006 is a PIR, but a temperature sensor. This should be used in a situation where the temperature to be measured is equal over the full viewing angle. That would require the burglar to be very close to the sensor, something he might not want to. LDRs are no use either, they detect light levels. The common way to detect a person's presence is a PIR presence/motion detector. I've used the Panasonic NaPiOn for this, which at the time was the smallest existing PIR. It has a matrix of detection zones, which, combined with the multi-faceted lens will detect even slight movements at meters distance. Use is easy. It has three pins: ground, Vcc, and output. The output goes high if the sensor detects a person moving in its detection field. Further reading: NaPiOn design manual
H: Do two stage common emitter current amplifiers add or multiply? So I've seen alot of explanations on two stage voltage amplifiers and how how their gains can be multiplied together. My question is when you are using a two stage common emitter amplifier for current amplification, does the current gain from each stage multiply together or add together? I am thinking they add together because if their base, emitter, and collector are tied together, their currents must add together to form a linear relation with voltage and power. Could someone verify this? AI: If you mean something like below, then the currents add: As Alfred mentions, this is not known as a "two stage CE amplifier" though. With BJTs, the emitter resistors are needed to prevent thermal runaway. This is caused by the fact that as a BJT gets hotter it passes more current. The emitter resistor provides some negative feedback (higher current = more voltage across resistor = lower Vbe to stop runaway) but wastes power. FETs don't have this problem and can be connected directly, so are better for parallel operation.
H: how these circuits work? I have 2 shematics of circuits in order to drive a LED I want to know how exactly these circuits work and what is the reason of using each components and why we need a dc-dc converter Tnx very much the link of the image is http://www.infineon.com/dgdl/LED+Driving+Concepts+and+Infineon+Basic+LED+Drivers_V1.1.pdf?folderId=db3a304314dca389011561889ef01fe7&fileId=db3a30432f91014f012f96084ec339a3 AI: What you have in the first schematic is a buck-converter. This is a special kind of switched-mode power supply, intended to regulate a higher voltage to a lower one. But instead of regulating a constant output voltage, it is using the resistor Rsense to regulate a constant current (when the voltage across Rsense is constant, so is the current through it). This ensures that the current through the LEDs is always the same, regardless of possible losses in the cables, or changing input voltage. The second circuit is nearly the same, but uses a separate constant-current regulator after the buck converter. So the converter operates in constant voltage mode, and the separate regulator is responsible for creating a constant current flow. Using a switching regulator, instead of a linear one, leads to reduced power losses, and reduces the created heat.
H: Set top boxes - database of ‘tv programme/channel’ I am currently researching the construction and functionality of set top boxes for services such as Sky + and Freeview. I need to understand if and how a database structure would be used in terms of the operation of such hardware. As these devices are accessing libraries of ‘tv programme/channel’ data I can only imagine that a database must form part of the set up, not least to query to achieve an on screen result. I cannot find anything in these box technical specification to suggest that though. I have found out a little about IMDs, In-memory databases but I don’t really understanding the workings of these - can anyone help? AI: Sky and Freeview adhere to the DVB standard. You want to read ETSI EN 300 468 and learn about decoding SI tables to construct an EPG.
H: Multiplexing, Animation, Bitmap coding on MCU. How to do it right? I have been recently getting into programming and micro controllers. I found myself that i don't really know how to do multiplexing, animation, easily displaying pictures on LED display. I have been looking for some code examples, but most of the articles I found, where about the hardware and the software was not even mentioned, the code examples are usually poorly commented and on a platform i don't know (I'm using TI MSP430 MCUs) and the operating theory of the software is never explained. I'm assuming this is because a lot of MCU beginner come from a software background, and they need more explanation on the hardware. My question is: How to implement Multiplexing, animation,bitmaps nicely. How should it be done? What is the theory of the software for these applications? Any comments, link to articles, book, etc... are very much appreciated. Also I have to stress that I have done it, and it's working, but i think my codes for it looks horrible, it would be impossible to manage in a larger program and there should be a better way to do it. But anyway here are two videos of multiplexing projects: http://www.youtube.com/user/undeadtreat/videos AI: This is a bit difficult to explain, since the way you'll do multiplexing depends on the type of the display and the type of the display depends on the type of the multiplexing you want and it gets complicated quickly. I'll explain how I did multiplexing for a project where I used 5x7 LED displays.It will be similar for other displays which are 8x8 or smaller and bigger displays can be made by combining 8x8 segments or using several multiplexers, but I'll explain a bit more later. So first let's start with the display itself and the LED. This is a common row anode display. The LED comes from light emitting diode, and as any diode, it has two terminals: The anode and the cathode and using the conventional current direction, current can only go through the diode in the direction of the symbol's arrow. As you can see, this screen is basically a matrix and you'll need to control both rows and columns. With this display the current needs to be sourced from the rows and sinked from the columns. With some microcontrollers you may be able to connect all rows and columns to its pins using resistors on rows or on columns and directly set some of them to high and others to low and sink and source current that way. The MSP430 series usually can't do that because they usually can provide very little current and work at low voltage. Also you'd need to dedicate whole microcontroller to a single display, so it gets expensive quickly. Here we come to the multiplexing part: Human eyes can't quickly detect LEDs turning on and off, so we can turn some of them off and have others be on and if we do it quickly enough, it won't be noticeable. There are circuits such as multiplexers, demultiplexers, shift register, counters, current sources and sinks and others which can be useful here. The basic idea is to control as much LEDs with as little microcontroller pins as possible and to have a separate source of current from the LEDs which won't rely on the logic circuits. This is important because the logic ICs can usually provide very little current and may be able to turn on few LEDs, while the screen has many LEDs. So basically we need to have current source (here for rows) and current sink (here for columns) which will be controlled using the logic ICs which are in turn controlled by the microcontroller. IF the current sources don't limit the current, we'll also need resistors for that. Now onto practical implementation: From the point of view of a single diode, we want to have this. Top switch controls the rows and the bottom switch controls the columns and the switches will be implemented by logic ICs. One thing that should be noted is that it's best to avoid driving a large (or any) number of LEDs directly from logic ICs. They can't source much current and LEDs usually require large amounts of it so that they are as bright as possible. I myself here used a combination of PNP transistors driven by 74HC138 "3 to 8 line decoder". The device is basically same as demultiplexer, but there is no data input, just the address input, and the output is inverted. I connected the outputs to PNP transistors, as shown in the simulation. When the output is inactive, it gives high voltage, which prevents the transistor from conducting and turns the row off and then the output is in active state, the it gives low voltage which makes the transistor conduct. You select the output using the 3 address pins to give the binary number you want. There are even a current source ICs that will replace the individual transistors and that may have non-inverted input, but I can't recommend any, since I didn't get to work with them much. This number can be decreased to 2 pins if you use a 595 series shift register (but I found that option to be less flexible). The register has basically 3 inputs: SER, RCLK and SRCLK, but if you short together RCLK and SRCLK, the SRCLK will be one pulse ahead of RCLK. SRCLK is used to store the data into the register and RCLK is used to shift data. So you feed the data using SER and then send a pulse out to SRCLK and RCLK and they will store the data and shift all bits by one place. Note that you'll need one extra shift at the end so that all bits are in their place. You can use this to output a series on 1s and then send a 0 which will in turn trigger each row of the screen. Why I found this less flexible, I'll explain later. Now for the columns: As I wrote, in this type of screen, the current needs to exit at the columns, so we need a current sink to do the job. A sink can be made using a number of NPN transistors, as shown in the simulation. Each will allow the current to flow through the LED and the LED will shine. For this task, you can also use current sink ICs such as ULN2803A. STmicro makes them in DIP package, if you want to experiment on a breadboard. The ULN2803A already has biasing resistors for the transistors matched for 5 V operation. This is higher than what you'll have with MSP430, bit I'll explain a bit more later on. Now why I found that using 595s as row selectors using 2 pins isn't as nice: If you want to drive multiple screens, you could do that by having a separate column control for each screen and a single row control for all screen (or share row control among several screens). When you're loading the 595s with data using two control lines, it will output wrong data until you're finished with data transfer. So in my setup, I used a 74HC138 and the fact that I have a 7 row screen. The 138 will set the screen to 8th non-existing row (and by doing that, disable it) while the 74HC595s are loading their data. After the data is transferred, the 138 will select the correct row and display the image. Also as a side-note: If you want to run several screens and use 595s, you can use single clock line for all of them and this way save MCU pins. Next, for the actual data storage: You'll need to store the image inside the microcontroller in a way that will waste the least amount of memory, since microcontrollers in general have little memory. The way I used (and I assume that there are better ways than this), is to make a matrix whose dimensions are the same as screen dimensions. So in my case, that would be 7x5 matrix. The type of data should be one of the integer types and will depend on the number of screens. With chars, up to 8 screens can be stored in a single matrix for example. The idea is that rows of the matrix represent rows of the screen and columns of the matrix represent columns of the screen. So you simply set the fields you want to be on to one. Make a program that will read column data for each row of the matrix, send data to 595s and then turn that row on on the screen. This may look a bit wasteful since we're using an entire matrix for single bits and that's where the common scenario of controlling multiple screens comes up. Since the matrix will at least be a matrix of chars, which are 8 bits long usually, and we set bits to 1 for the LEDs that should be on, we can store one screen and then using bitwise operations, shift entire matrix to the left one place and then store another screen of data. The procedure can be repeated a number of times until we have data for 8 screens. Since MSP430 is 16 bit, it should work fast with 16bit integers too, so we could easily control up to 16 screens this way. For larger data types, the operations are going to be a bit slower and sometimes that can be too slow. Next few words about refresh rate: You can display the animations on screen by having one "process" display the data (say a timer based interrupt) and another to change the data (say in the main while loop). The timer based interrupt should make sure that each row is turned on many times every second so that the image appears smooth. The number often found on the Internet is at least 60 times a second, but numbers greater than this make the screen easier to read. Finally, a bit about logic level conversion: MSP430 should run at up to 3.7 V and 4.2 V is the maximum voltage it can be exposed to. This leaves us a small problem: The usual nominal voltage for logic ICs is 5 V and the MSP430 can't run at that voltage. The good news here is that 595s can run as low as 2 V, so you can simply set the voltage to 3.7 V and run everything from it. Sometimes, this can be too low, so usually it's a good idea to get a logic level converter. There are complete logic level converters such as this one from Sparkfun. The schematic isn't too complicated either and can be made at home too. And now for a little bit extra information if the screen seems too dark: LEDs and LED screens usually in addition to maximum average current have maximum pulse current rating too. It can be used to make the screen appear brighter than it is. Usually after each pulse, a rest period is required and that will be indicated in the datasheet. For example for the screen I used we have this: So if we pick time period of such length that the average current is below 25 mA and average power dissipated at the screen is below 60 mW, we can have instantaneous current of up to 80 mA. Example of code I used for row number 1: if (1 == interrupt_counter)//The interrupt counter is incremented using {//interrupt counter++; //interrupt counter = interrupt counter % 7; A0=1;//multiplexer address bits A1=1; A2=1; empty_pulse();//sends out a pulse with no data empty_pulse();//since the register is 8 bit empty_pulse();//and I'm only using 5 bits //so this macro writes a zero to the register //and sends a clock pulse for (p1=0;p1<5;p1++) { data5=(screen_output[1][p1]>>1)%2;//data for screen number 5 data4=(screen_output[1][p1]>>2)%2;//data for screen number 4 data3=(screen_output[1][p1]>>3)%2;//the hard coded 1 data2=(screen_output[1][p1]>>4)%2;//is row number and data1=(screen_output[1][p1]>>5)%2;//p1 is column number pulse();//only a clock pulse is sent } pulse();//one more pulse is needed, to make sure that the late clock //is at correct place A0=1;//multiplexer is now set to output 1 A1=0; A2=0; }
H: How does audio get transmitted from my iPod to speakers? I need some help understanding a simple concept. I understand that my iPod/any other audio device sends electrical signals to my speakers/headphones. From my research so far, an analog signal is sent. Now what I need help understanding is that what is the analog component of the signal? In other words, is it the current that is varied and the voltage remains the same, or the other way around? I haven't found a definite answer, but it seems to me that the current is what fluctuates, and voltage remains constant. Under that assumption, would that mean that resistance also fluctuates as a direct result to balance the equation V=IR? Sincerest thanks :) AI: Audio signals are usually intended to be voltage mode. In other words, the ideal source for a audio signal has 0 Ohms, which means its voltage doesn't vary regardless of what the load does. Of course 0 Ohms is not possible in reality, but there are various levels of close enough. Power amplifiers designed to drive speakers have very low output impedance. Speakers are usually rated at 8 Ω, so audio power amps have output impedance a fraction of that. This is done by feedback internal to the audio amp. The feedback adjusts what the final output stage does so that the voltage immediately leaving the amp is what it's supposed to be, largely not effected by the current the speaker draws. Again, 0 Ω is not possible, but good audio power amps have output impedance less than 1 Ω. It's not worth going less than a 100 mΩ or so since the wires between the amp and the speaker will add more than that. Speakers are designed so that the sound output relfects the applied voltage, not the current they draw from that voltage. Another way of looking at this is that the speaker impedance is not a flat 8 Ω accross the frequency range, and it's not purely resistive either. If it were a purely resistive flat 8 Ω, then it wouldn't matter whether you drive it with a voltage or current signal since the two would always be proportional to each other. However, it's not a flat 8 Ω, so voltage and current aren't the same. The industry has converged on using voltage as the true audio signal, with current being whatever it ends up at roughly 8 Ω but with significant variation accross the frequency range and some reactive component. If you were to drive such a speaker with a current signal, you would get more distortion and poorer frequency response than with a voltage signal.
H: PCB part naming for LEDs Usually when I design a PCB, I name the LEDs as LED1, LED2, ... , but now I'm working on a set of boards where I do not have much space for the component names on the silkscreen. The boards are divided in four functional blocks. In order to be able to better identify which parts belongs to which functional block, I'm naming R101, R102, ..., for functional block 1, R201, R202, ..., for functional block 2, and so on. The problem is that it generates very large names for LEDs, LED101, LED102, ... So in order to solve this problem I replaced LED101 with D101. It was ok, since at the time, I didn't had diodes on the board, but now I need to use diodes and I want to easily distinguish which components are LEDs and which are diodes, but I don't have space to have LED101 on the silkscreen. Is there any convention for one letter prefix to use for LEDs that is different for diodes? AI: added IEC allows Stainless steel screen printing down to 1mm (but I know where you can get legible screen and printing at 0.5mm Q Is there any convention for one letter prefix to use for LEDs that is different for diodes? A Yes. DS for Display lampS (LEDs) and CR for current rectifiers (diodes) I wonder if any international standards committee members who stay awake at night solving these issues are wondering, why don't they teach standards in Engineering at University? IPC-2581 for Commercial Reference Designations Light Emitting Diodes< REFDES = Reference Designation ANSI/IEEE >>>> DS (preferred) IEC >>>>>>>>>>> E (preferred in EU) Other>>>>>>>>>> LED,DIS,CR,D I have always used DS for LED's since my military training days after university in Aerospace R&D according to Mil-Std Hdbk and my draftsman. Standards permit universal schematic interpretation in any language.. It has worked for me. I can read any Japanese or Chinese or Russian schematic instantly. Added .. "In 2005 IPC and IEC (International Electrotechnical Commission) established a joint standard for land pattern geometries (IPC-7351/IEC 61188-5-1) Table 1 contains list of the standard reference designators from the IPC-2612 standard for schematic symbol generation. Table 1: Standard Reference Designators for Schematic Symbols *These class letters would not appear in a parts list as they are part of a PCB and not an active electronic component. **Not a class letter, but commonly used to designate test points for maintenance purposes. Note: The above list is not exhaustive. See the standard list of class designation letters in ANSI Y32.2/IEEE Std 315, Section 22 and the Index." If you can get IEC 60617 series that would be a plus which are a subset of the symbols in IEEE 315 marked with IEC
H: Price History of FPGA My goal is to extrapolate (or estimate) the future prices of FPGAs and/or ASICs. Does anyone know of the price history of FPGAs or ASICs? I am looking for a source of information. I know that today FPGA's can be categorized into three basic categories (High end, mid range, and low end FPGA). I'm much more interested in the High end product range, but any information is helpful. Are there any academic or business journals that study the prices of FPGA or ASICs? Any input on this topic is welcomed. Thanks. AI: You can use octopart for that. Look for a component, and if you found one with an authorized distributor, on the detail page you get a history chart. Look for example at the XC9572XL history. More information is in the octopart blog.
H: Which schematic is better for keypad connection to an MCU? I have this three keypad connection sketches, all of which i've seen in various application, and some i've also used, but i want to know if there is any advantage of one over the other. The keypad will be connected directly to DIO pins of a PIC microcontroller, PIN 1,2,3 as OUTPUTS, and PIN A,B,C,D as inputs. The keypad will not be on board, but will be connected via cables to the PCB board, i don't know if this makes any difference. AI: Number 1 can be destructive for your controller. If you would use push-pull outputs for the columns, and the rows as inputs, then pressing two keys on the same row will short circuit the power supply through the microcontroller's outputs. If the microcontroller's outputs can be configured as open-drain, then there's no problem, but the outputs must have pull-up resistors as well. Then you basically have number 2, but with the pull-ups integrated. Number 2. Same story if you would use the rows as outputs. Using the columns as outputs makes more sense, since R1-R3 avoid a short-circuit of the outputs. Note that a low output level will see the series/pull-up resistor as a voltage divider, so that the input will be 0.1 Vcc, though that's usually not a problem. Number 3 avoids the divider, but the resistors on the inputs don't serve any function. A variant without the series resistor will do. So 1) may be an absolute no-no. 3) is a bit better than 2) because it doesn't have the voltage divider, but can do without the series resistor.
H: Basic wattage and volt conversion when using solar panel I have a basic electronic question or two I need to ask. I want to use a solar panel which delivers 5.2W and is rated for "8V open voltage and 650mA short circuit". If I connect a 5V voltage regulator to lower the volts to 5V, would the amps go up to be 1A after the regulator? (W = V * A) Another thing I'd like to know is, if I regulate the voltage to 5V and get approximately 1A out of it. How would using different components together work? I.e. I am using an arduino with a servo and a GPS unit and an XBee connected. Would these individual components' amp-usage just be added up (lets say to 850mA) and then the "extra" 150mA would just not be used? AI: I want to use a solar panel which delivers 5.2W and is rated for "8V open voltage and 650mA short circuit". If I connect a 5V voltage regulator to lower the volts to 5V, would the amps go up to be 1A after the regulator? (W = V * A) The percentages used below are "out of my head" based on experience with PV panels. Your panel may vary somewhat from my assumptions. Depending on technology used the ratio of Vmax_power to Voc will vary but using 0.8 is a good first guess. So V_max_power ~= 8V x 0.8 = 6.4V. Imax_power will be somewhat less than Isc - probably about 90% or better, so Imax_power ~= 650 mA x 90% = 585 MA -> say 600 mA. So actual max power in bright light will be V x I = ABOUT 6.4V x 600 mA = 3840 mW. Say about 3.8W. This will be at about 6.4V so to run with best efficiency you want to convert it to 5V with a switching regulator. A switching regulator will be typically 80% to 90% efficient if you use a good one - and rather less with lower quality designs. 3.8W x 90% =~ 3.4W 3.8W x 80% =~ 3W 3.8W x 70% =~ 2.6W If output is at 5V then Iout = Pout/Vout = 680 mA at 90% conversion efficiency 600 mA at 80% 520 mA at 70% Building a buck converter with an MC34063 will produce an OK result but efficiency will be lower than cxan be achieved with modern IC. An IC with synchronous rectification is required to maximise efficincy. The Richtek RC8286 looks ideal Datasheet here
H: Does higher dBi mean further range, for an antenna? I recently purchased this (ridiculously expensive) Bluetooth module for my Arduino from SparkFun. On the item's page it says that it has been tested at 100 m. I contacted SparkFun for info about their setup and they said to achieve the 100 m range they used this 2.2 dBi antenna. I presume any (2.4GHz) 2.2 dBi antenna will yield similar, 100m, results: is that correct? However, I have this 7 dBi antenna on it's way. If I use that will I be able to get further range than from the 2.2 dBi antenna? AI: Yes, you will get more signal strength from a 7 dBI antenna than a 2.2dBI (specifically 4.8 dB). It solves that by radiating energy more directionally than an idea antenna that radiates evenly in all directions (0 dBI). This increased signal strength of 4.8 dB is 10^(4.8/10) = 3 times more power. That will increase your range by about 70% in ideal conditions. Since it is directional, you will need to point it more carefully. Specifically the linked antenna is pretty much a vertical wire. It radiates in a circle around the antenna; your receiver shouldn't be much above or below this plane.
H: Solving input noise I built a very simple circuit so I could use my Bose headphones in the noisy server room without wasting batteries. I however feel silly that I did not know how noisy USB power was, thus the V(L) power is to noisy for the headphones to function properly. I'm pretty sure I just need an inductor on the input right? Is that all? If that is indeed all I need I was wondering if someone could provide me with a proper design example with the idea of approaching input noise in general as it was something I never really learned how to tackle. AI: Much depends what the frequency band of your noise is. For HF noise you'll often use ferrite beads. For instance the Murata BLM18PG221SN1 has a DC resistance of only 100 mΩ but a 220 Ω impedance at 100 MHz. If you can hear the noise it won't be 100 MHz, unless it's the result of mixing with a frequency in that range, so that difference frequencies occur. Let's assume that it's in the audio band, up to 20 kHz. You'll want to filter it out. The capacitor is one way, and you can improve on it by placing a 10 nF parallel to each of them. But capacitors by themselves are poor filters. They just form a load to the power line, what you need is a second impedance which will divide the noise in combination with the capacitor. One possibility is a series resistor. That gives you a first order low pass filter with a 20 dB/decade roll-off. This means that above the cutoff frequency the noise will be lowered to 1/10th for each x10 in frequency. It's a start. How low must the cutoff frequency be? As low as possible, then higher frequencies will be more attenuated. For instance for 1 Hz you have \$ RC = \dfrac{1}{2 \pi f_C} = 0.159 s \$ At a 1000 µF capacitor that would be a 159 Ω resistor. That's a high value, even for the 3 mA it would cause a 480 mV drop . A bit too much maybe. moving our cutoff frequency to 10 Hz would decrease that value to 15.9 Ω. The 1000 µF capacitor will again need some company from 1 µF and 100 nF nephews. What will this gain us? 1 kHz noise will be attenuated by 40 dB, or 100 times. That's the blue curve. By cascading RC filters you can increase the roll-off. The purple curve has a roll-off of 40 dB/decade. You won't get this characteristic with the sharp cutoff point with passive filters, though. This is the characteristic of an active second-order Butterworth filter. The passive filter will also have attenuation at 10 Hz, but in our case there's no harm in that. Other filters are pi-filters with two capacitors and an inductor, but at frequencies as low as 1 of 10 Hz the inductor will be impractically large.
H: What does frequency foldback do in a switching regulator? I'm looking into using the LT3759. One of the features that they advertise is frequency foldback. Frequency Foldback When VOUT is very low during start-up or a short-circuit fault on the output, the switching regulator must operate at low duty cycles to maintain the power switch current within the current limit range, since the inductor current decay rate is very low during switch off time. The minimum on-time limitation may prevent the switcher from attaining a sufficiently low duty cycle at the programmed switching frequency. So, the switch current will keep increasing through each switch cycle, exceeding the programmed current limit. To prevent the switch peak currents from exceeding the programmed value, the LT3759 contains a frequency foldback function to reduce the switching frequency when the FBX voltage is low (see the Normalized Switching Frequency vs FBX graph in the Typical Performance Characteristics section). Some frequency foldback waveforms are shown in the Typical Applications section. The frequency foldback function prevents IL from exceeding the programmed limits because of the minimum on-time. For the following example application circuit that they include, they provide a plot of the frequency foldback waveforms. This seems different from foldback short circuit protection. But how does frequency foldback work? What would be a good analogy to its process? What would the plot look like without frequency foldback? I also haven't noticed a frequency foldback feature in other switching regulator datasheets, so how important is this feature? AI: Frequency foldback as shown above is simply reducing the switching frequency. If the switcher is running at the minimum ON time but the inductor current is still rising (the inductor will actually discharge more slowly if there is a heavy load), then the only option left is to reduce the frequency. You can see on the waveforms when the output voltage drops to 0V, the switching waveform (Vsw) reduces it's frequency. Also note the discharge slope of the inductor is more shallow (bottom waveform)
H: Relay current question For the 16 CH 12V Relay module, does the output currency mean that we could run 5VDC, 12VDC or 24VDC through the relay? What ever current we input will be the output current, correct? AI: 1) Yes, the relays installed on the module are rated at 30VDC, 10A; so you can use it to drive anything below that range (that means 5VDC, 12VDC, 24VDC are ok. Make sure the current are below 10A though). 2) Yes, relay works like a physical switch; once connected, the current flows. The rated contact resistance of the relay is 100mOhm.
H: Specific color sensing, is it possible in an economical way, without using camera/image recognition? While I understand that color sensing with camera and sufficiently powered processor running image histogram logic (or other such algorithms) can determine presence of certain colours fairly reliably. However, are there other, significantly more cost-effective mechanisms to determine presence/absence of certain color (or it's close shades), at close range, using simpler/cheaper sensors and lower computational requirements ? I am guessing that things like pH sensors, or other chemical sensors might use such methods. In my case, the application is such that I need to detect presence/absence of a specific colour (a shade of light blue), in a small area, at close range. Edited: By 'close range' I mean something between 1-5cms, though this isn't a very strict requirement. I was thinking of "close" relatively, i.e. there is no direct irradiation from light source to sensor, kind-of a double barrel, such that only reflected light hits the sensor. So closeness is a function of physical sensor placement, and I am open to suggestions (including completely alternative / orthogonal approaches). AI: Since LEDs used as photodiodes are most sensitive to the colour they emit during normal operation, a basic colour sensor can be made using the LED in reverse and an opamp: The circuit above came from this page. It can also be done the other way round - a much more detailed look at colour sensing using LEDs and light sensors is available here - this page details using a normal light sensor and different colour LEDs. I couldn't find the app note mentioned in the comments, but this page seems to be quite a thorough treatment of the subject of transimpedance amplifiers. You can alter the bias across the LED to change response time/sensitivity.
H: Magnetic door lock I'm looking at buying an AEM10010 magnetic door lock (see page 4 of datasheet), but can't figure out how they're driven. The datasheet doesn't say anything about how to connect them, nor does it provide any in-depth technical specs. I can only assume they have two wires, one for ground and one for +ve, and I just hook them up to a 12V or 24V DC supply. Is this correct? AI: As far as I can tell from the datasheet they are simply elecktromagnets, you hook 'm up to their specified DC voltage and they will hold. Remove the voltage, and they will release their hold. No latching or moving parts.
H: Calculating parallel resistance of a rated bulb I have a bulb rated 110 V, 60 W and is in series with another bulb which is 110 V, 110 W. It's being powered with a 220 V source. Now, what would be the resistance of the resistor to be added in parallel to the first bulb so that each bulb will get the rated power? The way I approached this is first get the resistance of each bulb, then get the voltage drop of each bulb via current divider principle. After that, I'm stuck. AI: As Steven states, this is only true when the bulbs act like ordinary resistors. The solution is easy. The voltage across the 'divider' will be evenly distributed when power at the top half and power at the bottom half are equal. Power at the top half is 60W. Power at the lower half is 110W. To have equal power both at top and at bottom halves, you have to add an extra \$110W - 60W = 50W\$ in parallel to the existing top bulb. Ohms law: \$R = \dfrac{U}{I}\$ and \$I = \dfrac{P}{U}\$ Substituting the second equation into the first, gives us the familiar: \$R = \dfrac{U^2}{P}\$ Now fill in the details: \$R = \dfrac{U^2}{P} = \dfrac{(110 V)^2}{50W} = 242 \Omega\$
H: Selecting a MOSFET for driving load from logic I'm looking to drive a magnetic door lock from an Arduino. I've found a question about driving a solenoid from an Arduino, which includes a circuit that looks perfect for this kind of situtation: What I don't understand is how to select a MOSFET for the job. What properties should I look for, if I know my logic level, device voltage and device current? In this case it's 5V logic, and the load runs at 12V / 500mA, but it'd be nice to know the general rule. AI: You've got a luxury problem: there are thousands of FETs suitable for your job. 1) the logic level. You have 5 V, and probably less than 200 mV or so when off. What you need is \$V_{GS(th)}\$, that's the gate's threshold voltage, at which the FET starts conducting. It's given for a specific current, which you want to keep an eye on too, because it may be different for different FETs. Useful for you could be maximum 3 V @ 250 µA, like for the FDC855N. At 200 mV (or lower) you'll have a leakage current much lower than that. 2) Maximum \$I_D\$ continuous. 6.1 A. OK. 3) the \$I_D / V_{DS}\$ graph: This one's again for the FDC855N. It shows the current the FET will sink at a given gate voltage. You can see that it's 8 A for a 3.5 V gate voltage, so that's OK for your application. 4) \$R_{DS(ON)}\$. The on-resistance determines the power dissipation. For the FDC855N it's maximum 36 mΩ at 4.5 V gate voltage, at 5 V it will be a little less. At 500 mA that will cause a 9 mW dissipation. That's more than good enough. You can find FETs with better figures, but there's really no need to pay the extra price for them. 5) \$V_{DS}\$. The maximum drain-source voltage. 30 V for the FDC855N, so for your 12 V application OK. 6) package. You may want a PTH package or SMT. The FDC885N comes in a very small SuperSOT-6 package, which is OK, given the low power dissipation. So the FDC855N will do nicely. If you want you can have a look at Digikey's offering. They have excellent selection tools, and now you know the parameters to look out for.
H: Does this photodiode circuit work? Oli used this circuit in an answer, and it pops up a lot on Google images too. But does it work? If it does a theoretical explanation will be welcome. AI: According to this, the photodiode does indeed produce a current even when there is zero volts across it; it's the short circuit current. Note that the reference direction of \$I_S\$ in the question's diagram is opposite that of the \$I_{SC}\$ of the diode so the output voltage is: \$V_{OUT} = - I_S \cdot R_F = I_{SC} \cdot R_F\$ I found the above here. A reasonable question to ask is how can a current be produced with zero voltage? Remember that there's an internal E field through the depletion region even when the diode terminals are shorted together. Briefly, light generated EHPs in the vicinity of the depletion region are separated by the E field resulting in charge accumulating in the P and N sides (that's how \$V_{OC}\$ is developed). A short circuit allows a current to restore charge balance.
H: What is the definition of "cathode"? According to Wikipedia's definition, a cathode is "an electrode through which electric current flows out of a polarized electrical device". However, the direction of current flow is purely an arbitrary convention, and is in fact the opposite direction to which electrons flow in a metal conductor. Hence, this definition seems to be a bit lacking. If the definition is referring to the current carriers, then the definition might be rephrased as "cathode is an electrode through which the charged current carriers flow out" (or "in"?). How would you define this term clearly and unambiguously? Does the common use of the term "cathode" really reverse when the current carrier is positive, as suggested in the article? Edit: What actually confuses me is the phrase "Cathode polarity is not always negative". If electrons always flow into the cathode (by way of definition of cathode), this statement implies that the cathode can be at a positive voltage relative to the anode. Can this happen in a "simple" conductor like an electrolyte, or does this require some special circuit? AI: Wiki has it right, the cathode is the terminal of a component where the charge flows out. Charge flow (current) is the "standard" definition (i.e. Franklin's one from positive to negative, the opposite of electron flow). The cathode of a component can change depending on it's state - for instance when a battery is discharging, the cathode is its positive terminal, and when charging its negative terminal (since the charge is now flowing into the positive terminal, rather than out, and out of the negative one, so they are reversed)
H: Help finding appropriate AVR device I am working on a student project and need to find AVR microcontroller that will suit all project requirements. Here's a simple list: serial communication (UART), at least two ADC channels, PDIP package (for easy soldering, I do not have access to expensive equipment nor do I have skills to perform small-scale soldering), four I/O ports (excluding UART connections). I searched on Atmel's website and was stunned when I realised that no device exists that can support these simple requirements. Here are two devices I considered: ATtiny2313 (does not have ADC) ATtiny44 (does not support UART) I hope that someone will be able to point me to the right device, as I failed to find one to match the requirements. Any recommendations will be much appreciated. EDIT: I've noticed that the device selection tool on Atmel's website is not much reliable, at least not in my case. If you list all 8-bit microcontrollers, remove all filters and filter by number of ADC channels (select at least one) and number of UARTs (select at least one), no device in a PDIP package (according to the selection in Packages filter) will be available. You can see the results here. AI: Digikey has excellent selection tools for its components. You can select on package, manufacturer, ADC, and other features. (Odd that memory size doen't seem to be important.) I found 143 parts matching your requirements. The ATmega48P is 1.76 dollar in 1s and has 4 kB of Flash. The ATmega88P and ATmega168P are the same, but with 8 kB and 16 kB Flash, resp (same datasheet).
H: Diagram validatation for two motors connected with On-Off-On Switch I want to connect two motors on an On-Off-On switch. On position 1, I want motor 1 to me active, on position 2, I want motor 1 and 2 active. Here is the diagram I was thinking of implementing My second question, if this work, what kind of Diode should I be buying? on the circuit lab I've just used the basic diodes. My motors are 12V 25W water pumps AI: Jippie's answer (put as a comment) is largely correct. Current = Power/Volts = 25/12 ~= 2A. Substantially more current flows at startup and the diode must handle this. Diode D2 is not needed to achieve your functionality (just replace it with a wire, as he says). Using D2 may be useful to provide both motors with the same voltage (as both then have 12V - 1 x diode_drop but you will probably not notice the voltage drop across the motor when the pump is pumping. Many diodes will meet your need. Using Digikey's parametric selection guide I specified a diode of at least 5A rating and 40V reverse rating (safety margins never hurt) and asked for the cheapest silicon diode in a leaded package. Surprisingly it was [this 600V 5A BY500] (http://www.vishay.com/docs/88544/by500.pdf) This is far more capable than needed but cheapest is cheapest :-). About 53 cents/1 at Digikey. (I tried specifying a >= 2.5A and >=20V part and the above was STILL cheapest :-) ). You can actually get a Schottky diode for less, and these are in fact superior technically BUT are more easily killed when playing so specifying a standard Silicon diode is safer here. Be sure to be sure that the switch will handle the 12V inductive load of the motor.
H: query about the RAM IC in this picture Have this ZOOM recorder and it came with 150V power adapter. It got accidently plugged to a 250V and went dead. I opened to see if it can be fixed and found this RAM IC EM638165TS in this condition: Im just a amateur in this field can't understand if this picture looks normal. The other side there is also a TMS320 which is texas int. DSP but it look smooth surface. AI: At first glance it looks like the plastic package has erupted due to overheating and this may well be the case. However, package eruption is usually very localized over the top of the die. The marks could just be glue or some other contaminant but I fear this is just wishful thinking. If it is (as I suspect) thermal damage then it is unlikely to be the only part damaged and the recorder is no more. Try to scratch the suface of the IC with a small screwdriver. If pieces of the case flake away leaving pits in the surface of the case, the part is indeed incinerated.
H: How to calculate current and voltage draw of a single resistor circuit? If I have a single 270 ohm resistor connected in a circuit to a 3.3V 50mA power supply, how can I measure the voltage and current for the resistor? I'm familiar with Ohm's law V=IR, where V is the voltage differential, but what is the differential for a resistor? I'm trying to work out why when I put a blue LED (3V@20mA) into the circuit, the voltage I actually measure is less than 3V (more like 2.4V). Update I think the thing that is confusing me is the discrepency between the theoretical values, and the measured values. Theoretical values: I = V/R I = 3.3 / 270 I = 12.222mA Measured values: 3.28V 267 ohm 11.7mA But then if I plug the measured values back into Ohm's Law, they don't equate?! I = 3.28 / 267 I = 12.28mA V = IR V = 0.0117 * 267 V = 3.12V AI: You have to start with a closed circuit, so that there can flow current. Do you have the resistor connected between the + and the - of the power supply? Then the voltage difference is 3.3 V. And you use Ohm to calculate the current. The LED. Did you place that in series with the resistor? Which is how a LED circuit is built: the resistor makes sure that there's not too much current through the LED. Always use one. If the LED's voltage would be 3 V then the difference between your supply voltage and the LED's voltage would be across the resistor. Kirchhoff is to blame for that. Kirchhoff's Voltage Law (KVL) says that the total of the voltages in a closed loop is zero. So we'll have 1.1 mA through LED and resistor. The 3 V was specified at 20 mA, so we're an end below that. It's normal for a LED to have a lower voltage at low currents. But note that the 1.1 mA was true for 3 V LED voltage. We're apparently at 2.4 V, so the difference is now 0.9 V, and the current 3.3 mA. If you decrease the resistor value so that the current increases, you'll notice that the LED's voltage will increase as well. How do you calculate the value? (Here we go again) \$ R = \dfrac{\Delta V}{I} = \dfrac{3.3 V - 3 V}{20 mA} = 15 \Omega \$ edit re your update of the question Welcome to the real, imperfect world. What you have at hand is measurement error. This is an important issue in engineering, and handling it properly can be a painstaking process. You're giving your numbers in three significant digits, that's probably what the multimeter gives you. A multimeter's precision is most of the time expressed as a percentage (relative error) + a "count" (absolute error). A hobby quality meter may for instance have 2 % precision +/- 1 count. The 2 % should be clear: a 100 V reading may actually represent anything between 98 V and 102 V. The 1 count is an error in the last digit. A 5 may actually be a 4 or 6. That's an absolute error and doesn't depend on the value the meter gives you. If you measure 100 V then 1 count represents 1 %, if you read 900 V (same number of digits!) then 1 count is 0.11 %. Let's presume you have a decent multimeter with 1 % +/- 1 digit precision. Then worst case your values may become 3.28 V - 1 count = 3.27 V, - 1 % = 3.237 V 267 Ω + 1 count = 268 Ω, + 1 % = 270.7 Ω 11.7 mA + 1 count = 11.8 mA, +1 % = 11.92 mA. 3.237 V / 270.7 Ω = 11.96 mA, which agrees well with the 11.92 mA we calculated for worst case. If your multimeter has a 1.5 % precision the calculated current will fall perfectly within the measured value's error range.
H: Using a specific LCD with an arduino I have the following lcd (DisplayTech 128x64 COG STN Y/G) unfortunately after reading the data sheet I still have no idea how to hook this up with an arduino. Could someone either assist in explain how this needs to be hooked up and how you would interface with it once connected. AI: It uses a ST7565R controller from Sitronix. Use the controller datasheet. On pages 38/39 you can find reference examples for the voltage generator connections an on page 66 you find the MCU connection examples.
H: Designing high-power LED driver with PWM Update: Provided I set up the PIC and program it correctly (planning on using this guide to interface it as a USB HID device), would this be a suitable configuration? I'm not entirely certain how I should be deriving values for the passive components outside of the manufacturers given buck configuration application example. I also can't find any examples using this driver with digital PWM (as opposed to converting the digital to analog), and I can't find enough explanation on how the DCTRL and ACTRL pins work. In this schematic, I assumed it would work as I intend by just applying the PWM signal directly to the DCTRL pin and leaving ACTRL untouched. In any case, if I wanted to use the digital-to-analog conversion, I'd just need to add a capacitor from ACTRL to GND (Richtek suggests a .47uF). Thanks again :) edit 4: From my last comment -- ...I think I'm leaning towards using the RT8482 and the NTD4960 to drive the LED, and integrate it on a PCB along with a PIC18F2550 and its associated USB interface. If I were to do this, how should I be calculating resistor/capacitor/inductor values for the driver-side of the circuit (assuming 0-1.5A or 0-2A current range for the LED)? The worst part about this project, at the moment, is that a programmer for the PIC will cost more than parts =_= edit3: Given the answers I currently have, I should be able to deal with the analog part of the circuit, however, I still am at a loss as to how I should generate the PWM signal. What sorts of MCUs should I be considering, given the restrictions of it needing to do nothing more than generate a PWM signal, and be able to be interfaced via USB (be it native USB, or a conversion to USB from another standard)? I'm currently looking to design a driver for a single high-power LED that can be brightness controlled and turned on/off via a PC. I am using a Cree XM-L LED (datasheet here, it's the 240lm neutral white model, part number: 000LT40E4). I already have a GUI written in C# to control the other parts of the project (camera and 3-axis motors), and I'd like to integrate light control into my program. Currently we are using a basic analog circuit to drive the LED (nothing more than a current-limiting resistor and a rheostat). I figure the best approach would be to build a small constant-current, PWM controlled driver circuit. I stumbled upon this circuit on Instructables and think it would suit my needs fine (however, I have no commitment to any design, so any ideas would be appreciated). Pertaining to the circuit above, I'm not sure what kind of parts I'd want to get (for the transistors, the zener, if necessary), and likewise, I have no idea what kind of microcontroller I'd need. I have next to no experience with microcontrollers, so I'm not sure what I'd need to get started. I shouldn't have a problem programming the controller, I just don't know what type of controller I'd use for this application. Likewise, I'm not sure how I'd interface the controller with a PC after programming it, though I'd assume RS-232 would be feasible, in which case I shouldn't have an issue; I can use a RS-232 --> USB converter and deal with serial communication within the scope of C#. I've also stumbled upon ICs like this Maxim-IC MAX16834, but feel like these are a) overkill and b) less efficient, given I'd still need a microcontroller to generate the PWM signal and supply power transistors, so I could just use the basic circuit above and use the PWM and NPN transistor instead. As far as my background goes, I'm entering my third-year in the EE program at UMass Amherst. I'm familiar with basic circuit analysis and programming, but I haven't learned anything about electronics yet, hence why I'm posting this question. I get the gist of most of the circuit designs, I just don't know how to design them from scratch since I don't know how to calculate values when non-elementary items are added to the mix (transistors, mainly). I feel that with a simple list of parts and schematic for this project, I'd be able to figure out the rest (all that's really left is programming the microcontroller). If I left anything important out, please let me know. Thanks in advance! edit: I forgot to mention, at the moment, the LED isn't normally driven past 400mA. It is rated at 700mA nominal (but is rated to run all the way up to 3A). I'm not sure what levels of light we will need at the end, but I'd like to have the ability to supply up to 2A. edit2: To answer RusselMcMahon's question, I would prefer to run the LED off of 5V (I already have a Cincon CFM20 5V, 20W DC supply), but if a potential circuit design would require a different supply, it wouldn't be a problem to buy a new supply. AI: Given: Cree XM-L LED. Want: Up to 2A drive, PWM controled by PC via USB. This can be two parts. ie actual LED drive and PC to LED drive interface. These may or may not be integrated. A "very easy" approach is to 1. use an off the shelf USB to "output" device. "Output" may be analog level, PWM, 8 bit port etc to control ... 2. An off the shelf LED driver that uses analog or PWM input. For example, the circuit below using a RT8482 requires an analog input level or PWM with a simple RC filter (to convert the PWM to analog). The analog could be provided by a USB to analog output I/O device (COTS) or by a USB to parallel port device (not a printer port per se) (COTS) with a simple R2R digital to analog converter (about 16 resistors plus maybe a cheap op-amp). Many examples of R-2R ladders here - links live Or a microcontroller with USB capability could have a relatively simple program written to provide PWM or analog output. A USB enabled Arduino or a Raspberry Pi would do this. (USB has to be slave not host mode). LED drive: (1) "Off the shelf" complete units that do the LED drive part of this job well are available at good prices from eg ebay, or Mouser and similar. Using such is a good default solution unless you have some reason to do otherwise. (2) DIY LED driver. Digikey LED drivers are found here. Alas the parametric search is poor in this case (which is unusual). Searching using LED driver 2A gives better results. There will be a nummber. Example only: For $US1.52/1 in stock Digikey you get 1 Ricktek RT8482, buck or boost, LED driver. Drives external MOSFET so LED current capability essentially unlimited. Looks like a good start. 350 kHz for smallish inductors. High Voltage Capability : VIN Up to 36V, VOUT Up to 48V Buck, Boost or Buck Boost Operation C u r r e n t M o d e P W M w i t h 3 5 0 k H z S w i t c h i n g Frequency Easy Dimming : Analog, PWM Digital or PWM Converting to Analog with One External Capacitor Programmable Soft Start to Avoid Inrush Current Programmable Over Voltage Protection VIN Under Voltage Lockout and Thermal Shutdown 16-Lead WQFN and SOP Packages RoHS Compliant and Halogen Free A MOSFET suitable for use as M1 would be eg ONSEMI NTD4960 $US0.40/1 in stock Digikey, 30V, 9A, 9 milliohm on resistance nominal, logic gate - data sheet curves show good at 4V gate and say 4A. ADDED: Should I be looking at specific types of inductors for this sort of application Inductors are very special for best results. If this is a one-off then off the shelf inductors from eg Digikey or similar are wise. We can give advice in this when final real spec is known. I'm assuming all of the caps in this type of application would be ceramic? Ceramic capacitors will work well for all capacitors shown. At least 10V rating. More or much more voltage OK. D1 is Schottky and should have current rating equal or greater than LED max current. Now I just need to figure out how to generate the PWM signal. PWM is "easy" [tm] and may not be needed. Above LED controller example can use analog or PWM control. USB to I/O This USB to paraell FIFO I/O module](http://www.ftdichip.com/Support/Documents/DataSheets/DLP/usb245r-ds-v10.pdf) uses FTDI's FT245R USB-parallell FIFO interface IC - datasheet here . Vast amounts of related FT245 information here FT245 available from Digikey ~= $US4.50/1 from here FT245 based module from Digikey for about $40/1 here This page discusses a DIY USB printer port which, as you have complete control over the hardware and how it acts, could "easily" meet your need. Based on a PIC18F4550 microcontroller and not much else. All software PCB patterns, circuit etc free. Typical commercial USB to analog device
H: Creating a clock multiplier using a PLL I understand that PLLs can be used to modify the phase of a clock signal for various purposes. I have also heard that PLLs are often used to multiply clocks. How can a PLL be used to multiply a clock? AI: The normal method for using PLL to multiply frequency is analogous to the normal method of using an op-amp to multiply the voltage of a high-impedance signal: the non-inverting input is fed the input signal directly; the inverting input is fed a scaled-down version of the output. The op amp will vary its output voltage as necessary to make the two inputs equal. Likewise, when a PLL is used for frequency multiplication, the "non-inverting" input will be fed from the reference signal, and the "inverting" input will be fed from a divided-down version of the oscillator's output. The oscillator will attempt to vary its output frequency and phase as needed to make the frequency and phase of its two inputs be equal. Suppose, for example, the "inverting" input is driven by a divide-by-four circuit. Since the oscillator will have to output a frequency four times that of the reference input to make the frequency of the control inputs equal, that's what it will do.
H: Discrepancy between post-Place-and-Route static timing analysis and ISIM simulation results Overview I'm implementing a simple Harvard-style CPU using Xilinx ISE version 14.1. I'm using settings compatible with a Digilent Nexys3 board, but for the time being the entire project is performed in simulation only. I have the following entry in my UCF file that specifies the location (pin) of the clock on the Nexys3 board, along with a 100MHz period constraint. This means a period of 10ns. Net "clk" LOC=V10 | IOSTANDARD=LVCMOS33; Net "clk" TNM_NET = sys_clk_pin; TIMESPEC TS_sys_clk_pin = PERIOD sys_clk_pin 100000 kHz; I am clocking all synchronous logic using the positive edge of this clock. Post Place-and-Route static timing analysis suggests everything is fine: Timing constraint: TS_sys_clk_pin = PERIOD TIMEGRP "sys_clk_pin" 100 MHz HIGH 50%; For more information, see Period Analysis in the Timing Closure User Guide (UG612). 12987 paths analyzed, 961 endpoints analyzed, 0 failing endpoints 0 timing errors detected. (0 setup errors, 0 hold errors, 0 component switching limit errors) Minimum period is 4.003ns. The minimum period is well within the 10ns target. There are no unconstrained paths in the report. The report then mentions this path first. Since the timing matches, I assume it's the slowest path in the design (the path with the least slack). It's the path from the Instruction Register to the highest bit of the stack pointer. The path (through the ALU and bus 3) looks sane for my design when the register is loaded with an immediate value. The push/pop path takes a different path. Slack (setup path): 5.997ns (requirement - (data path - clock path skew + uncertainty)) Source: CONTROL/IR_15_2 (FF) Destination: SP/VALUE_31 (FF) Requirement: 10.000ns Data Path Delay: 3.951ns (Levels of Logic = 9) Clock Path Skew: -0.017ns (0.252 - 0.269) Source Clock: clk_BUFGP rising at 0.000ns Destination Clock: clk_BUFGP rising at 10.000ns Clock Uncertainty: 0.035ns Clock Uncertainty: 0.035ns ((TSJ^2 + TIJ^2)^1/2 + DJ) / 2 + PE Total System Jitter (TSJ): 0.070ns Total Input Jitter (TIJ): 0.000ns Discrete Jitter (DJ): 0.000ns Phase Error (PE): 0.000ns Maximum Data Path at Slow Process Corner: CONTROL/IR_15_2 to SP/VALUE_31 Location Delay type Delay(ns) Physical Resource Logical Resource(s) ------------------------------------------------- ------------------- SLICE_X13Y30.BQ Tcko 0.391 CONTROL/IR_15_3 CONTROL/IR_15_2 SLICE_X5Y31.D3 net (fanout=12) 0.847 CONTROL/IR_15_2 SLICE_X5Y31.D Tilo 0.259 RAM/read_address<1> ALU1/Mmux_RR11241 SLICE_X14Y24.B3 net (fanout=4) 1.283 bus3_1_OBUF SLICE_X14Y24.COUT Topcyb 0.380 SP/VALUE<3> SP/Mcount_VALUE_lut<1> SP/Mcount_VALUE_cy<3> SLICE_X14Y25.CIN net (fanout=1) 0.003 SP/Mcount_VALUE_cy<3> SLICE_X14Y25.COUT Tbyp 0.076 SP/VALUE<7> SP/Mcount_VALUE_cy<7> SLICE_X14Y26.CIN net (fanout=1) 0.003 SP/Mcount_VALUE_cy<7> SLICE_X14Y26.COUT Tbyp 0.076 SP/VALUE<11> SP/Mcount_VALUE_cy<11> SLICE_X14Y27.CIN net (fanout=1) 0.003 SP/Mcount_VALUE_cy<11> SLICE_X14Y27.COUT Tbyp 0.076 SP/VALUE<15> SP/Mcount_VALUE_cy<15> SLICE_X14Y28.CIN net (fanout=1) 0.003 SP/Mcount_VALUE_cy<15> SLICE_X14Y28.COUT Tbyp 0.076 SP/VALUE<19> SP/Mcount_VALUE_cy<19> SLICE_X14Y29.CIN net (fanout=1) 0.003 SP/Mcount_VALUE_cy<19> SLICE_X14Y29.COUT Tbyp 0.076 SP/VALUE<23> SP/Mcount_VALUE_cy<23> SLICE_X14Y30.CIN net (fanout=1) 0.003 SP/Mcount_VALUE_cy<23> SLICE_X14Y30.COUT Tbyp 0.076 SP/VALUE<27> SP/Mcount_VALUE_cy<27> SLICE_X14Y31.CIN net (fanout=1) 0.003 SP/Mcount_VALUE_cy<27> SLICE_X14Y31.CLK Tcinck 0.314 SP/VALUE<31> SP/Mcount_VALUE_xor<31> SP/VALUE_31 ------------------------------------------------- --------------------------- Total 3.951ns (1.800ns logic, 2.151ns route) (45.6% logic, 54.4% route) Armed with this knowledge I run a post-Place-and-Route simulation with a 10ns clock period thinking everything will be fine. However, it is not. The signals do not settle in time for the next clock edge and everything is a mess. Relaxing the clock to 50ns (20Mhz) allows plenty of time for everything to settle. At 425ns we get the clock pulse that signals the start of the cycle in which we will execute the instruction SP <- 0xFFFFFFFF. IR_15_2 is the signal from the timing report. SP_value is a register, so it only assumes the value presented to it on the next rising edge. SP is loaded from bus3 so we use that as a proxy. In the graph we see that it takes 3ns or so for IR_15_2 to be asserted at all. Then it takes over 10ns more for the signal to be taken over by bus1. At 451ns, a full 26ns later, the signal is available on bus3 and we can start thinking about loading SP with it. Question Static timing tell me that the path longest register-to-register path in the design should take about 4ns, whereas the simulation shows that the signals take about 26ns to settle. What is going on here? Is the static timing analysis not finding all relevant paths? Did I use/configure the simulator wrong? Did I misread the static timing analysis? I'm OK running the design at 20Mhz, this is not a speed competition. I just have the feeling that I'm missing something important. Additional Information The complete project (VHDL files, XISE project) is available on bitbucket. AI: Looking through your timing report, there is nothing that indicates a potential issue. Since you have a problem, this means that the scenarios that static timing analysis (STA) is checking are not covering the actual usage of your circuit. Without any serious setup of STA, some common assumptions are that all inputs are valid by the time the clock rises, and that all states are known (meaning a logic 1 or 0). Immediately, the UUUUUUUU on bus3 looks very suspicious, and is a possible issue with initialization. In logic simulations, U implies that the line is either a 1 or 0, but a register driving it was not initialized properly. This could cause the simulator to give weird answers until all registers are loaded or reset. However, this problem manifests itself in later cycles after all registers have been initialized. The other potential issue is bus1 starts in a high impedance state (ZZZZZZZZ). Considering that tri-state is not usually assumed in timing analysis, this is the most likely source of the timing discrepancy. Tri-state conditions must be carefully coded into your STA tool in order for them to be considered. This can be a very difficult task, and is prone to error (incorrect programming, missed cases, etc.). I believe that programming in tri-state delays would most likely give you an accurate STA result that should match your simulation. However, tri-state is usually a bad choice for on-chip communication for both ASICs and FPGAs. This ambiguity of STA reliability, potential for bus contention, and the uncertainty of drive strength requirements make tri-state more likely to cause problems than fix them. The safer method is to use a multiplexor to select which source "talks" to the bus, or partition the design differently. I would only use tri-state when I know it will solve more issues than it can cause.
H: Eliminating Thermal Isolation Pads in Eagle When creating a ground plane in Eagle, Eagle automatically creates a thermal isolation for the pad. My first question is, does this isolation limit the current compared to a pad that is "completely" connected to the plane? My second question is, is there a way to make Eagle not automatically create a thermal via? I know one work-around: I can connect the pad with a thick wire then make that same wire on the ground plane. Unfortunately this is hard to do and can introduce errors. AI: The Eagle term for this is "thermals". The basic idea is to limit the connection to the plane or polygon fill so that it is easier to solder. I believe that this is the default behavior for Eagle, although the default settings do not make it "easy" to solder. These thermal via patterns will increase the resistance through your polygon fill, but not by a whole lot. Often you will have four connections to the plane, as well as your original wire connection (assuming you make sure everything connects manually before you begin to use polygon fills). The easy way to prevent Eagle from making thermal vias is to disable them in the fill polygon. You can do this by selecting the "no thermals" option when you are creating the polygon (see image below), or to modify the properties of an existing polygon fill and unchecking the box labeled "Thermals".
H: Understanding the AVCC pin wiring on ArduinoLeonardo (low-pass filter?) The Arduino Leonardo has an interesting difference with previous boards: the AVCC pin of the ATMEGA32U4 is connected to +5V through a MH2029-300Y ferrite beads and to GND through a 1uF capacitor. In ArduinoUno and ArduinoMega2560, this pin was simply connected to VCC. According to the atmel datasheet, this pin should be connected to a Low-Pass filter when the ADC converted is used. Arduino Leonardo schema Is this really a low pass filter? If yes, how does it work? How would you call that type of circuit? How do you model it? AI: The inductor plus capacitor form a frequency-dependent voltage divider. \$ \dfrac{V_{OUT}}{V_{IN}} = \dfrac{Z_C}{Z_C + Z_L} \$ For DC and low frequencies the impedance of L1 (\$Z_L\$) is low, and that of C1 (\$Z_C\$) high, so the input voltage won't be attenuated much. At high frequencies it's the other way around: \$Z_L\$ is high, and \$Z_C\$ is low. The attenuation is high, and the higher the frequency the higher the attenuation. So this is indeed a low-pass filter. The inductor they used is not a good one, however. It's a high frequency EMI suppressor, targeted at frequencies of tens of MHz. (The used type has an impedance of 30 Ω at 100 MHz.) The impedance curve shows a 0.5 Ω/MHz slope, so at 100 Hz the reactive part of the inductance is negligible. What is actually needed is suppression of low frequency noise, like 100 Hz ripple from the power supply. Then this inductor is pretty useless, and it's like just having the capacitor. For low frequencies inductors can be impractically large, then a resistor instead of the inductor would have been a better choice. The datasheet says AVCC shouldn't be lower than VCC - 0.3 V, but I couldn't find how much current AVCC uses. That won't be much, say 10 µA maximum. The cutoff frequency of an RC filter is \$ f_C = \dfrac{1}{2 \pi RC} \$ So if we use a 15.9 kΩ resistor with the 1 µF capacitor, we have a 10 Hz cutoff frequency, and the frequency response will look like this: The 10µA through 15.9 kΩ is a 159 mV drop, so that's within spec. A 100 Hz ripple will be attenuated by 20 dB, that's 1:10, which isn't much, but VCC should have been decoupled properly already, so the 20 dB is just extra. Above 1 kHz noise will be reduced by at least 40 dB, that's a factor 1:100.
H: Acer Aspire 7535-5020 battery I need to replace my Acer Aspire 7535-5020 battery. The original battery has the spec: 10.8V, 4400mAh, 48Wh. The Acer Website says: "6-cell battery pack" The Quick guide for my model says: 3.36 kg (7.4 lbs.) with one HDD and 8-cell battery pack 3.25 kg (7.1 lbs.) with one HDD and 6-cell battery pack But this includes 7535/7235 Amazon has several choices: Bavvo 14.8v,8 cells Bavvo 11.1v,6 cells The first choice warns: This battery is not compatible with 10.8V or 11.1V original batteries. Before purchase please make sure all the technical specifications and the model No. match with your laptop battery. The second choice has a similar warning for 14.4v and 14.8v. But there are no other technical specifications to check -- and neither is 10.8v. Anyone know more information on how I can be sure what battery I need? AI: Given that Acer has documented two configurations for battery sources depending on peripheral power requirements, I recommend you choose the higher power rated battery, so that it will provide a higher cell voltage and thus a lower Amp load. This which will achieve a longer battery operation time in Hours. The DC-DC converter inside the laptop is designed for this range of cell voltages and Acer have specified both are suitable. From your ref link: Power subsystem • ACPI 3.0 • 71 W 4800 mAh* • 48.8 W 4400 mAh* • 3-pin 65 W AC adapter* • 3-pin 90 W AC adapter * Only for certain models* If we assume worst case your laptop consumed 48W from a 71W power source and we know it is 8 cell vs 6 cell. Let us assume the current average drops accordingly 6/8 from internal SMPS DC-DC, thus for 4800mAh rating you can expect 8/6 longer hr operation. Actual mileage may vary depending on actual design of MOBO and quality of battery but there is no risk of damage indicated. You ought to get a bigger universal battery charger too with a high capacity to reduce charge time. These come in a wide range now with 65W, 85W, 105W 125W readily avail. with many DC plugs included and some with variable cell voltage switches. Also 3rd party universal chargers are much less expensive now than OEM.
H: Does Arduino use step down voltage regulators? I am designing my first "permanent" Arduino application, and I would like to know if the voltage regulator is linear or step down. The reason I would like to know is because I am currently powering the prototype with an 11.1V 1300mAh LiPo battery. If it uses a linear regulator the efficiency would be, best case, 30% and 46% for the 3.3V and 5V regulators respectively. I would much rather add my own step down converter to drop the voltage to 5V and power via USB port if that would be much more efficient. I'm not sure if the different Arduino models have different parts or not, but for this application I am using an Arduino Leonardo. Here is the schematic of the Leonardo. AI: Arduino Leonardo, like the Uno, uses an NCP1117 linear regulator (LDO), which can supply 800 mA, but at 11.1 V input that would be 4.88 W, so thermal protection will set in much earlier. Using USB is a possible solution, but keep in mind that USB doesn't have to supply more than 100 mA, you'll have to negotiate for 500 mA. And Arduino is not designed for low-power, I don't know what the Leonardo consumes, but I guesstimate the Uno's supply current at 50 mA, so powered from USB that may leave too little for for instance a series of LEDs. Your own switching power supply looks like the best solution. Bypass the NCP1117 and supply it directly with 5 V. A 12 V to 5 V buck converter should be able to have a near 90 % efficiency. If the dingus would need 50 mA it can run for more than 48 hours on the LiPo battery. Further information Arduino Leonardo schematic
H: Common Analog Signal Frequencies I'm trying to scope out what frequencies different common analog signals are. The DPScope design specs provides a list of common lower (sub 1 MHz) frequencies (copied below). audio (20 kHz) infrared remote control signals (38 kHz) ultrasound (200 kHz) servo signals (a few kHz) bio signals, medical instruments (< 100 Hz) I2C (1 MHz) RS-232 (115 kHz) one-wire SPI (as long as <= 1 MHz) However, some of those listed are used for transferring digital data (for example, RS-232). Now my questions: Under what situations would it be necessary to have a bandwidth capable of measuring these digital lines as analog signals? What important analog signals (or digital signals that should be tested as an analog signal) have higher frequencies than those listed above? AI: I assume "as an analog signal" means on an oscilloscope as opposed to a logic analyser. For a digital signal, it is important to be able to check the signal integrity and see whether it is subject to problems such as ringing, crosstalk, reflections, jitter, attenuation, etc. This can only be done with a scope with a bandwidth > the frequencies present in the signal - remember with a digital signal there are frequencies much higher than the fundamental present, how high is dictated by the rise time of the signal. For a 1MHz digital signal you would generally want at least a 5MHz bandwidth, preferably much higher. For debugging a typical small microcontroller (e.g. PIC, Atmel AVR, Arduino, etc) a scope bandwidth of at least 50MHz is preferable. This should be capable of handling just about all situations you might encounter. There are many signals above 1MHz that need checking, most microcontroller clock signals are > 1MHz, SPI is often > 1MHz, USB, etc. FPGA designs may run at 100s of MHz, high speed ADCs and DACs, etc. On a logic analyser all you can see is whether it is above a certain level or below a certain level (like a 1-bit scope) so while useful in other ways they are not suitable for checking signal integrity. The image below (taken on an MSO - Mixed Signal Oscillscope, a combination of a scope and logic analyser) is a good example of crosstalk causing problems and why a scope is needed to see what's really happening. Notice the waveforms are quite a way from the idea of a "perfect" digital signal: For the leftmost red arrow the second trace down is the transmitting trace, and the top trace down is the "victim" (receiving trace) and the right hand pulse they are reversed. We can see on the rise of the "transmitting" signal it causes a spike in the receiving trace, resulting in a unwanted glitch on the logic display, which is what the digital receiver would "see". In this image at the top we can see signal degradation caused by an incorrectly terminated trace, causing reflections. At the bottom we can see the same signal after it has been correctly terminated: On the logic analyser, both signals may work, but there is no way of knowing how marginal the first signal is without checking with a scope. The incorrectly terminated trace may only cause problems intermittently, so it's important to be able to check it's integrity. Looking at your link to the DPScope design, I see it's dsPIC based. It won't be comparable to anything you can buy (you can get a 20MHz analogue scope for << £50 nowadays, and a 5-10MHz DSO for similar) However, it would be a great project for educational purposes, and you will get something perfectly useable for low frequency (e.g. audio, UART, PWM) purposes. Plus you'll have fun building it. If your thinking of doing so, I'd say go for it, just don't expect it to take care of all your debugging needs. If your budget is limited, get a cheap analogue scope - you will generally get the highest bandwidth for your money. Remember the chicken and egg problem - you need a scope in order to build and test a scope ;-)
H: How to indicate breakaway tabs in PCB design? I'm designing two boards that'll always be used together. I'd like to place them both on a panel and break them apart after manufacturing. I found a document on PCB CAD Design Guidelines that explains breakaway tabs and lists guidelines for their design. Board assemblies can be de-tabbed using perforated breakaway tabs, v-grooves breakaway tabs, or hand-cutting with a de-tabbing tool. However, how would I indicate break away tabs in the CAD file? For the perforated tabs, I could add through-holes in a line (although I hope there's a more standardized method), but I'm not sure how to indicate v-grooves. Also, what concerns should I be aware of with breakaway tabs? AI: I'm sure that processes vary from place to place, but it's been my experience so far that when a PCB needs to be panelized, two drawings are generated: a standalone file, and a panelization or array drawing. The standalone file is the usual PCB drawing, showing the etching, vias, dimensions, etc. for the standalone PCB. There's no graphical indication on this drawing that the PCB is part of a panel. The panelization drawing shows how many of the individual PCBs are to be included on a single panel by showing multiple standalone PCB outlines, along with the details of how they're joined (v-groove, breakaway tabs, etc.) - the specific PCB details other than the outlines (and any slots/holes therein) are omitted from this drawing. For example: This excerpt uses breakaway tabs and v-grooves. You generally need to keep components away from any depanelization areas, as the mechanical stress of depanelization can sometimes inflict some mechanical stress on nearby parts (ceramic capacitors can crack, for instance) - the tool that's used (v-groove cutting wheel) may need some clearance as well. You wouldn't want filet-o-capacitor on your finished goods.
H: I ran into LCD problem I am using Arduino mega 2560 and LCD with I2C. it is working well powered by USB but not working powered by external wall charger (9vDC). The LCD is on without any character. Do you know the issue and do I need to adjust the brightness and how? Thanks! AI: The link you have provided shows a LCD that is rated for 5V. You are powering your LCD with a 9V wall adapter. I'd expect your LCD not to operate (and possibly even damaged).
H: How to go from GPIO to digital signal? I'm sitting here with my Raspberry PI and some other equipment that requires digital signal (high/low, enabled/disabled). But the Pi only has a GPIO so to get it to work I would need a microchip of some sort (guessing)? I'm fairly new to all this, but like to play around on my breadboard. Could anyone point me in the right direction here? I need the PI to control a device that operates with digital high/low signal but also "enabled" / "disabled" AI: GPIO means General Purpose I/O, and that's a digital input or output (though you often can assign an alternative function to it, like I2C signals, or ADC input). Digital outputs can control other devices by using high (logical "1") and low (logical "0") levels. "enabled/disabled", both with the "d" at the end are terms which usually describe a status, and that will normally be an output of the device. If it's indeed an input (which usually would be named "enable/disable", without the "d") then it's likely also a logic level input, which you can control with a second GPIO pin.
H: How can I get extra power for USB 2.0 device? I have a raspberry pi and a WiFi module, unfortunately I can't get enough power from the raspberry to power up the WiFi module. Can I power up the device if I cut an USB cable, I'm letting the data wires untouched and I connect the power from an external power supply? AI: edit I presumed the RPi could be USB powered, but Tony points out that it's not recommended. That seems to be an understatement. The RPI doesn't seem to have a specification (!), at least I couldn't find it, but I did find others who had the same problem. So in the end you have to rely on third-party sources. :-( RPi models A and B consume 500 mA and 700 mA, resp. (Though even that doesn't seem to be a solid spec, as this page says "provisional, from alpha board".) So, if by "external power supply" you mean a USB host or powered hub, then the answer seems to be no, since USB doesn't have to provide more than 100 mA without negotiating. You'll need another power supply, like a 5 V regulated wall-wart. Many Wifi modules are designed to operate at 3.3 V, but if you can't find a 3.3 V regulated wall-wart you can use a 5 V type, and use an LDO (Low Drop-Out) post-regulator to go from the wall-wart's 5 V to 3.3 V. Even if the module works at 5 V you may have a connection problem, since, as I understand it, the Raspberry works at 3.3 V. So the output level of the Raspberry may be too low for the WiFi module (or probably just high enough), and the input to the Raspberry may be too high. If the inputs aren't 5 V tolerant the high level may damage the device. So 3.3 V is probably the way to go. The 3.3 V version of this power module can supply 750 mA. If you prefer to get your power from a 5 V supply then the NX1117CE33 is a suitable part: it can provide more than enough current for the WiFi module, and accepts input voltages up to 20 V (so an unregulated 12 V input can be used as well). But if you use a high input voltage you'll have to keep an eye on power dissipation.
H: R2 Arduino Uno and an R3 Ethernet Shield mismatch I bought an R3 Ethernet shield for my R2 Arduino Uno, but I noticed that it has a few more pins than my R2 Uno has sockets. Do I need to buy a different shield? Arduino UNO Arduino Ethernet Shield AI: When I take a look at the schematic for R3, it appears that the extra pins at the top left: carry the same signal as pin A4 (AD4/SDA) and pin A5 (AD5/SCL). The extra two pins at the bottom left are respectively unused and attached to +5V according to the same schematic diagram. Unsure why the printing IOREF on the PCB gives other impression. As a solution, you should be able to simply wire the top left two connections to the bottom right ones (A4 and A5). A multimeter should be able to confirm my theory. The new connections on R3 have probably been introduced to allow for smaller shields still using power supply and I2C bus. As a reference the R2 looks like this:
H: Is it okay to keep a mobile phone connected to its charger, 24 hours a day, 7 days a week? I want to ensure that a mobile phone is always charged, without requiring manual intervention: e.g. disconnecting/reconnecting the charger, switching the charger on/off, et cetera). One idea would be to leave the phone always connected to its charger, which in turn would always be connected to the AC mains. How feasible / practical is this? And are there better approaches? Note that I am unable to make changes to the phone, because it is an off-the-shelf, commercial phone. But I can make changes to the circuit of the charger. Edit: This is not a specific phone model I am talking about, but potentially a phone I'd buy, for a very specific purpose. This might be lower-end Android smartphone. The phone would be left in an unattended remote property, and serve as a landline replacement (since the area isn't served by fixed-line phones). A caretaker would use it periodically to report well-being, and share some video / pictures of the place by sending MMS multimedia messages. The place has bad power supply, and thus the I want to keep the phone always charged. I do not want to hand over the phone to the caretaker, since he doesn't live on the property. AI: Most modern phones have a charging control circuit which takes care of what you are proposing. When the battery is charged, the charge control IC will terminate charging of the battery, then monitor to see if it needs charging again. So all the charger has to do is make the power available. Below is a flowchart from the datasheet of MCP73831 Li-Ion charge controller IC from Microchip: You can see the various stages of the charge cycle. This is a pretty basic IC (I just picked it since I've used it a few times) but does the job and is nice and cheap - many phones will have a pretty complex power management IC, possibly a custom one.
H: Backup battery tester circuit I am attempting to read the voltage on a backup battery on an Arduino. To that end, I used the circuit Olin Lathrop offered in answer to this question. I am powering the Arduino with 5V, and the battery is 3 AA cells, so 4.6V or less. Using the battery checker circuit Olin offered, see link above, I can reliably read the voltage on the main power supply (~5V) but when I connect the battery instead, I am only reading 0.06V when the Q1 is turned on. I believe this is because the base voltage on Q2 is too close to Q2's collector voltage. I only see turning Q2 on as more difficult as the batteries discharge. I think the way to fix this is to modify the Q1 part of the circuit so that the base voltage on Q2 is less when this circuit is "on". Any input would be appreciated. AI: This circuit I showed in the other answer was for when the battery voltage was somewhat higher than the processor's voltage. After all, that was your original reason for not just connecting the battery to a processor input pin. When you know the battery voltage won't exceed the processor voltage you can do something like this: CTRL is driven by a digital output of the processor. When high, the battery test circuit is off. when low a few 10s of mA drain is put on the battery, and the battery voltage minus the Q1 saturation voltage appears at out. This only needs to be on for a few 10s of µs occasionally, so represents very little average drain on the battery. If the C-E voltage of Q1 introduces a unacceptable offset on the battery voltage reading, then you can replace Q1 with a P channel FET. You have to make sure to use one that can turn on well enough with just the processor voltage on the gate. Such things are sometimes called logic level FETs.
H: How do I use a quartz crystal in an oscillator? How can I get a quartz crystal to make square waves at 4.096MHz? So far I have the 4.096MHz quartz crystal and this schematic I saw: Where can you find an amplifier with a single input and what voltage should I use? AI: You can make a Pierce Oscillator similar to that shown in your question: The "single input amplifier" is usually a simple CMOS inverting gate, like the 74HC7404 (6 inverters in one package), SN74HC14D (single inverter) or similar. Voltage can be something within the operating range of the IC, such as 5V. You may need to add a series resistor to limit the crystal drive (you need to check the crystal datasheet for manufacturer recommendations) Here is a circuit with typical component values: Note the series R mentioned above. The above came from this Fairchild App Note which goes into some detail on the design process. You can only pull the frequency of a crystal oscillator a very small amount, so you will need a 4.096MHz crystal. Either that or you will need to use something else such as a PLL.
H: Displacement Sensor I am working on a project where I need to measure lengt of the objects floating on a surface. To perform that kind of sensing I am currently focusing on mouse sensors. I first tried ADNS 6010; however, 8-bit delta x/y output (as displacement amount registers) of it became so small for the speed I desire which is 2 meter/sec. Even max frequency of reading did not be useful. Then I tried a ADNS 9500 sensor which has 16 bit delta x/y registers. I get better results than 6010. But the problem is the accuracy of the output. When I measured same lenght with different speeds I get the output with 10% variaton. Also difference surfaces gives different results. Now I am stuck which method to perform. I am thinking of changing the lense to focus a wide area, or changing technology. Changing lense is difficult to adjust a good focus point. It needs a well designed mechanical equipment. And chaning thechnology is a problem for me, since there is no other technology I can think of. So I would like to ask your recommendations. AI: I see a dwg of a roll of material spooled that is driven onto an anti-static roller track conveyor and the issue is measure quality of a bag length cut by a cutter which may be sync'd to the sheet feeder rate. I am not sure if it is continuous feed or stop and go. This appears to be a measurement error in variability of a cut length of 10% by speed variation rather than a a variation in actual cut length. Pls Confirm. Examine sources of variability in length; - Variation in material slip to reach feed speed after cut. - resolution of optical sensor for start/end of sheet. 2m/s at 1m max length with 10% error means 10cm error or 10% of 0.5sec = 50mS error in sheet time interval @ 2m/s - so objective is confirm sheet speed is uniform from start of measurement to end < 1% - ensure measurement time interval is less than 1mS ? I would consider using UV LED or IR that is attenuates optical path through material and use interruptor method for time interval measurement of length. Consider using LED emitter overhead with heat-shrink tube precisely aimed over detector < 1m apart.. THis method can detect wire size interruptions of light such as a resistor but plastic needs to attenuate light sufficient to trigger detector. If IR wavelength is OK... I would use Pulsed LED with IRDA I SIR tranceiver rated for 115KHz for Tx path and detector with hysteresis to detect edge of plastic. Vishay make many IRDA devices in this range that operate ~ 1m or more distance. If this works I can detail path design of optic tube to prevent stray light and get 1mm resolution on edges.
H: How do I get this spool to work? I have this spool (image) and did some testing with a multimeter before I disassembled it. It's working range was [-3.3v,0v,3.3v]. When I tested it by just applying the battery after disassembly nothing happens. Does this work in other ways then just applying the correct voltage? AI: The interesting thing with coils (inductors) is current, not voltage. It might be that the circuit connected to your coil uses some type of current-control. In the most simple case, this would be a resistor in series with the coil. If this was the case, you might measure something like 3.3 V on the connected coil, and you would now measure something like the full battery voltage (7.2 V) on the wires leading to the coil when the coil is not connected. Also, it may be that the internal resistance of the batteries plays a big role. Can you try and measure the coil's DC resistance? Can you try and measure the current flowing into the coil? Can you look into the things connected between the battery and the coil?
H: What does it mean when there is a voltage difference between ground and neutral? Between ground and hot there's approximately 120V as expected. I had expected the voltage difference between ground and neutral to be 0v, but instead it's 0.4V. Why would this not be the case? Is it a hazardous condition? How would it be corrected? AI: It's the drop caused by current flowing through the neutral wire as Andreja says. Under normal circumstances there should be no current flowing through the earth wire. I see you have it plugged into a 4-way adaptor. If you turn on/off something plugged into that same adaptor (e.g. a light) and monitor the voltage, you should see it change (it will rise on turn on and drop on turn off) I just did this simple experiment with a 4-way and a halogen lamp, here are the results: With light off: With light turned on: The multimeter was on 2VAC range and attached to the adjacent socket neutral and earth as shown in your question. You can see the voltage drop increases by ~400mV when the light turns on. If you know the current drawn by the appliance you can make a rough calculation of the wire resistance.
H: How does current flow through this Arduino circuit? I must admit I'm rather ignorant of all things electric, so I got an Arduino with the intent of filling this gap in my education, and also learning more about the physics behind programming and do low-level stuff, but I've not found a proper theoretic introduction to exactly what's going on within the device. I can only find plug-things-like-this type tutorials. So, for example, here is a breadboard diagram of the blinking LED tutorial (pdf) It seems to me like the wire connected to the 5v pin is connected to the + pins of the breadboard... which are connected to nothing. There's nothing else on the + column. So isn't this an open circuit? What exactly is that + -- 5v connection doing? That connection is not drawn in the schematic diagram. Nor is it clear to me how pins are connected within the arduino itself. I know this is a basic "google it" question, but probably due to the fact that I don't have the vocabulary to do so I've not been able to find a description of current flow in an Arduino. AI: To know how things are connected on the Arduino itself you have to take a look at the schematic. This one is the Arduino Uno's. At the bottom right you can see how the board's I/Os are connected to the microcontroller: So following the line from pin 13 you go to PB5 of the microcontroller. That means bit 5 of port B. If you set that pin to output and make it high you're supplying 5 V to the LED circuit. The series resistor will limit the current to about 5 mA, which is an OK value for the microcontroller. So, since the 5 V comes from the Arduino's I/O pin the 5 V wire on the breadboard isn't needed.
H: Why don't my coil work? I disassembled my old Niko RC car today. Thought I could play around with the parts. But what I can't seem to understand is the coil. The powersource of the rc car is a 7.2v NiCd 620mAh battery. And as you all see (image 1) I've tried to connect it directly on the coil - nothing happens. As I know nothing about electronics I thought I might test with a 9v also (image 2) :-). But still nothing happens. Does anyone know what's wrong? I did some simple measurements with a multimeter before disassembling and the coil got -3.3v / 0v / 3.3v depending on what it was doing. This coil is controlling the rc car so its voltages for left / center / right. AI: Are you sure you have a proper connection to the coil? Magnet wire has a insulating coating which needs to be scraped off before you can get a good connection. Have you tested the DC resistance of the coil to confirm it's not broken? If you have what is it?
H: Buzzer on a computer mainboard I would like to remove the buzzer on an Intel mainboard, and replace it with an LED with a resistor. Is there a standard voltage that I can assume that comes to the two ends of the buzzer? Why was a buzzer used in the design of computer mainboards instead of an LED? Update: My buzzer is labeled HYCOM HY-05, datasheet here. AI: I'm not aware of a "standard" voltage as such, but it's pretty likely to be 3.3V or 5V (possibly 12V). The easiest way would just be to measure the voltage across it when it operates, then select your LED + series resistor accordingly. Bear in mind it could be driven by PWM if it has no internal oscillator, so a scope would be best to test with. PWM will still work for the LED though, but the brightness then depends on the duty cycle. For example, if we have a standard red LED with a Vf of 2V, and we aim for a ~10mA operating current @ 3.3V. This should be sufficient current for a basic indicator LED. If the voltage is 3.3V we get (3.3V - 2V) / 0.010A = 130 ohms for the series resistor. At 5V, we get (5V - 2V) / 0.010 = 300 ohms. At 12V we get (12V - 2V) / 0.010 = 1k ohms. Note that depending on the type of buzzer, there may be a series resistor present already so you might be able to fit the LED directly. The way to test this would be to either check the PCB, find the resistor and read the value, or measure voltage as above, add a resistor of known value in place of the buzzer and measure the voltage drop across it. Then do (Vsupply - Vr) / (Vr / R) = Runknown. For example if the supply is 5V and you use a 1000 ohm resistor and measure 4V across it: (5 - 4) / (4 / 1000) = 250 ohms. Again, bear in mind it may be PWM. EDIT - now we have the part number, we can see it is a 5V, 50mA electromagnetic buzzer, and it is driven by a 2.4kHz square wave (not DC) This is fine, just size the resistor for half that of DC to get the same brightness (as the duty cycle is 50%, it means the power is 50% compared to DC) So if you size for 20mA, you will get the equivalent of 10mA. This should be plenty bright enough.
H: Fixing APC UPS buzzing noise I have an APC UPS and one of the caps - an SIEMENS EPCOS 20uF 150V Capacitor - started making a buzzing noise. This seems to be a AC, non-electrolytic capacitor and most local stores have it priced at ~$20 + tax. They look like this: I also realized that caps of similar rating (20uF 250V) are present in the cheap pedestal fans they sell at Walmart! Those look like this: Most importantly, these ones are also available on eBay for ~$5 and are worth a shot, but I had a few questions: Is the buzzing because of the capacitor is bad or that a different component could be failing and having a secondary, audible effect on the capacitor? I thought the AC capacitors didn't have electrolytes in them and hence can't understand why they would be buzzing loudly when they did not previously Should not both these caps be interchangeable in this application? I am thinking of plugging out the 20uF 250V pedestal fan capacitor and putting this capacitor into such a fan instead, to confirm if the cap itself is causing the noise - sounds like a good idea? I am not sure why the fans use 250V caps but my assumption is that these Chinese makers just stock up on one variety of the caps since most of the world are at or below 250V. Hence, for this experiment, using a 150V cap instead of the 250V one for the fan (in the US) should not damage either fan or cap? If it's confirmed that the cap's at fault, could I put in the 20uF 250V pedestal fan capacitor on the APC UPS board and expect it to have no detrimental effect on the UPS? My understanding is that this is a power cap and as long as the capacitance and voltage rating is good, other cap chars like ESR don't matter? Here are pictures of the board: It seems the noise is from the yellow cap, although there is a slight chance it could be from components around it (or because of malfunction of a component that's leading to the noise in the cap?). AI: This is a YMMV / Caveat Emptor / DTTAH / ACNR type question and answer*: ie the following may help but you MAY blow things up. Is the buzzing because of the capacitor is bad or that a different component could be failing and having a secondary, audible effect on the capacitor? Could be either. Capacitor is possible but I've not heard one do this. You may get a better idea by using a 'sound transfer unit' eg a wooden ruler or length of solid plastic bar or similar. ENSURE it is not electrically conductive to the extent that applying 600 VDC on one end and your ear on the other will not cause "problems" [tm]. You may wish to use a piece of rubber glove on one end as well BUT in practice even touching the capacitor outer SHOULD be safe. Place one end of STU (sound transfer unit) against object to be tested and other end against ear or bone of head near ear. Sound can be localised and heard much better this way., Try on surrounding objects as well. Applying EHT to far end is to be frowned on - you should not have any EHT in a UPS. I thought the AC capacitors didn't have electrolytes in them and hence can't understand why they would be buzzing loudly when they did not previously AC capacitors will probably contain two x electrolytic capacitors of twice the target capacitance each, connected in opposed polarity. Should not both these caps be interchangeable in this application? There is a "reasonable chance" that the cheap fan cap WILL work OK here. Also, used or dead fans may be cheaper again. I am thinking of plugging out the 20uF 250V pedestal fan capacitor and putting this capacitor into such a fan instead, to confirm if the cap itself is causing the noise - sounds like a good idea? Yes. Sounds good. Always a risk that the fan will stress it worse than the UPS does but if it is good it should work OK. I am not sure why the fans use 250V caps but my assumption is that these Chinese makers just stock up on one variety of the caps since most of the world are at or below 250V. Many countries are 230 VAC. Some nominally 220 VAC. Voltages can be and are sometimes higher than nominal. 250 VAC is saying it will work anywhere. Hence, for this experiment, using a 150V cap instead of the 250V one for the fan (in the US) should not damage either fan or cap? Probably. Cap MUST be AC rated and suitable for whatever class of service it sees. X rates is phase-phase or phase-neutral or line-line. Y rated is phase-ground. Such ratings allow for surges, spikes etc. 250 VAC cap in 110 VAC system should be fine. If it's confirmed that the cap's at fault, could I put in the 20uF 250V pedestal fan capacitor on the APC UPS board and expect it to have no detrimental effect on the UPS? You can always EXPECT :-) ... . But, yes, it will probably be OK BUT no guarantee. My understanding is that this is a power cap and as long as the capacitance and voltage rating is good, other cap chars like ESR don't matter? See above re X and Y rated. Also, some designs pass high currents at all times and some don't and a cheap cap may get sadder quicker. *YMMV / Caveat Emptor / DTTAH / ACNR = Your milage may vary Let the buyer beware. Don't try this at home (you can but ...) All care, no responsibility
H: Crystals, Oscillators, and Resonators. What the difference? I am trying to figure out the difference between crystals, oscillators, and resonators. I'm starting to grasp it but I still have some questions. From my understanding, an oscillator is built from a crystal and two capacitors. What is a resonator then? Is it a difference in terminology? If an oscillator and a resonator are similar, why do these two items: http://www.digikey.com/product-detail/en/HWZT-16.00MD/535-9379-ND/675574 http://www.digikey.com/product-detail/en/FCR16.0M2G/445-1646-ND/653108 have two pins out and no ground. Whereas this one http://www.digikey.com/product-detail/en/ZTT-16.00MX/X908-ND/170095 has three pins one of which is a ground? Will any of these three devices work as an external clock for a microcontroller? PS: Bonus points for an explanation of how the capacitors help the crystal work properly. :) AI: Both ceramic resonators and quartz crystals work on the same principle: the vibrate mechanically when an AC signal is applied to them. Quartz crystals are more accurate and temperature stable than ceramic resonators. The resonator or crystal itself has two connections. On the left the crystal, right the ceramic resonator. Like you say the oscillator needs extra components, the two capacitors. The active part which makes the oscillator work is an amplifier which supplies the energy to keep the oscillation going. Some microcontrollers have a low-frequency oscillator for a 32.768 kHz crystal, which often has the capacitors built-in, so that you only need two connections for the crystal (left). Most oscillators, however, need the capacitors externally, and then you have thee connections: input from the amplifier, output to the amplifier, and ground for the capacitors. A resonator with three pins has the capacitors integrated. The function of the capacitors: in order to oscillate the closed loop amplifier-crystal must have a total phase shift of 360°. The amplifier is inverting, so that's 180°. Together with the capacitors the crystal takes care of the other 180°. edit When you switch a crystal oscillator on it's just an amplifier, you don't get the desired frequency yet. The only thing that's there is a low-level noise over a wide bandwidth. The oscillator will amplify that noise and pass it through the crystal, upon which it enters the oscillator again which amplifies it again and so on. Shouldn't that get you just very much noise? No, the crystal's properties are such that it will pass only a very small amount of the noise, around its resonance frequency. All the rest will be attenuated. So in the end it's only that resonance frequency which is left, and then we're oscillating. You can compare it with a trampoline. Imagine a bunch of kids jumping on it randomly. The trampoline doesn't move much and the kids have to make a lot of effort to jump just 20cm up. But after some time they will start to synchronize and the trampoline will follow the jumping. The kids will jump higher and higher with less effort. The trampoline will oscillate at its resonance frequency (about 1Hz) and it will be hard to jump faster or slower. That's the frequencies that will be filtered out. The kid jumping on the trampoline is the amplifier, she supplies the energy to keep the oscillation going. Further reading MSP430 32 kHz crystal oscillators
H: Sending a analogue signal? I have this old Nikko Tiger 2 RC car I've been playing around with. At first I disassembled it and played around with the parts and my parts (motor controller++). But then I asked myself, can't I use the parts already in there? And put the end of the antenna of the RC car (not the remote controller) into my arduino? Making the arduino produce the signal for the various commands (forward, backwards, steering). Is it possible? The remote controller is a simple, two throttles: up/down and left/right. It states that it operates on 27MHz. Could I do this in two steps: 1: open up the remotecontroller, plug the antenna to the arduni and record the various commands 2: plug the antenna of the car to the arduino and make the arduino produce the signal for the various commands? AI: Definitely possible, but you'll need more than the antenna. The remote controller has a 27 MHz RF transmitter, which sends the data to the car. That has an RF receiver, which gets the up/down, left/right data from the RF signal. You need both the transmitter and receiver. Check the remote controller's electronics. You'll have a PCB to which the antenna is connected. This will have a couple of wires coming from from the battery, and a few coming from your controls. Use a multimeter to see what their signal looks like when you handle the controls. That will probably be simple signals, like 0 V = left, 4.5 V = straight ahead, 9 V = right. Something like that. Same for the receiver's side. You have power supply, and outputs going to the motor(s) and maybe a solenoid. Measure what comes out when you use the remote controller. Arduino works at 5 V, and its I/O's can only output 0 V or 5 V. You'll probably need a few components, resistors, and maybe a transistor to create the signals for the transmitter from Arduino. It depends on what the signals look like. On the receiver side you have more options. Apart from the digital inputs (0 V or 5 V) Arduino has analog inputs, which can detect a range of input voltages. The receiver's output signals will probably be digital as well, though, if they control a motor (on/off, forward/reverse). The voltage level will probably not be 5 V. Again a transistor may adapt the level for the Arduino's 5 V. If you want to play with wireless a cheap but interesting alternative can be the RFM70: It's a small transceiver module you can directly connect to Arduino to transmit and receive any amount of data you want, so you're not restricted to the couple of controls from your RC. Costs only a few dollars.
H: Arduino: two more analog input! i'm dealing with analog sensors. I have an Arduino Lilypad Simple Board with only 4 analog input. Now, i need two more sensors and i've found on the net this schematics: But i don't understand if it could add delays on my project because i'm controlling audio-video stuffs and any kind of delay has to be avoided. Then, on the link i read this: It is possible to calculate the actual resistance from the reading but unfortunately, variations in the IDE and arduino board will make it inconsistant. Be aware of that if you change IDE versions of OS's, or use a 3.3V arduino instead of 5V, or change from a 16mhz Arduino to a 8Mhz one (like a lilypad) there may be differences due to how long it takes to read the value of a pin. Usually that isn't a big deal but it can make your project hard to debug if you aren't expecting it! I'm not a big expert of arduino and i don't understand what do i have to change for lilypad. Any advice could be appreciated! AI: This will most certainly add delays as you are polling the pin in a blocking loop while (digitalRead(RCpin) == LOW) { // count how long it takes to rise up to HIGH reading++; // increment to keep track of time if (reading == 30000) { // if we got this far, the resistance is so high // its likely that nothing is connected! break; // leave the loop } Assuming that your compiler can optimize the code extremely efficiently this loop would take something like 4 lines of code to execute since you have to read the pin, then compare it to a value, then branch based on the outcome (I would be very impressed if you could get this few instructions). Further assume that each one of those instructions takes only 1 clock cycle to execute (this is also probably going to take more, but it helps to bound the problem). This routine could take at most: \$MaxRoutineTime = LoopIterations \times \frac{Instructions}{LoopIteration} \times \frac{Seconds}{Instructions}\$ \$MaxRoutineTime = 30,000 \space Iterations\times \frac{4 \space Instructions} {LoopIteration} \times \frac{Seconds}{8,000,000 \space Instructions}\$ \$MaxRoutineTime = 15 \space mS\$ but I assume it will take a little more than that because of the aforementioned allowances. The reason it does not add delays when using an ADC is because the peripheral can be setup to generate interrupts and you will only be notified when the ADC reading is complete. The time it takes the ADC to complete a measurement is a finite number of clock cycles, so the app note you're referencing is pointing out that if you slow your clock speed, though the ADC will still take the same number of clock cycles to complete a measurement, your measurement will take longer because the clock is slower. Edit At first glance from your picture, combined with the fact that you mentioned audio, I thought you were measuring a microphone input. However, it appears that you're just using a Force Sensitive Resistor (FSR) which is just a pressure sensor. If you don't need to know the amount of pressure, only that it was pushed, you don't have to go through all the trouble of finding the exact reading. You can simply use any interrupt-generating, digital input if you pick the correct resistor value (in place of the capacitor). You will simply set a digital pin to generate interrupts on rising edges and pick a resistor that will give you a state change (low/high) with the desired amount of force for your touch. Then you'll know each time the FSR was pushed and can handle it in an un-blocking fashioner, introducing the least latency possible.
H: Is galvanic isolation of Hi-speed USB impossible? I have a USB isolator which provides galvanic isolation of a USB device from my PC, but only works for low speed and full speed USB. I can't find any alternative electric isolators which do provide Hi-speed connection; USB fiber extenders, however, are offered with hi-speed throughput and should provide both galvanic isolation and high bandwidth, though perhaps at higher cost? Is there a practical or physical limitation to the bandwidth of a galvanic isolator for USB? Are actual laws of physics involved, or is this merely an engineering challenge or cost issue? Edit Let me rephrase my own question: Non-fiber USB isolators cost about €100 but are limited to full-speed USB. Hi-speed USB isolators do not exist, so I assume they can not be made for €100, but would cost significantly more (€1000? €10000). At such a price, there is no market, thus there are no hi-speed USB isolators available. The question thus is this: What makes a hi-speed USB isolator so much more expensive than a full-speed USB isolator? Is there a physical limitation to the approach used for the full-speed devices which makes it inapplicable and/or cost prohibitive for hi-speed devices? AI: There are definitely laws of marketing involved. :-) Gigabit Ethernet and 10G-Ethernet have galvanic isolation. So, obviously it is possible and routinely done with today's technology. A fiber-optic USB extender basically works a bit like an opto-coupler except that the light source and the light receiver are on separate chips. Combining the functions of a fiber extender into a single package should be cheaper, not more expensive. Using magnetic or capacitive coupling instead of optical coupling should be cheaper again. USB is normally used for short distance (up to 5m) data connections where significant differences in ground potential do not exist and galvanic isolation is unnecessary. There are a few applications, e.g. medical or low electrical noise, which require or benefit from galvanic isolation. All of those applications are specialized and the existing fiber extender solutions fully cover the galvanic isolation requirement. Additionally, wireless solutions like Bluetooth, Zigbee, etc also satisfy the isolation requirement (at slow speeds). In conclusion, there is probably not much of a market niche for USB isolators. FWIW, I have used a fiber extender a few years ago during development work on a high voltage power supply sub-system. I only needed the isolation, the fiber remained coiled up on the bench. Thanks for the links. Edit: As for the part of the question "Are actual laws of physics involved, ..." No, there are many faster, galvanically isolated communications links such as Gigabit Ethernet, 10G Ethernet and even wireless solutions. "... or is this merely an engineering challenge or cost issue?" Yes, as of 2018, the engineering challenge is less than it would have been a few years ago, but would still be a significant effort. But who would fund development of such solutions if the demand appears very limited?
H: What is the difference between burden resistor and a normal one? I just came across the word 'Burden Resistor'. Is it any different from a normal resistor? If it is different, where can I possibly get one? Sparkfun hasn't got one listed. Any help is appreciated. I am trying to build a current sensing circuit. AI: No, they're the same components as regular resistors. The name refers to the function, not to the resistor's construction. Current transformers act as current sources and need a load. A current source is the dual of a voltage source, and just like you shouldn't short-circuit a voltage source because it would cause infinite current, you shouldn't leave a current source open, as it would cause an infinite voltage. The burden resistor converts the current to a limited voltage.
H: I broke my steering coil, where could I get I new one? I broke this coil: Does anyone know where I can pick up a similar coil? It was placed in my Nikko RC toy car (Nikko Tiger 2). AI: Chances are that this was custom made for Nikko, and that it isn't for sale is shops. If you want the same thing you'll have to buy a new car. But look at the functionality. It looks like the white dingus rotates and the pin pushes against something. You can do the same thing with a RC servo, though you'll have to change the way you control it. RC servos are pulse width controlled, typically 1 ms to 2 ms repeated at 20 Hz to 50 Hz.
H: Choose the resistence with voltage divider sensor I'm on voltage dividers circuits for reading some sensors that changes their resistance (force sentive resistor). With my tester (with input scale set on 200K ohms) I read 23 if sensor is not touched and 65 if the sensor is touched at maximum. Now, I'm trying to read it with a microcontroller and with a 220 ohms resistor (red red brown) i read values from 7 (not touched) to 1 (touched). With a 1000 ohms (brown black red) i read values from 40 (not touched) to 15 ( touched). I would like to get the best from this sensor and this microcontroller (it could read analog values from 0 to 1023) and I want to calculate the best resistor for get the best result and the biggest range of values i can. Can someone point me out? AI: Ah, I once wrote an absolutely fantastic answer :-) for that! I found that you get the maximum output range if the series resistor is equal to \$ R_S = \sqrt{R_{MIN} \times R_{MAX}} \$ You'll have to admit that this just looks beautiful. So for your sensor that would be \$ R_S = \sqrt{23 k\Omega \times 65 k\Omega} = 39 k\Omega\$ If you feed the resistive divider with the ADC's reference voltage you'll get readings of 380 and 640 for 23 kΩ and 65 kΩ, resp. That's a range of 260 discrete values, or a 0.4 % resolution. You can't get better than that without amplification or a higher voltage difference across the resistive divider. Note that using the same supply for the divider and the ADC's reference the reading is completely independent of voltage variations!
H: Which is easier to solder: TSSOP or QFN? Which package easier to solder on home-brew PCBs: TSSOP QFN I generally use solder paste and hot-air / hot-plate. AI: For hand soldering I'd go with TSSOP. QFN pretty much requires hot air, whereas you might be able to get away with a soldering iron with a TSSOP. The pitch of QFN can be smaller too, which is more difficult with home-made PCBs, but TSSOP can be small too. Sometimes they have a exposed pad in the center that needs to be grounded, which makes routing more difficult. One issue with QFN is you have to consider the package lying flat against the board without any gap under the package or between pins. This means you can't use conductive flux since you can't guarantee the flux will be rinsed away under the package. I know this because it actually happened to me. A local manufacturer that specializes in small quantity hand-built boards was new to QFN and didn't think about this. The boards we got back didn't work for various reasons. Eventually I figured out that pins were being shorted together under the package. The resistance was surpringly low, like only a few 100 Ohms in some cases. What a mess. Letting the boards sit in clean water for a few hours helped, but ultimately we had to remove all the QFN packages with our hot air station, clean the mess, then re-solder them with rosin flux. Then the boards worked as expected. For real professionally fabbed and built boards, there is no issue with QFNs, but for do it yourself situations they can be tricky.
H: UART adapter to... what is this connector's name? Any idea of what the connector from the right is named? AI: The left one is called Micro-MaTch™ connector, and it's a board to flat cable or board-to-board connector. This is a two-part connector, but there are also versions where you solder the flat cable holding part directly, so that it can't be removed. The other one is a board-to-board connector, like Jason says. Usually you'll have a couple of them, so that the boards can't rotate relative to the other one. This is tricky, though, as the least mispositioning will cause strain on the solder connections. Further information Micro-MaTch Connectors Overview at TE
H: switching DAC output to multiple inputs I am currently using a DAC (mcp4922) and want to send the output voltage (0 to 5V) to 1 of many (14) inputs on an Arduino Mega. I am currently using some VN2222 fets for switching (because I had them laying around) but would like to get something with a higher density. They are all connected to the DAC output and switched with 14 output pins from an Arduino. I know there is a DIP 20 part with 4 fets on-board, but I would still need 4 of them to get the number of pins. Does anyone have suggestions on other parts that would do something similar Hopefully a single DIP style case? Note that the switching is done to only one of the inputs at a time and typically for several milliseconds before it is switched to another one, so no high-speed pulsing-timing here. Thank you! AI: If understand correctly you are looking for a simple multiplexer, something like the 74HC4067 should do - it's a 1 to 16 multiplexer/demultiplexer. Simply input your signal to pin 1 (COM IN/OUT) and use S0 to S3 to switch it between I0 to I15 (each of which are connected to your Arduino inputs) For example if you want to connect to I7, then you set S3 to 0, S2 to 1, S1 to 1, S0 to 1 (i.e. 0111 binary = 7 decimal) This is a single supply IC, so it won't work if you DAC swings below ground, in that case you will need a dual rail mux (plenty out there, e.g. 4051 is an 8ch dual rail)
H: Clamp / pierce into flex PCB I'm hacking a pair of active-shutter 3D glasses. Leading to each lens is a flex PCB with 2 traces. I'd like to connect into those traces about 5 mm away from the lenses. How can I go about making a connection into them? melt the flex PCB to leave just the bare copper? somehow crimp metal teeth into the flex PCB from both sides? AI: I suggest neither melting nor crimping because the copper is way to thin and fragile (unlike magnet wire, where you melt away the insulation - and unlike a comparatively massive stranded or solid wire used for crimping, the 17, 35 or 70 µm Cu layer on flex "boards" is just way too thin for either method!). Flex boards are usually composed of a polyimide (PI) substrate below and a coverlayer above the etched copper traces: xxxxxxxxxxxx coverlayer or flexible soldermask ------------ Cu traces (thin!) ============ PI substrate PI is heat resistant and as a base material for copper traces to be soldered on, is about as good as good ol' FR4. Try finding out on which side you have the coverlayer, use something sharp to scratch it off, and try to solder onto the copper that remains on the PI substrate. The best way would be to clean away the coverlayer (or flex soldermask) and put the thing into a ZIF socket, because solder blobs on a flex "board" might not last long under mechanical stress - but I guess for a hobbyist's approach, soldering might do.
H: Standard wire colors I am fairly new to "electrical" engineering as a hobby/ past time. I have always loved electricity and have made simple circuits since I was a little baby. I am now working on one of my first arduino projects and I started thinking about what color wires I should use for the different I/O and serial communication. I know it doesn't matter, but I am curious: are there standard wire colors for things such as Tx and Rx, Digital IO, analogue IO? It is very common that Red is "Positive" and Black is "Negative." I have also noticed that USB data wires are usually green and white. Are there other standards that are commonly used for other applications? Can someone give me a list please? AI: Obligatory link to the XKCD comic about standards: So yeah, there are standards. There are so many of them that it's effectively the same as having no standard, as every possible wire arrangement likely has a standard that describes it.
H: Inverter ICs for (5v DC -> 5v AC) and (9v DC -> 9v AC) What are some ICs that can turn 5v DC into 5v AC? How about 9v DC into 9v AC? I'm wiring up the liquid-crystal lenses from active shutter 3D glasses to be electric-powered sunglasses. Depending on the lens model, they need either 5v or 9v to go fully dark. They can work when powered by DC (which is what I'm currently doing), but this biases the crystal and dramatically lowers its lifespan. Instead, they should be driven by AC with a frequency between 30 Hz - 100 Hz (see: http://www.pacificdisplay.com/lcd_static_drive.htm). AI: Liquid crystals take very little power to drive, so you don't need a special power circuit for them. The output of a ordinary digital CMOS logic gate will be fine. Some CMOS families can go up to 15 V, so 9 V is doable. OPAMPS can also do this. You can even create up to 10 V drive level with two 5 V logic outputs run 180° out of phase. With a setup like that, it would be possible to smoothly adjust the effective drive level by changing the phase between two square waves. 0° would be no drive, 180° full 10 V drive, and other phase shifts result in in-between levels.
H: Are sealed lead acid batteries water-resistant? I am going on a climbing trip in the Canadian Rockies for 20 days starting this weekend. I am bringing a 12volt 7Ah SLA battery that I am going to use to charge my GPS, iPod, Camera, and Sat Phone. I ordered this Yuasa battery. Will using this in a wet environment, and possibly getting rained on be bad for the cell? Will the water be able to get inside? I figured if the Lead Acid and HCl can't get out, then water can't get in. Is that true? Also, I know that cold weather makes the life of Alkaline's and even Li batteries shorter, does the cold have a negative effect on Lead Acid batteries? AI: Water shouldn't be able to get inside sealed lead-acid cells. The terminals are not environmentally sealed, though. If you backpack gets soaked, they battery could discharge through the wet cloth. Cold increases the internal resistance of the batteries. As a result, you lose more energy on the internal resistance. You will get less charge back from the battery. Max output current also decreases*. At 00C, you should still be able to get few amperes necessary for charging your gear. (source of image) * BTW, vehicle starter batteries are rated for Cold Cranking Amperes. So, they are rated for the worst case.
H: Can I charge a 12v sealed lead acid with an old wall-wart (not made for charging)? Will it hurt the battery? If I left it overnight would I run the risk of "exploding" the battery? I have a 7Ah SLA battery that I need to charge, but I don't have a charger and I don't want rake out $50 for a charger. Even if I did I need to charge it by the weekend, so I probably couldn't even get it in time. If I use a 1Amp wall wart it should take 7 hours to charge the battery. Would it be bad for me to plug the battery in for 7 hours and then unplug it when the voltage is about 13.5-14volts or so? AI: It's unlikely that your 1A wall-wart will handle the battery load, as regulation tends to be quite poor on many lower-quality models. Don't expect constant-current charging - most likely the voltage will sag as the load increases. I wouldn't assume it to be able to maintain 1A over the whole cycle. Also, some wall-warts don't like being connected to a source (like a battery) without isolation. Technically, charging a SLA at 2.35 to 2.4V per cell is OK (14.1 to 14.4V), but it's risky to leave the apparatus overnight, especially since the wall-wart doesn't have the ability to change modes (or shut off) to charge the battery properly without damaging it. I suggest reconsidering the idea. If you can find a lab supply with an adjustable current limit, you could charge the battery in a much safer manner. A proper SLA charger is your best bet.
H: Arduino Analog Input example clarification First of all I'm total nub in electronics. Recently I got an Arduino Nano. Now I'm trying to understand why there is no potentiometer nominal at http://arduino.cc/en/Tutorial/ReadAnalogVoltage example and how variation of this nominal would affect Analog input readings. Also why at http://arduino.cc/en/Tutorial/AnalogReadSerial example they picked 10k potentiometer, what would be different with 200k potentiometer. Thanks! AI: There would be no difference in the wiper voltage output from any (unloaded) potentiometer, they all work in the same way. However, the analogue input to your Arduino recommends a source impedance of less than 10kOhm, for optimum performance. This is due to the time it takes to charge the sample and hold capacitor, which can be seen as a dynamic impedance. The below image is taken from the AtMega328 datasheet (the microcontroller the Arduino is based around): Don't worry too much if you don't completely understand this right now, just accept we need a source impedance of less than 10kOhms. Now how do we calculate the output impedance from a potentiometer? For the details, look into Thevenin equivalent impedance. This tells us that the maximum output resistance from the wiper of a pot is 1/4 of it's resistance measured from top to bottom (when the wiper is at the centre) So if your pot is 10k, then the max output resistance is 2.5k. Here is a simulation of a 10k pot being swept from one end to the other: The X axis represents the rotation from 0 to 100% (ignore the actual values shown) The Y axis is the output impedance measured at the wiper. We can see how it starts and ends at 0 ohms and peaks at 2.5kOhms at the middle (50%) This is comfortably less than the recommended source impedance of 10k. So, you could use any pot value between e.g. 100 ohms and 40k as your voltage divider. EDIT - to answer the question about what happens if we use a 200k pot: As it says in the datasheet excerpt, the higher the source impedance, the longer the S/H capacitor takes to charge. If it's not fully charged before the reading is taken then the reading will show an error compared to the true value. We can work out how long the capacitor needs to charge to 90% of it's final value, the formula is: 2.3 * R * C After 1 RC time constant the voltage is at ~63% of it's final value. After 2.3 time constants it's at ~90% as above. This is calculated by 1 - (1 / e^(RC/t)) where e is the natural logarithm ~2.718. For example for 2.3 time constants it would be 1 - (1 / e^2.3) = 0.8997. So if we plug in the values shown - 50k source impedance, 100k series impedance (assume worst case) and 14pF capacitance: 2.3 * 150k * 14pF = 4.83us to charge to 90%. We can also calculate the -3dB value: 1 / (2pi * 150k * 14pF) = 75.8kHz If we want the final value to be within 99% we have to wait around 4.6 tau (time constants): 4.6 * 150k * 14pF = 9.66us to charge to 99% - this corresponds to around 16.5kHz So we can see how the higher the source impedance the longer the charge time and hence the lower the frequency accurately read by the ADC. In the case of a pot controlling a ~DC value though, you can sample at a very low frequency and give it plenty of time to charge, as the leakage is very small. So I think 200k should actually be fine in this case. For e.g. an audio signal or any varying (AC) high impedance signal you will have to take all the above into account though. This link goes into some good detail on the ATMega328 ADC characteristics.
H: How are multi-layer PCBs made? I know how normal PCBs are etched, but every time I grab a magnifying glass and examine the edge of a multi-layer board I'm astounded by the precision that must be required during production. On top of that, some of them have buried vias and other such trickery, which must further complicate the process. How are these boards made? AI: In a nutshell, to make a 4-layer board, 2 double sided boards and a separator are laminated together. You can extend this idea to 6, 8, n-layer boards. :-) I'm astounded by the precision that must be required Amazing isn't it? A key to manufacturing multi-layer boards is the mechanical registration system which ensures layers line up with sufficient accuracy.
H: Powering 3 LEDs I have 3 LEDs which I assume are white (they look white, in a blue glass/plastic). I need to power them, but Im a bit rusty with my electrical knowledge. I have the following power supplies (all 240v mains input): Nokia cell phone charger: DC 5V/350mA ATX 320W PC power supply Some weird AC convert (I think): +5V/10A, +12V/1A -5V/1A (see photo) What would be best suited to powering the LEDs? And what extra stuff would I need (e.g. resistors)? The LEDs are from ozstick (the LED buttons), which says "colored 12v LED". AI: White LEDs need a voltage of about 3 V to 3.2 V, YMMV. You place a series resistor to control the LED's current. A 0.5 V drop across the resistor will not give you good control, I'd rather go for at least a volt. So if you place the LEDs in parallel you'll need 4.5 V minimum. For parallel LEDs place one series resistor for each of them. If your power supply can deliver a higher voltage you can l=place the LEDs in series. Then they will need 9V to 9.6 V, or thereabout. Again a series resistor for at least 1 V drop, and you come up close to 12 V. To calculate the value of the series resistor you need the LED's current requirement. Suppose this is 20 mA, then for the 12 V supply with the 3 LEDs in series you need \$ R = \dfrac{12 V - 9.6 V}{20 mA} = 120 \Omega \$ If the LEDs' voltage is somewhat lower you'll have a higher current: 25 mA at 3.0 V LEDs. If you want to use one of the 5 V supplies you get \$ R = \dfrac{5 V - 3.2 V}{20 mA} = 90 \Omega \$ Again, at 3 V per LED you'll get a higher current: 22 mA. Note that the difference in current is smaller, which is because voltage tolerance compared with the resistor's voltage drop is smaller. That's why a minimum voltage drop of 1 V to 2 V is recommended. edit You added a link to the product, which says "coloured 12V LED". There are no 12 V LEDs. So this is either a LED with the required series resistor built-in, or an incandescent bulb. In the former case you can probably simply apply 12 V to it, as the site also suggests for the replacement LED. I'd love to have seen a polarity indication on it though.
H: PICKIT 3 and 16F684 in-circuit debugger I am not sure which other parts (except PIC KIT 3) do I need for in-circuit debugging of PIC 16F684... Do I need additional ICD header? What about RJ-11 adapter/cable to connect PICKIT and header? Do I need one or is it included with header? Is it possible to use in-circuit debugging functionallity without those two parts (is there any other way)? AI: MPLAB will tell you if the 16F684 needs a separate debug header - select the device using Configure > Select Device. You should see that you need an AC162055 header. The product web page also mentions it. It comes with an RJ11 connector, so you will need an adapter to use it with a PICkit. The only debugging you will be able to do without the header is by using the simulator, or by inserting debug statements into your code and using a serial connection to your PC.
H: How to configure the analog port in PIC18F? How to configure the analog port of PIC18F452 to read analog values? They need to change their status while running the program. AI: Check the PIC18F452 datasheet (google it). It will say how to set ADCON0 and ADCON1 registers in order to set portA pins to work as either digital or analog..
H: How is a transformer working at 10's of MHz designed? In this answer a switching power supply using a transformer operating at 10's of MHz range to reduce size is mentioned. How would such transformer be designed? Would it still have a plain old design with a core and windings, just smaller, or would it have some alternate design? AI: The design of a transformer at 10s of MHz is not the main issue in making a switching power supply operate at high frequency like that. There are plenty of ferrites that can be used as the core material that won't be particularly lossy at that frequency. The biggest issue will be to minimize capacitive coupling between the primary and secondary and between parts of each winding. This might call for a toroid with each winding not quite spanning half the toroid so that there is some gap between then and the ends of each winding are apart. The real problem will be switching losses. When the whole switching cycle is only 100 ns or less, then a 10-20 ns switch transition time is significant. If the switch is a FET, then then charging and discharging the gate 10 M times a second represents significant current. Fast parts generally cost more and require more power to drive. While the inductor can be made nicely small, the loss of efficiency at this frequency will limit size due to heat dissipation problems. It sounds worth looking into a resonant design. That might actually put parasitic capacitance accross each transformer winding to use with some cleverness.
H: Powering LED with 9V battery I want to take an LED and power it with a 9V battery. I just don't seem able to get the math right. Taking an average 9V battery and a 10mm LED, what kind of resistor would I need and how do I know for how long the LED will run on the battery? Also, can infrared LEDs be "seen" (using a camera?) from a distance? AI: 10 mm is not an electrical specification, you should consult the datasheet to find out how much current it needs. For an indicator LED that's often 20 mA. The LED will have a voltage across it, what's called the voltage drop. We also need that, it's also in the datasheet. The voltage drop mainly depends on the color, for a red LED 2 V is a typical value. So with 2 V and 20 mA we can get to work. We're going to place a resistor in series with the LED to control the current. At 9 V battery voltage and a 2 V drop across the LED we'll have 7 V remaining for the resistor. Then according to Ohm's Law Voltage = Current x Resistance, we can calculate the resistor value as \$ R =\dfrac{V}{I} = \dfrac{7 V}{20 mA} = 350 \Omega \$ The closest E12 value is 390 Ω. To know how long the battery will light the LED we want to know the battery's capacity, expressed in mAh, for mA-hours. An alkaline barry may have a capacity of 560 mAh. Then at 20 mA it will work for about 28 hours, maybe somewhat less. And yes, a camera will see IR, from how far depends on the LED's power output.
H: How can I make a thermostat? I would like to make a threshold-temperature on-off switch (a.k.a. a thermostat). Short of buying a commercial sensor like an LM335Z (I know that it's super cheap) and figuring out how to use the output, I thought that it could be a fairly simple task to design something that would turn on an electrical device below a certain temperature. Imagine a two-layer long narrow "wafer" made of two materials with dissimilar thermal expansion coefficients, perhaps rubber and very thin steel. This would be a physical action arm that engages and disengages a switch by its position. I would calibrate the switch to turn on at the right temperature with a separate temperature gauge, and have a working thermostat. My current plan is to make a device that will help maintain an environment suitable for bread to rise (anywhere from 85 to 105 F). It could also be used to make yogurt. Or keep a lizard cage at the right temperature. The possibilities are many. As a bonus, I'd like to teach my son some science and handicraft, so this has additional purpose beyond the practical. It's just a vague idea at the moment, so I wonder if others with more experience in DIY projects of this type could offer advice. I have some wiring experience and am willing to purchase parts if needed (even if that raises the total price beyond what I could simply buy). I also have a fairly large store of random electronics parts and pieces that I may be able to use. AI: Yes, the mechanism you describe works and is the basis for many commercial thermostats. Actually it's better to use two dissimilar metals instead of a metal and rubber. The characteristics of the rubber are too unpredictable and will change too much. Such a temperature switch is quite common, and is referred to as a bi-metalic element or switch. Take the cover off your home thermostat and you will probably see a "spring" like coil of a flat metal strip. That is a bi-metallic strip. Attached to the top may be a mercury switch that opens or closes depending on which way it is tilted by the coiled bi-metal. While a bi-metallic switch as the basis of a thermostat is well grounded in physics, it is not the first DIY solution I would try. Laminating the two metals is probably not easy, and I'd worry about things shifting, ending up with frozen or fried lizards, rotten yogurt, etc. A simple thermistor with pullup or pulldown resistor into one leg of a comparator, and the output of a power supply dividing pot into the other will work nicely. You have to set the pot to where the comparator is just tripping when you reach the desired temperature, and the system should maintain it from there. The pot isn't calibrated, but then neither was your bi-metal strip. I'd also add some latching or hysteresis. Hysteresis is as simple as adding a high value resistor from the comparator output to the positive input. That will cause a small temperature difference between the trip-on and trip-off points such that the system won't be oscillating. Your home thermostat with the mercury switch does this thru the mechanical action of the mercury moving from one side to the other, favoring tripping in the direction it just went. I once did a photographic temperature bath controller using latching instead of hysteresis. This was in 1980 before microcontrollers were cheap, available, simple, and easily programmed as they are now. I wanted the temperature regulation to be tight, so instead of hysteresis I fed the output of the comparator into a flip-flop. That flip-flop got clocked once every 64 power line cycles, and its output controlled a relay which turned on a commercial off the shelf immersion heater. Regardless of how the comparator might be oscillating, the output only switched at most a little less than once a second. The system worked very well, and I used it for years until wet process photography went the way of the dinosaur.
H: Programmable power supply I have been assigned to design a kind of programmable power supply. Can't decide on a way to make it. Need help with this. This is a high level block diagram of the required system: How it works (How it should work) The system will be given 0 to 10 Volt variable input, which decide output voltage. The output should be proportional to the input. So that when input is Min, output is also Min (i.e. 0v), when input goes to Max, output also should be Max (i.e.24V). Simply, if the input voltage is V_I, then the output voltage should be (24/10)*V_I The output is drawn from the systems power supply, not from the input voltage. (Actually input and output should be isolated.) I hope that part is clear. Then there is another input (input 2). Let’s think about it as a Potentiometer. So that its value can vary between two values, for the sake of explanation, lets say it changes between -10 and +10. Its role is like this. (I’ve mentioned it as tolerance.) Output value is decided from the input 1. That value is changed a bit around the original value by this input 2. For example, if output is 10V now, I can increase it a bit by rotating my preset clockwise. Or decrease it a bit by rotating it counterclockwise. Maximum change, lets say, will be 10% of the set value. That’s it. I tried to explain the thing to the best I can. If any clarifications are needed please ask. This is the requirement. I’m very good at microcontrollers, But not much experienced in electrical side. I thought a lot to make this using microcontroller. May be there is, but can’t figure out. But it doesn’t need to be microcontroller-based, this is an actual requirement. So if there is any way to achieve this, then I’ll move to that. Please share your knowledge. If anyone can point me in an exact direction that will be much appreciated. AI: What you want is called a power supply amplifier or PSA in the business. You are essentially looking for a power amplifier with a gain of 2.4, although it only needs to drive in one direction but has to be isolated. Think of how a power supply works. At some point there is a feedback signal indicating how high or low the output is and a reference that indicates what that feedback signal should be. The controller looks at the difference and tweaks the output up or down. You can control the output by changing the reference signal. Isolation makes things more difficult. Sometimes this comparison to the reference is performed on the isolated side with a simple digital high/low indication transmitted back thru a opto to the hot side. The system still works as I described, but the reference is on the isolated side which is not where you want it. This leaves two possibilities. Communicating the reference to the isolated side and doing the comparison there, or communicating the actual output level to the hot side and comparing it to the reference there. Both schemes have some merit, but I'd probably pick the first in a DIY project. The best solution is to simply buy a PSA if you can find one with the right characteristics.
H: WiFI signal level in dBm I have a outdoor WiFi connection, each module has a 5dBi antenna, today I extended with a 16dBi directional external antenna. before it was -65dBm the received signal level now it's -83dBm, I'm a bit confused I waited to increase the value, like -30dBm? Is it a better value? AI: No. -83 in fact, is a borderline. For example, in wpa_supplicant software -90 is the threshold on which wifi client will start aggressive scanning at the expense of power consumption. -95 in reality is the level when no traffic will happen. If you are measuring from the place where your new directional antenna is pointing to, then something is wrong.
H: HOA0901 Wheel Encoder Circuit I am trying to use the wheel encoder mentioned in the circuit but somehow i can't manage to understand why there is a full voltage drop in the IR led and why the resistors are not limiting that voltage drop, considering that in "ohmic" terms my circuit should work. I would like somebody to help me pin what i am doing wrong The datasheet is http://sensing.honeywell.com/index.php?ci_id=50399 In the electric characteristics the datasheet says that the forward voltage should be 1.6 V@20mA and the supply of detector should be between 4.5 and 5.5V@7mA So to use the resistors i have at hand the circuit is in the following attachment. For the IR led i connected it to a 5V source with a 220hm resistor and to the receiver 47 + 47 Ohm resistors. Also i am connecting the A and B channel outputs to an atmega328 directly as the datasheet says the HOA0901 has internal pullups. I also set the atmga328p in input mode. Thanks AI: If you are measuring 0V across your resistor, then it looks like your LED is blown (open circuit) V / R = I, so 0V * 220 = 0mA. This means there must be a high impedance in series with the resistor (i.e. open circuit LED)
H: MicroSD flash block size I'm working on a low-power application with data storage on a microSD card. In the interest of minimizing power consumption, I'm planning to buffer data to RAM before writing, and I suspect that the optimal buffer size would be an integer multiple of the flash block size in the SD card, as this would minimize/eliminate high-power/slow block erase/rewrites. Unfortunately, I've had little to no success finding any info about flash block sizes in SD cards; the best I've found is that they apparently range from 16Kb to 2Mb. Naturally, being a consumer product, manufacturer tech details are practically nonexistent. Is there some esoteric command in the SD spec or something I can use to determine flash block size? Is this approach unnecessary/overkill/otherwise pointless? Whoops, found it: SECTOR_SIZE (erase sector size) in the CSD register. So I guess a followup is whether or not it's useful to sector-align writes for power saving purposes, but at the very least I'll probably be able to measure that. AI: By aligning your block writes with the flash card blocks you might increase the write speed since you'll only be writing one block rather than two or more, and thus decrease the amount of time the card has to be powered. Further, one flash block write will consume less power than the two that would be required if you wrote across a boundary. However your greatest power savings will be in communicating with the card as fast as possible so you can power it for as short a period of time as possible. Even though a flash block write consumes quite a bit of power, communicating slowly with the card and leaving it powered during communications will eat quite a bit more if you don't speed up communications.
H: Mylar Paste Stencils - Paste Mask File Conversion I want to cut some cheap mylar stencils from mylar for quickly assembling some fine pitch SMT designs. I have access to a laser cutter for this purpose. The laser cutter accepts various file types... unfortunately g-code or RS274x is not one of them. Does anybody have any options for converting output from Altium to a DXF? Even better, with an option to offset the lines by half the kerf of the laser? Though I can always do this manually using a CAD program... EDIT: For extra credit :), a solution to go straight from RS274x to DXF (free) would be desirable as well. Sometimes I let the board house panelize and all I get back is the gerbers. AI: When editing a layout in Altium, you can do "File->Save As", and then for the file type choose "Export AutoCAD files". This enables saving as either DXF or DWG and gives a few other options as well:
H: What is the simplest sound generating circuit? I'm relatively new to electronics, and have no formal training other that what I picked up through my electrical engineer father. I solder well, can read schematics, have assembled kit projects with a rough understanding of how all the parts work, and know basic electrical terminology and principles. Ohm's law is about as far as my electical math skills go. So while this may seem like a very basic question to a more experienced and better trained person, please bear with me. I spent a couple weeks messing around with some LEDs. I started by just hooking one up to my power source. Then, what happens when I add a resistor? What about a capacitor? what about resistors in parallel vs. series? From just playing with my breadboard, I now have an LED that blikcs randomly. Impressive? Nah...but I figured it out myself, and feel that I truly understand it. Now, I want to design a synthesizer from scratch to give myself an understanding of how specific components affect sound. Starting from the most barebones circuit that can make a noise, I want to add a pot, then some capacitors, then some 555s...you get the idea. I just want to start with the basics and play around to see what happens. Finding that circuit is proving to be quite difficult. I'm looking for a circuit more complex than hooking a speaker directly to a battery but less complex than http://www.musicfromouterspace.com 's Wacky Sound Generator (which, while simple compared to a real synth is still a lot more complex for me to truly understand what component A vs. compoent B does). In essence, I want to find the sonic equivalent of Battery-to-Speaker and start playing with what can happen in between. Electronics golf: what can produce sound with the minimal number of components? AI: The 555 is a good way to start making tones in a speaker. I suggest you make a simple oscillator using one, before you attack projects that use several of them. Also, we had a question, What is the simplest way to make an oscillating signal? That turned out to be an inverter gate with feedback.
H: High-side current monitor to measure microamps I am trying to sense very low current (50 - 200 μA) on the high side of a circuit, and was considering LTC6102HV for the job since it can be "floated" to 105 V. My problem, however, is that my circuit is not floated to +105 V but to -105 V and the current does not flow to the ground. If I understand it right, I cannot use the LTC6102HV. Here's a picture that illustrates the problem, I am trying to measure Isense through Rsense. I can probably just use a diff amp (e.g. AD629), but since I am measuring microamps, I am not sure if it is the right way to do it. Any ideas? AI: Actually the AD629 you already found should work for you. If you look at the web page for it you will see that it is categorized under 'Current Sense Amplifiers'. Its special feature making it so usable is the capability to amplify correctly even with high common mode voltages. This means that both inputs have a voltage with respect to ground, but only a small difference. This is exactly what you need for a current sense amplifier. When you measure micro amps, the current sense resistor you want to use might be about 1kOhm, which would give you 1mV/1µA (without amplification). You might want to look at Dave Jones uCurrent project as an example for how to measure even nano amps, and for a discussion of how the size of the sense resistor might affect your circuit (though I doubt that even 1V voltage drop will affect your circuit when it is powered by 100V...) Another option you can consider is using a isolated OpAmp like the AMC1200. You would need to power directly from the rail where you are measuring, so you have no common mode voltage. The isolated output allows you to use it at any other place of your circuit without any level shifting.
H: Arduino SPI limit Is there a limit to how many slaves you can control with a Arduino board using the SPI bus as long as you do not run out of pins? Uno, for example, has 14 digital I/Os. So theoretically, I could have 11 slaves if I wanted to since MISO, MOSI and SCLK will be shared and there would be 11 different CS pins. I was wondering if anyone would run into any practical problems long before controlling 11 slaves. ( Although I will not use MISO ) I plan on controlling six 12 bit DACs for a project using UNO using the SPI bus. Is there something I need to be aware of? AI: The number of SPI slaves is not limited. In fact, you can add digital muxes (multiplexors) and control more slave devices than you have digital pins on the Arduino. However, the SPI was design for communication over short distances within a box. So, the physical size of the bus can become a problem (bus capacitance, EMI). If you have to make a long-distance ruggedized SPI, there are application notes on the subject: Extending the SPI bus for long-distance communication.
H: How to use Altium Buses? I am new at Altium, I am trying to connect 8 wires but using a bus. I have read about this in Altium's web page but I doesn't explain too much about how to connect buses on the way I need. I want to connect in this way: I know pin count doesn't match on both sides but that is my idea. I would like to connect the buses whit a Port or Netlabel if it were possible. I have tried on this way: But it is not being connected when I import on my PCB design. How is the right way of doing this ? AI: I would use Net Labels to connect buses together. Ports are mostly used when connecting nets from different sheets. As The Photon says, the 8 signals from the left IC must have the same net label as the 8 signals from the right IC. Your bus connection should look like this: Buses are used to graphically represent how a group of related signals, such as a data bus, is connected on a sheet. They are also used to collect together all the signals belonging to a bus on a sheet and connecting them to a port to enter or leave a sheet. In this instance, they must have a net label of this format: D[0..7]. When it comes to buses, the only way to establish connectivity between a bus and the individual lines within it, is through logical connectivity between net labels. The use of bus wires and bus taps is merely a visual aid. Connectivity will be establish regardless of whether they are present or not. For more information about buses: Connectivity and Multi-Sheet Design Altium Training Video: What is the best way for me to wire up my schematics?, video #2
H: Why do batteries not last as long in a cold environment? I know that batteries don't lase as long when they are used in a cold environment, but why is that? For normal conductors resistance decreases as temperature goes down, so shouldn't the internal resistance of a battery go down as well, making it more efficient? I know that the resistance of semiconductors increase as temperature goes down, but most simple batteries (such as Pb-Acid, NiHm, and Li) don't have any semiconductors in them, do they? AI: Batteries don't rely on semicondutors, correct. They do, however, store energy chemically, and rely on chemical reactions to create electron flow. Note that "last as long...in a cold environment" can be taken two ways--discharge duration under load or total useful life. I'm assuming that you meant time under load, as nearly all batteries benefit from an extended useful life if stored at low temperatures. Most batteries (ignoring a few more exotic flavors) use two metallic or carbon electrodes, separated by an electrolyte. Current is produced by ion exchange (oxidation/reduction reaction) between the electrolyte and the anode and between the electrolyte and the cathode. At reduced temperature, the internal impedance of the cell increases and the rate of ion exchange is reduced because the necessary chemical reactions progress more slowly. This causes more power to be dissipated in the cell rather than in the load, and also reduces the peak current available from the cell at low temperature. The cell doesn't last as long under load because less chemically stored energy can be converted to useful electrical energy. This resource may be of interest.
H: Using electric motor to adjust blinds? So I'm trying to do some insane home DIY with my room blinds. I'm trying to make them adjust (go up and down) automatically. Now for this, obviously, I will need a motor. The blinds I'm working with don't require much strength to pull down, but a fair bit to pull them up (using the little string/cord), So I'll need something fairly powerful, but slow. I'm taking a look at a few gear motors on this site, but I have no idea which one would be right to use for this kind of task. Could anyone help me out? AI: Using electric motor to adjust blinds The blinds I'm working with don't require much strength to pull down, but a fair bit to pull them up (using the little string/cord), So I'll need something fairly powerful, but slow. Cord pull in kg ~= (Torque in N.cm)/10 on a 1 cm RADIUS = 0.8" dia drum Cord pull in pounds = kg x 2.2 Bigger drum = smaller pull. Smaller drum =- bigger pull. Torque on your chart is given in N.cm (chart image at end) kg.cm ~ N.cm/10 1cm radius = 2cm diameter ~= 0.8 inch. So, if you have a 0.8 inch diameter or 2 cm diameter drum for the cord then the cord pull in kg = N.cm/10. So a 20 N.cm motor will provide 2 kg cord pull. Pounds force ~= kgf x 2.2 Kg to Pounds: Double pounds, THEN add 10%. eg 2 kgf -> 2 x2 = 4, +10% = 4.4 lbf 5 kgf = 11 lbf etc. Looking at their 1st line of motors you have torques including 25, 50, 100, 300, 900 N.cm = 2.5, 5, 10, 30, 90 kg.cm = same cord pull on a 1cm radius = 2cm dia = 0.8 inch dia drum. = 5.5, 11, 22, 66, 198 lbf cord pull. Use a fishing scale (as DeanB suggests) or tie on bottles of water or exercise weights or ... to get some idea of needed oull. I'd expect 2.5 kg to be low, 10 kg to be getting OK, 90 kg to be tearing the cord off. YMMV. Double drum dia = half cord pull. Halve drum dia = double cord pull. DIY You can make your own rotary to linear gearboxes using threaded rod. Rotate a captive nut on a rod and rod moves. Rotate a captive rod in a nut and the nut moves. Simple pulley speed reductions from motor to rod increase overall effective reduction.
H: What's the max discharge (in "C") of a Pb-acid and LiFePO4 (lithium iron phosphate)? I know that lead acid batteries can handle massive loads, and they are even used to power houses with solar panels, but what is the maximum safe discharge for one of these? I've done some Googling but I can't seem to find a number. And, of course, it's not going to be the same from battery to battery but I'm sure they're all in the same ballpark. Lately I've been seeing more and more LiFePo4 batteries come into the market as competitors for Pb-acid batteries. I personally don't own any because they are about 4x as expensive, but what sort of discharge rates can these handle? AI: (1) Battery university will supply reasonably good answers to many battery questions. "Lead acid" is a very broad description and there are many subtypes and special types that fall under that description. The terms VRLA, AGM, flooded, calcium ..., pure lead, spiral wound, gel, traction, deep discharge, automotive, SLA, boost, float, CC, CV, ... all are descriptors of specific aspects of lead acid battery technology which also have implications for charge and discharge rates, longevity, temperature range and best applications. This is not to say that th field is 'inscrutable' but that rather, narrowing down the application area within those covered by lead acid is liable to allow a more concise and useful answer. (2) Lead Acid. To complement the above site, this superb Yuasa sealed lead acid battery application manual addresses this and many other questions related to lead acid batteries. Fig 1 shows the performance of a wide range of capacity batteries under a range of loads. The rated capacity is given at the 20 hour discharge rate. Fig 1 gives discharge curves up to about 3C rate (eg 30A for a 10Ah battery) but also shows that capacity decreases rapidly with increasing discharge rate. eg a 10 Ah battery at the 20 H rate = 10Ah/20 = 500 mA will give about 0.5A for 20 hours = 10 Ah and 5.9A for 1h = 5.9 Ah and about 32A for 6 minutes = 3.2 Ah ie you can run this battery at increasingly high rates with decreasing energy return. These curves and this document are for AGM (absorbed glass mat) that have no gel and no liquid acid present. Results are different for flooded and Gel cells but this gives some feel. Use of "pure lead" electrodes give much higher discharge current capability at the loss of some capacity and some batteries use a mix of electrodes to give a certain amount of capacity and high discharge and a higher amount at lower discharge rates. A 40Ah automotive battery will generally happily crank at around 400 A and may be able to be persuaded to supply 600A under protest. (3) LiFePO4 / Lithium Ferro Phosphate Varies quite widely. Charge 1C - 10C Discharge 1C / 10C / 25C / 50C! ie varies widely Lead acid batteries generally offer the lowest capital cost per initial Ah capacity of any usual technology. LiFePO4 batteries generally offer the lowest whole-lifetime cost of Ah capacity x cycles of any usual technology. ie, across the lifetime of the battery a properly designed and operated LiFePO4 battery is substantially cheaper than a Lead acid system. As a guide, the only reason to use a LA system in preference to liFePO4 is lower up front cost. LP offers very many more discharge cycles, smiles in the face of deep discharge, offers superior high and low temperature performance, higher charge and discharge rates, and more. Actual charge and discharge rates will vary by manufacturer but discharge at 10C or 20C is common. Some specify less - say 5C. LiFePO4 cell - up to 25C Example batteries - brief specs available Some claim A123 18650 cells can be run at 50C discharge !!!!!!!!!!!!!!! eg here Caveat Emptor / YMMV Graphs A123 at 1/14/16 C Wikipedia LiFePO4 BUT !!! Charge C/3, discharge < 1C 90Ah, 1500 cycles ! DO NOT TRY THIS AT HOME !!!! :-) Youtube LiFePO4 short circuit demonstration !!! . Trying this with same size LiIon or LiPo would produce a "rather different" result.
H: A quick question about TFT LCD Can I use this 1.8" TFT LCD to make it show graphic? Or all the TFT LCD can display graphic? AI: Yes, you can draw graphics on this display. You can draw graphics on any display that is (individually controllable) pixel based, i.e. it mentions a resolution, something like 128 x 160 in the specs. They are referred to as "Graphic" displays. Common types include STN, TFT, OLED. The other common type of display is usually referred to as "Alphanumeric", and lists a spec like 16 x 2 (characters x lines) With these you can only display letters/numbers. Most Alphanumeric displays are STN (Super Twisted Nematic) based.
H: Use sheet entries on Altium I am trying to make a sheet entry to use ports to connect devices in different sheets as explained in this image: But I am getting an error from Altium saying: Sheet Entry RB[0...7] Warning: Nets whit multiple names Error: Nets whit possible connection problems Of course, nets are not being connected on the PCB. It is my sheet entry: As you can see there is a red line below RB[0...7]. I want to connect a bus between the two sheets. If I put a simple pin instead of a bus I get the same error so I suppose the problem is in the sheet entry and not on the other sheets. My project looks like: Thank you for your help :) EDIT: Esquema PIC.SchDoc: Entrada Analizador Logico.SchDoc: Settings: PCB I can't see any differences between your examples and my sheets SOLUTION @Fake Name answer was ok, you have to name ports and net labels as RB[..] not RB[...] (2 points instead on three) and you have no put a Port in each bus AND a net label also whit the same name in order to connect them. AI: Can you post your sub-sheets? From looking at what you have posted, I think you may have a typo in the entry: RB[0..7]. You typically get the red line below the entry when it is not correctly tied to a port on the child-sheet. Right-click on the sheet symbol, and select "Sheet Symbol Actions" -> "Synchronize Sheet Entries and Ports" Anyways, I created a simple, minimal test schematic to do what you are doing: Top Sheet: Sheet 1: Sheet 2: Project Hierarchy: And it properly connected the nets across the different schematics: For what it's worth, I am fairly sure you have to both name the buses with net-labels on each child-sheet, and name the ports. Also, the bus name and wire names have to have the same prefix: For example, a set of wires HERP0 HERP1 HERP2 HERP3 HERP4 has to be in a bus named HERP[0..4]. It may also have to be zero-indexed (i.e. start at 0, rather then 1), but I'm not totally positive on that. Also, I do indeed get the "Net NetName has multiple names" warning, but it's just that, a warning. You can turn the warning off, or just ignore it. I tend to leave it on, and before I have a board produces, go through all the warnings and make sure that I intend for whatever they refer to to be that way.
H: Transformer winding ratio vs actual winding count Output voltage of transformer depends on ratio of winding count on primary and secondary coils, but is there an impact on transformer performance by actual winding count? Say, i want to have 1:2 ratio, i could wind 10:20 or 100:200 windings. In general, more windings - bigger the resistance, inductance and cost. Is there any point in winding more or is winding count kept to absolute minimum? How minimal winding count is determined? AI: The induced magnetic field is proportional to ampere-turns, that's current times number of turns. Electrical energy is converted to magnetic energy in the core and back to electrical. The core must be big enough to hold that without saturating. For a 100 VA transformer you want to transfer more energy magnetically than for a 10 VA transformer. The 100 VA is larger because it has more turns to build up a stronger field, and also needs a bigger core to avoid it saturating.
H: What wattage should a headphone amp be? I was at a local surplus store today and I got two LM386N ICs. I thought I could make a really simple headphone amp out of these. But I have no idea what the wattage of a normal headphone amp is. These LM386 are rated 325 mW at 8 Ohm, which should be about 81.25 mW at 32 Ohm load. Is 81.25 mW a reasonable power for a headphone amp? How does that compare to, say, a Laptop's 3.5 mm jack's power; how about an iPhone's? AI: Alfred already explained that for a voltage source (which an amplifier is) you'll have less power at higher impedance, because the current decreases. If your amplifier would be a current amplifier you would get a higher power, because the same current in a higher impedance will increase voltage. Citing from this document, because I can't explain it better myself: Headphone manufacturers specify a “sensitivity” rating for their products that is very similar to loudspeaker sensitivity ratings. For loudspeakers, the standard is to apply 1 watt and then measure the sound pressure level (SPL) at a distance of 1 meter. For headphones, the standard is to apply 1 milliwatt (1 mW = 1/1000 of a watt) and then measure the sound pressure level at the earpiece (using a dummy head with built-in microphones). Sensitivity is then stated as the number of dB of actual sound level (SPL) produced by the headphones with 1 mW of input; headphone specifications commonly refer to this by the misleading term “dB/mW.” What they really mean is dB SPL for 1 mW input. Think about these sensitivity definitions a moment: headphone sensitivity is rated using 1/1000 of a watt; loudspeaker sensitivity is rated using 1 watt. So a quick rule-of-thumb is that you are going to need about 1/1000 as much power to drive your headphones as to drive your loudspeakers since both of their sensitivity ratings are similar (around 90- 110 dB SPL). For example, if your hi-fi amp is rated at 65 watts, then you would need only 65 mW to drive comparable headphones. (Actually you need less than 65 mW since most people don’t listen to their loudspeakers at 1 meter.) And this is exactly what you find in hi-fi receivers—their headphone jacks typically provide only 10-20 mW of output power. Take another moment and think about all those portable tape players. They sound great, and loud. Why, you can even hear them ten feet away as the teenage skateboarder that ran over your foot escapes. Power output? About 12 mW. (emphasis by me) Thanks to marketing numbers of 100 W amplifiers most people don't realize this, but 1 W is a lot of power for a good speaker. It can give you more than 90 dB SPL at 1 m. At full power a 100 W amplifier just won't break the windows. Claiming to play 2000 W at full power in your living room is nothing to brag about: it just says that you have lousy speakers :-). 2000 W in 92 dB speakers delivers 125 dB SPL, which will turn you deaf in no time. (That may be OK, once you're deaf it also stops hurting your ears. :-) Further reading Understanding headphone power requirements
H: What is "RFIS" tag I read somewhere about "RFIS" tag. I know what is "RFID" but does something called "RFIS" exist? I tried to search but all suggestions are RFID related. Would be nice if you have any clue share it please. It could be just a mistake, so just simply it should have been RFID! or maybe this is something very new and no one knows about it! This is a part of title: "a body area network composed of compass and tilt sensors and RFIS tags" AI: Almost certainly a typo. Note that the s key is right next to the d. But it may also refer to the new "Radio Frequency ISentification" technology, of course :-). edit after your question update The abstract talks about "intelligent guide to help blind people to solve puzzles". It's easily imaginable that RFID could be used to identify the puzzle pieces.
H: CE# pin pulsed low by ARM when configured I have an STM32F2 that has a "Flexible Static Memory Controller" (FSMC). For some reason, when I configure the Chip Enable (CE#) pin of my PSRAM as a FSMC pin, the STM32 will pull the pin low (by default the pin is pulled high with an external pull-up). The reason I ask is because this CE# pulse maybe explain why the very first read/write operation fails on my PSRAM. Why is there such a pulse? Does STM have detailed documentation for it's Flexible Static Memory Controller explaining this behaviour? AI: It looks perfectly normal to have \$\mathrm{\overline{CE}}\$ low for an external memory controller. The external memory will ignore all signals if \$\mathrm{\overline{CE}}\$ is high. \$\mathrm{\overline{CE}}\$ is often logically combined with the output of a partial address decoder to avoid several devices simultaneously accessing the databus. You probably won't have pin conflicts with GPIO as long as you don't change the pin's function from FSMC to GPIO.