Jump to content

make a pulse with timer


Recommended Posts

Hello everyone,

I have an issue, I want to make one of my output ( a  LAMP) blinking with the timer (TD).

by starting timer  blink slowly and when it get to end of the timer blink fast. a pulse with elapsed Time... 

I try everything but could not solve that.

please help !

Best regards

Link to comment
Share on other sites

  • MVP 2023

You can use PWM FB for generate different ON OFF condition for one output.

You can manipulate PWM in range 0.0% ---100.0% (0--1000) and Duty Cycle  in steps of 0.25ms  (400=1sec).

If you set PWM=500 and change Duty Cycle for example from 1sec (400) to 0.5sec (200) - you can see slow and fast blink.

If PWM=0 lamp go OFF PWM=1000 - lamp go to constant light.

 

 

  • Like 1
Link to comment
Share on other sites

  • MVP 2023

Kratmel, I think the need is for the blink speed to increase as the timer runs.  So as the timer nears finishing it is blinking quickly.

Alighz, I would be doing this using a toggle coil whose input is controlled by a self-resetting count that reduces the reset number as a direct inverted linearization of the total timer time, as the time elapses.  Also be aware that ideally you can't use a relay output for this, transistor output would be preferable.  Plug away at that concept and see how it goes.

cheers, Aus

  • Like 1
Link to comment
Share on other sites

  • MVP 2023

Combine Aus idea with linearization, some compare nets and PWM can realase visual effect with normal blink, fast blink before end of time and constant LIGHT when time is over.

As for me normal blink must be active at the all normal process time. Faster blink  must be active only before time near finishing and this blink must not befaster then twice as normal.

I build this idea on plastic welder machine. Only one GREEN LAMP and  two button is present on operator panel of this old machine.

And user know when process go to the end by fast lamp blink.

  • Like 1
Link to comment
Share on other sites

On 10/16/2020 at 11:45 PM, kratmel said:

Combine Aus idea with linearization, some compare nets and PWM can realase visual effect with normal blink, fast blink before end of time and constant LIGHT when time is over.

As for me normal blink must be active at the all normal process time. Faster blink  must be active only before time near finishing and this blink must not befaster then twice as normal.

I build this idea on plastic welder machine. Only one GREEN LAMP and  two button is present on operator panel of this old machine.

And user know when process go to the end by fast lamp blink.

That's  exactly what I want to do, to inform the user about that it is going to end and constant light means it ends.

Thank you for the instruction, I will try this.

The user can change the Timer and for compare part I think I should do this:

For example T/2< Mi<T   ,    T/3<Mi<T/2     MI< T/3    and  Mi = 0

Is That right ??

Link to comment
Share on other sites

On 10/16/2020 at 10:48 PM, Ausman said:

Kratmel, I think the need is for the blink speed to increase as the timer runs.  So as the timer nears finishing it is blinking quickly.

Alighz, I would be doing this using a toggle coil whose input is controlled by a self-resetting count that reduces the reset number as a direct inverted linearization of the total timer time, as the time elapses.  Also be aware that ideally you can't use a relay output for this, transistor output would be preferable.  Plug away at that concept and see how it goes.

cheers, Aus

Thank you ,Aus , for you comment. I am a bit confused about this Solution.
I know it takes time, but if it was possible please send me Ladder diagram. That would be Awesome.

 

Best regards, Ali

Link to comment
Share on other sites

  • MVP 2023

At present I can't spare time to do this.  Someone else may. 

The initial point was for you to try, the forum isn't necessarily about providing ready made answers, it's about learning as well.  If you step through the words, relating them to ladder elements, you'll likely figure it out.

cheers, Aus

  • Like 1
Link to comment
Share on other sites

  • MVP 2023

This is actually not a trivial problem.  It consists of three logical parts:

1.  The primary TD timer (not hard)

2.  The blinking lamp is achieved by two more timers - one for ON and one for OFF off the lamp.

3.  Some math to examine the primary timer's preset vs accumulator %, decrease the OFF timer's preset, and increase the ON timer's preset.  The sum of those two presets must equal the primary timer's preset.

On 10/18/2020 at 4:02 AM, alighz said:

For example T/2< Mi<T   ,    T/3<Mi<T/2     MI< T/3    and  Mi = 0

This is probably the easiest solution.  If you want to take a swing at it and post your program we can probably help.

Joe T. 

  • Like 1
Link to comment
Share on other sites

  • MVP 2023

Out of curiosity I worked on this a bit.  The attached vlp is nowhere near perfect, it was just banged together to show the concept I was talking about.  I'd be putting in various other compares to limit the flash rates, both min and max Hz.   Along the way I changed my thinking a little, this works on a simple method of using scan rate, but this basis could easily be changed to something else more "fixed".

It was done on a 130, but should transfer to anything else with a bit of minor tweaking.  It flashes the screen backlighting impersonating an indicator.  This might need changing for your model.

Look through the ladder and it should all become apparent as I haven't refined it at all.   (and I'm not going to!) 🙂

cheers, Aus

B130timerflash2.vlp

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...