Show Posts
Pages: [1] 2 3 ... 86
1  Using Arduino / General Electronics / Re: Limiting current to motor? on: Today at 09:29:09 pm
Why not use an appropriate sized thermistor? Kind of like an electronic clutch for current.
http://www.ohioelectricmotors.com/what-are-thermistors-and-how-do-they-limit-inrush-current-702

I'm not sure how to select one, and I'm not sure if it would limit the current quickly enough in a stall condition to protect someone's hand if it gets in the way of the moving parts.  It is only a tiny DC motor, but with a 30:1 gear reduction, so there's probably not much danger, but the whole point is to stop the thing immediately if something gets in the way. 

I did search Digikey though.  If any of them are suitable, it would be one of these through hole ones which are in stock:
http://www.digikey.com/product-search/en?pv69=521&pv69=80&FV=fff4001e%2Cfff803f7&k=thermistor&mnonly=0&newproducts=0&ColumnSort=0&page=1&stock=1&quantity=0&ptm=0&fid=0&pageSize=25

I'm gonna check out the datasheets of a few and see if I can suss out how quickly they'd react, but I doubt it will be fast enough.
2  Using Arduino / General Electronics / Re: Wire reverse polarity indicator led to handle voltage above breakdown? on: Today at 09:49:39 am
Well I stuck a resistor and an LED in a breadboard and measured it at various points and sure enough, 2.5V across the LED, 6V across the resistor, and 8.5V across either end from the battery.  I guess this will work then.  Thanks!

I have to wonder though why none of my searches pulled up any explanations of how to do this.  I actually found one circuit using an opamp to do it, and other places suggested diodes in series with the LED.  
3  Using Arduino / General Electronics / Re: Wire reverse polarity indicator led to handle voltage above breakdown? on: Today at 09:32:10 am
So like this?


That's it?  I would have imagined if I measured across the LED that was conducting at best I'd get Vin - Fv, and that's what the reverse voltage across the other LED would be.
4  Using Arduino / General Electronics / Wire reverse polarity indicator led to handle voltage above breakdown? on: Today at 07:37:35 am
I will be implementing the reverse voltage protection circuit shown in this video on a board I'm designing:
https://www.youtube.com/watch?v=IrB-FPcv1Dc

I have a red/green led which I will be using for a status indicator, and to reduce unique component count, I figured why not use it for my power indicator LED as well?  Then I got to thinking that perhaps I could wire it to not only indicate power, but also indicate reversed polarity so it's easy to tell if the problem is a dead battery, or a reversed battery.

The problem is, my circuit can be powered by anything from 4.5V to 16V, and if I simply placed one led in reverse across the power input, I assume even if I have a resistor on the led sufficient to limit the current to 20mA at the maximum voltage I expect, that I may still damage the LED thanks to overvoltage.

Is that true, and if so, how can I implement this cheaply?  I'd rather not add another unique component to the board, like a diode.  I was hoping to get this for free.

I considered a voltage divider, but if I divide by 2 while 5v becomes 2.5v which will still be enough to light the led, 16v becomes 8v which is still too high for the reverse breakdown which is 5V.
5  Using Arduino / General Electronics / Re: Limiting current to motor? on: April 15, 2014, 06:59:39 pm
Yeah, I've got the PWM part nailed down.  I will either be using a dedicated controller IC, or mosfets with flyback diodes.

Or are you saying I can just use a lower duty cycle to reduce the torque?  That will reduce the speed of my motor under load though.  What I really want is a way to prevent the motor from exceeding the current it draws under load, so that if it's stalled there will be insufficient current, and therefore torque.
6  Using Arduino / General Electronics / Limiting current to motor? on: April 15, 2014, 05:57:07 pm
I have a small DC gear motor and I'd like the limit the torque it outputs, without impacting the speed of the motor under a normal load.  But I also want to keep costs and component count low.

So I was wondering, what effect a simple resistor attached to the motor would have, and why it would be preferable to use a more sophisticated current limiting circuit over that.   Ie, how would it affect the speed and torque? 

I'm guessing with a motor things are going to be a little more complex than just choosing a particular resistor to limit the voltage and current to a specific level.

Oh, and I'm going to be controlling this motor with PWM.
7  Using Arduino / General Electronics / Reset into programming mode circuit for an Xmega. on: March 31, 2014, 05:21:17 am
Hey guys,

I think I finally figured out that reset/programming circuit I was working on.

This circuit is designed to allow an XMEGA to be reset into programming mode with a single button press.

Normally, if you have the board powered from the USB port, you'd have to press and hold reset, then press and hold a program button, then release reset, and finally release the program button.  Or you'd need a switch or jumper on the board to enable programming mode. 

With this setup, you just push the button, the board resets, and assuming you don't release the button faster than the reset occurs, the program line will be pulled low when that happens, and the board will enter programming mode.

In addition, because the programming pin by default is on one of the SPI lines, and I didn't want to lose an SPI port, I needed to find a way to ensure that SPI on the programming pin wouldn't reset the board, that it would still be possible to reset the board if the programming line were being pulled high or low, and that pressing the button while SPI was active would not short the pin to ground. 

This circuit does all of the above:

Java simulation: http://goo.gl/Jp7jex

Note that the forward voltage drop on the diodes (well, the one on the reset pin at least) needs to be below 400mv or the capacitor discharge will cause the voltage to spike above the 3.8v max on the MEGA's reset pin.  It isn't tolerant of high voltage like the Atmega and 32U4.

Also, the 25K capacitor by the reset pin is the internal 25K pullup on that pin, so the final part count is 2 resistors, 2 diodes, and a capacitor.

