uCurrent v2.0 - Page 1
Forum section: electronics / projects

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 10:16:49 am
content: Hi Dave, hi guys,I'm not sure if this is the right forum for this, so I apologize in advance if it is not.In EEVBlog RAW Dave mentioned some features and changes he would add to the uCurrent, if he were to design it again. I don't have a uCurrent yet, and apparently they are sold out again. Plus, shipping to my country would surely be f***** expensive.So I thought I build my own, since it is open source. But, if I build my own, I could very well improve if it, if I'm at it. So I thought we could collect some ideas to improve the uCurrent.1) Dave's new feature was a automatic power-off (or a bigger battery) using a micro (he mentioned putting in "some intelligence"). My choice would be a MSP430 G-series. Very low power and very affordable.2) I would like to see over current and over voltage protection.3) Having a micro, auto-ranging can be done, eliminating a switch (which is not cheap).Also Dave said he would use "another technique" so the uCurrent can measure lower currents. I presume he meant an feedback ammeter?So what do you think? What features would you like and how would you implement them, keeping complexity and price low?Do you have a uCurrent? What would you improve? What does annoy you?I hope you have many ideas!

author: BravoV
author_rank: Super Contributor
timestamp: December 30, 2011, 10:26:01 am
content: Quote from: lai3IeSh on December 30, 2011, 10:16:49 amAbout the over current protection feature, I think its not an easy task and can not be done cheaply.There is a good thread discussing why current measurement has this design challenge even at high end multimeter ->https://www.eevblog.com/forum/index.php?topic=5513.msg71871#msg71871

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 10:37:34 am
content: Why not? What's wrong with a fuse? Or, if you use a transimpedance amplifier, you can just use an opamp with a short-circuit proof output - if there is one suitable for our task. Or am I missing something?Thanks for the link, I'm reading it right now and it is very interesting.Edit: I read the thread and it seems fuses are not an option because they would introduce too much resistance and hence cause higher burden voltage. I didn't think there.Also it was mentioned a transimpedance amplifier would go to about 2mA, because of the low-power nature of the device. A mixed approach of a shunt in "high" current measurement and a transimpedance amplifier for "low" current measurement was suggested. I think that is sensible.I also just thought of using a comparator + FET for over current protection. If the current exceeds the currently selected range, the comparator switches the FET off. But maybe that's just over-engineered.

author: EEVblog
author_rank: Unknown
timestamp: December 30, 2011, 10:56:31 am
content: Quote from: lai3IeSh on December 30, 2011, 10:16:49 amWorst case shipping is about $12-$13 or so.Dave.

author: Psi
author_rank: Super Contributor
timestamp: December 30, 2011, 12:21:04 pm
content: Quote from: EEVblog on December 30, 2011, 10:56:31 amDepends what country he's in, there maybe bribes required to stop the package from "disappearing".(Not all countries have honest postal systems)

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 12:43:22 pm
content: No, it's Germany, usually no bribes required. But my experience was, it's pretty expensive to get a package from the US to Germany. UPS would have taken 60 bucks or more.

author: Bloch
author_rank: Unknown
timestamp: December 30, 2011, 12:43:38 pm
content: Or he did see.QuoteI must say i was surpriced that Dave did send uCurrent outside his country. After reading the quote on the shop. I know it was on a other page. Anyhow there seems to be a supply / demand problem for the uCurrent

author: Unknown
author_rank: Unknown
timestamp: December 30, 2011, 01:12:45 pm
content: Quote from: lai3IeSh on December 30, 2011, 12:43:22 pmUPS is extremely expensive. USPS starts at a few USD for first class letter mail, and small packages are $10 or so. Usually cheaper than the other way around. My guess is that Australia post is similar.

