1st grade timer question

rscott9399

Member
Join Date
Aug 2017
Location
in space
Posts
114
Stupid question i know but i know i have seen this done before and yet i cant get it to work

For the preset value of a TON
I want to use a tag instead of a number

I am creating an AOI instruction and i want one of the inputs to be the preset value of a timer that is in the function.

I have an INPUT variable tag for the function but the timer will not accept it.
the type is DINT which is suppose to be what the TON instruction takes

What did i miss?

Thanks guys
 
yep that will work for me purpose, although not elegant,
sorry useless post right here lol

For a more elegant solution, make the DInt tag an ALIAS to the Timer.PRE. The DInt tag is an Input, and so is exposed outside of the AOI. The timer is Local scoped.

Because it's an alias, no MOV is required to get the tiger's preset from outside of the AOI to the TIN instruction inside it.
 

Similar Topics

As far as I know the UKCA mark is mandatory from 2023, and that is 9 months from now. That is not a lot of time to investigate, design, validate...
Replies
22
Views
4,714
Hi All, I cannot seem to find a way to move a Boolean from an Arrays UDT into a DINT. I have an Array of 32 elements with a UDT data type of 4...
Replies
3
Views
1,728
Hey guys, I need help calculating first Monday of the month. Has anyone ever had to perform such calculation? Rockwell has UFDB that calculates...
Replies
10
Views
2,672
Hi, I have received a copy of a PLC program for a customers Carton erector that uses a beckhoff PLC and HMI. I just downloaded the trial version...
Replies
8
Views
2,231
I'm new to PLC programming, however my system seems very simple compared to others I've been reading on this site. I have layout my 1st system...
Replies
5
Views
2,154
Back
Top Bottom