Flexinol Transistor Circuit Resistance

Hi all! I’m working on making a simple sort of pulley thing with flexinol muscle wire, but for right now I’m just testing out what I need to make the wire contract safely. I’ve got a bit of an odd situation; I got it working, but I’m unsure why the set-up I’ve got works! I’d appreciate some help if anyone’s got it to offer, since I’ll likely be working with muscle wires and the like for some time, and I’d like to know where I’m making mistakes in my designs!

This is the circuit diagram I have to work with, with one notable change – I moved the collector resistor (Rc) to between the switch and the flexinol wire:

The Arduino is an Arduino Uno. The Flexinol is 10 cm of 100 micrometer diameter wire (which I calculated to have 15 ohms of resistance and need 180-200 mA of current based on the datasheets I have), and the transistor I’m using is a PN2222A NPN transistor.

I had some trouble working out what the hfe of my transistor would be at the currents I needed it (especially given I couldn’t calculate the voltage across its parts without knowing what current would come out of it), so I decided to just build the thing and test it out, magic smoke or not.

Based on this guide, I worked out I’d need around 27.7 ohms of resistance on the collector to get 180 mA on the wire; I stuck with 25 ohms because I knew I could safely let the current go a bit higher. I stuck 100 ohms on the base resistor because we all get a little stupid and impatient sometimes – that was swiftly taken off.

At 25 ohms on Rc I was only getting around 140 mA on the wire. I only got to a range of 180-220 mA when I dropped down to my 4.7 ohm resistor.

Final relevant values for the above diagram:
Ic= 180-220 mA
Rc = 4.7 ohms
Rb = 0 ohms

So, my questions:

Why does this work, and perhaps more importantly, will it continue to?

One particular point of concern – how far above the recommended current for flexinol wire can one safely go? The datasheets I have did not specify a maximum or minimum value, and in fact gave two different values for “recommended current” – 180 mA or 200 mA.

Another concern – could my Arduino be putting out less than 5V? This thing’s been through… a bit.

Is there a more reliable way to calculate resistor values for flexinol transistor circuits?

Is it safe to run this amount of current through the wire for an extended period of time?

In addition, any other information on designing with flexinol (or those snazzy fishing-line-based artificial muscles) is heartily welcomed, as are scathing criticisms of this circuit in general.

Thanks so much for your time and help!

Try changing the 2N2222 into a constant current driver.

220ohm resistor between Arduino pin and base.
Two 1N4148 diodes in series between base and ground (cathode to ground).
3.3ohm resistor between emitter and ground.
Wire between 5volt and collector.
(post a diagram, so we can check).

The Arduino pin provides current for the base and the 1.3volt zener (the two diodes in series).
Base now has a constant voltage (1.3volt), so emitter also has constant voltage (0.65volt).
A constant voltage on the emitter resistor is a constant current through the emitter resistor
(0.65/3.3 = ~200mA).
A constant current through the emitter is a constant current through the collector (wire).
Leo..

Edit:
The transistor now dissipates what the extra resistor did (~0.27watt), and gets warm.
Keep an eye on it.

Did you measure the voltage of the 5V with the wire turned on ?

According to the datasheet, the Hfe is about 200 at Ic of 200 mA.
That means the base needs 1 mA.
Let’s make that 1.5 mA, and assume the Arduino 5V has dropped to 4.5V.
(4.5 V - 0.6) / 1.5 mA = 2k6

I don’t know how you have calculated the collector resistor to 27.7 Ω, because I get 12 Ω.

I can even make it plausible that your 4.7 Ω works.
For the collector current: (4.5 V - 0.1) / 200 mA = 22 Ω
So the collector resistance would be 22 Ω - 15 = 7 Ω
The resistance of the wire might increase when it gets hot. When also the voltage is dropped lower than 4.5, then it is indeed possible that your resistor of 4.7 Ω was needed.

Grab a new 2N2222A and use a base resistor of 2k2. Use a extra power supply of 5V. Don’t forget to connect the GNDs.

A mosfet is better and more fun.

A constant current driver, as mentioned by @Wawa is the best.

I think you need a higher voltage for better control of the current.

Hfe is not the right parameter for switching applications, it's applicable e.g. for analog amplifiers. See the transistor data sheet how much Ib is required for which Ic.

The current source approach looks good to me, it allows to control the output current more precisely.

@DrDiettrich, you can check my calculations.
I used the graph of the datasheet for 200mA; I lowered the 5V to 4.5; I used 50% extra current for saturation while 30% is recommended; I lowered the resulting 2k6 to 2k2. I think that the 2k2 is a fair value for the base resistor.

For 200mA a hFE of 200 is achieved only at Uce 10V, what is outside the supply voltage and also would kill the transistor with 2W immediately. At Uce 1V only hFE 150 is shown.

Now check the Collector Saturation diagram. Assuming a DC amplification of 200 at Ic 150mA would suggest Ib 0.75mA - a point that is outside the diagram, perhaps at 10V. For 0.1V saturation 3mA base current is required for 150mA collector current, a ratio of only 50.

