trying to get this to work

I have been trying to get this to work with the pwm of my arduino.

It is a triak with proportional control and is controlled with 2-10v dc. I have made a circuit as below but it does not seem to work. The voltage on the input pins is ok as I get 10v when the pwm pin is at 255 and 5v at 120 etc. do I need to look at another method on the electronics side.
be gentle with me as this is my first project.

Any help would be appreciated.

pcsw.png

The voltage on the input pins is ok as I get 10v when the pwm pin is at 255 and 5v at 120 etc

Your PWM output is either 5V or 0V.
If you want anything in between, you need to smooth it.

why do I get the correct voltage when I test the pos neg terminals of the triak. ie analoguewrite 255 I get 10v across the terminal analoguewrite 120 I get 5v . I have tested the triak with a battery and it is working perfect, so the problem has to be my circuit. how can i get the arduino to control 2-10v?

when I test the pos neg terminals of the triak. ie analoguewrite 255 I get 10v across the terminal analoguewrite 120 I get 5v

How are you testing this?

with a multimeter

Analogue, or digital?

digital

I really wasn't expecting that.
The fact remains, that with the circuit you showed, the voltage at the collector of the transistor will be either 0V or 10V.
How your Crydom device responds to this, I have no idea.

do you have any other method to allow me to control 0-10v.

Yes, you could low-pass filter the PWM.
Sorry, I'm not an analogue person.

Take your arduino pin, run it thru a 1K resistor to the base of the transistor, and add a 1 uF cap to ground from the base of the resistor.
This will make a low pass filter, so the transistor will see a DC level and not a hard 0V or 5V level.

See "passive electronic realization" here

Adust R & C so that the 490 Hz switching of the PWM output is filtered out.
F = 1/(2piRC)
F2piR = 1/C
C = 1/(F
2piR), so for 300 Hz, 1K resistor, I think that works out to a 53uF cap.

Try different Rs & Cs, see how it works out.

Is this correct

.jpg

How do you have this connected, and to what do you have it connected?

The data sheet says for resistive loads. With No Load it may not show that it is doing anything. And 50Amps is rather exciting...

I'd say yes.

http://arduino.cc/forum/index.php/topic,93735.0.html
I was leaning toward a DAC
An AD558 is still available, but expensive.
A DAC0808 is still available, less expensive, but req's a dual-ended supply and an op-amp.

The low-pass on the input to the base, above, will only result, still, in switching the transistor - it won't effect a variable voltage the way jimjam wants.
Anyway, if you low-pass the pwm and then run that into a buffer, its output would be a variable voltage, likely with some ripple. An op-amp might not be able to supply the current needed at 10V (20mA?). So, something like a common-collector amp for the op-amp's out would take care of that.

Attached is a DAC (digital to analog converter) circuit that works great.
It requires a dual-ended (+5, -5V) supply, a source of fear and loathing for many.

DACproject.JPG

kf2qd:
How do you have this connected, and to what do you have it connected?

The data sheet says for resistive loads. With No Load it may not show that it is doing anything. And 50Amps is rather exciting...

It is needed to control the load of a 3kw heater

jimjam:
Is this correct

I am really struggling here, when I put the capacitor in for the filter I get 9v across the pos and neg of the controller. If I take out the cap the voltage goes to what it should be.

I'm not at all sure that this is going to work...

At present you have the control circuit of the triac in series with your transistor.

The resistance of the triac is the order of 1K (it takes 1ma at 5v).

So when the transistor is "on" you are getting around 11 V across your triac. When it's off, the voltage drop is nearly all across the transistor. All good so far.

However, the transistor is likely to switch at a pretty narrow voltage just a little above ground giving you an on/off at a certain PWM level with your filter on the base side of the transistor. To get a mid-point value, I think you will need your low-pass filter on the far side of the transistor.

If the resistance of the triac input is around 1K then you could try a 56 uf between the collector of the transistor and ground.

Edit - no, sorry, that doesn't work either, 'cos there's no resistance to stop the capacitor discharging through the transistor. I'll have another think....

yes just tried it and it doesnt work