Internet PLC Forum

General => Technical support => Topic started by: Ken on September 27, 2002, 11:25:24 AM

Title: need to slow input or recognition speed on 100md+
Post by: Ken on September 27, 2002, 11:25:24 AM
I am using the following custom function once upon startup to set some values.  My problem is that I want to increment the values one at a time or at least slow it down so that I can reach a specific integer.  The inputs are switches, and the plc is scanning so fast that I cant increment as slow as required.

Thanks in advance,
Ken


DM [50] = 1


SETLCD 0,1,CHR$(1)
SETLCD 1,1,"GPM CALIBRATE"

@10 REFRESH
IF TESTIO (SelectUp) = 1
DM[111] = DM[111] + 1
ENDIF
IF TESTIO (SelectDn) = 1
DM[111] = DM[111] - 1
ENDIF
SETLCD 2,1,STR$(DM[111],4)
IF TESTIO (Select) = 1
DM[50] = DM[50] + 1

ENDIF

IF DM[50] = 1
GOTO @10
ENDIF


SETLCD 0,1,CHR$(1)
SETLCD 1,1,"FPM CALIBRATE"

@20 REFRESH
IF TESTIO (SelectUp) = 1
DM[110] = DM[110] + 1
ENDIF
IF TESTIO (SelectDn) = 1
DM[110] = DM[110] - 1
ENDIF
SETLCD 2,1,STR$(DM[110],4)
REFRESH
IF TESTIO (Select) = 1
DM[50] = DM[50] + 1
ENDIF



IF DM[50] = 2
GOTO @20
ENDIF


@30 REFRESH
IF TESTIO (Selectup) = 1
TOGGLEIO FPM300
ENDIF
IF TESTIO (FPM300) = 1
DM [106] = 300
SETLCD 2,1,"FPM300"
ELSE
SETLCD 2,1,"AUTO  "
ENDIF
REFRESH
IF TESTIO (Select) = 1
DM[50] = DM[50] + 1
ENDIF

IF DM[50] = 3
GOTO @30
ENDIF
Title: Re:  need to slow input or recognition speed on 10
Post by: support on September 27, 2002, 04:21:53 PM
In this application using the ladder logic in combination with Custom function will work very well. You may want to check out the sample program: "SetTimCtrSV.pc5" in your TRiLOGI "samples" folder. We used 3 push button switches for you to set the value. Each time you press a button it only increment or decrement one step at a time regardless of how fast the ladder logic scan.