The 2k2 base resistor is okay, the diagram shows about 0.15V for 2mA at Ic 150mA, maybe 0.5V at 200mA. The calculation of the collector resistor has to be adjusted accordingly. The constant current source approach will eliminate all those voltage and temperature dependencies.

Ah, I see. Thanks !

Oh gosh, that’s a lot of help! Thanks so much everyone!

Wawa:
220ohm resistor between Arduino pin and base.
Two 1N4148 diodes in series between base and ground (cathode to ground).
3.3ohm resistor between emitter and ground.
Wire between 5volt and collector.
(post a diagram, so we can check).

Is this what you’re suggesting? (I’m assuming the “extra resistor” is Rc, and the “Wire between 5volt and collector” isn’t a separate wire between the 5V and collector, placed before the Flexinol wire.)

I should be able to drop by the store for some 1N4148s today or tomorrow. Do I need this specific type of diode to make this work, or would different parts work (with different values on the resistors)? (Ex: The store I live by for sure has a 1N5338B 5.1V 5-Watt Zener Diode (which sounds like it’s too high a voltage for this?))

Wawa:
The Arduino pin provides current for the base and the 1.3volt zener (the two diodes in series).
Base now has a constant voltage (1.3volt), so emitter also has constant voltage (0.65volt).
A constant voltage on the emitter resistor is a constant current through the emitter resistor
(0.65/3.3 = ~200mA).
A constant current through the emitter is a constant current through the collector (wire).

If I’ve got the Flexinol wire on the collector end, wouldn’t that make the current it gets less than 200 mA? (Going off of IE = Ib + Ic.)

Also, if you have time – how are you calculating these resistor and voltage values? I tried working them out on my own but I’m not sure how everything works with a transistor in the mix (I’ve only been over resistor and capacitor circuits so far, haha, everything else is just piecemeal. ^^; )

Koepel:
Did you measure the voltage of the 5V with the wire turned on ?

I wasn’t sure how to safely do that! I figured I needed to measure the voltage from power to ground, but got spooked because I’m using jumper wires on a breadboard and don’t want to accidentally break the circuit while trying to measure the voltage from the tiny exposed metal parts on the ends of the wires, and burn out the fuse on the multimeter. Not really sure what to do about it, though I feel like I’m missing something obvious.

Koepel:
I don’t know how you have calculated the collector resistor to 27.7 Ω, because I get 12 Ω.

A series of increasingly embarrassing math mistakes! :grinning:

Koepel:
The resistance of the wire might increase when it gets hot. When also the voltage is dropped lower than 4.5, then it is indeed possible that your resistor of 4.7 Ω was needed.

This seems to be the case! The Austenite/contracted phase of the wire has higher resistivity, which means it will have higher resistance, right?

Koepel:
A constant current driver, as mentioned by @Wawa is the best.

I think you need a higher voltage for better control of the current.

DrDiettrich:
The current source approach looks good to me, it allows to control the output current more precisely.

I think I’ll go with the constant current driver, then!

How does higher voltage / a separate voltage source help control the current? (I’m not averse to it – I’ll need a separate battery anyway, since the project I’m working on will need as many as 16 of this circuit – I just don’t understand how it works.)

DrDiettrich:
Hfe is not the right parameter for switching applications, it’s applicable e.g. for analog amplifiers. See the transistor data sheet how much Ib is required for which Ic.

I’m not sure I understand why this is a switching application? I’m trying to use the transistor to amplify the current from the Arduino’s output pins.

The datasheet I have for the PN2222As I’m using here doesn’t seem to give values for how Ib corresponds to Ic, just hFE for given VCE and Ic values. Am I looking at the wrong datasheet / is there a different sort of documentation for those sort of numbers (and the Collector Saturation diagram you mentioned in your later post)?

BJT transistors have a somewhat more complicated behaviour than MOSFETs.

For the constant current source you can use any diodes, including 1N400x, which have a somewhat constant forward voltage of about 0.6V. Connect the resistor to the transistor base, as usual, and the diodes from the base to Gnd.

Diagram is not correct.
Read the instructions again.
The diodes go between base and ground.

This is the closest example I could find on the net.

The 1N4148 is a very common small signal diode.
But any small diode would do here, even the 1N400x.
Leo..

Wawa:
Diagram is not correct.
Read the instructions again.
The diodes go between base and ground.

This is the closest example I could find on the net.

The 1N4148 is a very common small signal diode.
But any small diode would do here, even the 1N400x.
Leo..

I'm not sure how I misunderstood that! Thanks for your patience. Like this?

Managed to get out and get some 1N4148s today, so I'll give it a go! Will report back with results!

Diagram is correct now :slight_smile:
Leo..

Hi all! Sorry for the late reply -- had some stuff come up that delayed working on anything for a while.

Set the circuit up like in the circuit diagram, everything works perfectly! Steady 180 mA on the wire. Thanks so much for all your help!