author: metalphreak
author_rank: Frequent Contributor
timestamp: December 30, 2011, 01:33:48 pm
content: Quote from: lai3IeSh on December 30, 2011, 10:16:49 amHaving a micro doesn't eliminate the switch. The switch is there to change the current path through different sense resistors.http://www.alternatezone.com/electronics/ucurrent/uCurrent%20Schematic.png

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 01:49:12 pm
content: Quote from: metalphreak on December 30, 2011, 01:33:48 pmNo, not directly, but instead of a (mechanical) switch you could use MOSFETs, driven by the micro. At least that was my first idea. Of couse, this is not a good idea, when a shunt is used, because Rdson is too high/unkown, but in a transimpedance amplifier one could maybe switch feedback resistors of different values in or switch in different gain resistors, if a gain-configuration is used.I don't know if that works. The first problem is the Rdson, which will introduce an error. The second problem is driving the MOSFET. The third problem is polarity - the body diode of the MOSFET will always conduct in one direction, so an antiparallel-configuration is needed if current-sensing in both direction is required. That makes driving the MOSFET a little bit harder.

author: metalphreak
author_rank: Frequent Contributor
timestamp: December 30, 2011, 02:13:05 pm
content: I don't really think auto-ranging is a necessary feature. Once you engineer in the mosfets to achieve the same level of accuracy and control, you've far exceeded the cost of a 60cent switchThe idea of the uCurrent is to be as simple as possible to get the least possible burden voltage. Once you start making it complicated you might as well just use the multimeter current reading. The current sense resistor is 10milliOhm on the mA range, and if you read Dave's article the switch contact resistance starts to affect the burden voltage. The RDS(on) resistance of a mosfet will probably make it useless in this situation. Also don't forget you only have 3V supply on the board which limits the type of mosfets you can switch with it.I'm not saying auto-ranging can't be done, but it would require a different approach to the current sensing part of the circuit, rather than trying to retrofit something in place of the switch.http://www.nxp.com/news/press-releases/2011/06/nxp-small-signal-mosfets-set-new-benchmark-in-rds-on.htmlTake these mosfets from NXP. Still 18mOhm at Vgs of 4.5V (remember the uCurrent only has a single 3V cell). 23mOhm down at Vgs = 2.5v. Variability in the resistance doesn't really matter, since you are still only reading the voltage across whatever sense resistor, but the burden voltage increases significantly again on the mA range.So yeah, mosfets could work I guess. Those NXP ones are $1.20ea in large volume. I'm sure there are more suitable ones available, they were just the first hit in google for low RDSon

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 02:22:38 pm
content: Well, you are talking about sensing across a shunt. As I said, it makes no sense to use MOSFETs there. But in a transimpedance amplifier configuration your feedback resistor would be in the range of 1k to 100k. An Rdson of, let's say 6? is an error of 0.6% for 1k. If you are using gain resistors, you could switch those and select their value to be in 10s to 100k?s range.But i suppose you are right, auto-ranging seems a little bit too complex. But, I'm not retrofitting. I want to use a transimpedance amp in the uA/nA range and a shunt in the mA range. Or maybe remove the mA-range completely. As of right now, I'm just collecting ideas.

author: Bloch
author_rank: Unknown
timestamp: December 30, 2011, 02:31:15 pm
content: Quote from: lai3IeSh on December 30, 2011, 02:22:38 pmNo not at all just use a relay.But a relay is not cheaper than a switch. As you wanted in you first post.Quote from: lai3IeSh on December 30, 2011, 02:22:38 pmNo problem this is also the most fun / learning part.

author: metalphreak
author_rank: Frequent Contributor
timestamp: December 30, 2011, 02:41:21 pm
content: Wouldn't a relay draw too much current though? As it stands, Dave gets ~200hrs out of a cell, or 50hrs with the LED on.There's no visual reminder that you've left the device on if you don't have it in battery test mode. If you leave it on and put it away, it only take a week or so to drain the battery. Instead of an auto-power off, perhaps just add a simple circuit to flash an LED once every XX seconds? Dirt cheap npn transistor, capacitor, and a resistor is all you need(whoops nevermind need something like a 12v source to use the Esaki effect)

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 02:46:55 pm
content: Quote from: metalphreak on December 30, 2011, 02:41:21 pmThen you would have to stare at it for XXs to be sure it is off (or on). Or you put in 2 AAs, or 2 AAAs. I think I will use a mobile phone battery and be done with it. They are cheap and have high capacity, although NiMH or NiCd in AA or AAA form will do too.

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 02:50:41 pm
content: Quote from: Bloch on December 30, 2011, 02:31:15 pmA relay would be ideal regarding on state resistance. I wonder if there exist relays working with 1.5V and a few uA. I think not

