Go Down

Topic: Using Flex Sensor to control Voltage (Read 740 times) previous topic - next topic

SMorteza

hi, in my project i have small sheet of special alloy that a wire of Ni-Cr is wind around it. by increasing the input voltage to wire, it will be warmer by internal resistance and the alloy will bend. i want to have flex sensor to sense the bending curvature and send it to Arduino to increase or decrease the output voltage to wire. the main source is 10v and 1A. can anybody help me please?

BuzziBi


wvmarle

Flex sensor is indeed a problem with the heat.

Something to measure the distance one end of the bimetal (that's what you're using, right?) may be easier.

For the heating control, you don't normally control the voltage, it's much easier to control the current. Use a MOSFET and PWM to control it.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

SMorteza

#3
Jan 15, 2019, 09:50 am Last Edit: Jan 15, 2019, 09:55 am by SMorteza
Flex sensor is indeed a problem with the heat.

Something to measure the distance one end of the bimetal (that's what you're using, right?) may be easier.

For the heating control, you don't normally control the voltage, it's much easier to control the current. Use a MOSFET and PWM to control it.
Flex sensor have a suitable distance from heating source and it's have very simple circuit, it mades by  plastic and carbon, as it bends, the resistance in increased ( a role like Potentiometer resistance ) and after that, the current must be change. i need one map function to receive the resistance from sensor and map it to device(Wire) current input.
i don't know what is the MOSFET, is it work to my project? i want just to solve my project issue, the way is not so important, i am mechanical engineer and have little information about arduino. thanks for your attention.

wvmarle

I see one issue here. I think you want to make the metal bend to a certain extent, and keep it there. That calls for a bit more control, as you have to use the reading from the flex sensor to tell you where you are (it's a feedback), and have a setpoint (user input) that tells you where to go. Change the heat (PWM duty cycle) based on the difference.

You may benefit from PID control here. Can probably leave out the I for small, fast reacting heating wires.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

SMorteza

Yaah, every things that you say is true and is my goal. now how i can do it? with arduino or any etc PID control? the flex sensor in flat mode have a about 50 k ohm resistance and in bended mode, 140 k. please tell me what part and circuit i need to control? these pics shows before and after heat and curvature.

wvmarle

A 100k series resistor should do fine for that sensor.

Hook it up, see what readings you get.

Wire up the heating wire with MOSFET switch, make sure you can control this properly.

Combine them together. The PID is the hard part.

For all the separate parts you'll be able to find lots of tutorials.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

SMorteza

A 100k series resistor should do fine for that sensor.

Hook it up, see what readings you get.

Wire up the heating wire with MOSFET switch, make sure you can control this properly.

Combine them together. The PID is the hard part.

For all the separate parts you'll be able to find lots of tutorials.
OK. i buy one MOSFET IRFZ44N, Arduino UNO R3, I have sensor before. i write the pid controller, i define the pin 9 & 6 as PWM. as the sensor bends, the voltage in PWM pins is changed. i saw it by multi-meter. now please tell me where i must put the MOSFET? in the PWM pin, i can not have more than 5v. i need more about 10v, by mosfet.

wvmarle

Standard MOSFET circuit.
Output pin to the gate; pull-down resistor from gate to GND, load between positive supply and drain, source to GND.

Why two PWM pins? You have two heaters?

The voltage your multimeter indicates is an average. Connect it to a scope and you'll see the block wave.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

SMorteza

Yaah, I have two heater. i bring every thing that you say to me, but i am week against you in electronic. can i ask you to draw me the circuit?

Grumpy_Mike



Quote
i buy one MOSFET IRFZ44N
You buy the wrong sort of FET, you need one like this:-

https://www.adafruit.com/product/355

SMorteza


You buy the wrong sort of FET, you need one like this:-

https://www.adafruit.com/product/355
Tnx. Does it have a similar? i can not find it in stores.

Grumpy_Mike

#12
Jan 18, 2019, 11:10 pm Last Edit: Jan 18, 2019, 11:10 pm by Grumpy_Mike
Look for FETs with an L in the part number and then look at the data sheet at the Ron parameters, Resistance of the FET when on, and the conditions that is measured under is a 5V gate voltage.

These are called logic level FETs.

wvmarle

#13
Jan 19, 2019, 01:23 am Last Edit: Jan 21, 2019, 11:35 am by wvmarle
Tnx. Does it have a similar? i can not find it in stores.
The IRLZ44N will do just fine, too. Note the L instead of the F.

And that Fritzing image misses the mandatory flyback diode - mandatory as it's a motor switch. Your heating element doesn't need this, so you can just replace the motor by the heating element and you'll be fine.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.

SMorteza


You buy the wrong sort of FET, you need one like this:-

https://www.adafruit.com/product/355
This product that you advise to me, is IRLB8721, and i can not find it, but i find the IRLB8743, does it works for me?
I also find and buy the IRLZ44N, that you say must have L in product type. thanks for your kindly guidance.

Go Up