Internet PLC Forum

General => Technical support => Topic started by: Khalid Baig on December 12, 2003, 09:18:47 AM

Title: Using Analog Input to control process
Post by: Khalid Baig on December 12, 2003, 09:18:47 AM
How can I use the analog input to control a process? For example when the reading on channel 1 exceeds a given number,  an output is to be turned off.

Further can that given number be a parameter entered in memory?

Title: Re: Using Analog Input to control process
Post by: support on December 12, 2003, 09:29:45 AM
The TBASIC language supports IF THEN ELSE statements so it is really easy to achieve. E.g.

IF ADC(1) > 2000
   CLRIO  HEAT1      ' HEAT1 is the label name of heat output.
ELSE
   SETIO  HEAT1
ENDIF
  
For more example programs, please visit:

http://www.tri-plc.com/examples.htm