PWM Question

Discussion in 'General Electronics Chat' started by Spogpean, Apr 24, 2008.

  1. Spogpean

    Thread Starter New Member

    Feb 5, 2008
    8
    0
    right im trying to control temperature. i dont know whether this relation will be correct so maybe can someone point me in the right direction. if my error is large, i need a large amount of power. Conversely when the error is small i need a small amount of power.

    can i generate an error signal by dividing the measured temperature by the setpoint? For example, a setpoint of 50 with an measured temperature of 25 degrees would give me an error of 0.5 (25 / 50). this fraction would then correspond to a certain duty cycle.

    similarly is this fraction was greater than one, meaning the setpoint is above the measured temperature, then the PWM would be deactivated and no power would be sent out.

    is this ok? does this also qualify as proportional control? or could someone recommend me something else? cheers!
     
  2. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    will you use a microcontroller to compare the temperature with the set point?

    do you have an analogue output from the thermometer and you want to compare it with a set point?

    do you want to keep the temperature the same as the set point?
     
  3. Papabravo

    Expert

    Feb 24, 2006
    10,137
    1,786
    Proportional Control is computed as some constant times the difference between the setpoint and the controlled variable. What you want is a control response that is proportional to the error. The constant of proportionality can be either large or smal depending on how sensitive you want to be.

    Systems involving temperature move slowly and there is considerable time lag between the application of the control response and a change in the output. The most extreme example I've experienced is doing touch and go landings in a hot air baloon. You have to initiate a propane burn a full 30-45 seconds before you expect to be at minimum altitude.
     
  4. Spogpean

    Thread Starter New Member

    Feb 5, 2008
    8
    0

    1. Writing a probram in Visual Basic
    2. analogue output from the PRT is calibrated and working so no worries these
    3. yes

    thanks for the replys lads!! my main problem is that im getting a voltage in and im sendin kW out so they're not linear. anyone got a conversion factor or some other idea that i could use??
     
  5. Papabravo

    Expert

    Feb 24, 2006
    10,137
    1,786
    That's just nonsense.
     
  6. mik3

    Senior Member

    Feb 4, 2008
    4,846
    63
    You can compare the voltage measured from the thermometer and compare it with your set point.
    If the the voltage measured from the thermometer is greater then than the set point's voltage then decrease the pulse width progressively by 1% until the temperature falls to the desired level.
    If the the voltage measured from the thermometer is less than the set point's voltage then increase the pulse width progressively by 1% until the temperature rises to the desired level.

    Of course this will be done automatically by your microcontroller. Note that the the voltage measured from the thermometer and the voltage of the set point must be the same for the same temperature.
     
  7. rougie

    Active Member

    Dec 11, 2006
    410
    2
    Spogpean,

    I strongly suggest that you google "PID loops" it is the most serious way of controlling natural variables such as Level, weight, pressure, heat, PH and so forth!

    There are effective calculations on how to use propotionality, integrations and derivitives!

    With regards Robby!
     
Loading...