author: metalphreak
author_rank: Frequent Contributor
timestamp: December 30, 2011, 02:53:38 pm
content: Quote from: lai3IeSh on December 30, 2011, 02:46:55 pmAh no, I meant just as a small improvement to the original design. Just in case you leave it in the on position, the led serves as a reminder to turn it off, but doesn't constantly suck out power like it does in the On (battery check) mode.AAA batteries would definitely fit inside the originally spec'd UB5 jiffy box (83 x 54 x 31mm). AAA battery is only about 45x10mm

author: Bloch
author_rank: Unknown
timestamp: December 30, 2011, 03:10:38 pm
content: Quote from: lai3IeSh on December 30, 2011, 02:50:41 pmsure there are ...... almosthttp://dk.farnell.com/omron-electronic-components/g6ju-2fsy-3dc/relay-smd-dpdt-3vdc-latching/dp/9899600It is a 3 Volt LATCHING relay. >> Give it one puls and forget it. So will only need power then change mode.And I cant remember why Dave did use the CR2032 and not like 2 D batteries in series ?. then you have like 12000 mAh instead of 225mAh

author: metalphreak
author_rank: Frequent Contributor
timestamp: December 30, 2011, 03:14:18 pm
content: Something like the MicroChip PIC10F320 could be a contender. It's only about 60cents, has a built in voltage reference, and 4 I/Os (one is input only, use it for A/D to measure batt voltage).The LF low power versions have an operating current of 25 uA @ 1 MHz, 1.8V, typical.Availability is a bit sketchy since its only just been released. Only PDIP and DFN versions for now.Link:http://www.microchip.com/wwwproducts/Devices.aspx?dDocName=en552961Configurable logic cell stuff seems interesting (but not in this application).

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 03:27:02 pm
content: Quote from: Bloch on December 30, 2011, 03:10:38 pmUh. I found that relay too, but I missed the latching. I will keep that in mind, thanks.Quote from: Bloch on December 30, 2011, 03:10:38 pmAs far as I can remember, he didn't like/found battery holders. They also would have to fit on the PCB since he doesn't like the batteries rattling around in the case. Glueing is ugly too. Maybe he just had a CR2032 and a holder handy, when he first build the uCurrent.

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 03:50:03 pm
content: Quote from: metalphreak on December 30, 2011, 03:14:18 pmWow. Thats almost an order of magnitude lower than a MSP430 (220uA @1MHz, 2.2V). However, I have no development tools/experience for/with PICs, so I will probably go with an MSP430 (or AVR ATtiny, which uses 25uA @1 MHz, 1.8V, idle and 200uA active).

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 04:46:40 pm
content: I made up an LTSpice circuit with over voltage/over current protection and a transimpedance amplifier.Overvoltage protection on the Opamp inputs is done with anti-parallel schottky diodes.Over current protection is done using two anti-serial MOSFETs, driven by comparator, which compares the voltage output of the transimpedance amplifier against a reference voltage and switches the MOSFETs off, if an over current condition occurs. I think I will replace the MOSFETs with 1.5V (I found one!) to 3V latching relay. The drawback is the on-state resistance of the relay of approximately 100mOhm or the Rdson of the MOSFETs. Missing is a hysteresis for the comparator, so it will not oscillate.