I have not tested this circuit myself yet, so buyer beware. 

It should be possible to add an additional reset button that performs a normal reset with the addition of another diode, but I never end up using those things, I just reprogram.  It's easy enough to unplug the board to reset it anyway. 

Anyway, if anyone has any thoughts on the circuit let me know.  The only thing I'm not certain about is that the reset line is pulled low for long enough to trigger the reset, but I think the timing is the same as the Uno here, so it should be okay.  The Mega requires a maximum of 1000ns low I think to trigger it which is a really small amount of time.

[edit]

Oh, and in the above circuit, the resest pin is the dot on the right side of the schematic, and the programming pin is the white dot at the top left.  The switch highlighted in blue is the pushbutton that triggers the reset and programming mode.  Above it is a switch to test what effect spi communication via the programming pin would have.  It's the miso line, and without that diode there, going low would trigger the board to reset.  There's also a switch next to it which disconnects that other switch from the circuit so the programming pin will be as it would be in its normal input state.

Also, the scope on the left is the reset pin, and the scope on the right is the program pin.
8  Using Arduino / General Electronics / Re: Help me understand what's going on with the reset circuit in this simulation. on: March 31, 2014, 12:34:44 am
Yeah, I got confused.  I was thinking ISP and FTDI functioned the same as far as the reset line was concerned.
9  Using Arduino / General Electronics / Re: Help me understand what's going on with the reset circuit in this simulation. on: March 30, 2014, 05:48:49 pm
Yes, I get that... But it wasn't doing anything in the simulation of the Uno or Leonardo circuits.  When DTS went low, reset simply followed DTS.  It didn't go low, and then high again.

I haven't figured out the problem with the Leonardo schematic, and I've given up on it, but I have finally had some success simulating the Uno schematic.

Here is the Uno schematic:


And here is the simulation of it:

Sim: http://goo.gl/DNRTxu

As you can see it now peaks slightly above 5V.  So far so good.

But look at what happens when I set Vcc to 3.3V:

Sim: http://goo.gl/bkByZb

That is with a diode forward voltage of 700mv.   Approximately the fv of the diode Crossroads says is used on the Uno:
http://forum.arduino.cc/index.php?topic=86389.msg1178112#msg1178112

In order to keep the spikes below 3.6v, I have to set the diode's fv to less than 325mv.

I suppose that doesn't matter on the Uno (or the boards that use the 32U4) because the reset pin is special and can handle up to 13v regardless of Vcc.  But I thought I'd mention it because I'm looking at using an Xmega and the reset pins on those are the same as any other pin, aside from a 25K internal pullup so their reset pin can't stand more than 3.8v max.

Anyway, I guess my problem is resolved.
10  Using Arduino / General Electronics / Re: Help me understand what's going on with the reset circuit in this simulation. on: March 30, 2014, 06:29:37 am
I'm gonna see if I can figure out LTspice and try simulating the circuit in that.  It's high time I started using a decent tool instead of that Java app.  I just hope it has a way to show the current flow.  I find it very helpful in visualizing what's going on.
11  Using Arduino / General Electronics / Re: Help me understand what's going on with the reset circuit in this simulation. on: March 30, 2014, 06:19:44 am
I just looked at your schematics Pito.  It seems you have a square wave generator V1 connected to DTS.  But why is V1 also connected to ground?  I can't tell from your still image if when V1 outputs 5V it goes to both traces attached to it or not, and that would make a difference whether R2 is connected to ground or... 2.5V?  when V1 is on.
12  Using Arduino / General Electronics / Re: Help me understand what's going on with the reset circuit in this simulation. on: March 30, 2014, 06:12:03 am
Btw Pito, neither of your schematics actually represent the Uno or Leonardo reset circuits.  Whether your circuits are correct or not, I don't know, but what I'm trying to figure out here is if the Uno and Leonardo schematics are correct.
13  Using Arduino / General Electronics / Re: Help me understand what's going on with the reset circuit in this simulation. on: March 30, 2014, 06:10:02 am
Here ya go:
14  Using Arduino / General Electronics / Re: Help me understand what's going on with the reset circuit in this simulation. on: March 30, 2014, 06:03:45 am
Pito:
The schematics I am referring to are all on this site.  I'm talking about the differences between the Uno and Leonardo auto reset circuits. 

The first few simulations I posted were simulations of those circuits.  The simulations indicated they would not behave the way they should.  The only thing a screenshot of the simulator would show you is that the circuit I constructed is identical to the one in the schematic.

Either the simulator is wrong, or the schematics are wrong.  You have the schematics., so at the very least you can see that they should, or should not work as advertised, and explain why they are different.

If  I posted a picture of the simulator all you would see is a still image of the circuit in the UNO schematic, with an osilliscope output showing a square wave on the reset pin when I switch the DTS high and low.
15  Using Arduino / General Electronics / Re: Help me understand what's going on with the reset circuit in this simulation. on: March 30, 2014, 05:27:31 am
I still haven't had any success with the actual Uno circuit, but I've made some progress.  This variation seems to work how it's supposed to, at least for the DTS portion:

http://goo.gl/D0b3t9

I still need to add the reset button to this and figure out how to make it function the same way though.   

[edit]

Well, this seems to work...

http://goo.gl/XJEeFy

It doesn't drop and bounce back on its own while the button is held, but it does go back to 5v after you release it which ought to have the same effect.  I'd rather it snap back to 5v while held down though.  Would feel more responsive.
Pages: [1] 2 3 ... 86