author: metalphreak
author_rank: Frequent Contributor
timestamp: December 30, 2011, 05:21:03 pm
content: I'm a bit of a PIC fanboiIf microchip has something that does what I need for a reasonable price I normally go with them. Element-14 has the PIC10F322-I/OT in stock (SOT23 +$0.87) so I'm going to order some of those and the other bits necessary. With that, I can remove the TI voltage monitor chip completely (-$1.20), as the PIC can do voltage monitoring. Also, since the rest of the circuitry draws (much) less than 20mA I should be able to power it directly from one of the output pins (effectively a low voltage cutoff so you can't take possibly bad readings).I had a bit of think more about the auto-ranging feature. I've realised that if this is implemented, you need some kind of visual display to the user about which range it's selected, otherwise you don't know what measurement units the meter reading is in. This means more power usage. Not such an issue if you use a better power source though.If you come up with something cool for the overcurrent protection that'd be awesome. Otherwise I'm just going to make a "uCurrent v1.1" with voltage monitoring/auto turn off

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 05:49:33 pm
content: Well, I suppose I am a bit of a PIC hater. But looking at this chip I have to admit I like it. Still I won't use a PIC as long as a PICKit is >30 bucks.You're right with the range indication for the auto-ranging. I haven't thought of that. Maybe I will use 3 LEDs, one for each range. Of course low current LEDs running at 1 or 2mA, or even less. I think I can live with that. The range indication also functions as on-LED.I wouldn't power the analog circuitry from a micro I/O-pin, because of the "digital dirt" it may be carrying. Possibly one could use a MOSFET to disable the analog circuit, but i think noise could be coupled in by way of the gate-source/gate-drain capacitance.There are Opamps which have a shutdown input, reducing current to less than 0.1uA. I don't know if there are low-offset types.

author: metalphreak
author_rank: Frequent Contributor
timestamp: December 30, 2011, 06:52:46 pm
content: Pin 1 on the maxim chip is actually a shutdown pin so I can just use thatDP3T switches are incredibly hard to find anywhere... Might have to just cop the $30 shipping fee from digi-key, and make sure I get all the other good stuff I can't get locally

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 06:59:00 pm
content: Well, someone said, they are "just" 60ct. But they are not.Maybe Dave can give some thoughts on improving the uCurrent.

author: Zad
author_rank: Super Contributor
timestamp: December 30, 2011, 07:13:48 pm
content: You want as little on the input probes as possible, preferably just input overload protection. When it gets down to the low uA (and even more so in nA and pA ranges) the leakage current can be problematic.Anyone wanting to make their own improved version could do worse than to start here, a transimpedance amplifier with input protection. Basically the op-amp applies feedback to make sure the inverting input is at the same potential as the non-inverting one, so burden voltage is almost zero:Offset (burden) voltage for the AD8638 circa 9uV. Offset current is <50pA.Yes, it is as simple as that. Note the range switching is done in the feedback, not in the sense wires. Depending on what feedback resistor values you choose, you will need to add capacitance to stop it oscillating. A buffer/gain amplifier following it would be wise.

author: Rufus
author_rank: Super Contributor
timestamp: December 30, 2011, 07:25:01 pm
content: Quote from: metalphreak on December 30, 2011, 06:52:46 pmIf you do the input like this you don't need a switch or other range indication.

author: EEVblog
author_rank: Unknown
timestamp: December 30, 2011, 09:46:19 pm
content: Quote from: lai3IeSh on December 30, 2011, 12:43:22 pmIn Australia, postage is entirely dependent upon weight. The uCurrent only weight 80g, so cost in minimal. A whole bunch of people just ordered from Germany, they paid $12.50.Couriers like UPS are very expensive.Dave.

author: EEVblog
author_rank: Unknown
timestamp: December 30, 2011, 10:07:43 pm
content: Quote from: Bloch on December 30, 2011, 03:10:38 pmElegance, board mounted. And I already had some of those CR2032 holders from another project.And it's trivial for anyone to solder on an external wired battery holder if they want too.Dave.

author: EEVblog
author_rank: Unknown
timestamp: December 30, 2011, 10:13:02 pm
content: Quote from: lai3IeSh on December 30, 2011, 05:49:33 pmGive me a break, it's $45, that's cheap, and no reason not to use PIC's if you want too.Dave.

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 10:23:27 pm
content: Yes, but a TI Launchpad is $4.30! Tenth of the price! Plus, I'm a student, so i don't earn the big bucks (yet).

author: EEVblog
author_rank: Unknown
timestamp: December 30, 2011, 10:36:46 pm
content: Quote from: lai3IeSh on December 30, 2011, 10:23:27 pmSo Microchip won't sell their programming tools at a loss, what's the problem with that?It's not like they are ripping anyone off, you do get more for your money.The Launchpad doesn't have a nice case, programmer-to-go, programmable target voltage supply, nor support their entire range of micro's.There is absolutely no reason to complain about the price of the PICkit. If you are strapped for every last cent, fine, use the Launchpad, nothing wrong with that.How much are you paying to build this uCurrent from scratch?Dave.

author: lai3IeSh
author_rank: Contributor
timestamp: December 30, 2011, 11:22:52 pm
content: I don't care if a company sells (some) of their products at a loss or not. I buy something if the price is right (for me).And I'm quite happy with the Launchpad. I don't need a case. I don't need a programmer to go. I program at my desk.I never felt the need to change the voltage of my targetI see your point though, PICKit has some advantages - but they don't matter to me. In fact, the big drawback for me is, that there is no gcc backend for PIC. Plus, the Launchpad is not only a programmer but also an eval/dev-board, and 2 micros go with it.As for the uCurrent: the money saved on a PICKit I can now spend on a uCurrentBut actually I didn't want to go into micro-religion, I'd rather hear your ideas/suggestions/criticisms/... for an enhanced/new/reimplemented version of the uCurrent. Your EEVBlog RAW show gave the impression you have some ideas or improvements, although you made clear you would not built another revision. After all you are the inventor, and I now I always have some improvements for my projects

author: EEVblog
author_rank: Unknown
timestamp: December 31, 2011, 12:54:39 am
content: Quote from: lai3IeSh on December 30, 2011, 11:22:52 pmSure, no problem, use whatever suits your needs, nothing wrong with the Launchpad at all.I was merely commenting on your suggestion that the PICkit3 was somehow overpriced because it's more than $30.QuoteI don't recall saying I would never build another version, my interests in projects change often.In fact, because of it's new-found popularity (or so it seems), I am considering a revised design, or a supplementary design.I could go into some details, but it would take way too long to explain things in any worthwhile detail.Dave.

author: BravoV
author_rank: Super Contributor
timestamp: December 31, 2011, 05:18:43 am
content: Just asking, how easy and how much they will cost you for those precision parts that are needed for this kind of circuit in Germany ? Those must be dirt cheap there I guess.In my situation, buying just small amount of these precision components is no big deal, its the crazy shipping chargethat made me not to build it my self, also not to mention every ucurrent was tested by Dave himself which I think adds another value.

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2011, 07:11:34 am
content: Could probably remove the battery altogether and add one or two of those tiny solar panels Dave showed in a previous vid.Use it to keep an ultracapacaitor charged up.It's not like ya use a microcurrent 24/7, its got plenty of downtime to keep the cap charged from your normal room lighting.

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 09:31:06 am
content: Quote from: Psi on December 31, 2011, 07:11:34 amI wanted to do that last year. But it does not work. I measured some solar cells and it's just not enough power. Remember: you are inside. You won't get anywhere near the specs for the cell, because the specs are for direct sun light - which you (usually) don't have in your lab. However, my cells were pretty small, so have a go for it!

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 09:42:58 am
content: Quote from: BravoV on December 31, 2011, 05:18:43 amWell, go to farnell.de and see for your self ... I think you can go to your local farnell-page and look for a product. Change the product URL from xx.farnell.com to de.farnell.com and then you know what that part will cost in Germany.I wouldn't say parts are dirty cheap in Germany, I would say parts are dirty cheap in the USFor example 1k 0.1% resistor goes for 9.8ct (€) + tax, so thats ok - put passive components are cheap everywhere.Everything integrated (precision opamps, for example) is not what would I consider "cheap" - but I don't know what they cost outside of Germany.Shipping is 8€ from farnell inside Germany, so buying passives for 10€ makes no sense.I design usually 2 to 3 projects, get the PCBs ready, and get them made in a batch and buy the parts all at once.

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 09:52:12 am
content: Quote from: EEVblog on December 31, 2011, 12:54:39 amWell I didn't say that. Actually, I think it is reasonably priced. But for my private collection I don't wan't to spend that money (right now). That is what I was trying to say. Sorry for the misunderstanding.Quote from: EEVblog on December 31, 2011, 12:54:39 amOk, my mistake.

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2011, 10:06:31 am
content: Quote from: lai3IeSh on December 31, 2011, 09:31:06 amQuick calculation says it would take something like ~30 hours to discharge a small 55F cap from 3V to 2V @ normal uCurrrent usage (600uA)Estimated normal hobby usage, maybe 3 hours per week, its going to take 10 weeks to fully discharge the cap.I would have thought even a low current solar panel could put enough back in to keep it topped up.EDIT: Looks like the ucurrent battery dead level is 2.6V, the cap would be down to that level if it was left on for 11 hours.Could easily fit two 55F caps though, they're 40mm x 18mm

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 10:40:06 am
content: So with a 3h/week 600uA pulsed operation, you would need a 10uA charge over 10 weeks to re-charge, if I'm not mistaken. Again, I don't know your specific cell, so take your uCurrent and measure the short circuit current the cell gives you in your lab. But open-circuit voltage of your cell in your lab has to be greater than the cap-voltage plus a (schottky-) diode drop. I'm very curious if it works for you.

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2011, 10:45:25 am
content: i don't have a cell at present. I was just thinking about those small cells that were in one of the blog eps.Found the videoLooks like they do 10-20uA indoors (~4 minutes in)

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 11:37:46 am
content: Well, 10 to 30 uA short-circuit seems promising. The question is, how much current the cell can push into a 3V charged cap + shottky diode. Maybe Dave can measure it?

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2011, 11:48:59 am
content: Quote from: lai3IeSh on December 31, 2011, 11:37:46 amyeah,Might better to use an ideal diode ic, to keep the Vdrop down.Though the IC might use more than it saves.

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 12:16:13 pm
content: A Bat54 has a forward voltage drop of less than 250mV @50uA. That is 12.5uW. I don't know if you can beat that.

author: BravoV
author_rank: Super Contributor
timestamp: December 31, 2011, 12:19:19 pm
content: Quote from: lai3IeSh on December 31, 2011, 12:16:13 pmHe is talking bout using mosfet + special ic to make a really low forward voltage diode, no native diode can beat that even germanium type.

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 12:22:16 pm
content: Sure but the IC will use power too. And the question is, if the power lost in the diode is smaller than the power lost in the ideal diode controller + FET.In my experience such controllers are used for high-current applications, not for 10uA.

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2011, 12:25:09 pm
content: Yeah, I just had a look at ideal diodes.Best one i found needed 40uA to run the chip. Not all that useful when you only have 20uA availableI wonder if ya could use a FET with a photodiode on its gate.

author: metalphreak
author_rank: Frequent Contributor
timestamp: December 31, 2011, 12:35:42 pm
content: What about LIR2032 batteries. 3.7v nominal lithium ion coin cell batteries. I've already built a lithium charger using a microchip MCP73831 powered by a mini-USB socket.They have about 35mAh of capacity, so around 50hrs of runtime. Charging at ~17mA (0.5C rate) would take 2 hours. Minimal extra cost for the charging IC and the usb socket.Discharge curve also shows terminal voltage to be >3.0v all the way down to its final usable capacity.While you're at it with the USB port, add an FTDI serial chip, and use serial comms on the microcontroller to sample the output voltage and send it to a datalogging app on a pc

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 12:36:21 pm
content: Depends on the Rdson you get for 2.5 to 3V Vgs.

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2011, 12:38:02 pm
content: Quote from: metalphreak on December 31, 2011, 12:35:42 pmYeah, that would be functionally better.I just get a kick out of using green technology and ultra capacitors due to their lifespan compared to batteries.

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 12:39:10 pm
content: Quote from: metalphreak on December 31, 2011, 12:35:42 pmCharging via USB is certainly an option, but I think it is abuse of USBYou could use standard AA NiMHs or LiPos and charge them in your standard battery charger - no extra cost except for the battery socket. And you probably would charge them seldom, because they have a high capacity. And they are cheap.

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 12:41:30 pm
content: Quote from: Psi on December 31, 2011, 12:38:02 pmI like that. Thinking greenYou could also use a royer converter to transfer energy wireless, so you would have some kind of "charging cradle".I wanted to do this with my phone (I have a big Sony Ericcson, so lots of space) for a while now, but I had no spare time.

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2011, 12:43:12 pm
content: Quote from: lai3IeSh on December 31, 2011, 12:39:10 pmYou could keep the supercapacitor, they charge up insanely quick (~instant) if you have enough input current.No need to wait for ya batteries to charge before you can use your ucurrent.

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 12:46:15 pm
content: Quote from: Psi on December 31, 2011, 12:43:12 pmBut watch out! USB allows you to take only 100mA, so you have to regulate your inrush current.

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 12:48:07 pm
content: Quote from: lai3IeSh on December 31, 2011, 12:16:13 pmI just found the BAT754, which has a Vf of maybe 180mV @100uA. The reverse leakage current is <150nA @3V Vr

author: Psi
author_rank: Super Contributor
timestamp: December 31, 2011, 12:56:23 pm
content: Quote from: lai3IeSh on December 31, 2011, 12:46:15 pmhehe yeah, going to need much more current than what USB is able to do if we want to charge it instantly.Probably need like a laptop powerbrick

author: lai3IeSh
author_rank: Contributor
timestamp: December 31, 2011, 03:37:38 pm
content: Well, here is what I could come up with.The LTC3535 is a step-up with Vin > Vout operation, so you can plug anything between 0.8 and 5V in.If you know your minimum battery voltage is above 3.6V or so, it would obviously better to use step-down converters. However, I started out with a single 1.2V NiMh or LiPo cell. The LTC3535 has two outputs with independent shutdown pins.1.8V for the micro and 3.6 with an LDO for the analog circuitry. Maybe I'll use a single 3.6V step-up for digital and analog (analog still with 3.3V LDO).The micro can shutdown the power supply for the analog part and itself. Using a tact-switch, /SHDN is pulled above 0.8V and the step-up for 1.8V micro is active. The micro then pulls /SHDN1 high and also /SHDN2, activating the analog power supply.There is no off-switch as of yet, the micro auto-shuts device off.The analog circuitry is a straight forward transimpedance amp, with selectable feedback resistor Rf (5k, 50k, 1M).All currents are converted to a 2mV to 200mV range as noted on the circuit. I didn't want to make the output of the transimpedance amp too small, so the offset voltage of the gain amplifier wouldn't matter much.I'm not happy with that many switches, maybe it is possible to reduce the number by smart routing of the signals. I think I'll use analog muxes/switches, with less than 5 Ohm on-resistance, so it is negligible. I know, I'm a hypocrite, because the analog switches/muxes cost mor than the mechanical ones.The switches are controlled by the micro, which also has 3 LEDs indicating the current range, so you can interpret your DMM output.I don't know what to do with the 2mA-range. Using a 1Ohm feedback resistor forbids an analog switch. Using 500 or 50 Ohm Rf requires another voltage divider.Also, I guess in the uA/pA range guarding is required, and I didn't look at the leakage of the protection diodes either, nor did I calculate the required power.I'd like some thoughts/suggestions on the feedback resistor values and the corresponding gains.Edit: I just realised, the voltage divider has to buffered, or it will form a voltage divider with the feedback resistor. I think it is possible to move the divider behind the gain amplifier.