13.07.2015 Views

AL 20AN Programmable Logic Controller ... - FF-Automation

AL 20AN Programmable Logic Controller ... - FF-Automation

AL 20AN Programmable Logic Controller ... - FF-Automation

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

AutoLog <strong>AL</strong><strong>20AN</strong> Instruction ManualCORRECTIONS IN DOCUMENTChange Date On page(s) Maker Commentsnumber001 Changes in chapters ,1, 2, 3,4, 5, 6, 9, App. A002 29/12/2006 7.6 Chapter 7, page 6: R O 224, R O 254, added12.25-26 comands FCN 51, 52, 53, 54<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong><strong>20AN</strong> Instruction Manual7. RESERVED VARIABLE LOCATIONS ................................................................................... 7-17.1 Register outputs reporting on or controlling the operation of the PLC ....................... 7-17.2 Register outputs which must be set ............................................................................ 7-77.3 W GM variables reserved for PID controllers ............................................................. 7-87.4 Modbus Error information Register Outputs ............................................................... 7-88. DISPLAY/KEYPAD UNITS ..................................................................................................... 8-18.1 <strong>AL</strong>1096 Display/Keypad units <strong>AL</strong>1096PS/PE/T/S ...................................................... 8-18.2 <strong>AL</strong>1095A/B Display/Keypad unit ................................................................................. 8-18.3 <strong>AL</strong>1093C/D/F Display/Keypad unit ............................................................................. 8-28.4 <strong>AL</strong>1094/R Display/Keypad unit ................................................................................... 8-28.5 <strong>AL</strong>1094AF Display/Keypad unit .................................................................................. 8-38.6 <strong>AL</strong>1094FM Display/Keypad unit ................................................................................. 8-38.7 Reading the Keypad ................................................................................................... 8-48.8 Control of LED Indicators ............................................................................................ 8-48.9 Display Control Characters ......................................................................................... 8-58.10 Display Modes ............................................................................................................ 8-58.11 Program examples ...................................................................................................... 8-89. CONTROLLERS .................................................................................................................... 9-19.1 Register Variables of <strong>Controller</strong>s ................................................................................ 9-19.2 Three point controllers ................................................................................................9-29.2.1 Control algorithm ......................................................................................................... 9-29.3 <strong>Controller</strong> types ........................................................................................................... 9-49.4 <strong>Controller</strong> tuning .......................................................................................................... 9-510. DATA COMMUNICATION ................................................................................................. 10-110.1 <strong>AL</strong><strong>20AN</strong> serial connections ....................................................................................... 10-110.2 Terminal / printout ..................................................................................................... 10-310.3 MODBUS .................................................................................................................. 10-310.4 Modem - <strong>AL</strong><strong>20AN</strong> ..................................................................................................... 10-611. OPERATION OF THE PLC ................................................................................................ 11-111.1 Switching on and special supply conditions .............................................................. 11-111.2 Start of program execution ........................................................................................ 11-211.3 START command ..................................................................................................... 11-21.4 Remedies to common problems ............................................................................... 11-312. PROGRAMMING ............................................................................................................... 12-112.1 Programming methods .............................................................................................. 12-112.2 <strong>AL</strong><strong>20AN</strong> variables ..................................................................................................... 12-312.3 <strong>AL</strong><strong>20AN</strong> Error messages .......................................................................................... 12-412.4 <strong>AL</strong><strong>20AN</strong> INSTRUCTIONS ......................................................................................... 12-513. TABLES .............................................................................................................................. 13-113.1. ASCII-codes .............................................................................................................. 13-113.2. Decimal / Octal conversions ..................................................................................... 13-214. LIST OF <strong>AL</strong><strong>20AN</strong> PRODUCTS .......................................................................................... 14-114.1 Basic board .............................................................................................................. 14-114.2 Expansion boards .................................................................................................... 14-114.3 Accessory boards .................................................................................................... 14-114.4 Analog /digital input modules .................................................................................... 14-114.5 Analog outputs on CPU board .................................................................................. 14-214.6 Converters for serial communication ........................................................................ 14-214.7 Power supplies .......................................................................................................... 14-214.8 Programming and additional software ...................................................................... 14-214.9 Programming and auxiliary cables ............................................................................ 14-2<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 1 - 129/12/20061. SYSTEM COMPONENTShe AutoLog <strong>20AN</strong> is a modular PLC from <strong>FF</strong>-<strong>Automation</strong>, Finland. Due to it’smodular design it is suitable for controlling individual machine or small group ofmachines. Analog input points on the main board are defineable by connectionmodules to function as analog or digital inputs. Autolog Display/keypad units areavailable to provide a user interface. Expansion boards, DI16 digital input board,RO16 relay output board, RIO 8 digital input / relay out board, DO32 digital outputboard and EXA8/4 analog board (12bit) can be used to expand number of I/Oconnections. EXA8/4 board can be used as digital inputs by using DIN modulesto convert analog input to 3 digital or to 2 isolated digital inputs.Main board <strong>AL</strong> <strong>20AN</strong>CON302CON301CON303SW1CON101H108H107H106H105H104H103H102H101MOD6MOD4IC3IC4MOD7MOD5MOD3MOD2MOD1MOD0IC1IC2IC10SER2RX TXRX 12VSER1CON501CON1TXEXTI 2 C IC2RUNB1H201H202CON201H203H204H205H206H207H208CON502CON503 J1 J2CON403CON401CON402- 8 universal inputs analog (12bit) or 24 digital inputs,defineable by modules. An analog input may be definedto three digital inputs.- Calibration of Analog inputs by system program.- 2 analog outputs 0 - 5 or 0 - 10 V, (12bit)- 8 digital inputs 24VDC.- 8 digital outputs, 24VDC 1A- I 2 C interface for Display/keypad unit- I 2 C connector for extension boards- RS232 serial interface for programming ordata communication SER1- RS232 serial interface for data communication SER2,with conversion module RS485- Input voltage 18 -30 VDC / 15.5 - 24 VAC or10 -30 VDC / 7.5 - 24 VAC from external supply unit.- can be mounted on Phoenix UM-modules<strong>FF</strong>-<strong>Automation</strong> Oy


Page 1 - 229/12/2006AutoLog <strong>20AN</strong> Instruction ManualExpansion board RO16CON104CON103CON102CON101H9H10H11H12H13H14H15H16H1H2H3H4H5H6H7H8C11 C10 C9 C8 C7 C6 C5 C4 C3 C18 C17 C16 C15 C14 C13 C12K8 K7 K6 K5 K4 K3 K2 K1 K16 K15 K14 K13 K12 K11 K10 K9IC8IC5IC6IC7CON2FROM CPUCON1J11-2 3-4 ADDR1 1 32100148640 0 80TO EXT- 16 relay outputs, RC protection, outputs isolated from each other (two terminals)- I 2 C expansion interface- operation voltage supplied from main board- can be mounted on Phoenix UM-modulesExpansion board RIO8H8H7H6H5H4H3H2H1H16H15H14H13H12H11H10H9CON103CON102CON101C11 C10 C9 C8 C7 C6 C5 C4K8 K7 K6 K5 K4 K3 K2 K1IC5IC8IC7IC6CON1CON2FROM CPUwww.<strong>FF</strong>-<strong>Automation</strong>.comJ1 1234561-2 3-4 5-6 ADDR 1-2 3-4 5-6 ADDR1 1 1 32 0 1 1 641 1 0 40 0 1 0 721 0 1 48 0 0 1 801 0 0 56 0 0 0 88TO EXT- 8 relay outputs, RC protection, outputs isolated from each other (two terminals)- 8 in group isolated inputs for contacts 24VDC or PNP sensors- I 2 C expansion interface- operation voltage supplied from main board- can be mounted on Phoenix UM-modules<strong>FF</strong>-<strong>Automation</strong> Oy


C2AutoLog <strong>20AN</strong> Instruction ManualPage 1 - 329/12/2006Expansion board DI16- 16 isolated inputs for contacts 24VDC or PNP sensors- I 2 C expansion interface- operation voltage supplied from main board- can be mounted on Phoenix UM-modulesExpansion board DO3211H C1FROM CPUTO EXTCON202CON201CON102CON101H8H7H6H5H4H3H2H1H16H15H14H13H12H11H10H9CON102CON101IC7IC6IC5IC8CON1CON2FROM CPUJ11-2 3-4 ADDR1 1 32100148640 0 80TO EXTCON1CON2- 32 in group isolated FET outputs, LED indication of output state- I 2 C expansion interface- operation voltage supplied from main board- can be mounted on Phoenix UM-modules<strong>FF</strong>-<strong>Automation</strong> Oy


Page 1 - 429/12/2006AutoLog <strong>20AN</strong> Instruction ManualExpansion board EXA8/42ICRUNIC105IC3MOD104MOD103MOD102MOD101JP2RUNIC2MOD105MOD107X1MOD106MOD108IC1IC103IC102IC1012IC- 8 analog inputs / 24 digital inputs with <strong>AL</strong>20DIN modules.- Analog input modules: Pt100, KTY10, 0-20 mA, 4-20 mA, 0-5 (10) VDCor from -10 to +10 VDC- 4 analog outputs 0 - 5 VDC or 0 - 10 VDC, software defineable- I 2 C expansion interface- operation voltage supplied from main board- can be mounted on Phoenix UM-modules<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 1 - 529/12/2006Display/keypad unit <strong>AL</strong>109404152637- 4 digit LCD display- 8 keys (0 ... 7)- 4 LED indicator lights- I 2 C connection cable (0.25m) to PLC- operation voltage supplied from main boardDisplay/keypad unit <strong>AL</strong>1094R0 12 3- 2x16 digit alphanumeric LCD display, backlit- 4 keys (0 ... 3)- 2 LED indicator lights- I 2 C connection cable (0.25m) to PLC- operation voltage supplied from main boardDisplay/keypad units <strong>AL</strong>1094041 2 35 6 74321<strong>AL</strong>1094AF- 2x20 digit alphanumeric LCD display, backlit- 8 keys (0 ... 7) / 16 keys (0 ... F)- 4 LED indicator lights- Clock and calendar with battery backup- buzzer- I 2 C connection cable (0.9m) to PLC- operation voltage supplied from main board- one 24VDC 300mA output for externalindication light- resistance against interference and radiation;CE approved- operating temperature 0 - 55 °C- ambient humidity 5 - 95% RH, (non condensing)- cooling; natural air conditioning- open structure, not encapsulated- the unit can be fitted with a client designedface plate0 1 2 34 5 6 78 9 A BC D E F<strong>AL</strong>1094FM4321<strong>FF</strong>-<strong>Automation</strong> Oy


Page 1 - 629/12/2006Display/keypad unit <strong>AL</strong>1093D, <strong>AL</strong>1093FAutoLog <strong>20AN</strong> Instruction ManualDIS10 1 2 3 48 9 A B C5 6 7D E F- 2x16 character alphanumericLCD display, backlit- 16 keys (0 ... F)- 6 LED indication lights- clock and calendar, battery backup- I 2 C connection cable (1m) to PLC- operation voltage supplied from mainboardDisplay/keypad unit <strong>AL</strong>1095A, <strong>AL</strong>1095BLED1LED2LED3LED4DIS1LED5LED6LED7LED80 1 2 34 5 6 78 9 A BC D E FDIS10123- 8x21 character alphanumericLCD display / 128x64 pixel graphicdisplay, backlit- 16 / 4 keys (0 ... F / 0 ... 3)- 8 LED indication lights- clock and calendar, battery backup- I 2 C connection cable (1m) to PLC- operation voltage supplied from mainboardDisplay/keypad unit <strong>AL</strong>1096- Models S and T:- 240x128 pixel graphic LCD display, backlit- Model S, 5 keys- Model T is touchscreen operated- Models PS and PE:- 320x240 pixel STN graphicLCD display, backlit- touchscreen operated- clock and calendar, battery backup- external supply voltage 24VDC±10%; < 10W- connection to PLC via modbus cable- programming with ADP software /PC serial port- communication protocol with AutoLog isModbus RTU<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 2 - 129/12/20062. SPECIFICATIONS2.1 Main Board <strong>AL</strong> <strong>20AN</strong>Instructions<strong>Logic</strong>, arithmetic, compare, timer, counter, step drive and reportingNumber of instructions About 260Program capacity 8192 instruction linesProgramming Instruction list using RS-232C terminal and PC with macros and commentsProgramming device Terminal or microcomputer with RS232C interfaceCycle timeAverage 3 ms + 20 µs per instruction line. In addition, a program loop to beexecuted every 5 ms can be programmed.Special functions When the PLC is booting the binary accumulator is 1 during the two first programcycles and when application program is running, the progran cycle time islocated in the register accumulator in the beginning of program cycle.The unit of cycle time is milliseconds and resolution is 5 ms.Auxiliary memories 256 x 1 bit memories; 128 of these with differentation.256 x 1 bit outputs, excluded PLC’s controlled connected outputs256 x 1 bit common memories (BM)256 x 1 bit common memories (GM)256 x 8 bit register memories ( R M )256 x 8 bit register general memories ( R GM )256 x 8 bit unconnected outputs ( R O ), reserved for PLC’s system program use2 of register outputs are connected to physical outputs of PLC256 x 16 bit directly addressable word memories (W M) (indirectly 65535 pcs)256 x 16 bit directly addressable word outputs (W O) (indirectly 4096 pcs)256 x 16 bit directly addressable word general memories (W GM)Timers4 timers 0.01 - 2.55 s, set by application program4 timers 0.1 - 25.5 s, set by application program8 timers 1 - 255 s, set by application program64 timers 0.1 - 25.5 s, set by application programText constants 256 text constant, length 16 character eachCounters16 counters 0 - 255, set by application programSequence registers 32 sequence registers, steps 0 to 255. 24 step registers have battery backupFIFO-registers 8 pcs, 256 places 8 bit registersShift registers 4 pcs, places 0 - 255, 8 bit registers<strong>Controller</strong>s32 pcs PID controllers with programmable parametersSerial interface 1 RS232 asynchronous communication port SER1 and 1 RS232 (with conversionmodule RS485) asynchronous communication port SER2.Baud rates 300/1200/2400/4800/9600/19200/28800/38400/57600.SER1 for programming (with PC). Both for terminal, MODBUS slave/master,serial printer, line modem, GSM modem or electric to optic modem.Memory retention The application program is held in FLASH memory.The single-bit memories M, GM, BM 0-95 and 192-255, outputs O 0-95 and192-255, word outputs 0-95, timers, counters and sequence rgisters (0-7) arereset after a power failure. Register memories, register outputs, 1 bit. memoriesM 64-191, outputs O 96-191, word outputs 96-4095, word memories, FIFO’s andshift registers retain their contents if desired.Digital inputs 8 - 32 pcs, depends on modules, 24 VDC/ max 8 mADigital outputs 8 pcs, 24 VDC/ max 1 A, group max. 2AAnalog inputs 0 - 8 pcs 12 bit, depends on modules (Pt100, 0(4)-20mA, 0-150mV 24vdc DI)Analog outputs 2 pcs 12 bit, (0-5VDC or 0-10VDC)Isolation24VDC inputs and outputs are isolated in groupAnalog inputs and outputs are not isolatedTiming control I 2 C connection for clock/calendar/display/keypad unitExpandability I 2 C connection (RJ45) for expansion boards, max. 8 expansion boardsBattery backup 2 years (full battery in storage conditions), app. 10 years in normal use.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 2 - 229/12/2006AutoLog <strong>20AN</strong> Instruction ManualWatchdogInstallationPower supply<strong>AL</strong><strong>20AN</strong> PLC has advanced watchdog functionality. The features ofwatchdog are described in chapter 5.1, page 5-1, concerning the functionalstate of the controller and in chapter 11, starting from page 11-1, concerningthe behaviour of PLC during different supply voltage levels.Can be mounted with expansion boards, installed on panel or on PHOENIXUM modules. With the modules the unit is mountable on DIN rail.Supply voltage 9 - 30 VDC or 6,5 - 21 VAC from external supply unit.2.2 Expansion board RO16Digital outputsBus connectionPower supplytheInstallation16 relay outputs, RC protection, outputs isolated from each other (two terminals)Connected from I 2 C FROM CPU connector to I/O connector on CPU or toI 2 C TO EXT connector on previous expansion board. The next expansion boardis connected to extpansion board’s I 2 C TO EXT connectorThe board receives the operation power from the CPU board. The power unit forcontrolled equipment must be external. The control voltage of field equipmentmust be < 250VAC/DC and maximum control current 1A.Can be mounted with CPU and expansion boards, install on plate or onPHOENIX UM modules.2.3 Expansion board RIO8Digital inputsDigital outputsBus connectionPower supplyInstallation8 group isolated inputs for contacts 24VDC or PNP sensors8 relay outputs, RC protection, outputs isolated from each other (two terminals)Connected from I 2 C FROM CPU connector to I/O connector on CPU or toI 2 C TO EXT connector on previous expansion board. The next expansion boardis connected to extpansion board’s I 2 C TO EXT connectorThe board receives the operation power from CPU board. The power unit for thecontrolled equipment must be external. The control voltage of field equipmentmust be < 250VAC/DC and maximum control current 1A.Can be mounted with CPU and expansion boards, install on plate or onPHOENIX UM modules. Modules needed for one RO16 board are 2 pcs UMK-SE 11,25-1, 1 pcs UMK-BE 22,5, 3 pcs UMK-BE 45 and 3 pcs UMK-FE.With these modules the unit is mountable on DIN rail.2.4 Expansion board DI16Digital inputsBus connectionPower supplyInstallation16 group isolated inputs for contacts 24VDC or PNP sensorsConnected from I 2 C FROM CPU connector to I/O connector on CPU or toI 2 C TO EXT connector on previous expansion board. The next expansion boardis connected to extpansion board’s I 2 C TO EXT connectorThe board receives the operation power from CPU board. The power unit for thecontrolled equipment must be external. The control voltage of field equipmentmust be < 250VAC/DC and maximum control current 1A.Can be mounted with CPU and expansion boards, install on plate or onPHOENIX UM modules.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 2 - 329/12/20062.5 Expansion board DO32Digital outputsBus connectionPower supplyInstallation32 in group isolated FET tarnsistor outputs.Connected from I 2 C FROM CPU connector to I/O connector on CPU or toI 2 C TO EXT connector on previous expansion board. The next expansion boardis connected to extpansion board’s I 2 C TO EXT connectorThe board receives the operation power from the CPU board. The power unitfor the controlled equipment must be external.The control voltage of field equipment must be < 30VDC and maximum controlcurrent 1A, max. group current 2A .Can be mounted with CPU and expansion boards, install on plate or onPHOENIX UM modules.2.6 Expansion board EXA8/4Analog inputsDigital inputsAnalog outputsBus connectionPower supplyInstallation0 - 8 pcs 12 bit, depends on modules (Pt100, 0(4)-20mA, 0-150mV, 24vdc DI,RMS AC voltage 0 - 0.25 VAC or 0 - 25 VAC)0 - 24 in steps of 3 inputs for potential free contacts, 24VDC (DIN module)4 pcs 12 bit analog outputs, 0 - 5 VDC or 0 - 10 VDC, defineable by softwareConnected from I 2 C FROM CPU connector to I/O connector on CPU or toI 2 C TO EXT connector on previous expansion board. The next expansion boardis connected to extpansion board’s I 2 C TO EXT connectorThe board receives the operation power from CPU board. The power unit for theanalog inputs external.Can be mounted with CPU and expansion boards, install on plate or onPHOENIX UM modules.2.7 <strong>AL</strong><strong>20AN</strong> Operating environment and storageSupply voltage 10 to 30 VDC / 7.5 to 21 VAC or18 to 30 VDC / 15 to 21 VAC from external power unitDegree of protection IP20 (unprotected)Operating temperature +5 to +45 °CStorage temperature -20 to +50 °C (non-condensing)<strong>FF</strong>-<strong>Automation</strong> Oy


Page 2 - 429/12/2006AutoLog <strong>20AN</strong> Instruction Manual2.8 Display/keypad units<strong>AL</strong>1093D/F:DisplayFunction keysTiming controlPower supplyProtection2x16 character alphanumeric LCD display, backlit16 keys ( 0 - F ), each key can control one binary output in PLC (16 pcs)Contains clock and calendar, battery backuppowered through I 2 C connection cable (1m) from CPU board.<strong>AL</strong>1093D is front panel mount model, rear construction is open and theunit can be fitted with a client-designed face plate.Model <strong>AL</strong>1093F is encapsulated, for front panel mounting, front panel seal IP54and the display can be fitted with client designed face plate.<strong>AL</strong>1094:DisplayKeypadIndicator lightsPower supplyProtection4 character LCD display8 keys ( 0 - 7 ), each key can control bit output4 LEDs, controlled by bit outputssupply voltage through system cable (0.25m) from PLC’s supply unit.open structure, not encapsulated. The display unit can be fitted with a clientdesignedface plate.<strong>AL</strong>1094R:DisplayKeypadIndicator lightsPower supplyProtection2 x 16 character alphanumeric LCD display, backlit4 keys ( 0 - 3 ) each key can control bit output2 LEDs, controlled by bit outputssupply voltage through system cable (0.9m) from PLC’s supply unit.open structure, not encapsulated. The display unit can be fitted with a clientdesignedface plate.<strong>AL</strong>1094AF / 1094FM:DisplayKeypadIndicator lightsPower supplyProtection2 x 20 character alphanumeric LCD display, backlit8 keys ( 0 - 7 ) /16 keys (0 - F), each key can control bit output4 LEDs, controlled by bit outputs, buzzer and extra output for external buzzersupply voltage through system cable from PLC’s supply unit.open structure, not encapsulated. The display unit can be fitted with a clientdesignedface plate.<strong>AL</strong>1095A/B:DisplayKeypadIndicator lightsTiming controlPower supplyProtection8x21 character alphanumeric LCD display / 128x64 pixel graphix display,backlit. In graphic mode 4 different trends / 4 different bar graphs.A-model has 16 keys ( 0 - F ), B-model has 4 keys ( 0 - 3 ) each key cancontrol bit output8 LEDs, controlled by bit outputscontains clock and calendar, battery backupsupply voltage through system cable (1m) from PLC’s supply unit.<strong>AL</strong>1095A is encapsulated, front panel mounting model, front panel seal IP54and the display unit can be fitted with a client-designed face plate<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 2 - 529/12/2006<strong>AL</strong>1096S/T:Display STN graphic 240x128 pixel LCD display (display area 108x58 mm 2 ),backlit. Freely designeable graphic figures.KeypadS-model 5 keys, T-model is touch-sensitive display unit(10x8 switches)ScreensMax. 255 graphic screensUser memory 128k FLASHFirmware memory 64k FLASHWorking memory 32k RAMPower supply 24VCD +10%.... -15%, 0.35A.Installation Front panel mount model, dimensions 192x144x75 mmFront panel seal IP54Operatingenvironment 0 - 50°C; 20 - 90% relative humidity (non condensing)Communication port One RS232/RS422/RS485, 9600 - 19200 bit/sPLC prototocol Modbus RTU, unsigned binary in connection with AutoLog PLC’s.<strong>AL</strong>1096PS/PE:Display STN graphic 320x240 pixel LCD display (display area 116x86 mm 2 ),backlit, monochrome blue mode STN LCD, freely designeable graphic figures.Display adjustment Contarst adjustable from touch screenTouch screen Analogue resistive type; max. number of switches are 40x30User memory 512k FLASHPower supply 24VCD ±10%, under 10W.Installation Front panel mount model, dimensions 203x161x70 mmFront panel seal IP65Operatingenvironment 0 - 50°C; 20 - 90% relative humidity (non condensing)CommunicationportsCOM1: RS232, 4800/9600/19200 bit/sCOM2 RS232/RS422/RS485, 4800/9600/19200 bit/sPLC prototocol Modbus RTU, unsigned binary in connection with AutoLog PLC’s.Additional features of <strong>AL</strong>1096PEPrinter port Centronics compatibleBattery backedmemory 64k, used for recipes and data logging<strong>FF</strong>-<strong>Automation</strong> Oy


Page 2 - 629/12/2006AutoLog <strong>20AN</strong> Instruction Manual<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 3 - 129/12/20063. COMPONENT LAYOUT3.1 Main Board <strong>AL</strong><strong>20AN</strong>CON302CON301CON303SW1CON101H108H107H106H105H104H103H102H101MOD6MOD4IC3IC4MOD7MOD5MOD3MOD2MOD1MOD0IC1IC2IC10RX TXRX 12VRUNH201H202H203H204H205H206H207H208SER2CON501SER1CON1TXEXT2I C2ICB1CON201CON502CON503 J1 J2CON403CON401CON402CON1 Power supplyCON101 Digital inputsCON201 Digital outputsCON301 Analog inputsCON302 Analog inputsCON303 Analog outputsCON501 RS485 serial connectionCON502 RS232 serial connectionCON503 RS232 serial connectionCON401 I 2 C for display unit RJ45CON402 I 2 C for display unitCON403 I 2 C for expansion boards RJ45SW1 DIP-switchJ1, J2 Watchdoc & 12 VDC power jumpersIC1 ProcessorIC10 Address coderIC2 Data-RAMIC3 System program FLASHIC4 Application program FLASH3.2 Expansion board RO16CON104CON103CON102CON10115B15A14B14A13B13A12B12A11B11A10B10A9B9A8B8A7B7A6B6A5B5A4B4A3B3A2B2A1B1A0B0AH9H10H11H12H13H14H15H16H1H2H3H4H5H6H7H8C11 C10 C9 C8 C7 C6 C5 C4 C3 C18 C17 C16 C15 C14 C13 C12K8 K7 K6 K5 K4 K3 K2 K1 K16 K15 K14 K13 K12 K11 K10 K9IC8IC5IC6IC7CON2FROM CPUCON1J11-2 3-4 ADDR1 1 321 0 480 1 640 0 80TO EXTCON101 Relay outputs 0 - 3CON102 Relay outputs 4 - 7CON103 Relay outputs 8 - 11CON104 Relay outputs 12 - 15CON1 Control cable from CPUCON2 Control cable to expansion boardsAddress codes for outputs in chapter 4.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 3 - 229/12/2006AutoLog <strong>20AN</strong> Instruction Manual3.3 Expansion board RIO8FROM CPUTO EXTCON101 Digital inputsCON102 Relay outputsCON103 Relay outputsCON1 Control cable from CPUCON2 Control cable to expansion boardsAddress codes for outputs / inputs in chapter 4.3.4 Expansion board DI16 GND1514131211100908 GND0706050403020100 CON1CON2www.<strong>FF</strong>-<strong>Automation</strong>.comJ1 1234561-2 3-4 5-6 ADDR 1-2 3-4 5-6 ADDR1 1 1 32 0 1 1 641 1 0 40 0 1 0 721 0 1 48 0 0 1 801 0 0 56 0 0 0 88 CON1CON2FROM CPUwww.<strong>FF</strong>-<strong>Automation</strong>.comJ11-2 3-4 ADDR1 1 321 0 480 1 640 0 80TO EXTCON101 Digital inputsCON102 Digital inputsCON1 Control cable from CPUCON2 Control cable to expansion boardsAddress codes for outputs / inputs in chapter 4.<strong>FF</strong>-<strong>Automation</strong> Oy


C2AutoLog <strong>20AN</strong> Instruction ManualPage 3 - 329/12/20063.5 Expansion board DO3211H C13.6 Expansion board EXA8/4134133132131124123122121114113112111104103102101848382812ICRUNIC105IC3MOD104MOD103MOD102MOD101JP2IC2RUNMOD105MOD107X1MOD106MOD108IC1IC103IC102IC1012IC14114214314415115215315416116216316417117217317485868788 COM232231230229228227226225COM224223222221220219218217 COM216215214213212211210209COM208207206205204203202201 ☺ ☺ ☺ ☺ ☺CON1FROM CPUJ1 1 2 3 4J1 1-2 ADR 32J1 3-4 ADR 64www.<strong>FF</strong>-<strong>Automation</strong>.comTO EXTCON2CON101 Digital outputsCON102 Digital outputsCON201 Digital outputsCON202 Digital outputsCON1 Control cable from CPUCON2 Control cable to expansion boardsAddress codes for outputs / inputs in chapter 4.IC1 ProcessorCON1 Connection from CPU’s I 2 C display connectorCON2 Connection to display unit or to next EXA8/4 boardCON101 Analog inputsCON102 Analog inputsCON201 Analog outputsMOD101 - 108 Analog conversion module connectorsAddress codes for outputs / inputs in chapter 4.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 3 - 429/12/2006AutoLog <strong>20AN</strong> Instruction ManualTypical connection layout for AutoLog <strong>20AN</strong> control systemIC3IC1TEMPERATURE +65°C12:31041 2 35 6 74321IC2Display/keypad unitCON302CON301CON303SW1CON101H108H107H106H105H104H103H102H101MOD6MOD7MOD4MOD5MOD3MOD2MOD1MOD0IC1IC3IC2IC4<strong>AL</strong><strong>20AN</strong> (CPU)20 I/O points,of which someare configurableIC10H201H202H203RX TXRX 12VH204H205H206H207H208RUNSER2CON501SER1CON1TXEXT2I C2ICB1CON201CON502CON503 J1 J2CON403CON401 CON402CON104CON103CON102CON101H9H10H11H12H13H14H15H16H1H2H3H4H5H6H7H8Max. 5 metersC11 C10 C9 C8 C7 C6 C5 C4 C3 C18 C17 C16 C15 C14 C13 C12K8 K7 K6 K5 K4 K3 K2 K1 K16 K15 K14 K13 K12 K11 K10 K9Expansion I/O board16 relay outputsIC8IC5IC6IC7CON2FROM CPUCON1J11-2 3-4 ADDR1 1 321 0 480 1 640 0 80TO EXTMax. 5 meters Expansion I/O board16 digital inputs CON1FROM CPUJ11-2 3-4 ADDR1 1 321 0 480 1 64www.<strong>FF</strong>-<strong>Automation</strong>.com 0 0 80TO EXTCON2<strong>FF</strong>-<strong>Automation</strong> Oy


CON302MOD6 MOD4MOD7 MOD5SER2CON502RX TXRX 12VCON501SER1TXCON1CON301CON503 J1 J2IC1EXT I CCON4032IC10I CCON401 CON4022CON303 CON101IC3 IC4B1IC2CON201H208H207H206H205H204H203H202H201RUNAutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 4 - 129/12/2006 04/01/994. SWITCHES4.1 Main Board <strong>AL</strong><strong>20AN</strong>IC3 IC4CON303 CON10111110410310210184838281ON1 2 3 4 5 6SW1181716MOD3MOD2MOD1MOD0H108H107H106H105H104H103H102H101SW1DIP-switch SW1DIP ON O<strong>FF</strong>1 FLASH not write protected FLASH write protected2 Ser1: (Mode selected by R O 214 )- for controller printouts- Modbus- programming deviceSer1:Used for programmingDIP 300 bd 1200 bd 9600 bd Rate determinedby R O 21334O<strong>FF</strong>O<strong>FF</strong>ONO<strong>FF</strong>O<strong>FF</strong>ONONONDIP ON O<strong>FF</strong>5 Data memory cleared whencontroller is switched onData memory retainedduring power failureNOTE! System programreads DIP switch settingsand values of registeroutputs 213 and 214 afterevery program cycle.This means that settingssuch as linecommunicationparameters can bechanged without powershut down.<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 4 -- 204/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual4.2 Jumpers on Main boardRX TXRX 12VRUNSER2CON502CON501D+D-GNDSER1TXCON11 +24V2 GDN3 AC24 AC1CON503 J1 J2EXTCON4032I CCON4012ICCON402B112VJ14321J24321Jumper Reset voltage WatchdogJ1 : 1 - 2J1 : 3 - 4O<strong>FF</strong> = 17 VON = 9 VO<strong>FF</strong> = DisabledON = EnabledJumperUse PLC’s 12 Vsupply voltageJ2 : 1 - 2 O<strong>FF</strong> = NOON = YESJ2 : 3 - 4Enable internal12 V powerO<strong>FF</strong> = DisabledON = Enabled<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 4 - 329/12/2006 04/01/994.3 Expansion board RO16J1: 1-2 J1: 3-4 AddressCON104CON103CON102CON101ON ON 32 - 47O<strong>FF</strong> ON 48 - 63ON O<strong>FF</strong> 64 - 79O<strong>FF</strong> O<strong>FF</strong> 80 - 95H9H10H11H12H13H14H15H16H1H2H3H4H5H6H7H8C11 C10 C9 C8 C7 C6 C5 C4 C3 C18 C17 C16 C15 C14 C13 C12K8 K7 K6 K5 K4 K3 K2 K1 K16 K15 K14 K13 K12 K11 K10 K9IC8IC5IC6IC7CON2FROM CPUCON1J11-2 3-4 ADDR1 1 321 0 480 1 640 0 80TO EXT4.4 Expansion board RIO8J1: 1-2 J1: 3-4 J1: 5-6 AddressON ON ON 32 - 39O<strong>FF</strong> ON ON 40 - 47ON O<strong>FF</strong> ON 48 - 55O<strong>FF</strong> O<strong>FF</strong> ON 56 - 63ON ON O<strong>FF</strong> 64 - 71O<strong>FF</strong> ON O<strong>FF</strong> 72 - 79ON O<strong>FF</strong> O<strong>FF</strong> 80 - 87O<strong>FF</strong> O<strong>FF</strong> O<strong>FF</strong> 88 - 95 CON1 FROM CPU www.<strong>FF</strong>-<strong>Automation</strong>.com J1 1234561-2 3-4 5-6 ADDR 1-2 3-4 5-6 ADDR1 1 1 32 0 1 1 641 1 0 40 0 1 0 721 0 1 481 0 0 56 0 0 1 800 0 0 88 TO EXT CON2 4.5 Expansion board DI16J1: 1-2 J1: 3-4 Address ON ON 32 - 47 O<strong>FF</strong> ON 48 - 63ON O<strong>FF</strong> 64 - 79 O<strong>FF</strong> O<strong>FF</strong> 80 - 95CON1FROM CPUJ11-2 3-4 ADDR1 1 321 0 48www.<strong>FF</strong>-<strong>Automation</strong>.com0 10 06480TO EXTCON2<strong>FF</strong>-<strong>Automation</strong> Oy


C2HC11 J1 1-2 ADR 32J1 3-4 ADR 64 ☺ ☺ ☺ ☺☺www.<strong>FF</strong>-<strong>Automation</strong>.com 1Sivu Page 4 -- 404/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual4.6 Address jumpers on DO32 boardJumpers 1 - 2 3 - 4Output1 32 642 33 653 34 664 35 675 36 686 37 697 38 708 39 719 40 7210 41 7311 42 7412 43 7513 44 7614 45 7715 46 78FROM CPUJ1 1 2 3 4 CON1 CON216 47 7917 48 8018 49 8119 50 8220 51 8321 52 84TO EXT 22 53 8523 54 8624 55 8725 56 8826 57 8927 58 9028 59 9129 60 9230 61 9331 62 9432 63 95<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 4 - 529/12/2006 04/01/994.7 Address jumpers on EXA8/4 board2ICIC105IC3MOD104MOD103MOD102MOD101JP2RUNIC2MOD105MOD107X1MOD106MOD108IC1IC103IC102IC101RUN2ICJumpers 1 - 2 3 - 4 5 - 6 Analog Analog DigitalCard Address inputs outputs inputs1 ON ON ON 32 - 39 32 - 35 96 - 1192 O<strong>FF</strong> ON ON 40 - 47 40 - 43 120 - 1433 ON O<strong>FF</strong> ON 48 - 55 48 - 51 144 - 1674 O<strong>FF</strong> O<strong>FF</strong> ON 56 - 63 56 - 59 168 - 1915 ON ON O<strong>FF</strong> 64 - 71 64 - 67 192 - 2396 O<strong>FF</strong> ON O<strong>FF</strong> 72 - 79 72 - 757 ON O<strong>FF</strong> O<strong>FF</strong> 80 - 87 80 - 838 O<strong>FF</strong> O<strong>FF</strong> O<strong>FF</strong> 88 - 95 88 - 91<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 4 -- 604/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 45 - 15. INDICATOR LIGHTS29/12/2006 04/01/99 12/01/995.1 Main Board <strong>AL</strong><strong>20AN</strong>A red LED indicator light indicates the functional state of the controller as follows:RX TXRX 12VRUNSER2CON502CON501D+D-GNDSER1CON1TX1 +24V2 GDN3 AC24 AC1CON503 J1 J2EXTCON403I 2 C IC2CON401CON402B1LIGHT PROGRAM STATE CAUSED BY ACTIONSteady on or dark,i.e. duty cycle 100 %Program halted.Outputs retain theirProgram halted withprogramming deviceProgram can be startedwith START (!) characterSlow flashing (0.5Hz),duty cycle 50 %Program running<strong>Controller</strong> is operatingnormallyCombined slow andfast flashing rateProgram runningUnsteady supply power.Flashing rate will return tonormal 4 minutes afterCheck quality of supplypowerFast flash,duty cycle 90 %Program halted.Outputs cleared to zeroLow supply voltage, hasfallen below 16V and notCheck quality of supplypowerFast flash (5Hz),duty cycle 50 %Program halted.Outputs cleared to zeroProgram errorCorrect the program andstart program executionVery fast flash,duty cycle 20 %Program halted.Outputs cleared to zeroHardware fault, or STOPinstruction ha beenremoved, or ENDinstruction has beenrelocated during programexecutionSwitch controller poweroff and back on, correctthe program and startexecution<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 45 - - 212/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual5.2 Indicator LEDs for inputs and outputsLED indicateswhen 12 VDC voltage isconnected toanalog modulesand to expansionboards (RIO8,RO16, DI16 orDO32)Digital inputs10 I O Input 011 I 1 Input 112 I 2 Input 213 I 3 Input 314 I 4 Input 415 I 5 Input 516 I 6 Input 617 I 7 Input 7Digital outputs20 O 0 Output 021 O 1 Output 122 O 2 Output 223 O 3 Output 324 O 4 Output 425 O 5 Output 526 O 6 Output 627 O 7 Output 7RS232 RS485 RS232POWEREXPANSIONBOARDSO 0O 1O 2O 3O 4O 5O 6O 7COMDISPLAY BATTERYDIGIT<strong>AL</strong> OUTPUTSCON502D+D-GNDCON503 J1 J2TX1 +24V2 GDN3 AC24 AC1CON403CON401 CON402202122232425262728CON501CON1B1SER2SER1CON2012EXT I C2ICRX TXRX 12VRUNH201H202H203H204H205H206H207H208IC10IC2MOD6 MOD4MOD7 MOD5MOD3MOD2MOD1MOD0IC3 IC4IC1H108H107H106H105H104H103H102H101CON302CON301CON303 CON101SW117417317217116416316216115415315215114414314214113413313213112412312212111411311211110410310210184838281181716151413121110AN<strong>AL</strong>OG INPUTS 4 - 7 AN<strong>AL</strong>OG INPUTS 0 - 3 AN<strong>AL</strong>OG OUTDIGIT<strong>AL</strong> INPUTS7 GND7 Sign-7 Sign+7 I+6 GND6 Sign-6 Sign+6 I+5 GND5 Sign-5 Sign+5 I+4 GND4 Sign-4 Sign+4 I+3 GND3 Sign-3 Sign+3 I+2 GND2 Sign-2 Sign+2 I+1 GND1 Sign-1 Sign+1 I+0 GND0 Sign-0 Sign+0 I+O 1 I-O 1 I+O 0 I-O 0 I+COMI 7I 6I 5I 4I 3I 2I 1I 0<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 45 - 35.3 Indicator LEDs for outputs of RO16 board29/12/2006 04/01/99 12/01/99FROM CPU1-2 3-4 ADDR1 1 321 0 480 1 640 0 80TO EXTCON1J1IC8IC7IC5 IC6CON2K8 K7 K6 K5 K4 K3 K2 K1 K16 K15 K14 K13 K12 K11 K10 K9C11 C10 C9 C8 C7 C6 C5 C4 C3 C18 C17 C16 C15 C14 C13 C12H9H10H11H12H13H14H15H16H1H2H3H4H5H6H7H815B15A14B14A13B13A12B12A11B11A10B10A9B9A8B8A7B7A6B6A5B5A4B4A3B3A2B2A1B1A0B0ACON104CON103 CON102CON101O 47O 46O 45O 44O 43O 42O 41O 40O 39O 38O 37O 36O 35O 34O 33O 32Output numbers shown in picture are smallestpossible address values on expansion board.<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 45 - - 412/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual5.4 Indicator LEDs for inputs of DI16 board GND1514131211100908 GND0706050403020100GNDI 47I 46I 45I 44I 43I 42I 41I 40GNDI 39I 38I 37I 36I 35I 34I 33I 32 Input numbers shownin picture are smallestpossible addressvalues on expansionboard.CON1CON2FROM CPUwww.<strong>FF</strong>-<strong>Automation</strong>.comJ11-2 3-4 ADDR1 1 321 0 480 1 640 0 80TO EXT5.5 Indicator LEDs for inputs of RIO8 board O 39O 38O 37O 36O 35O 34O 33O 32I 39I 38I 37I 36I 35I 34I 33I 32 CON1CON2FROM CPUwww.<strong>FF</strong>-<strong>Automation</strong>.comJ1 1234561-2 3-4 5-6 ADDR 1-2 3-4 5-6 ADDR1 1 1 32 0 1 1 641 1 0 40 0 1 0 7211001048560000108088TO EXTInput and output numbers shown in picture are smallest possibleaddress values on expansion board.<strong>FF</strong>-<strong>Automation</strong> Oy


1H1AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 45 - 529/12/2006 04/01/99 12/01/995.6 Indicator LEDs for outputs of DO32 boardFROM CPUwww.ff-automation.comTO EXTJ1 1-2 ADR 32J1 3-4 ADR 64CON1 CON2J1 1 2 3 4C2 C1 ☺ ☺ ☺ ☺ ☺ COM232231230229228227226225COM224223222221220219218217 COM216215214213212211210209COM208207206205204203202201 O 63O 62O 61O 60O 59O 58O 57O 56O 55O 54O 53O 52O 51O 50O 49O 48O 47O 46O 45O 44O 43O 42O 41O 40O 39O 38O 37O 36O 35O 34O 33O 32Output numbers shown in picture are smallestpossible address values on expansion board.<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 45 - - 612/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual5.7 RUN led indicating function of EXA8/4 boardAI36+AI36 I+AI36 I–COMAI37+AI37 I+AI37 I–COMAI38+AI38 I+AI38 I–COMAI39+AI39 I+AI39 ICOM141142143144151152153154161162163164171172173174IC101IC103IC102MOD106MOD108MOD105MOD107MOD103 MOD101MOD104 MOD102IC105134133132131124123122121114113112111104103102101COMAI35 IAI35 I+AI35 +COMAI34 I–AI34 I+AI34 +COMAI33 I–AI33 I+AI33 +COMAI32 IAI32 I+AI32 +AO34+COMAO35+COM858687882ICIC1RUNIC2JP2IC32IC84838281COMAO33+COMAO32+X1RUNInput and output numbers shown in picture are smallestpossible address values on expansion board.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 45 - 729/12/2006 04/01/99 12/01/995.8 Display/keypad unit <strong>AL</strong>1093DChe board has six indicatorlights controlled by registeroutput R O 2045.9 Display/keypad unit <strong>AL</strong>1093Fhe board has six indicatorlights controlled by registeroutput R O 2045.10 Display/keypad unit <strong>AL</strong>1094/R/AFThe boards has two / four indicator lightscontrolled by register output R O 204.<strong>AL</strong>1094<strong>AL</strong>1094AF<strong>AL</strong>1094R<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 45 - - 812/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual5.11 Display/keypad unit <strong>AL</strong>1094FMThe board has four indicator lights, buzzer andoutput controlled by register output R O 204041 2 35 6 74 LED43LED48 9 A BC D E F21LED4LED45.12 Display/keypad unit <strong>AL</strong>1095A/BThe board has eight indicator lights controlledby register output R O 204DIS1LED1LED2LED3LED4LED5LED6LED7LED8<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 65 - 129/12/200604/01/996. INST<strong>AL</strong>LATION AND CONNECTIONS6.1 Environmental requirementsThe inputs and outputs of the <strong>AL</strong><strong>20AN</strong> CPU board are isloated in group and theisolation of the inputs on expansion boards and DIN modules depends onconstruction of board. More information of isolation in following chapters. Theserial connectors RS232 and parallel with it RS485 (SER2) and RS232 (SER1)are not isolated from PLC’s internal voltages. To ensure proper function of<strong>AL</strong><strong>20AN</strong> the installation circumstances must be carefully considered.Operating temperature + 5 to + 45°CMoisture, corrosive gases, liquids and conductive dust must not be presentwhere PLC boards are installed.The PLC boards don't resist heavy vibration very well.The distance from electromagnetic field generating devices, such as electricmotors, switch gear, thyristors, welding equipment, switched power suppliesand power converters/inverters must be adequate.PLC boards are quite immune against powerfull light sources.If some item above or any other envinronmental feature may cause errors to PLCfunction it is advisable to install the PLC in the steel plate enclosure. It is also advisableto install possible auxiliary input/output relays fuses and power units intheir own enclosure near the PLC. All the contactors connected to PLC have to beequipped with RC protection devices and the 24 VDC control relays withextinguish diodes.6.2 Field wiring6.2.1 Earthing/groundingThe metal parts of the PLC enclosure must be connected to the plant’s logicground.6.2.2 Power supply connectionsNormally no functional grounding is necessary when 24 volt floating voltagesystem is used with the PLC’s power supply connection. It is important that the 24volt wiring is carefully kept isolated from ground level and 230 volt supply voltages.The CPU board, <strong>AL</strong><strong>20AN</strong> receives the +24 V DC supply voltage from an external,isolated power supply unit (such as 24VDC /1.2A or 24VDC /2.5A). The controllerconverts this to the voltages it requires.<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 54 6 - - 212/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualExpansion boards DI16, RIO8, RO16 and DO32 receive their supply power fromCPU board through the bus cable. Input board DI16 and the input part of theboard RIO8 doesn’t need any external power supplies. The control/operatingpower for the controlled loads must be taken from external supply units.6.2.3 Digital inputsThe digital inputs are isolated in group on <strong>AL</strong><strong>20AN</strong> CPU board. Externallypowered potential free contacts or PNP type inductive/capacitive sensors may beconnected to PLC. The supply voltage for the PNP sensors is normally taken fromexternal I/O power unit.It is recommended to use twisted pair shielded cables in input wiring. The cablingshould be installed separately from the 230/400 VAC power cabling. The cableshields may be connected to logic ground only at one point, normally at the end onthe PLC enclosure. If there is heavy electromagnetic disturbance, the PLC’sunisolated inputs can be isolated from field equipment with relays oroptoelectronic modules.Look at chapter 6.3.3.6.2.4 Digital outputsThe digital outputs are isolated in group on <strong>AL</strong><strong>20AN</strong> CPU board and on DO32expansion board. Only low powered 24VDC control relays, LED indicating lights or24 volt indicating lights may be connected to the outputs. The supply voltage forloads is taken from external I/O power unit.It is recommended to use twisted pair shielded cables in output wiring. The cablingshould be installed separately from the 230/400 VAC power cabling. The cableshields may be connected to logic ground only at one point, normally at the end onthe PLC enclosure. If there is heavy electromagnetic disturbances, the PLC’sisolated outputs can be double isolated from field equipmnet with relays oroptoelectronic modules. Look at chapter 6.3.3.6.2.5 Analog inputs/outputsThe analog inputs and outputs are unisolated in <strong>AL</strong><strong>20AN</strong> CPU board and inEXA8/4 expansion board. If active transducers are used, it should be checked thatthe output circuits of the transducers are galvanically isolated from it’s supplyvoltages. If you can’t be sure of isolation, it is advisable to furnish the transducerwith an external galvanic isolator. The supply power for passive transducer isnormally taken from PLC’s power unit. The impedance of <strong>AL</strong><strong>20AN</strong> PLC’s analogmilliamper input is 46Ω.It is recommended to use twisted pair shielded cables in output wiring. The cablingshould be installed separately from the 230/400 VAC power cabling. The cableshields may be connected to logic ground only at one point, normally at the end onthe PLC enclosure.RMS analog input modules requires 12 VDC power to function. Look at page 6.5section Power supply connection for expansion boards and DIN moduleshow to check that 12 VDC power is connected.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 65 - 36.3 Connection examples digital inputs / outputsThrere are 8 - 32 digital inputs on <strong>AL</strong><strong>20AN</strong> CPU board. 8 inputs of those areisolated in group from PLC’s internal voltages. Inputs connected vith DIN modulesto analog inputs are not isolated. The 8 inputs on RIO8 expansion board and 16digital inputs on DI16 expansion board are not isolated.Terminal strips for 2,5mm 2 wire are provided.29/12/200604/01/996.3.1 Connecting a switch or NPN sensor to unisolated digital input+12VDC+ 24VDC- 24VDC<strong>AL</strong><strong>20AN</strong> v2, unisolated DI16, RIO8 or <strong>AL</strong>20DIN module (3 Inputs)6.3.2 Connecting a switch or PNP sensor to isolated digital input on CPU boardInternalExternalI1SwitchI0GNDPNPsensor6 - 30 VDC<strong>AL</strong><strong>20AN</strong> v01212, isolated RIO8 or DI16<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 54 6 - - 412/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual6.3.3 Connecting loads to digital outputsThere are 8 digital outputs, isolated in group, on <strong>AL</strong><strong>20AN</strong> V01212 CPU board, 8 relayoutputs on RIO8 expansion board, 16 relay outputs on RO16 expansion board and 32FET outputs on DO32 expansion board.Terminal strips for 2,5 mm 2 wire are provided.Connection of load to groupisolated transistor output12 - 30 VDC28COM21O0 ... O7Load20O0 ... O7Load<strong>AL</strong><strong>20AN</strong> v01212 CPU or DO32Connection of load to relay outputOn( )Load+0 - 240VAC(/DC)+0 - 240 VAC(/DC)( )N(/ )On( )LoadN(/ )OnLoad+0 - 240 VAC(/DC)( )N(/ )RIO8 or RO16 boardCOMRIO8 or RO16 boardOnLoad<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 65 - 529/12/200604/01/996.3.3 Optoelectronic / relay isolation of inputs and outputsSince the inputs and outputs (excluding relay outputs) are not isolated on<strong>AL</strong><strong>20AN</strong> PLC boards, it is advisable to provide external isolation in anenvironment prone to disturbances. A suitable solution is the use of PHOENIXdigital optical input interface modules and relay output modules. The Modulesprotect the PLC against the static discharges and cut the circulating faultcurrents. The modules are mechanically fully protected DIN rail units.Features of the I/O modules:• very long life• optoelectronic isolation rated at 2500 V• low power consumption• vibration proofPHOENIX’s digital I/O modulestype I/O voltage max. current logic voltageDEK-OE-24DCDEK-OE-230ACDEK-REL-24/1/SEN24 ± 20% VDC230 ± 10% VAC12 - 250 VAC 3 A24 V24 V24 VOE modules are inputmodules and REL modules are relay output modules.INPUT MODULE DEK-OE-230ACOUTPUT MODULE DEK-REL-24/1/SENA1A1+ 13AA2A20 14PHOENIX modules: DEK-OE input module and DEK-REL type output module<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 54 6 - - 612/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualThe figure below shows how Phoenix DEK-... -interface modules may beconnected to <strong>AL</strong><strong>20AN</strong> V01212 CPU board’s group isolated input/output points.N (-)~ ( + )13141314DEK-REL-...SENDEK-REL-...SENA1A2A1A2A1A2DEK-OE-...VAC/DC+A0~ ( + ) N (-)A1A2FIELDDEK-OE-...VAC/DCPHOENIXDEK...CONTROL+A0I/O PowersupplyCON401 CON402202122B12IC2ICCON201RUNIC10IC2IC1IC3 IC4CON303 CON10111411311211110410310210184838281181716232425262728151413121110<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 65 - 729/12/200604/01/996.4 Analog inputsThere are 0 - 8 individually adaptable analog inputs on CPU board and 0 - 8 inputson EXA8/4 board which can be used for the measurement of temperature, currentor voltage signals. The number of available analog inputs is defined according toadapter modules. Part or all of analog inputs can be defined as digital inputs byadapter modules. Analog inputs are not isolated from PLC vlotages. Everymeasured signal / range needs its own individual adapter module.(Look chapter14. LIST OF PRODUCTS).6.4.1 Connection examplesBecause of the low signal levels to be measured, shielded twisted-pair cablesshould be used. The shield should be grounded at one end only in order to avoiddegradation of accuracy by external disturbances.GND101102103104I+sign+sign-I-Pt100Temperature measurement with a PT100 sensorThe current (I+ - I-) flows through the PT100 sensor.The measurement is made by inputs sign+ and sign-101102103I+sign+sign-U= 0...5V0...10VVoltage measurementTwo ranges are available: 0...5V or 0...10V.GND104I-+-121122123sign-I+ 4...20 mAsign+Passive transm.Power unitfor PLCCurrent measurementTwo ranges are available: 0...20mA or 4...20mA.GND124I-24 VDC<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 54 6 - - 812/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualConnection of potential free contact to unisolated input module <strong>AL</strong>20DIN andisolated input module <strong>AL</strong>20DIN I.In the picture below are shown lowest possible input numbers.101102I+sign+Inp. 8101102I+sign+Inp. 8GND103104sign-I-Inp. 9Inp. 10GND103104sign-I-Inp. 9Unisolated<strong>AL</strong>20DIN moduleInput contactsIsolated Ext. 24VDC - +<strong>AL</strong>20DIN I module Input contacts6.5 Analog outputs on Main and EXA8/4 boardsThe <strong>AL</strong><strong>20AN</strong> board has two (12 bit) analog outputs and EXA8/4 board has four(12 bit) analog outputs. The analog outputs are voltage outputs (0 ... 5V or 0 ... 10V),the output voltage levels are defineable by register outputs ( R O 9 - 17).Register output 9 (R O 9) includes this information in it’s two least significant bits andR O 10 - 17 includes this information in it’s four least significant bits.Analog output 0 (W O 0) has voltage level bit 0 and W O 1 bit 1. Whencorresponding bit is zero (0) voltage range is form 0 to 5 volts and when the bit is one(1)output level is from 0 to 10 VDC. If both outputs are wanted for output range 0 - 10 V,correct value for R O 9 is three (3 = 00000011 bin).The define variables for EXA8/4 board’s outputs are presented in chapter 7.81820 ... 10 VR = 4k7min83840 ... 10 VR = 4k7min<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 65 - 929/12/200604/01/996.6 Serial communicationThe <strong>AL</strong><strong>20AN</strong> CPU board has two RS232 serial connections by RJ 45 connector andwith SER2 a parallel RS485 connector. The function of serial communication SER1 isdefined by DIP switch (SW1) and register outputs RO215 and RO229. The RS485communication needs an additional converter board installed on CPU card. Thecommunication behaviour of serial port SER2 is defined using register outputs. Lookin chapter 7.6.6.1 Connector signalsPin Signal Pin Signal1 +5V (form PLC)2 RXD (data to PLC)3 TXD (data from PLC)4 DTR (approx. 12V from PLC)5 GND6.6.2 Interconnection cables6 N/C7 RTS8 CTS12345678Pin numbers ofRJ45 connector,seen from front offemale connectorPCCannon DB25STxD 2RxD 3GND 7<strong>AL</strong><strong>20AN</strong>RJ452 RxD3 TxD5 GNDPCCannon DE9STxD 3RxD 2GND 5<strong>AL</strong><strong>20AN</strong>RJ452 RxD3 TxD5 GNDMODEMCannon DE25PRxD 3TxD 2GND 7DTR 20DCD 8RTS 4CTS 5OR<strong>AL</strong><strong>20AN</strong>RJ452 RxD3 TxD5 GND7 RTS8 CTS7 RTS8 CTSApplies in the case of a dialledconnectionApplies in the case ofa leased line<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 54 6 - - 1012/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual6.6.3 <strong>AL</strong><strong>20AN</strong> and CNV4 Signal level converter boardIt’s possible to isolate the serial connections by using external conversionmodules e.g. CNV4. The CNV4 provides isolation of the serial communicationsignal and conversion of the voltage level of the signal. All units, power supply,RS232 side and RS422/485 side are galvanic isolated from each other. The signallevel can be +5 V, RS-232C or RS-422/485. Isolation is neccessary when thedevices communicating through the line are fed from power sources at differingpotentials. The output of the RS-422/485 interface is in a high-impedance statewhen not transmiting, and max. 32 PLC’s can be connected to the same bus. Thecommunication cable to the CNV4 board comes from the RJ45 (RS232) connectorof the <strong>AL</strong><strong>20AN</strong>.The CNV4 signal level converter board is described in more detail in a separateinstruction: CNV4.The figure below shows an example of the use of the CNV4: the connection of<strong>AL</strong><strong>20AN</strong> controller via an RS-232/RS485 interface to RS232 board.Power supply unitPC / RS2321230 VAC INL1N230 VAC/5 - 9 VDC or18 - 36 VDC or36 - 72 VDCdepending onCNV-4 typeRX2TXGNDRTSCTS3456789D+D-RS232RJ45ACACDCDCPOWERTX/RXTX/RXCOMRXRXRS422/485RXDTXDPLCRS485TXDRXDRS422/485RXRXCOMTX/RXTX/RXPOWERDCDCACACRJ45RS232PLCRS23212345678+5VRxTxGNDRTSCTS<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 5 6 - 1129/12/200604/01/996.6.4 <strong>AL</strong><strong>20AN</strong> and CNV2/CNV4 Signal level converter boardsIt’s possible to isolate the serial connections by using external conversionmodules e.g. CNV2 and CNV4. The CNVs provides isolation of the serialcommunication signal and conversion of the voltage level of the signal. The inputsignal level from PLC is +5 V RS-232C. Isolation is neccessary when the devicescommunicating through the line are fed from power sources at differing potentials.CNV2 gets power supply from PLC through communication cable and uses RTS/CTS handshakes. CNV4 accepts power supply either from PLC throughcommunication cable or from external power unit. CNV4 unit changes datatransmit direction controlled by incoming serial data from RS232 port.The figure below shows an example of the use of the CNV-2: the connection of<strong>AL</strong>10SP controller(s) via RS485/RS-232C interface to PC.PCPowerCNV4TxDRxD<strong>AL</strong><strong>20AN</strong>CNV2TxDRxD<strong>AL</strong><strong>20AN</strong>CNV4TxDRxDMorePLCs<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 54 6 - - 1212/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja Manual6.7 Terminal strip numbering and connection diagramsConnecting supply power to <strong>AL</strong><strong>20AN</strong> Main board.ACPower unitRS232 RS485 RS232POWEREXPANSIONBOARDSO 0O 1O 2O 3O 4O 5O 6O 7COMDISPLAY BATTERYDIGIT<strong>AL</strong> OUTPUTSCON502D+D-GNDCON503 J1 J2TX1 +24V2 GDN3 AC24 AC1CON403CON401 CON402202122232425262728CON501CON1B1SER2SER1CON2012EXT I C2ICRX TXRX 12VRUNH201H202H203H204H205H206H207H208IC10IC2MOD6 MOD4MOD7 MOD5MOD3MOD2MOD1MOD0IC3 IC4IC1H108H107H106H105H104H103H102H101CON302CON301CON303 CON101SW117417317217116416316216115415315215114414314214113413313213112412312212111411311211110410310210184838281181716151413121110AN<strong>AL</strong>OG INPUTS 4 - 7 AN<strong>AL</strong>OG INPUTS 0 - 3AN<strong>AL</strong>OG OUTDIGIT<strong>AL</strong> INPUTS7 GND7 Sign-7 Sign+7 I+6 GND6 Sign-6 Sign+6 I+5 GND5 Sign-5 Sign+5 I+4 GND4 Sign-4 Sign+4 I+3 GND3 Sign-3 Sign+3 I+2 GND2 Sign-2 Sign+2 I+1 GND1 Sign-1 Sign+1 I+0 GND0 Sign-0 Sign+0 I+O 1 I-O 1 I+O 0 I-O 0 I+COMI 7I 6I 5I 4I 3I 2I 1I 0<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 5 6 - 13In the table below are possible definitions of the input and output points of<strong>AL</strong><strong>20AN</strong> PLC’s CPU board.29/12/200604/01/99Analog inputs/ digital inputsConn. Digital Digital10 I 0011 I 0112 I 0213 I 0314 I 0415 I 0516 I 0617 I 0718 COM20 O 0021 O 0122 O 0223 O 0324 O 0425 O 0526 O 0627 O 0728 COMAnalog OUTPUTSConnnum.81 AO 0082 GND83 AO 0184 GNDAnalog outputConn. Defining Analog Digital101 Module I + I 08102 Module AI 00 + I 09103 Module AI 00 - I 10104 GND GND111 Module I + I 11112 Module AI 01 + I 12113 Module AI 01 - I 13114 GND GND121 Module I + I 14122 Module AI 02 + I 15123 Module AI 02 - I 16124 GND GND131 Module I + I 17132 Module AI 03 + I 18133 Module AI 03 - I 19134 GND GND141 Module I + I 20142 Module AI 04 + I 21143 Module AI04 - I 22144 GND GND151 Module I + I 23152 Module AI 05 + I 24153 Module AI 05 - I 25154 GND GND161 Module I + I 26162 Module AI 06 + I 27163 Module AI 06 - I 28164 GND GND171 Module I + I 29172 Module AI 07 + I 30173 Module AI 07 - I 31174 GND GND<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 54 6 - - 1412/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualTerminal strips of RO16 expansion board.The possible output numbering variations are shown in chapter 4.2. In the picturebelow are smallest possible output numbers.CON10115B15A14B14A13B13A12B12A11B11A10B10A9B9A8B8A7B7A6B6A5B5A4B4A3B3A2B2A1B1A0B0AO 47O 46O 45O 44O 43O 42O 41O 40O 39O 38O 37O 36O 35O 34O 33O 32CON104CON103CON102H9H10H11H12H13H14H15H16H1H2H3H4H5H6H7H8C11 C10 C9 C8 C7 C6 C5 C4 C3 C18 C17 C16 C15 C14 C13 C12K8 K7 K6 K5 K4 K3 K2 K1 K16 K15 K14 K13 K12 K11 K10 K9IC8IC5IC6IC7CON2FROM CPUCON1J11-2 3-4 ADDR1 1 32100148640 0 80TO EXTTerminal strips of RIO8 expansion board.The possible output numbering variations are shown in chapter 4.3. In the picturebelow are smallest possible input and output numbers.H8H7H6H5H4H3H2H1H16H15H14H13H12H11H10H9CON103CON102CON101O 39O 38O 37O 36O 35O 34O 33O 32I 39I 38I 37I 36I 35I 34I 33I 32C11 C10 C9 C8 C7 C6 C5 C4K8 K7 K6 K5 K4 K3 K2 K1IC5IC8IC7IC6CON1CON2FROM CPUwww.<strong>FF</strong>-<strong>Automation</strong>.comJ1 1234561-2 3-4 5-6 ADDR 1-2 3-4 5-6 ADDR1 1 1 32 0 1 1 641 1 0 40 0 1 0 721 0 1 48 0 0 1 801 0 0 56 0 0 0 88TO EXT<strong>FF</strong>-<strong>Automation</strong> Oy


C2AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualPage Sivu 5 6 - 1529/12/200604/01/99Terminal strips of DI16 expansion board.The possible input number variations are shown in chapter 4.4. In the picturebelow are smallest possible output numbers.H216H215H214H213H212H211H210H209H208H207H206H205H204H203H202H201H116H115H114H113H112H111H110H109H108H107H106H105H104H103H102H101CON202COM232231230229228227226225COM224223222221220219218217CON201CON102COM216215214213212211210209COM208207206205204203202201CON101O 63O 62O 61O 60O 59O 58O 57O 56O 55O 54O 53O 52O 51O 50O 49O 48O 47O 46O 45O 44O 43O 42O 41O 40O 39O 38O 37O 36O 35O 34O 33O 32H8H7H6H5H4H3H2H1H16H15H14H13H12H11H10H9GND1514131211100908CON102CON101GND0706050403020100GNDI 47I 46I 45I 44I 43I 42I 41I 40GNDI 39I 38I 37I 36I 35I 34I 33I 32IC7IC6IC5IC8CON1CON2FROM CPUJ11-2 3-4 ADDR1 1 321 0 48www.<strong>FF</strong>-<strong>Automation</strong>.com0 1 640 0 80TO EXTTerminal strips of DO32 expansion board.The possible output number variations are shown in chapter 4.6. In the picturebelow are smallest possible output numbers.1IC209IC1091IC8IC7IC6IC5IC2IC4IC3J3H C1IC1J6 J4 J5 J2CON1FROM CPUJ1 1 2 3 4J1 1-2 ADR 32J1 3-4 ADR 64www.<strong>FF</strong>-<strong>Automation</strong>.comTO EXTCON2<strong>FF</strong>-<strong>Automation</strong> Oy


22Sivu Page 54 6 - - 1612/01/99 04/01/99 29/12/2006AutoLog AutoLog <strong>20AN</strong> <strong>20AN</strong> Instruction Käsikirja ManualTerminal strips of EXA 84 expansion board.The possible output number variations are shown in chapter 4.7. In the picturebelow are smallest possible input (32 - 39) and output numbers (32 - 35).AI36+AI36 I+AI36 I–COMAI37+AI37 I+AI37 I–COMAI38+AI38 I+AI38 I–COMAI39+AI39 I+AI39 ICOMAO34+COMAO35+COM14114214314415115215315416116216316417117217317485868788I CIC101IC103IC102MOD106MOD108IC1MOD105MOD107IC105MOD104 MOD102MOD103 MOD101RUNIC2JP2IC3I C13413313213112412312212111411311211110410310210184838281COMAI35 IAI35 I+AI35 +COMAI34 I–AI34 I+AI34 +COMAI33 I–AI33 I+AI33 +COMAI32 IAI32 I+AI32 +COMAO33+COMAO32+X1RUNPower supply connection for expansion boards and DIN modules.The expansion boards, DIN modules and analog RMS modules gets the 12 VDCpower from CPU board voltages. To connect the 12 VDC voltage for thesedevices set the 12 VDC connector jumper to shortcut the pins shown in picturebelow and check that the 12 V indication led shows that voltage is connected.12VRUNCON11 +24V2 GDN3 AC24 AC1POWEREXT2I C2ICJ1 J2 CON403 CON401 CON402EXPANSION DISPLAYBOARDS12 VDC connection jumper<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 7 - 129/12//20067. RESERVED VARIABLE LOCATIONSThe register outputs R O 0 - 255 are reserved for use of PLC’s system program,W GM 0 - 255 are reserved for PID controllers, look chapter 9. CONTROLLERSand R GM 128 - 191 for control variables of graphical symbols of <strong>AL</strong>1095 display.7.1 Register outputs reporting on or controlling the operation of the PLCdec.oct.R O 000 000R O 001 001R O 002 002 Connected input expansion boards, addresses ( bits 7 6 5 4 3 2 1 0)R O 003 003 Connected output expansion boards, addresses ( bits 7 6 5 4 3 2 1 0)R O 004 004 Connected EXA84 cards ( bits 7 6 5 4 3 2 1 0)R O 005 005R O 006 006R O 007 007R O 008 010R O 009 011 Analog output voltage level Bit.0=AO0 Bit.1=AO1 0=0..5v 1=0..10vR O 010 012 EXA84 Adr0; output type bits 3..0; I/O addr. 32 –>R O 011 013 EXA84 Adr1; output type bits 3..0; I/O addr. 40 –>R O 012 014 EXA84 Adr2; output type bits 3..0; I/O addr. 48 –>R O 013 015 EXA84 Adr3; output type bits 3..0; I/O addr. 56 –>R O 014 016 EXA84 Adr4; output type bits 3..0; I/O addr. 64 –>R O 015 017 EXA84 Adr5; output type bits 3..0; I/O addr. 72 –>R O 016 020 EXA84 Adr6; output type bits 3..0; I/O addr. 80 –>R O 017 021 EXA84 Adr7; output type bits 3..0; I/O addr. 88 –>R O 018 022R O 019 023R O 020 024R O 021 025R O 022 026R O 023 027R O 024 030R O 025 031R O 026 032R O 027 033R O 028 034R O 029 035R O 030 036R O 031 037R O 032 040R O 033 041 Keypad/Display unit type, ID codes in chapter 8R O 034 042 The version number of PLC’s system programR O 035 043 DIP switch statusR O 036 044R O 037 045 The receive error counter on datafile receivingR O 038 046 Prosessor type: 0 = Intel, 1 = Dallas, 2 = Philips 80C552R O 039 047 The version type number of CPU board<strong>FF</strong>-<strong>Automation</strong> Oy


Page 7 - 229/12//2006AutoLog <strong>20AN</strong> Instruction Manual⇒29/12/06⇒29/12/06dec. oct.R O 040 050 Error code on saving application prog. to flash memory | 0 = OKR O 041 051 Last programmed | 28 = saving errorR O 042 052 address | 48 = saving errorR O 043 053 FPGA IDR O 044 054R O 045 055 Flash manufacturerR O 046 056 Flash device codeR O 047 057R O 048 060 Number of non answered Modbus master request for Ser1R O 049 061 Type number of detected Modbus master error for Ser1R O 050 062 Modbus error information for Ser1, chapter 7.4R O 051 063 Modbus counter, abandoned messages Ser1R O 052 064 Modbus counter; accepted messages Ser1R O 053 065R O 054 066 Modbus message transmission delay for Ser1, default 50 ms = 50R O 055 067 Modbus responce timeout for Ser1, default 10 (=1second)R O 056 070 Modbus responce timeout for Ser2, default 10 (=1second)R O 057 071 CTS/RTS control memory for Ser1, CTS=bit7, RTS=bit1 only if bit0=1R O 058 072 CTS/RTS control memory for Ser2, CTS=bit7, RTS=bit1 only if bit0=1R O 059 073 Modbus error information for Ser2,chapter 7.4R O 060 074R O 061 075R O 062 076R O 063 077R O 064 100R O 065 101R O 066 102R O 067 103R O 068 104R O 069 105R O 070 106R O 071 107R O 072 110R O 073 111R O 074 112R O 075 113R O 076 114R O 077 115R O 078 116R O 079 117R O 080 120 Modbus counter: abandoned messages on Ser2R O 081 121 Modbus counter: accepted messages on Ser2R O 082 122R O 083 123 Modbus message transmission delay for Ser2, default 50 ms = 50R O 084 124R O 085 125R O 086 126R O 087 127R O 088 130 Number of non answered Modbus master request for Ser2R O 089 131 Type number of detected Modbus master error for Ser2<strong>FF</strong>-<strong>Automation</strong> Oy


dec.oct.AutoLog <strong>20AN</strong> Instruction ManualPage 7 - 329/12//2006R O 090 132R O 091 133R O 092 134R O 093 135R O 094 136R O 095 137R O 096 140R O 097 141R O 098 142R O 099 143R O 100 144R O 101 145R O 102 146R O 103 147R O 104 150R O 105 151R O 106 152R O 107 153R O 108 154R O 109 155R O 110 156R O 111 157R O 112 160R O 113 161R O 114 162R O 115 163R O 116 164R O 117 165R O 118 166R O 119 167R O 120 170R O 121 171R O 122 172R O 123 173R O 124 174R O 125 175R O 126 176R O 127 177R O 128 200 Update interval for 12-bit PID controllers group 1 (default 5=500ms)R O 129 201 Update interval for 12-bit PID controllers group 2 (default 5=500ms)R O 130 202 Update interval for 12-bit PID controllers group 3 (default 5=500ms)R O 131 203 Update interval for 12-bit PID controllers group 4 (default 5=500ms)R O 132 204 Pulse interval for 12-bit PID controllers group 1 (1=0.1s.)R O 133 205 Pulse interval for 12-bit PID controllers group 2 (1=0.1s.)R O 134 206 Pulse interval for 12-bit PID controllers group 3 (1=0.1s.)R O 135 207 Pulse interval for 12-bit PID controllers group 4 (1=0.1s.)R O 136 210 Closing bits for 12-bit PID controllers group 1R O 137 211 Closing bits for 12-bit PID controllers group 2R O 138 212 Closing bits for 12-bit PID controllers group 3R O 139 213 Closing bits for 12-bit PID controllers group 4<strong>FF</strong>-<strong>Automation</strong> Oy


Page 7 - 429/12//2006AutoLog <strong>20AN</strong> Instruction Manualdec.oct.⇒29/12/06⇒29/12/06R O 140 214 Opening bits for 12-bit PID controllers group 1R O 141 215 Opening bits for 12-bit PID controllers group 2R O 142 216 Opening bits for 12-bit PID controllers group 3R O 143 217 Opening bits for 12-bit PID controllers group 4R O 144 220R O 145 221R O 146 222R O 147 223R O 148 224R O 149 225R O 150 226R O 151 227R O 152 230R O 153 231R O 154 232R O 155 233R O 156 234R O 157 235R O 158 236R O 159 237R O 160 240R O 161 241R O 162 242R O 163 243R O 164 244R O 165 245R O 166 246R O 167 247R O 168 250R O 169 251R O 170 252R O 171 253R O 172 254R O 173 255R O 174 256R O 175 257R O 176 260R O 177 261R O 178 262R O 179 263R O 180 264R O 181 265R O 182 266R O 183 267R O 184 270R O 185 271R O 186 272R O 187 273R O 188 274R O 189 275<strong>FF</strong>-<strong>Automation</strong> Oy


dec.oct.AutoLog <strong>20AN</strong> Instruction ManualPage 7 - 529/12//2006R O 190 276R O 191 277R O 192 300R O 193 301R O 194 302R O 195 303R O 196 304R O 197 305R O 198 306R O 199 307R O 200 310R O 201 311R O 202 312R O 203 313R O 204 314 Control for LEDs on display unit, chapter 8.8R O 205 315R O 206 316R O 207 317 Read bit information from keys ( 0 - 7) on keypad, chapter 8.7R O 208 320 Read bit information from keys ( 8 - F) on keypad, chapter 8.7R O 209 321 The ASCII-code of last character received from keypadR O 210 322 SER1 data legth and parity in terminal modeR O 211 323 Reserved for test informationR O 212 324 Selected PLC language, chapter 7.2R O 213 325 Ser1 communication speed, chapter 7.2R O 214 326 Ser1 mode, programming/terminal/printout/MODBUS slave/master, chp 7.2R O 215 327 Ser2 mode, terminal/printout/modem /MODBUS slave/master, chp 7.2R O 216 330R O 217 331R O 218 332R O 219 333 Ser2 data length and parity in terminal mode, chapter 7.2R O 220 334 Step of analogue input calibration, chapter 16R O 221 335R O 222 336 Analog input number to be calibrated, chapter 16R O 223 337R O 224 340 Lower calibration value (LO) hi-byte (4 MSB), chapter 16R O 225 341 Lower calibration value (LO) lo-byte (8 LSB), chapter 16R O 226 342 Higher calibration value (HI) hi-byte (4 MSB), chapter 16R O 227 343 Higher calibration value (HI) lo-byte (8 LSB), chapter 16R O 228 344 The amount of step registers. (Deafault 32 pcs. / max. 64 pcs.)R O 229 345 Ser2 communication speed, chapter 7.2R O 230 346 Word variable: multiplication/division (MSB)R O 231 347 Word variable: multiplication/division (LSB)R O 232 350 Ser1 last char. received from terminal, all chars are transferred into FIFO5R O 233 351 Ser2 last char. received from terminal, all chars are transferred into FIFO6R O 234 352R O 235 353R O 236 354R O 237 355R O 238 356R O 239 357<strong>FF</strong>-<strong>Automation</strong> Oy


Page 7 - 629/12//2006AutoLog <strong>20AN</strong> Instruction Manualdec.oct.⇒29/12/06⇒29/12/06R O 240 360 Selection the display information, chapter 8R O 241 361 Number of the power fail interruptionsR O 242 362 Set the real time clock time, chapter 8R O 243 363 Slave address of <strong>AL</strong><strong>20AN</strong> in data communication (Modbus)R O 244 364 Register variable (8 bit) Multiplication high byte / devision remainderR O 245 365 Left side of numerical display (for <strong>AL</strong>1092), chapter 8R O 246 366 Right side of numerical display (for <strong>AL</strong>1092), chapter 8R O 247 367 Date and time information: month, chapter 8R O 248 370 Date and time information: date, chapter 8R O 249 371 Date and time information: day of week (0 ... 7), chapter 8R O 250 372 Date and time information: hour, chapter 8R O 251 373 Date and time information: minute, chapter 8R O 252 374 Date and time information: second, chapter 8R O 253 375 Clock and calendar: number of six minutes from the beginning of the day, chp 8R O 254 376 NetID address of <strong>AL</strong><strong>20AN</strong>R O 255 377 Date and time information: year, chapter 8Control variables for <strong>AL</strong>1095 graphical symbolsR GM 128 200 Graphic object 1:mode R GM 160 240 Graphic object 5:modeR GM 129 201 Value R GM 161 241 ValueR GM 130 202 X start point R GM 162 242 X start pointR GM 131 203 X length R GM 163 243 X lengthR GM 132 204 Y start point R GM 164 244 Y start pointR GM 133 205 Y length R GM 165 245 Y lengthR GM 134 206 uppdate interval R GM 166 246 uppdate intervalR GM 135 207 R GM 167 247R GM 136 210 Graphic object 2: mode R GM 168 250 Graphic object 6: modeR GM 137 211 Value R GM 169 251 ValueR GM 138 212 X start point R GM 170 252 X start pointR GM 139 213 X length R GM 171 253 X lengthR GM 140 214 Y start point R GM 172 254 Y start pointR GM 141 215 Y length R GM 173 255 Y lengthR GM 142 216 uppdate interval R GM 174 256 uppdate intervalR GM 143 217 R GM 175 257R GM 144 220 Graphic object 3: mode R GM 176 260 Graphic object 7: modeR GM 145 221 Value R GM 177 261 ValueR GM 146 222 X start point R GM 178 262 X start pointR GM 147 223 X length R GM 179 263 X lengthR GM 148 224 Y start point R GM 180 264 Y start pointR GM 149 225 Y length R GM 181 265 Y lengthR GM 150 226 uppdate interval R GM 182 266 uppdate intervalR GM 151 227 R GM 183 267R GM 152 230 Graphic object 4: mode R GM 184 270 Graphic object 8: modeR GM 153 231 Value R GM 185 271 ValueR GM 154 232 X start point R GM 186 272 X start pointR GM 155 233 X length R GM 187 273 X lengthR GM 156 234 Y start point R GM 188 274 Y start pointR GM 157 235 Y length R GM 189 275 Y lengthR GM 158 236 uppdate interval R GM 190 276 uppdate intervalR GM 159 237 R GM 191 277Graphic object update interval: 1 = 1 sec., 2 = 2 sec., ..., 0 = 256 sec.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 7 - 729/12//20067.2 Register Outputs witch must be setdec.oct.R O 210 322 Terminal mode SER 1: data configuration (when R O 214 = 1 or 2)0 8 bit, parity NONE1 7 bit, parity EVEN2 7 bit, parity ODD3 8 bit, parity EVEN4 8 bit, parity ODDR O 212 324 Selected language0 English1 FinnishR O 214 326 Serial interface SER 1: mode0 Programming1, 2 Terminal / printing / modem4 Serial interface to computer (MODBUS slave)/modem5 MODBUS masterR O 213 325 Serial interface SER 1: communication speed0 300 bit/s1 1200 bit/s2 2400 bit/s3 4800 bit/s4 9600 bit/s5 19200 bit/s6 28800 bit/s7 38400 bit/s8 57600 bit/sR O 219 333 Terminal mode SER 2: data configuration (when R O 215 = 1 or 2)0 8 bit, parity NONE1 7 bit, parity EVEN2 7 bit, parity ODD3 8 bit, parity EVEN4 8 bit, parity ODDR O 215 327 Serial interface SER 2: mode0 Terminal / printing / modem4 Serial interface to computer (MODBUS slave)/modem5 MODBUS master<strong>FF</strong>-<strong>Automation</strong> Oy


Page 7 - 829/12//2006AutoLog <strong>20AN</strong> Instruction Manualdec.oct.⇒29/12/06R O 229 345 Serial interface SER 2: communication speed0 300 bit/s1 1200 bit/s2 2400 bit/s3 4800 bit/s4 9600 bit/s5 19200 bit/s6 28800 bit/s7 38400 bit/s8 57600 bit/s⇒29/12/06R O 240 360 Selection the display information.0 Mode 0. Normal display mode2 Mode 1. Data display mode, the values of R O 245 and R O 2464 Mode 2. R O 245 and R O 246 controls 7-segment displays16 Whole display is reserved for text output (doesn’t show the time)32 Change the values of variables disabled ( B-key)128 Display is locked (current display information will be retained and nochanges will be allowed)7.3 W GM variables reserved for PID controllersAll 16-bit W GM (0 to 255) variables are reserved for the 12-bit controllers of PLC.More exact declarations of variable’s functions are explained in chapter9. CONTROLLERS.7.4 Modbus Error information Register OutputsSER1 SER2Slave ID number R O 48 R O 88Type number of detected error R O 49 R O 89Error codes:First cyclesecond cycle17d 33d warning, error in building master request18d 34d warning, error on sending master request19d 35d warning, no answer20d 36d warning, receive timeout (command)21d 37d warning, receive timeout (data)22d 38d warning, CRC error23d 39d warning, received address/command differentthan request address/command<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 8 - 129/12/20068. DISPLAY/KEYPAD UNITSThere are several display/keypad units available for the AuroLog PLCs, most of whichcan be connected to the PLC board via I 2 C interface..8.1 <strong>AL</strong>1096 Display/Keypad Units (serial connection)<strong>AL</strong> 1096PS/PE<strong>AL</strong> 1096S<strong>AL</strong>1096T- front panel mounted enclosure- 320x240 pixel STN graphic LCD display, backlit- touch screen max. 40 x 30 touch keys- Clock and calendar, battery backup- front panel mounted enclosure- 5 function keys- 240 x 128 pixel graphic LCD display, backlit- front panel mounted enclosure- touch screen max. 10 x 8 touch keys- 240 x 128 pixel graphic LCD display, backlit8.2 <strong>AL</strong>1095A/B Display/Keypad Units, (ID code 34)DIS1DIS10123LED1LED2LED3LED40 1 2 34 5 6 78 9 A BC D E F<strong>AL</strong>1095<strong>AL</strong>ED5LED6LED7LED8<strong>AL</strong>1095B- Connection to PLC’s I 2 C bus by system cable, length 1 m.- 8x21 character alphanumeric LCD display/128x64 pixel graphic display, backlit- 8 LED indicator lights- 16 keys 0 ... F (model A), 4 keys 0 ... 3 (model B)- skandinavian/cyrillic characters, selectable by jumper- supply voltage through system cable from PLC’s supply unit- clock/calendar, battery backup- the unit can be fitted with a client designed face plate- encapsulated, front panel mount, front panel seal IP54<strong>FF</strong>-<strong>Automation</strong> Oy


Page 8 - 229/12/2006AutoLog <strong>20AN</strong> Instruction Manual8.3 <strong>AL</strong>1093 Display/keypad Units, (ID code 15)There are three versions of the <strong>AL</strong>1093 unit. These are <strong>AL</strong>1093C, <strong>AL</strong>1093D and<strong>AL</strong>1093F. All <strong>AL</strong>1093 units have 2 x 16 character alphanumeric display, 16-key hexadecimalkeypad and 6 LED indicator lights. <strong>AL</strong>1093 units can be connected to anyAutolog PLC. In addition to displaying the values and time/date information, the <strong>AL</strong>1093unit can also display text (using the PRT instruction). The LCD display is backlit. Theclock and calendar functions are battery backed-up.All <strong>AL</strong>1093 models are front panel mounted and models D and F can be fitted withclient-designed face plate.<strong>AL</strong>1093C / D<strong>AL</strong>1093FDIS10 1 2 3 48 9 A B C5 6 7D E F8.4 <strong>AL</strong>1094 / R Display/keypad Units, (ID code 19 / 11)The <strong>AL</strong>1094 display/keypad unit withoutclock and calendar functions. It has a4-digit 7-segment display, four LED indicatorsand a 4-key keypad. The unit canbe fitted with client designed face plate.04152637The <strong>AL</strong>1094R display/keypad unit withoutclock and calendar functions. It has 2 x 16character alphanumeric display, two LED indicatorsand a 4-key keypad. In addition todisplaying the values and time/date information,the <strong>AL</strong>1094R unit can also display text(using the PRT instruction). The unit can befitted with client designed face plate.0 12 3<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 8 - 329/12/20068.5 <strong>AL</strong>1094AF Display/keypad Unit, (ID code 67)The <strong>AL</strong>1094AF display/keypad unit has 2x20 character alphanumeric display, clock/calendar, 8 keys, 4 indicating leds, buzzer and one 24VDC 300 mA output for externalindicating light. The <strong>AL</strong>1904AF can display text (using the PRT instruction). The unitcan be fitted with client-designed front plate. Output O 4 = buzzer, output O5 = controloutput for external indication light. The unit is designed for install with client designedface plate.041 2 35 6 743218.6 <strong>AL</strong>1094FM Display/keypad Unit, (ID code 67)The <strong>AL</strong>1094FM display/keypad unit has 2x20 character alphanumeric display, clock/calendar, 16 keys, 4 indicating leds, buzzer and one 24VDC 300 mA output forexternal indicator light. The <strong>AL</strong>1904AF can display text (using the PRT instruction).The unit can be fitted with client-designed front plate. Output O 4 = buzzer, outputO 5 = control output for external indication light. The unit is designed for install withclient designed face plate.041 2 35 6 7438 9 A BC D E F21<strong>FF</strong>-<strong>Automation</strong> Oy


Page 8 - 429/12/2006AutoLog <strong>20AN</strong> Instruction Manual8.7 Reading The KeypadR O 209:The ASCII code of the last character from keypad is stored in theregister output R O 209, when the keypad is connected to PLC’s I 2 Cconnector .Example: PLC receives a character from keypad.STR R O 209 ; Read the character from keypadLES R C 000 ; If value 0EQ R RO 209 ; reset the bufferPRT R T ; and output the characterSTOPThe keypad status is stored in the bits of R O 207 and R O 208. When no key isbeing pressed, all bits are set to ‘0’. When a key is pressed, the bit corresponding tothat key is set to ‘1’. The keys and their corresponding bit are shown below.R O 207 bit 7 6 5 4 3 2 1 0 R O 208 bit 7 6 5 4 3 2 1 0key 7 6 5 4 3 2 1 0 key F E D C B A 9 8REMARK! Keys of <strong>AL</strong>1094 display affects only to R O 207 because of 7 keys.Example: PLC reads which key is pressed and saves key state to memory.STR R O 207 ; Read the pressed key codeBIT M 010 ; save state to memories M 10 - 17 ( keys 0 - 7)STR R O 208 ; Read the pressed key codeBIT M 018 ; save state to memories M 18 - 25 ( keys 8 - F)STOP8.8 Control of LED IndicatorsThe LED indicators / other outputs from display are controlled by the bits R O 204. AnLED / output can be set on by setting the approriate bit to ‘1’, and subsequentlyturned off by setting the bit to ‘0’. The LEDs and their corresponding bits are shownbelow.R O 204 bit 0 1 2 3 4 5Output O0 O1 O2 O3 O4 O5<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 8 - 529/12/20068.9 Display Control CharactersMnemonic Hex FunctionBS (Back space) 08 Moves the cursor one character to the left and clears that position.If the cursor is at the beginning of a line, it moves to the end of theHT (Tabulator) 09 Moves the cursor one character to the right without clearing thatposition. If the cursor is at the end of a line, it goes to the beginningLF (Line Feed) 0A Moves the cursor to the next line.<strong>FF</strong> (Form Feed) 0C Clears the display and moves the cursor to the beginning of theCR (Return/Enter) 0D Moves the cursor to the beginning of the present line.NAK 15 Moves the cursor one character to the left without clearing thatposition.If the cursor is at the beginning of a line, it goes to the end,"Y",,1B 5901 08Moves the cursor to line 1, column 8.Line 1...4, column 1...40, maximum numbers along displays.8.10 Display ModesAll display/keypad units have several display modes. Some modes are not available forevery unit (e.g. those without clock and calendar functions and reduced keypads). Thedisplay modes are outlined below and defined by register output R O 240.R O 240:Content02481632FunctionMode "0" (normal Mode)Mode "1"Mode "2"Mode "3"Mode "4" the entire display is reserved for PRT outputsMode "5" as mode "0", but the B-key disabled (changes)8.10.1 Normal display mode - Mode '0' (R O 240 = 0)KeyFunction0-9 Numeric keysASet clock/calendarBEnter parameters into register variablesCDisplay register variablesDNext display/entryEDisplay address (in register variable display mode)FReturn to clock display<strong>FF</strong>-<strong>Automation</strong> Oy


Page 8 - 629/12/2006AutoLog <strong>20AN</strong> Instruction Manual'A' Set Clock/CalendarThe clock/calendar is set as follows:Key display continue'A' 1-xx year (two digits) D or F2-xx month (two digits, 01-12) D or F3-xx day (two digits, 01-31) D or F4-xx hour (two digits, 01-24) D or F5-xx minute (two digits, 01-59) D or F6-x day of week (one digit, 01-07) D or F(1 = mon, 2 = tue ,..., 7 = sun)'B' Enter Parameters into Register variableKey display continue'B' RM000 new address (octal number) D or B or FWM089 continue with 'B' browsing variables D or B or FRO255 address of variable continue with 'D' D or Fxxx enter parameters value D or FXX001 address 001 or new address D or Fxxx enter parameters value D or Fand/or quit by ‘F’-key'C' Display register memory/output or word memoryREMARK!Otherwise like with allother PLC units, with<strong>AL</strong>14 PLC’s theaddresses of thevariables are in decimalnumber format.For example:With <strong>AL</strong>16AN we pressW M 376 (oct), andwith <strong>AL</strong>14 we pressW M 254 (dec).The value of register variable is updated continuously into thedisplay.Update rate is one second.Key display continue'C' RM000 new address (octal number) C or D or FWM199 continue with 'C' browsing variables C or D or FRO219 address of variable 'D' -> update D or E or Fyyy ‘D’ -> next variable D or FRO000 ‘E’ display varaible’s address C or D or Fescape by ‘F’-key'D' Next Display ModeIn the normal display mode ‘0’, the display information may be changed by pressing the‘D’-key. This is performed as follows:Key display continue‘D’ 15:30 hours:minutes D or F17.05 date.month D or F00:01 date of week D or F(models <strong>AL</strong>1093, <strong>AL</strong>1094AF, <strong>AL</strong>1095)<strong>FF</strong>:<strong>FF</strong> R O 245 and R O 246 in hex D or F15:30 hours:minutes.... etc.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 8 - 729/12/20068.10.2 Data Display Mode '1' [R O 240 = 2]This mode is available for all models. In this mode the contents of R O 245 and R O246 are sent to the display. In this mode it is not neccessary use the ‘D’ key to changethe display mode (as with mode ‘0’) each time after power-up.Example: I000 connects the display control program and the contents of R O 245and R O 246 are immediately displayed. When I 000 is truned off, it disconnectsthe control program, and the display will again show the time.STR R C 000 ; Normal display modeEQ R O 240 ; chosen for displaySTR I 000 ; set input on (=ON)STR R C 002 ; the control code for mode '1' isEQ R SO 240 ; transferred to register output R O 240.STOP; When writing the value to R O 240 ends,; returns the to normal mode (two first instruction lines)8.10.3 7-Segment mode - mode '2' (R O 240 = 4)This display mode is available only for the <strong>AL</strong>1094 with 7-segment display. In thismode R O 245 controls the right hand side of the 7-segment display, so that seven ofthe eight bits controls a segment each, and the eighth bit controls the minus sign asshown in the diagram below.xfgabR O 245: bit 7 6 5 4 3 2 1 0segment x g f e d c b ae cdSegments are illuminated by writing the sum of the corresponding values into R O 245Segment Number Segment Numberabcd1248efgx163264128For example, to display segments e, cand d, the sum of correspondingnumbers (16+8+4=28) should bewritten into register output R O 245.STR R C 028EQ R O 245 ; Display segments e, c and d8.10.4 Text Display Mode ‘4’ (R O 240 = 16)This mode is available only for the <strong>AL</strong>1094R, <strong>AL</strong>1093, <strong>AL</strong>1094AF and <strong>AL</strong>1095 withalphanumeric displays. The entire display will be reserved for text produced by thePRT instruction.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 8 - 829/12/2006AutoLog <strong>20AN</strong> Instruction Manual8.10.5 Normal Mode with Key 'B' Function Disabled. Mode ‘5’ (R O 240 = 32)This mode is available only for the <strong>AL</strong>1094F/R, <strong>AL</strong>1093C/D/F and <strong>AL</strong>1095 models withalphanumeric displays. The unit functions otherwise normally but the changes of contentof variables are disabled.8.10.6 Display Lock Mode ‘6’ (R O 240 = 128)This mode is available only for the <strong>AL</strong>1094R, <strong>AL</strong>1093C/D/F and <strong>AL</strong> 1095A/B withalphanumeric displays. Current display information will be retained and no changes willbe allowed.8.11 Program examples8.11.1 Printing Date InformationSTR I 001EQ M 000STR DP 000 ; printPRT R O 248 ; datePRT T .@ ; pointPRT R O 247 ; monthPRT T .19@ ; point and hundreds of yearPRT R O 255 ; year ( 0 - 99)8.11.2 Real Time Control with R O 253 (6 minutes from midnight)STR R O 253 ; read number of six minute periods from beginning of dayLES R C 174 ; every day starting from 17:30EQ M 000 ; (17.5 * 60/6 = 175)GRT R C 210 ; until 21:00AND M 000EQ O 001 ; output onSTOP8.11.3 Display Step Registers 0 and 1 (0 ... 99)STR R C 002 ; set register outputs R O 245 and 246EQ R O 240 ; display mode '1' valueSTR R S 000 ; read step register’s 0 step into register accumulatorBCD; convert to BCD formEQ R O 245 ; save the value into display variableSTR R S 001 ; read step register’s 1 step into register accumulatorBCD; convert to BCD formEQ R O 246 ; save the value into display variableSTOP<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 8 - 929/12/20068.11.4 Display Control CharactersSTR W I 0.01 ; read word input 001 into word accumulatorBDC W T ; convert to BCDEQ W M 000 ; save into word memorySTR P 001 ; print on 1 second periodPRT (,"Y",,) ; to line 1 column 4PRT R M 000 ; the value of W T 1, first high bytePRT R M 001 ; and then low byteSTOP8.11.5 Set the Time and Date Using Register variablesSTR R S 000 ; Step register 0 in useSTR I 0.00 ; Clock synchronising inputEQ M 065STR DP 065AND S 000STEP S 001 ; activate clock time settingSTR R S 000 ; step registers step to register accumulatorLES R C 000 ; program is executed only if currentIF T ; step is greater than 0STR R S 000LES R C 019 ; 2 seconds delay, made by STEP register 0STEP S 000STR R C 005EQ R SO 242 ; transfer time to real time clockSTR S 001 ; if in stepSTR R C 001EQ R SO 242 ; disable reading of real time clockSTR R C 001 ; check if reading of real time clockEQU R O 242 ; is disabledAND P 000 ; pulse, interval 0.1 secondSTEP T ; go to next stepSTR R C 96 ; set yearBCD R TEQ R O 255STR R C 3 ; set monthBCD R TEQ R O 247STR R C 10 ; set dayBCD R T ; of monthEQ R O 248STR R C 9 ; set hourBCD R T ; part of timeEQ R O 250STR R C 25 ; set minuteBCD R T ; part of timeEQ R O 251CONTSTOPSequencies in setting clock time:1 Stop system program RTC clockread function by inserting toR O 242 value 1.2 Set new values to clock variablesfrom R O 247 to R O 255in BCD format.3 Start function “insert new values”by inserting to R O 242 value 5.Now system program updatesthe RTC and resets R O 242to zero which starts normal clockreading to R O variables.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 8 - 1029/12/2006AutoLog <strong>20AN</strong> Instruction Manual8.11.6 Read and Set the Time and Date Using Register variablesSTR R O 242 ; Read real time clockGRT R C 001 ; and change values to binary modeIF T ; Value 1 interrupts time update from rtcSTR R O 255 ; Year (BCD)BIN R TEQ R O C_Year ; Year (BIN)STR R O 247 ; Month (BCD)BIN R TEQ R O C_Month ; Month (BIN)STR R O 248 ; Day (BCD)BIN R TEQ R O C_Day ; Day (BIN)STR R O 249 ; Day of week (BCD)BIN R TEQ R O C_DOWK ; Day of week (BIN)STR R O 250 ; Hour (BCD)BIN R TEQ R O C_Hour ; Hour (BIN)STR R O 251 ; Minute (BCD)BIN R TEQ R O C_Mins ; Minute (BIN)STR R O 252 ; Second (BCD)BIN R TEQ R O C_Secs ; Second (BIN)CONTSTR R O 242 ; Set new time from binary variablesEQU R C 005 ; to real time clock. PLC’s systemIF T ; program resets R O 242 after time setSTR R O C_Year ; Year (BIN)BCD R TEQ R O 255 ; Year (BCD)STR R O C_Month ; Month (BIN)BCD R TEQ R O 247 ; Month (BCD)STR R O C_Day ; Day (BIN)BCD R TEQ R O 248 ; Day (BCD)STR R O C_DOWK ; Day of week (BIN)BCD R TEQ R O 249 ; Day of week (BCD)STR R O C_Hour ; Hour (BIN)BCD R TEQ R O 250 ; Hour (BCD)STR R O C_Mins ; Minute (BIN)BCD R TEQ R O 251 ; Minute (BCD)STR R O C_Secs ; Second (BIN)BCD R TEQ R O 252 ; Second (BCD)CONT<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 9 - 129/12/20069. CONTROLLERS9.1 Register Variables of <strong>Controller</strong>sThe <strong>AL</strong><strong>20AN</strong> PLC’s system software includes 32 12-bit direct digital controllers (DDC)with PID charasteristics. The controller parameters are held in 16-bit W GM memoriesand in 8-bit register outputs (R O).The number of used controllers per group is given in the register outputs (R O 128 -R O 131). This number also determines the group update interval depending on thenumber of controllers used. If one controller in a group is updated, the update time is100 ms. Similarly, if two controllers in a group are updated, the update time interval is200 ms. Maximum update interval is 25500 ms, or 25.5 seconds.If in PLC’s application program the update interval is not defined the default updateinterval of 500 ms is used (R O 128 - R O 131 = 5).<strong>Controller</strong> numberR O numberGroup 1Group 2Group 3Group 4081624191725210182631119274122028513212961422307152331R O 128R O 129R O 130R O 131Example: If it is desired that three controllers update interval is100 ms and twocontrollers 500 ms, parameters should be set as followsGroup 1 - desired update interval is 100 ms, then R O 128 = 1Group 2 - desired update interval is 100 ms, then R O 129 = 1Group 3 - desired update interval is 100 ms, then R O 130 = 1Group 4 - desired update interval is 500 ms, then R O 131 = 5<strong>Controller</strong>s operating mode is given in 16-bit variables (W GM 0, 8, 16 etc.). Everycontroller has the following individual operating modes.0 <strong>Controller</strong> not in use1 <strong>Controller</strong> is in normal automatic operate mode2 <strong>Controller</strong> is in inverted automatic operate mode3 <strong>Controller</strong> is in manual operate mode<strong>FF</strong>-<strong>Automation</strong> Oy


Page 9 - 229/12/2006AutoLog <strong>20AN</strong> Instruction Manual9.2 Three point controllersThere are 32 PID controllers available in <strong>AL</strong><strong>20AN</strong> PLC, and every one of these canoperate also as a three point controller. Operating parameters are in 16-bit variablesW GM 0 - 255.Pulse interval, i.e. the dead time that the controller will wait for the process responseto settle, is programmed into register outputs R O 132—135. The time range is from0.1 s to 25.5 s, corresponding to the numbers 1 - 255.A typical application, controlling the temperature of the circulating water in a centralheating system, is illustrated on the page 9 - 6.<strong>Controller</strong>s 0 - 7 8 - 15 16 - 23 24 - 31Control intervalPulse intervalValve closing bitValve opening bitR O 128R O 132R O 136R O 140R O 129R O 133R O 137R O 141R O 130R O 134R O 138R O 142R O 131R O 135R O 139R O 143Contoller 0 1 2 3 4 5 – 30 31Mode 0 8 16 24 32 40 – 240 248Actual value 1 9 17 25 33 41 – 241 249Set value 2 10 18 26 34 42 – 242 250D time/100ms 3 11 19 27 35 43 – 243 251I time/100ms 4 12 20 28 36 44 – 244 252Gain term 5 13 21 29 37 45 – 245 253Output 6 14 22 30 38 46 – 246 254Aux. variable 7 15 23 31 39 47 – 247 2559.2.1 Control AlgorithmThe control algorithm DY=(100/gain)*{e(ti)-(e(ti-1)) + ; P termof PID is as follows: e(tI)/integration time constant+ ; I termdifferentiation time constant *(e(ti)-2e(ti-1)+e(ti-2)} ; D termD term controls how strongly the control process reacts to rapid changes in the inputsignal. The derivative time constant is an 8-bit parameter and is given in hundreds ofmilliseconds (value 1 - 255 equals 0.1-25.5s). The larger the time the greater thechanges to the output signal. If the derivative time constant is given as0 the term is not used.I term controls how quickly the process reacts to stabilise offset error. The integrationtime constant is a 16-bit parameter and is given in hundreds of millisconds (0.1-6553.5s). The larger the integration time constant the slower the process reacts tooffset errors. If the integration time constant is given as 0, the term is not used.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 9 - 329/12/2006P term controls the gain such that: P=100/gain, where gain can be from 0.01 to 100.Therefore if gain = 0P-TERM NOT USEDif gain = 5 P = 20if gain = 0.5 P = 200if gain = 0.02 P = 5000if gain = 0.01 P = 10000The following figures describe the effect of controllers differents parameters.Effect of the gain PP is a value 1 - 10000 corresponding to gains of 0.01 - 100.0 .(200 correspods to a gain of 0,5.)Fig. 1 Fig. 2Fig. 1P = P =I = I =D = D =Fig. 2P = P =I = I =D = D =Set pointOutputFigure 1 shows how increasingthe gain yields fastercontrol action.Figure 2 shows how reducingthe gain stabilises the oscillation.caused by a short integration time.The sum of the proportional, derivative and integral terms is multiplied by the gain, P.Thus the gain, P, strengthens or weakens the effects of these coefficients.Fig. 1 Fig. 2 Fig. 1P = P = P =I = I = I =D = D = D =Fig. 2P = P = P =I = I = I =D = D = D =Set pointOutput<strong>FF</strong>-<strong>Automation</strong> Oy


Page 9 - 429/12/2006AutoLog <strong>20AN</strong> Instruction ManualThe figures show the behaviour of the same process for two different values of gain,P and varying integration time, I. It can be seen that using high gain will result inovershoot even with longer integration times. If the integration time, I is too short, anoscillation of the type shown in the right-hand figure will occur.Effect of the derivative time constant, DThe effect of the derivative time is critical, as illustrated in the figures below. Derivativecontrol is unsuitable for many types of systems, or is not necessary at all.D = 0 D = 2 D = 5 D = 109.3 <strong>Controller</strong> typesSet pointOutputThe figure below shows the step response of the three basic controller types.t t tP-controller PI-controller PID-controller- The P controller has constant gain, and the result is unsatisfactory, especially if thegain is low.- The PI controller changes the apparent gain and correscts the error in time.- The PID controller exaggerates variations of error in order to abtain rapid errorcorrection. The step responce becomes faster.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 9 - 529/12/20069.4 <strong>Controller</strong> tuningIn a control system suitable values must be found for the control parameters P,I and D.Suitable parameters can be determined using mathematics or a Bode diagram,however, these methods can be time consuming. <strong>Controller</strong>s are usually tuned on thebasis of experimental data from the control system.Two simple and effective methods for this are described below:- Step response method:The delay and rise time of the step response of the process are determined, and thecontroller settings are calculated on that basis.U(t)UotT t U 0P <strong>Controller</strong>: U P = = cT s Y 0Y(t)YoTtTstPI <strong>Controller</strong> : U P = 1.25 cT I = 3 T tPID <strong>Controller</strong> : U P = 1.25 cT I = 3 T tT D = 0.42 T t- Oscillation method:The gain and oscillation cycle time at the point of oscillation are determined, and thecontroller settings are calculated on that basis.P <strong>Controller</strong>:PI <strong>Controller</strong>:PID <strong>Controller</strong>:K P = 0.5 K PcrK P = 0.455 K PcrT I = 0.85T crK P = 0.6 K PcrT I = 0.5T crT D = 0.12T crK P =1U P= gainT I = Integration time constantT D = Differentiation time constantK Pcr = Critical gain at which the processoscillatesT cr = Cycle time of process oscillationThe above two methods yield reasonable starting points for the controller parameterswhich can be further refined during operation. The <strong>AL</strong>Pro software can be used formonitoring controller variables, building trend data and producing producingdocumentation<strong>FF</strong>-<strong>Automation</strong> Oy


Page 9 - 629/12/2006AutoLog <strong>20AN</strong> Instruction ManualA typical application, controlling the temperature of the circulating water in a centralheating system, is shown below.The mixing valve is controlled by a pulse driven actuator motor. The dead time in anapplication of this kind can be several seconds., as changes in the water temperaturewill not immediately be detected by the sensor. It is, therefore, futile to give further drivepulses to the valve before the true effect of the previous action is known. This deadtime can be accounted for when tuning the controller using the step response method.Example Temperature control of circulating water by 3-point control.Setpoint value W I 001Actual value W I 000Mixing valveCON302CON301CON303SW1CON101H108H107H106H105H104H103H102H101BoilerMOD6MOD4IC3IC4MOD7MOD5MOD3MOD2MOD1MOD0IC1IC2IC10RX TXRX 12VRUNH201H202H208H207H206H205H204H203SER2CON501SER1CON1TXEXTI 2 C IC2B1CON201CON502CON503J1 J2 CON403CON401CON402O 1 'close'O 0 'open'<strong>Logic</strong> program for water heating:STR R C 010 ; Control interval is defined toEQ R O 128 ; 1 second (10*100 ms)STR W C 050 ; Integration time (50 * 0.1s) ( 0 - 65535)EQ W GM 012 ; greater value gives slower actionSTR W C 002 ; Differentiation time (2 * 0.1s) ( 0 - 255)EQ W GM 011 ; greater value gives bigger stepsSTR W C 500 ; Gain P = (100/500) P=0.2EQ W GM 013 ; greater value gives slower actionSTR W I 001 ; Set point, e.g. from potentiometerEQ W GM 010STR W I 000 ; Actual value from temperature sensorEQ W GM 009STR W C 001 ; <strong>Controller</strong> in automatic modeEQ W GM 008STR R C 010 ; Pulse interval 1sEQ R O 132STR R O 140 ; Read 'open' bitsBIT M 020 ; Convert to bits (controllers 0 - 7)STR M 021 ; Use bit for controller 1EQ O 001 ; to open valveSTR R O 136 ; Read 'close' bitsBIT M 020 ; Convert to bitsSTR M 021 ; Use bit for controller 1EQ O 002 ; to close valve<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 10 - 129/12/200610. DATA COMMUNICATION10.1 <strong>AL</strong><strong>20AN</strong> serial connections<strong>AL</strong>20 board has two RS-232C level RJ 45 connectors CON502 (Ser2) and CON503(Ser1) and parallel with CON502 RS485 level connector, CON501 (Ser2).Connectors CON502 and CON501 are connected to the same serial port (Ser2), justthe hardware connection differs. The function of data communication for Ser1 isdefined by DIP switch SW1 and register outputs. The switch settings override the R Osettings. The function data of Ser2 can be defined only by register outputs (seeChapter 7).See chapter 4. SWITCHES.RX TXRX 12VRUNSER2CON502CON501D+D-GNDSER1TXCON11 +24V2 GDN3 AC24 AC1CON503 J1 J2EXTCON403I 2 C IC2CON401CON402B1RS232 RS485 RS232 I 2 C connectorSer2 Ser2 Ser1 for displayRegister output variables of serial port 1Register output Effect AlternativesR O 214 Operating mode 0 = programming device1,2 = terminal / printout / modem4 = MODBUS computer bus (slave) / modem5 = MODBUS masterR O 213 Baud rate 0 = 300 Bd1 = 1200 Bd2 = 2400 Bd3 = 4800 Bd4 = 9600 Bd5 = 19200 Bd6 = 28800 Bd7 = 38400 Bd8 = 57600 Bd<strong>FF</strong>-<strong>Automation</strong> Oy


Page 10 - 229/12/2006AutoLog <strong>20AN</strong> Instruction ManualIf serial communication is not working check all settings listed below:DIP switch settings ( R O 213 defines the baud rate only when switches 3 and 4 are in ON position)the value of R O 213 ( check that the baud rate is correct)the value of R O 214 ( check that the operating mode is correct)the position DIP switch 2 ( DIP switch 2 chooses the serial bus for programming or data communication)cable connection ( check that the cable is correctly connected)the jumpers on CNV-1 ( if a CNV-1 converter is used)The modem settings and connection of modem cable if a modem is in useThe Modbus address of PLC ( in R O 243 the address is in decimal format)<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 10 - 329/12/200610.2 Terminal / printoutThe last character received from the Ser1 port can be read in register output R O 232,all characters received from the serial port are stored to FIFO 5 (256 first characters).If there are more than 256 characters and the application program doesn’t read thesefrom FIFO, overflows the FIFO and after that received characters are lost.Corresponding characters from Ser2, last character in R O 233 and all characters arestored to FIFO 6.The number of characters in FIFO storage can be saved to the register accumulator byinstruction READ F 5, and the code (0-255) of the character first received can be readby instruction FOU F 5. The read character codes can be saved to register memories.By using the PRT instruction the application program can print the characters e.g. todisplay or utilize the received characters in some other way.10.3 MODBUSMODBUS protocol allows the PLC to be connected to the serial line of a computer oranother PLC (e.g. <strong>AL</strong>2000). The <strong>AL</strong><strong>20AN</strong> PLC can operate as master or slave.Before the bus is used, certain settings must be made at the PLC. Thus, if the addressof the PLC to be 2 and the communication rate is to be 9600 Bd, the following settingsmust be made:DIP switch SW1:DIP234PositionONO<strong>FF</strong>ONRegister output:R O 214 = 4 ; ModeR O 243 = 2 ; AddressThe serial line has the following characteristics:- asynchronous- RS-232C (or with CNV-1, RS-422 with high-impedance output), CNV-2 or RS485 module (Ser2)- 1 start + 8 data + 2 (1) stop bits (on sending 2, on receiving 1 stop bit)- baud rate 300/1200/2400/4800/9600/19200/28800/38400/57600 Bd10.3.1 ProtocolModicon Modbus RTU, using the following functions:01 read binary outputs or memories 05 write binary output or memory02 read binary inputs 06 write register output, memory,03 read register ouputs, memories, word output or memoryword outputs or memories 15 write binary outputs or memories04 read word inputs 16 write register outputs or memories08 Master - slave loop back test- slave addresses 1 - 255, and address 0, which the slave recognizes only for functions 5,6,15 and 16.( writing to address 0 is broadcast, this means that all slaves accept the message,but none answers)<strong>FF</strong>-<strong>Automation</strong> Oy


Page 10 - 429/12/2006AutoLog <strong>20AN</strong> Instruction Manual- Makes the following checks:- checksum CRC16 correct - address correct- command from list on previous page - message length correct- message length 200 byte max. - writing into inputs not allowed- data address in permissible range - receiver overflow and characterframing errorMessages may be transmitted at rates 300,1200,4800,9600, 19200, 38400 or 57600baud, the composition of the message frames is shown below:SLAVEADDRESSFUNCTIONMEMORYADDRESSDA- TA CRC16 CHECK-SUMSTART(1 bit)DATA( 8 bits)STOP(2 bits)- A pause of about 50 ms indicates end of message.- Responce time to command:The message is processed between program cycles, and the time will thus vary;in addition there is a delay of 0,1 - 2 s depending on the message length and baudrate.- Modbus parameters for Ser1:R O 214 ; Mode of serial connection (4 = Modbus slave)R O 213 ; Baud rate (4 = 9600 Bd)R O 052 ; Counter, accepted modbus messagesR O 054 ;Send delay for Modbus message; default 50 ms = 50When the PLC is defined as a Modbus slave, the system program sets the dataconfiguration 8 bit, NO parity, 2 stop bit at sending and 1 stop bit at receiving.Register variables (R M, R I, R O) are 8 bit numbers, but they are transferred as 16bit words with the high byte set to zero.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 10 - 529/12/2006Binary outputs and memories as well as register outputs, memories, word outputsand memories are distinguished from each other by means of the Modbus dataaddress, such that references to memory variables are 1024 = 400hex higher in theaddress field than output variables.Thus for example: Variable Modbus addressR O 000 = 0000HR O 001 = 0001HR M 000 = 0400HR M 001 = 0401HW O 000 = 0800HW M 000 = 0C00HW M 1024 = 1C00HO 002 = 0002HM 005 = 0405H(This addressconversion istransparent, whenAutoLog master andAutoLog slave PLCsare used together.)In many control software systems,Modbus is configured on the basis of number of theregister type. The following table shows variable addresses:Read/write operationModbusreadModbuswriteAddressoffsetControl sw.AddressFCS sw.AddressBinary output (O)Binary memory (M)Binary memory (GM)Binary memory (BM)Binary input ( I )Word input (W I)Register output (R O)Register memory (R M)Word output 0 ->1023 (W O)Word memory 0 ->1023 (W M)Register general memory (R GM)Word general memory (W GM)Word output 1024 -> 2047 (W O)Word memory 1024 -> 4095 (W M)Word output 2048 -> 4095 (W O)Word memory 4096 -> 16275 (W M)0101010102040303030303030303030305, 1505, 1505, 1505, 1506, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 160102420483072010240102420483072409651206144716810240122880000101025020490307310001310254000141025420494307344097451214614547169SDO 0001SDO 1025SDO 2049SDO 3073SDI 0001SAI 1025SAO 0001SAO 1025SAO 2049SAO 3073SAO 4097SAO 5121SAO 6145SAO 7169Possible RS485 data communication, connector CON4 (pins D-, D+ and GND), isactivated same as the RS232C data communication.<strong>AL</strong><strong>20AN</strong> PLC’s system program takes care of handshake functions during datacommunication.<strong>FF</strong>-<strong>Automation</strong> Oy


RX TXRX 12VTXPage 10 - 629/12/2006AutoLog <strong>20AN</strong> Instruction Manual10.4 Modem - <strong>AL</strong><strong>20AN</strong>Two wire, carrier, modems are normally used on standard ‘dial-up’ telephone lines.Modems which conform to the following CCITT recommendations are suitable for usewith the <strong>AL</strong><strong>20AN</strong> system:* V.22 (1200 baud)* V.22bis (2400/1200 baud)* V.32 (9600/4800 baud)Using an auto-dialing modem which recognises ‘AT instructions, remote <strong>AL</strong><strong>20AN</strong> unitscan dial-up and send data to a supervising computer.The PRT instruction is used to dial telephone numbers:For example. ATDP 90-844992.The modem reports a connection using the "CONNECT" response. For the specificformat of ‘AT’ instructions, consult the modem manual.Data transfer rates of over 1200 baud, using telephone lines, can result in frequenterrors. If PRT instructions are used to transfer data, error correcting modems shouldbe used as data transfer errors may lead to operational problems. However, if an errorcorrecting protocol like modbus is used, error correcting modems are not necessary.Only type approved modems may be connected to the public telephonenetwork!Controlsoftware<strong>AL</strong><strong>20AN</strong>CON302CON301CON303CON101MODEMMODEMMOD7MOD6MOD5MOD4MOD3MOD2MOD1MOD0IC 1IC 3 IC 4IC 2IC 10RUNSER2CON501SER1CON1EXTI 2 C IC 2B1CON201CON502CON503 J1 J2 CON403 CON401 CON402MasterDial-upconnectionSlave<strong>FF</strong>-<strong>Automation</strong> Oy


CP U2000SDIC 32 DC AIC8 DIC 32DCAutoLog <strong>20AN</strong> Instruction Manual Page 10 - 729/12/2006Baseband modems are mostly used on short distance connections (telephone cablenot exceeding 15 km). A 4 wire connection is generally used, allowing the network tobe branched.ControlsoftwarelMasterMODEMRS-232CRxTxPrivatenetworkRS-232ClineTx Rx Tx Rx Tx RxModemDS 28565 4 7 2 38 7 5 3 2serial connectornumberingModemModemDS 2856 DS 285655<strong>AL</strong> 2000<strong>AL</strong><strong>20AN</strong> <strong>AL</strong> 14Slave Slave SlaveA baseband modem can also be used on a point-to-point connection.Most modems use a mains supply. It is advisable to check the power supplyarrangements of the modems with a view to battery back-up.<strong>AL</strong><strong>20AN</strong> SRM-6 4-wire SRM-6 <strong>AL</strong>2000lineMODEMMODEMmax.15kmAutoLog 2000In order to use a modem with the <strong>Programmable</strong> <strong>Logic</strong> <strong>Controller</strong>, the data communicationprotocol (R O 214=2 or 4) and the data transfer rate (R O 213) must be defined.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 10 - 829/12/2006AutoLog <strong>20AN</strong> Instruction ManualExample program below shows how the PLC can contact the modem.STR R C 000 ; Commands in EnglishEQ R O 212STR R C 002 ; Terminal communicationEQ R O 214STR R C 001 ; 1200 BdEQ R O 213STR S 000 ; Set up connectionAND I 000ATSTEP S 001DSTR S 001 ; Dial numberPPRTSTEP S 002EQ R RO 232EQ R RO 233EQ R M 000("ATE0V0DP040123456",)NEXT S 002 030 ; Timeout control in case of errors.NEXT S 003 060STR S 004STEP S 001STR R O 232 ; Check if connectionEQU R C 013 ; has been madeAND S 002STEP S 010STR R O 233EQU R C 049AND S 010STEP S 011STR S 011 ; Data transferPRT ("<strong>AL</strong>14 LOOKING FOR A CHAT",)STEP S 055NEXT S 055 060STR S 056STEP S 012NEXT S 012 003 ; Hang upSTR S 013PRT ("+ + +")STEP S 014NEXT S 014 003STR S 015PRT ("ATH0",)STEP S 016EQ R RO 232EQ R RO 233NEXT S 016 005 ; PLC begins to waitSTR R O 232 ; for the next callEQU R C 013AND S 017STEP S 019AND S 019STEP S 000NEXT S 017 005 ; If hang-up is unsuccesfulSTR S 018 ; then hang-up againSTEP S 012STOPTE0V0speed, character lengthand paritydial phone numberpulse dialingtone dialingdisable echodigit responces<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 11 - 129/12/200611. OPERATION OF THE PLC11.1 Switching on and special supply conditionsThe incoming supply power is smoothed and any spikes are suppressed. The eventsimmediately after switching on and in response to supply voltage variations aredescribed below.Voltage, U+32 V+24 V(b+20 V+16 V+14 V(c+8 V1. 2. 3. 4.5.(aTime, s1. The PLC is in ShutDown state (no function is detected).2. The chopper circuit starts -> the supply voltage is converted to a +5V regulated supply for thelogic processor and the rest of electronics.The POWFAIL signal from the voltage monitor is active and the RESET signal is active.3. The POWFAIL and RESET signals are deactivated. The logic processor does not start regularprogram execution until POWFAIL has been inactive for at least 600 ms.4. The <strong>Programmable</strong> <strong>Logic</strong> <strong>Controller</strong> operates normally.If the supply voltage falls below + 16 V for any reason, the PLC responds as follows:5. The POWFAIL signal is activated. The logic processor suspends normal operation and awaits thereturn of the supply voltage, the POWFAIL counter (R O 241) is incremented by 1.a) The supply voltage falls below + 14 V.The Reset signal stops the processor and protects the memory circuits.b) The supply voltage falls below + 16 V and rises again to a value above + 17,5 V within less than20 ms.The logic processor resumes program execution. Power fail counter R O 241 is incrementedby 1 to indicate a brief power interruption. The indicator light on the CPU boardflashes at a combined slow (=0,5Hz) and fast (= 5 Hz) rate for 4 minutes.c) The supply voltage falls below + 16 V but not below + 14 V and rises again to a value above+ 17,5 V within a longer time than 20 ms.The logic processor stops program execution, all outputs of the PLC are cleared,and logic processor flashes the indicator light at a very fast rate while awaiting the returnof supply power. When the supply voltage again rises, the logic processor resumes programexecution in the same way as after an ordinary switch-on, but flashes the indicator light at acombined slow and fast rate for 4 minutes.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 11 - 229/12/2006AutoLog <strong>20AN</strong> Instruction Manual11.2 Start of program executionWhen the PLC is started, bit memories (M,BM,GM 0-95 and 192-255), bit outputs (0-95and 192-255) and step registers (0-7) are cleared.If the position of the switch SW1 DIP 5 on the board is on, bit memories (96-191), bitoutputs (96-191), timers, counters and step registers (8 -31), register memories, wordvariables, FIFO and shift registers are also clered.Next the logic program stored in an FLASH memory is transferred to RAM.The logic program is checked and any error messages are sent to the programmingdevice. If the program is OK, it starts.After the second program cycle the logic processor examines those register variablesthrough which the logic program can tell:- what the serial interface is to be used, if not for programming- the baud rate of the serial interface, if not defined by the switches- the language selection, English or FinnishAll kinds of communication in the PLC (computer, user terminal, modbus) can commenceafter the second program cycle.The bit accumulator of the PLC is set to one during the two first program cycles, after thatit is always zero at the beginning of program cycle.In the beginning of the every program cycle the register accumulator holds the value ofprogram cycle time in milliseconds ( resolution 5 ms)11.3 START commandWhen program execution is initiated with the START command from the programming devise, thefollowing takes place:- the states of outputs and memories remain unchanged- the logic program is transferred from RAM to FLASH memory- The logic program is checked, and started if it is OK.- after the second program cycle the parameters are read fromthe register variables.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 11 - 329/12/200611.4 Remedies to common problemsProblems with communication of the programming device and the PLC:- Set the DIP switch 2 of the SW1 to position 0 (O<strong>FF</strong>).- Set the baud rates of the programming device and the PLC to the same values with DIPswitches 3 and 4 of SW1.- Check the type of the interconnection cable.- If the programming device is an IBM PC or equivalent, the correct programming software is<strong>AL</strong>ProWin or <strong>AL</strong>Pro- When using the <strong>AL</strong>Pro software, remember to keep the CAPS-LOCK on.- Check the operation of serial communication by pressing CLR (N) in terminal mode.One program line or an error message must appear on the screen.- Check that the correct serial port is used in PC (COM1/COM2)- Check that the supply power for the programming device is taken as far as possible from thesame outlet/phase/fuse as for the PLC.Switch off both the PLC and the PC for a moment and restart them.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 11 - 429/12/2006AutoLog <strong>20AN</strong> Instruction Manual<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 129/12/200612. PROGRAMMING(Paragraph 12.1 discusses the available alternative programming methods. Since separatedocumentation is provided for the programming programs, they are only briefly outlined below.)12.1 Programming methodsThe programming device can be any IBM compatible PC computer. The program istransferred through the programming cable to the PLC. When programming with a PC,the AlPro programming software is used. With the programming software, the PLCprogram can be written either in O<strong>FF</strong> LINE mode (without a PLC, forsubsequent transfer) or in ON LINE mode (the program is immediately transferred to thePLC).The <strong>AL</strong> 14 series <strong>Programmable</strong> <strong>Logic</strong> <strong>Controller</strong> incorporates a programming portSer1, (information on the operation of instructions and commands) and an RS-232Cinterface. Accordingly, the following alternative programming methods are available:- the <strong>AL</strong>ProWin programming software- the <strong>AL</strong>Pro programming software- a PROM programmerA complete program for the PLC can be produced using the programming software<strong>AL</strong>ProWin or <strong>AL</strong>Pro, which run on a personal computer. The programming software alsoallows for off-line programming and versatile program documentation etc.Memories of the PLC and programs:When a program is transferred from a programming device to the PLC, the program first goes toRAM and, after completion of the START command, to FLASH memory. When a logic program istransferred from the PLC to a programming device, the program is first stored from RAM to FLASH,and then transferred to the programming device.The logic program is stored in a FLASH memory. When power is applied to the <strong>Programmable</strong> <strong>Logic</strong><strong>Controller</strong>, the program is read into RAM for execution.12.1.1 Programming with a PROM programmerWhen a number of PLCs with identical functions are required, programming iseasiest to do by duplication. First program one FLASH using one of theprogramming programs or a terminal and then copy the finished program into theprogram memories of the remaining PLCs with a FLASH programmer.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 229/12/2006AutoLog <strong>20AN</strong> Instruction Manual12.1.2 Programming with <strong>AL</strong>ProWin/<strong>AL</strong>ProThe program, with comments, is first written in plain text form using the text editor of<strong>AL</strong>ProWin. (Any other text editor producing ASCII text will do just as well.) The programis then compiled with <strong>AL</strong>ProWin compiler into a form that the <strong>Programmable</strong> <strong>Logic</strong><strong>Controller</strong> understands, stored on a diskette, and transferred into the memory of thePLC when desired.Further features of <strong>AL</strong>ProWin:• Macros: Emphasizing the program structure. (Page division, writing similar programsections, etc.)Windowing: Error messages easy to include in the listing file.• ON-LINE features including display of variables, history display, on-line editor, etc.For example, the basic displays can be stored on disk, which facilitates the clearing offault conditions.• <strong>AL</strong>ProWin contains HELP screens describing the functions.• Available in Finnish and English language versions.A free version of the program, <strong>AL</strong>ProWin-demo or <strong>AL</strong>Pro-demo, is also available (similarto <strong>AL</strong>ProWin / <strong>AL</strong>Pro proper, but the length of the program that can be written is limited)as well as a manual (<strong>AL</strong>ProWin / <strong>AL</strong>Pro Programming manual).12.1.3 Fast program loopA fast program loop can be written into the <strong>Programmable</strong> <strong>Logic</strong> <strong>Controller</strong> for executionat timer interrupts, at intervals of 5 ms. The executable program of the loop starts asprogram line 0000 and ends at an END instruction.When the fast program loop is in use, the PLC reads inputs 0 - 7 and writes to outputs0 - 7 every time before executing the fast loop.The differentiation of auxiliary memories 0 - 7 is timed by the fast loop.The maximum permissible length of the fast loop is 62 instructions, but it is advisable tokeep it as short as possible in order to avoid slowing down the main program more thannecessary.No PRT instructions are allowed in the fast loop.CAUTION! The END instruction must not be written while program execution is inprogress. The program must always be halted when instructions preceding the ENDinstruction are deleted, added, or changed.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 329/12/200612.2 <strong>AL</strong><strong>20AN</strong> variables12.2.1 One bit variablesIInput, 8 - 96 off. Numbered 000...007, 8 –31 using analog/digital modules,32 - 95 expansion cards RIO / DI. Total number of DIs depend on used combination.NIOne’s complement of input. When I n=1 , NI n=0.M Auxiliary memory, 256 off. Numbered 000...255.BM, GM Auxiliary memory, 256 off. Numbered 000...255.NM, NB, NG One’s complement of auxiliary memory.OOutput, 8 - 72 off. Numbered 000...007, 32 - 95 using expansion cards RIO / DO.Total number of DOs depend on used combination. All unused ouputs can beused as one-bit auxiliary memory.NOOne’s complement of output.SM, SB, SG, SO Conditional set of memory or output, 256 off. Used in conjunction with EQ instruction.RM, RB, RG, RO Conditional reset of memory or output, 256 off. Used in conjunction with EQ instruction.DP Change of auxiliary memory from 0 to 1, 128 off. Numbered 000...127.Compares the state of the memory to its state at the beginning of the program cycle.DN Change of auxiliary memory from 1 to 0, 128 off. Numbered 000...127.Compares the state of the memory to its state at the beginning of the program cycle.PPulse variable. The variable is one for the duration of one program cycle, P000 tentimes per second, P001 once per second and P002 once per minute.SSequence register or a step of a sequence register. There are 32 sequence registers,with 256 step each.TXString constant (0 - 255). These are text strings with a maximum length of 16 ASCIIcharacters each. Used in conjunction with the PRT or EQU R TX instructionsTTimer, 80 off. Numbered 000...79. The resolution and range ofthe timers varies as follows:resolutionrangeT 000...003 10 ms 0,02...2,55 sT 004...007 100 ms 0,2...25,5 sT 008...015 1 s 2...255 sT 016...079 100 ms 0.2...25.5sIn the IF and STEP instructions T refers to the bit accumulator.In the PRT instruction T refers to TEXT.CCounter, 16 off. Numbered from 000 to 015. The counters count down;their range is 255 . . 0.In the PRT instruction C refers to to a numerical value.12.1.2 Register variables or 8 bit variablesR M, GMR NMR OR NOR SM, SOR RM, ROR TR CRegister memory, 256 off. Numbered from 000 to 255. Register GMs 128 - 255 arereserved for control variables of <strong>AL</strong>1095 Keypad/Display unit’s graphical symbols.One’s complement of register memory.Register output, 256 off. Register outputs are reserved for PLC’s system program.One’s complement of register output.Conditional set of register memory or output. Used in conjunction with EQ instruction.Conditional reset of register memory or output. Used in conjunction with EQ instruction.Register timer. Identical with the timers listed above; T or R T is used as the variableaccording to the instruction. Also refers to register accumulator in some instructions.Register constant 000...255 (decimal), except register counter with the READ andLOAD instructions. C or R C is used as the variable according the instruction.Q Queue, 4 off. Numbered from 0 to 3. The queue length can be 1 - 256.<strong>FF</strong>IFO store, 8 off. Numbered from 0 to 7. The FIFO store has 256 locations.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 429/12/2006AutoLog <strong>20AN</strong> Instruction Manual12.2.3 Word variables or 16 bit variablesW IWord input, 0 - 8 off. Numbered from 000 to 007. Used as analog inputs (12 bit).W M Word memory, 65536 off. Directly addressable numbered from 000 to 256.Indirectly addressable from 00000 to 65535 (EQI and STI instructions).Word memories 0 to 127 overlaps with register memories 0 - 255.W GM Word general memory, 256 off. Directly addressable numbered from 000 to 255.Reserved for PID controller variables.W O Word output, 4096 off. Directly addressable numbered from 000 to 256.Indirectly addressable from 0000 to 4095 (EQI and STI instructions).Word outputs W O 0-95 are reserved for analog outputs.W SM, SO Conditional set of directly addressable word memory or output.W RM, RO Conditional reset of directly addressable word memory or output.W TWord accumulator.W CWord constant 0...9999 (decimal).NOTE! Refer to chapter 15 at the end part of this manual:- <strong>AL</strong><strong>20AN</strong> PLC’s memory and I/O maps- <strong>AL</strong><strong>20AN</strong> PLC’s data retention during power failure12.3 Error messagesThe programming software issues error messages when it encounters error conditionsduring programming:ERROR 010 No AutoLog instruction on program lineERROR 020 Instruction write to memory failedERROR 021 Instruction write to memory failedERROR 022 Instruction write to memory failedERROR 025 The instruction entered is not validERROR 030 Variable number too largeERROR 031 Decimal number too largeERROR 032 Decimal number setting too highERROR 033 Invalid octal numberERROR 040 Instruction not found in program by FINDERROR 044 Not an AutoLog 16 instructionERROR 050 Transfer exceeds program spaceERROR 060 Hex file read errorERROR 080 Invalid variable (DISP)ERROR 085 Insertion pushes program beyond 2047/4095ERROR 090 Unidentified instruction in program at startERROR 091 Address of END instruction is 62 = 76 octERROR 092 A second END instruction in the programERROR 093 No STOP instruction in the program<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 529/12/200612.4 <strong>AL</strong><strong>20AN</strong> InstructionsBA Bit Accumulator RA Register AccumulatorWA Word Accumulatorn variable number d constant• AND I/M/O/NI/NM/NO/BM/GM/NB/NG/DP/DN/P nOperationSets the bit accumulator equal to the logical product of its oldvalue and the variable.BA RA WA VariableAffected Yes No No NoExample STR I 001 ; If input I 1 is ON andAND NI 002 ; input I 2 is O<strong>FF</strong>• AND S dOperationIf the bit accumulator is 1 before the instruction and the current sequence registeris at step d, the bit accumulator remains at 1; otherwise it is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR I 000 ;If input 0 is 1 and theAND S 019 ;sequence register is at step 19,EQ SM 201 ;set memory 201 to 1.• AND R C dOperationSets the register accumulator equal to the logical product of its old value andthe constant d (0 - 255).BA RA WA VariableAffected No Yes No NoExample STR R I 002 ;R I 002 = 10010001 BAND R C 015 ; = 00001111 BEQ R M 006 ;R M 6 = 00000001 B• AND R M/O/NM/NO nOperationSets the register accumulator equal to the bit-by-bit logical product of its old valueand the variable.BA RA WA VariableAffected No Yes No NoExample STR R O 002 ;R O 2 = 10010001 BAND R M 005 ;R M 5 = 00110001 BEQ R M 006 ;R M 6 = 00010001 B<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 629/12/2006AutoLog <strong>20AN</strong> Instruction Manual• AND W C dOperationSet the word accumulator equal to the logical product of its old value andthe constant d.BA RA WA VariableAffected No No Yes NoExample STR W I 003 ;W I 3 = 0000 0011 0000 1101 BAND W C 05667 ; = 0001 0110 0010 0011 BEQ W M 015 ;W M 15 = 0000 0010 0000 0001 B• AND W I/M/O nOperation Set the word accumulator equal to the logical product of its old value and variable n.BA RA WA VariableAffected No No Yes NoExample STR W I 003 ;W I 03 = 0000 0011 0000 1101 BAND W M 014 ;W M 14 = 0000 0000 0010 0110 BEQ W M 015 ;W M 15 = 0000 0000 0000 0100 B• BCD R TOperationConverts the number in the register accumulator into a two-digit BCD number00 - 99; if the number in the accumulator is greater than 99, the result isindeterminate.BA RA WA VariableAffected No Yes No NoExample STR R C 080 ;Acc. = 0101 0000B (= 80 DES)BCD ;now = 1000 0000B (= 80 BCD)• BCD W TOperationConverts the number in the word accumulator into a four-digit BCD number;if the number in the accumulator is greater than 9999, the result is indeterminate.BA RA WA VariableAffected No No Yes NoExample STR W C 04396 ;W A before = 0001 0001 0001 0001 BBCD W T ;W A after = 0100 0011 1001 0110 B; before ( 4396 DEC) after ( 4396 BCD)EQ W M 000 ;W M 0 = 17302 DEC<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 729/12/2006• BIN R TOperationConverts the contents of the register accumulator into binary format, assuming itcontained a two-digit BCD number before the instruction; if the accumulator doesnot contain a BCD number, the result is indeterminate.BA RA WA VariableAffected No Yes No NoExample STR R C 148 ;Acc. = 1001 0100B (= 94 BCD)BIN R T ;now = 0101 1110B (= 94 DES)• BIN W TOperationConverts the contents of the word accumulator into binary format, assuming itcontained a four-digit BCD number before the instruction; if the accumulator doesnot contain a BCD number, the result is indeterminate.BA RA WA VariableAffected No No Yes NoExample STR W C 00512 ;W A before=0000 0010 0000 0000 BBIN W T ;W A after = 0000 0000 1100 1000 B; before W A = 200 BCD, after 200 DEC• BIT M/O/BM/GM nOperationMoves the content of the register accumulator into 8 successive bit variables suchthat the least significant bit goes to address n, the next to address n + 1, etc., andthe most significant bit to address n + 7.Register accumulator Variablebit 0nbit 1 n + 1bit 2 n + 2bit 3 n + 3bit 4 n + 4bit 5 n + 5bit 6 n + 6bit 7 n + 7BA RA WA VariableAffected No No No YesExample STR R C 130 ;= 10000010BBIT O 008 ;Turn on outputs 015 and 009<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 829/12/2006AutoLog <strong>20AN</strong> Instruction Manual• BYT I/M/O/BM/GM nOperationConverts 8 successive variables to a byte in the register accumulator. Variable nbecomes the least significant bit and variable n + 7 the most significant bit.Variable Register accumulatorn bit 0n + 1 bit 1n + 2 bit 2n + 3 bit 3n + 4 bit 4n + 5 bit 5n + 6 bit 6n + 7 bit 7BA RA WA VariableAffected No Yes No NoExample BYT I 000 ;The time setting forBIN;timer 6 is read fromSTR NI 010 ;inputs, for exampleLOAD R T 006 ;a thumbwheel switch.• CLO R M/O nOperation Compares the 16-bit value in register memories RM 250 and RM 251 (RM 250 =high byte) with the variable given as the instruction parameter. The bit accumulatoris reset to 0 when (RM 250, RM 251) = (R M/O n, R M/O n + 1).CAUTION: The 16-bit values compared must be in the same format, i.e.both binary or both BCD.BA RA WA VariableAffected Yes No No NoExample CLO R M 192 ;Output 012 is turned onEQ O 012 ;when the clock time reachesCLO R M 194 ;the value written into RM 192INV;and RM 193, and off when theAND O 012 ;clock time reaches the valueEQ O 012 ;written into RM 194 and RM 195.• CONTOperationTerminates the skipping of instructions. (The STOP instruction also has this effect.)The first CONT instruction encountered stops the effect of all nested IF instructions.BA RA WA VariableAffected No No No NoExample IF I 000 ;If Input 000 = 1,STR I 001 ;then ...EQ O 001IF I 002 ;if Input 000 = 1 and Input 002 = 1,STR O 003 ;then ...EQ O 004CONT;Continue here in any case.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 929/12/2006• CSR nOperationThe PLC executes the subprogram n if the bit accumulator is trueBA RA WA VariableAffected No Yes No NoThe states of the accumulators remain unchanged, so subroutine can use theaccumulator states.See page 12-40.• DCD R M/O nOperationDecodes the value of the variable n into the register accumulator. If the variable isbetween 0 and 7, the corresponding bit is set to 1 and the remaining bits are resetto 0. If the variable is greater than 7, the register accumulator is reset to 0.The value 0 corresponds to the least significant bit and 7 to the most significant bit.BA RA WA VariableAffected No Yes No NoExample STR R C 006EQ R M 000DCD R M 000 ;Acc. = 01000000BValue of variable0 11 22 43 84 165 326 647 128>7 0Register accumulator after DCD instruction• DCR C nOperationIf the bit accumulator is 1, decrement counter n by 1. This instruction does notperform differentiation - for example, when counting pulses, the program mustensure that the counter is decremented by one for each pulse.BA RA WA VariableAffected No No No YesExample STR NI 000LOAD C 000 100 ;Count 100 pulsesEQ O 000STR I 001EQ M 001STR DP 001 ;Differentiate input 1DCR C 001<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 1029/12/2006AutoLog <strong>20AN</strong> Instruction Manual• DEC R M/O nOperationIf the bit accumulator is 1, decrement the variable by 1 and load the value of thevariable into the register accumulator. Decrementing a variable whose value is 0gives 255. If the bit accumulator is 0, the variable is not decremented but onlyloaded into the register accumulator. If the variable was decremented (the bit accumulator was 1) and the result was 255 (zero minus 1), the bit accumulator is set to 1;otherwise the bit accumulator remains at 0.BA RA WA VariableAffected Yes Yes No YesExample STR P 001 ;Decrement memory 112DEC R M 112 ;once per second. Every timeXOR O 001 ;the memory goes fromEQ O 001 ;0 to 255, invert output 1.• DEC W M/O nOperationIf the bit accumulator is 1, decrement variable n by 1 and load the new value ofthe variable into the word accumulator. If the bit accumulator is 0, the variable is notdecremented but only loaded into the word accumulator. Decrementing a variablewhose value is 0 gives 65535. If the variable is decremented (the bit accumulatorwas 1)and the result is 65535, the bit accumulator is set to 1; otherwisethe bit accumulator is reset to 0.BA RA WA VariableAffected Yes No Yes YesExample STR P 000 ;Decrement memory 130DEC W M 130 ;10 times per second. Every timeXOR O 000 ;the memory goes fromEQ O 000 ;0 to 65535, invert output 0.• DIV R C dOperationDivide the register accumulator by the constant d. The quotient remains inthe register accumulator and the remainder is stored in register output RM 244.BA RA WA VariableAffected No Yes No NoExample STR R M 010 ;RM 10 = 15DIV R C 006 ;Acc. = 2;RM 244 = 3<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 1129/12/2006• DIV R M/O nOperationDivide the register accumulator by the variable n. The quotient remains in theregister accumulator and the remainder is stored in register output RM 244.BA RA WA VariableAffected No Yes No NoExample STR R M 100DIV R O 000• DIV W I/M/O nOperationDivide the word accumulator by the variable n. The quotient remains in the wordaccumulator and the remainder is stored in register outputs RM 230,231 (MSB/LSB).BA RA WA VariableAffected No No Yes NoExample STR W M 025DIV W I 010 ;result is in word accumulatorEQ W M 010STR R O 230EQ R M 230STR R O 231EQ R M 231STR W M 115EQ W M 011 ; the remainder is in W M 011• DIV W C dOperationDivide the word accumulator by the constant d. The quotient remains in the wordaccumulator and the remainder is stored in register outputs RM 230,231 (MSB/LSB).BA RA WA VariableAffected No No Yes No• ENDExample STR W M 025DIV W C 01040OperationLast instruction of the fast program loop. CAUTION: The END instruction must notbe written while the program is being executed. The program execution must alwaysbe suspended if any of the instructions preceding the END instruction are removed,added, or altered.BA RA WA VariableAffected No No No NoExample STR NO 000 ;A 100 Hz oscillator.EQ O 000 ;This loop runs every 5 ms.ENDSTR I ... ;The regular program starts here.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 1229/12/2006AutoLog <strong>20AN</strong> Instruction Manual• EQ M/O/BM/GM nOperationSets the variable equal to the contents of the bit accumulator.BA RA WA VariableAffected No No No YesExample STR I 000 ;Output O0EQ O 000 ;follows input I0.• EQ SM/SO/SB/SG nOperation If the bit accumulator is 1, set the variable to 1;if the bit accumulator is 0, do nothing.BA RA WA VariableAffected No No No YesExample STR I 000 ;Input O0 setsEQ SO 010 ;output 10 to 1.• EQ RM/RO/RB/RG nOperation If the bit accumulator is 1, reset the variable to 0;if the bit accumulator is 0, do nothing.BA RA WA VariableAffected No No No YesExample STR I 0.00 ;Input I 0.00 resetsEQ RO 1.00 ;output O 1.00.• EQ R M/O/GM nOperationSets the variable equal to the contents of the register accumulator.BA RA WA VariableAffected No No No YesExample STR R C 085 ;Constant 85 loaded intoEQ R M 211 ;register memory 211• EQ R RM/RO nOperation If the bit accumulator is 1, reset the variable to 0;if the bit accumulator is 0, do nothing.BA RA WA VariableAffected No No No YesExample STR R C 123 ;If input 10 = 1,EQ R M 100 ;register memory 100STR I 010 ;is set to 0,EQ R RM 100 ;otherwise 123.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 1329/12/2006• EQ R SM/SO nOperationIf the bit accumulator is 1, set the variable equal to the contents of the registeraccumulator; if the bit accumulator is 0, do nothing.BA RA WA VariableAffected No No No YesExample STR R C 123EQ R M 100 ;If input I1 = 1,STR R C 200 ;register memory 100 = 200,STR I 001 ;otherwise registerEQ R SM 100 ;memory 100 = 123.• EQ W M/O/GM nOperationSet the variable equal to the contents of the word accumulator.BA RA WA VariableAffected No No No YesExample STR W I 000 ;Word memory 3EQ W M 003 ;follows analog input 0.• EQ W RM/RO nOperation If the bit accumulator is 1, reset the variable to 0; if the bit accumulator is 0,do nothing.BA RA WA VariableAffected No No No YesExample STR W C 03000 ;If input I004 = 1,EQ W M 130 ;word memory 130STR I 004 ;is set to 0,EQ W RM 130 ;otherwise 3000.• EQ W SM/SO nOperationIf the bit accumulator is 1, set variable n equal to the contents of the wordaccumulator; if the bit accumulator is 0, do nothing.BA RA WA VariableAffected No No No YesExample STR W C 04500EQ W M 130 ;If input I004 = 1,STR W C 05000 ;word memory 130 = 5000,STR I 004 ;otherwise wordEQ W SM 130 ;memory 130 = 4500.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 1429/12/2006AutoLog <strong>20AN</strong> Instruction Manual• EQI M/O/BM/GMOperationWrites the state of bit accumulator into bit output/memory.Register accumulator is pointing to the bit variable to be written.BA RA WA VariableAffected No No No YesExample STR R C 008 ;program sets the state of bit accumulatorEQI O ;into output 8.• EQI R M/O nOperationLoads the content of the register accumulator into the variable whose address isthe value of the variable given as the instruction parameterBA RA WA VariableAffected No No No YesExample STR R C 001EQ R M 000EQI R M 000 ;1 into memory 1INC R M 000EQI R M 000 ;2 into memory 2INC R M 000EQI R M 000 ;3 into memory 3• EQI W M/O nOperationLoads the content of the word accumulator into the variable whose address is thevalue of the variable given as the instruction. Accessible addresses are W M variables0 to 2047, W O variables 0 to 1023 (check from memory tables)BA RA WA VariableAffected No No No YesExample STR W C 11 ; min 0, max 2047EQ W M 000EQI W M 000 ;value of word accumulator into memory 11INC W M 000EQI W M 000 ;value of word accumulator into memory 12• EQU R C dOperation If the constant d is equal to the register accumulator, the bit accumulator is set to 1;if unequal, the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR R M 001EQU R C 010EQ O 001 ;There may be severalEQU R C 020 ;successive comparisonsEQ O 002<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 1529/12/2006• EQU R M/O nOperationIf variable n is equal to the number in the register accumulator, the bit accumulatoris set to 1; if unequal, the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR R M 001 ;If memories 1 and 2EQU R M 002 ;are equal,EQ O 000 ;output 0 is 1.• EQU R TX nOperationCompares if the content of text string (TX n) n is found in given FIFO n. If an identicaltext string is found, the bit accumulator is set to 1. Into register accumulator istransferred BCD number which is formed from the next two characters after the stringfound. If the characters don’t represent a BCD number, the register accumulatorbecomes zero. Into the word accumulator is transferred the ASCII codes of the ormercharacters. The FIFO number to be compared is given in register accumulator.BA RA WA VariableAffected Yes Yes Yes NoExample STR C 001 ; Bit accumulator to 1EQ R RM 024 ; reset W M 12EQ W RM 025 ; reset W M 12STR R C 005 ; Compare if FIFO 5 (ser 1)EQU R TX 024 ; includes the text srting (TX 24)EQ M 024 ; Save the result to bit memory, the BCDEQ R M 024 ; number into R M 24 and charactersEQ W M 025 ; ASCII codes into W M 25 (R M 50, 51)• EQU W I/M/O nOperationIf variable n is equal to the number in the word accumulator, the bit accumulator isset to 1; if unequal, the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR W C 03000 ;If word memory 37EQU W M 037 ;equals 3000,EQ O 008 ;output 8 is on.• EQU W C dOperationIf the constant d is equal to the number in the word accumulator, the bit accumulatoris set to 1; if unequal, the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR W M 001EQU W C 01000EQ O 001 ;There may be severalEQU W C 02000 ;successive comparisonsEQ SO 001<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 1629/12/2006AutoLog <strong>20AN</strong> Instruction Manual• FCN nOperationIf the bit accumulator is true, the FCN instruction executes one of the followingfunctions. After successful execution of the instruction the bit accumulator is true.An undefined function call or illegal calculation parameter(s) may cause bitaccumulator to reset.BA RA WA VariableAffected Yes No Yes NoCAUTION! TheFCN instruction must not beused in the fast programloop!n selects the function for execution calculationtime0 = logarithm a. 13 ms1 = natural logarithm a. 12 ms2 = sqrt (square ) a. 7 ms8 = percent10 = scaling of word variable a. 7 ms11 = scaling of word variable a. 8 msoutput: sign, integer and decimal part24 = Send modbus message30 = write to I 2 C channel31 = read from I 2 C channel32 = read serial number from IbuttonBefore calling the FCN instruction the variables content, which is to be scaled, mustbe written to word accumulator. After execution of FCN instruction the result ofcalculation is in word accumulator. The resolution of the result depends on theused function.0 log 65535= 4.8164, in word acc. is 481641 ln 65535= 11.090, in word acc. is 110902 sqrt 65535= 255.99, in word acc. is 255998 %, value in WA, number in RA = percent value, after execution the resultis in word accumulator ( WA * RA)/100<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 1729/12/2006• FCN 10 ScalingIn WA is the number to be scaled, in RA is the address of word memory pointer, thatcontains the scaling parameters. The range of scale word memories is freelyselectable. The order of scaling parameters is:W M 100 = low limit of measured input (0 ... 4095)W M 101 = high limit of measured input (0 ... 4095)W M 102 = low range scaled output (eg. 10 (°C))W M 103 = high range scaled output (eg. 115 (°C))Example STR W C 0800 ; low limit of input (4 - 20 mA)EQ W M 100 ; wanted output 0 - 1000 (tenths of percent)STR W C 4095 ; high limit of inputEQ W M 101STR W C 0000 ; low limit of outputEQ W M 102STR W C 1000 ; high limit of outputEQ W M 103STR R C 100 ; parameters start address to RASTR W I 001 ; word input to be scaled into WASTR C 001 ; set bit accumulator to 1FCN 010 ; call scaling functionEQ W M 200 ; save the result to WM 200STOP<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 1829/12/2006AutoLog <strong>20AN</strong> Instruction Manual• FCN 11 Scaling, returns sign,integer- and decimat partIn WA is the number to be scaled, in RA is the address of word memory pointer,that points to the scaling parameters. Pointer offset 0 points to W M area, offset32768 points to W O area.The range of scale word memories is freely selectable.The order of scaling parameters is:W M 100 = low limit of measured input (0 ... 4095)W M 101 = high limit of measured input (0 ... 4095)W M 102 = low range scaled output (eg. 10 (°C))W M 103 = high range scaled output (eg. 115 (°C))W M 104 = offset to 0-value (input data)W M 105 = decimal count 0..4 (input data)W M 106 = Sign 0=plus, 1=negative (output data)W M 107 = interger part (output data)W M 108 = decimal part (output data)Example STR W C 00000 ; low limit of input (Pt100 -50-150°C)EQ W M 100 ; wanted output -50.0 - 150.0 (tenths of percent)STR W C 04000 ; high limit of inputEQ W M 101STR W C 00000 ; low limit of outputEQ W M 102STR W C 00200 ; high limit of outputEQ W M 103STR W C 01000 ;offset (1000=0°C)EQ W M 104STR W C 00001 ;decimalsEQ W M 105STR W C 00100 ; Intialize pointer 2EQ W M 099 ; points to W M 100STR R C 099 ; Initial pointer 1 points to W M 099STR W I 001 ; word input to be scaled into WASTR C 001 ; set bit accumulator to 1FCN 011 ; call scaling functionSTOP<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 1929/12/2006• FCN 24 Launch modbus message to serial channelCommand is executed only if Bit accu equals 1 before instruction.Function parameters are defined in word memories. Register accu must hold theaddress of the first parameter before FCN instructionParameters: 1 st parameter:Serial Channel (1=Ser1, 2=Ser2, 3=Ser3)2 nd parameter:Message number (0..511)Execution time is about 0.03 msFNC 24 checks the parameter values and if parameters are OK it will add the messagenumber to the first place in message queue and returns with bit accu set to 1.If any of parameters is not acceptable, FCN will return with bit accu set to 0.If message already exists in message queue, the previous message request will beremoved from message list.If current "transfer in progress" is the same message as requested message, requestis ignored. Function will however return 1.Example 1 Send message every time input goes acticeParameters: W M 010 :3 ; Serial channel 3W M 011 :10 ; message numberProgram: STR I 000 ;EQ M 000STR DP 000 ; On positive derivationSTR R C 010 ; Get parameters from W M 10->FCN 024INVEQ SM ERROR ;STOP• FCN 25 Launch in PLC program defined modbus message to serial channelCommand is executed every time when it’s called. Function gives the statusinformation to register accu if BA=0 before function call or sends the messageif BA=1 before function call.Function parameters are defined in word memories. Register accu must hold theaddress of the first parameter before FCN instructionParameters: 1 st parameter: Serial Channel (1=Ser1, 2=Ser2, 3=Ser3)2 nd parameter: Slave address (0 - 255)3 d parameter: Direction (0=read, 1=write)4 th parameter: Slave data type (0..11, WM=9)5 th parameter: Slave data address (0 - 51980)6 th parameter: Data count (max. 100)7 th parameter: Master data type (0..11, WM=9)8 th parameter: Master data address 0 - 519809 th parameter: NetIDExecution time is about 0.03 msFNC 25 checks the parameter values and if parameters are OK it will add the messagenumber to the first place in message queue and returns with bit accu set to 1.If any of parameters is not acceptable, FCN will return with bit accu set to 0.If message already exists in message queue, the previous message request will beremoved from message list.If current "transfer in progress" is the same message as requested message, requestis ignored. Function will however return 1.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 2029/12/2006AutoLog <strong>20AN</strong> Instruction ManualData types andError codes0 Output (O) 129 Start address too high1 Memory (M) 130 Read to input2 General memory(GM) 131 Invalid data type3 Binary memory (BM) 132 Out of range (Attempt to read4 Input (I) out of range. Decrease block size.)5 Register output (R O)6 Register memory (R M)7 Register general memory (R GM)8 Word output (W O)9 Word memory (W M)10 Word generag memory (W GM)11 Word input (W I)Example 1 Send message every time when control memory is set on.Program: STR R S 010 ; Step register 10 in useSTR S 000AND M Send-msg ; When controlledSTEP S 010 ; launch the message; Initialize variablesIF S 010 ; Read values from slaveSTR W C 00002EQ W M Ser_Chnl ;230 ; 1. (1=ser1, 2=ser2, 3=ser3)STR W O Slave_ID ; slave's modbus addressEQ W M Hst_addr ;231 ; 2. slave address, history readSTR W C 00000EQ W M Direction ;232 ; 3. Direction (0=read, 1=write)STR W C 00009EQ W M Datatype ;233 ; 4. Slave data type (0..11, WM=9)STR W C 00004STR W M SlvD_adr ;234 ; 5. Slave data addressSTR W C 00064 ; read 64 variables in one messageEQ W M Data_Cnt ;235 ; 6. Data count (max. 100)STR W C 00009EQ W M MDataType ;236 ; 7. Master data typeSTR W C 04096 ; master's memory start offsetEQ W M MData_Adr ;237 ; 8. Master data addressSTR R O Net_IDEQ R M AuxLbytSTR R C 000EQ R M AuxHbytSTR W C 00002EQ W M Net_ID ;238 ; 9. NetIDSTR C 000STR W C 52080MIN W M SlvD_adr ; 5. Slave data address (Start)GRT W M Data_Cnt ;235 ; 6. Data count (max. 100)EQ W SM Data_Cnt ;235 ; 6. Data count (max. 100)CONTContinues on next page...<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 2129/12/2006IF S 010 ; Read data from slaveSTR C 001EQ RM Send-msg ; reset control memorySTR C 000STR W C 00230 ; Start address of parametersFCN 025 ; Call function 25 for status infoEQ R M 000GRT R C 018 ; If status = OK to sendEQ M 000LES R C 127 ;OR M 000IF TSTR W C 00230 ; Start address of parametersFCN 025 ; Call function 25 send messageSTEP S 000 ; If BA=1 go to step zero (messageINV; successfully sent)STEP S 080 ; If in error step go to step 80EQ R SM 003 ; save error codeCONTIF S 080 ; Error stepSTR C 001EQ RB 086 ; Reset Data read memoryEQ SB 087 ; Set Data read interruptedSTEP S 000CONTSTOP<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 2229/12/2006AutoLog <strong>20AN</strong> Instruction Manual• FCN 26 Launch in PLC program defined modbus message to serial channelCommand FCN 26 places launched modbus message to the end of modbusmessage que.Command is executed every time when it’s called. Function gives the satusinformation to register accu if BA=0 before function call and sends the messageif BA=1 before function call.Function parameters are defined in word memories. Register accu must hold theaddress of the first parameter before FCN instructionDefine parameter construction is similar as in function FCN 25, onlydifference in funtion is the placement the message in modbus que.• FCN30 AND FCN 31 I 2 C Write (FCN30) & read (FCN31) functionsThese commands are used to communicate with external I 2 C devices connected into AutologPLC’s I 2 C channel.Command is executed only if Bit accu equals 1 before instruction.Function parameters are defined in word memories. Register accu musthold the address of the first parameter before FCN instructionParameters:1 st parameter: Slave address2 nd parameter: Byte count3 rd parameter: Data 0n th parameter: Data nExecution time is about 0.1 ms /byteFor read function (FCN 31), last byte is always read without ACK.Read bytes are stored right after parameter “byte count “When you wish to connect I2C devices to PLC, refer always to specificationprovided by the device manufacturer.(device address, READ/WRITE operations etc.)Also make shore that there are no duplicated device addresses in I 2 C-channel.Example 1Write Outputs every 1 secondParameters: R M 010 : 4Ch ; I2C I/O.board addressR M 011 : 1 ; byte countR M 012 : 0Fh ; output data.Program: STR P 001STR R C 010 ; parameters R M 10 ->FCN 030 ; Write<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 2329/12/2006Example 2Read keypadParameters: R M 020 : 40h ; <strong>AL</strong>1093 keypad addressR M 021 : 1R M 022 ; keypad dataProgram: STR R C 020 ; parameters R M 020 ->FCN 031 ; readExample 3 Read Clock 8583Parameters: R M 010 : A0h ; Base addressR M 011 : 1 ; byte countR M 012 : 1 ; data addressR M 013 : A0h ; Base addressR M 014 : 6 ; byte countR M 015 : clock data: hundredth of a secondR M 016 : clock data: secondsR M 017 : clock data: minutesR M 018 : clock data: hours,R M 019 : clock data: year/dateR M 020 : clock data: weekday/monthProgram: STR P 001STR R C 010 ; parameters from R M 010 ->FCN 030 ; initialize read addressSTR R C 013 ; parameters for read fcnFCN 031 ; read only if FCN 30 was successful.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 2429/12/2006AutoLog <strong>20AN</strong> Instruction Manual• FCN 32 Read Ibutton serialcodeThis command is used to read serial code from IButton device connectedinto Autolog PLC’s I 2 C channel.Command is executed only if Bit accu equals 1 before instruction.Function parameter is defined in register accu. Register accu must hold theaddress of the 1 st byte save locationExecution time is 1.4 msIf iButton is not connected to PLC, command retuns BA = 0 and RA = 0.If iButton is connected but CRC does not match, BA = 0 and RA 0.If iButton is connected and it was successfully read, BA = 1 and RA = 0.Example 1Read iButton once in a secondProgram: STR P 001STR R C 000 ; serial code saved into R M 0 ->FCN 032 ; check for ibuttonIF T ; if ibutton was attached to PLC and data; was succesfully readSTR R M 000 ; make comparisonEQU R M 100 ; device codeEQ M 000 ; result to memory 0STR R M 001 ; 1 st data byteEQ R M 101 ;AND M 000EQ M 000Etc.CONTExample 2 Check for iButton every 1 secondProgram: STR R C 000 ; parameters from R M 000 ->STR P 001 ; every second…IF T ; parametrit alkaen R M 10 ->FCN 032 ; Read possible IbuttonEQ O 005 ; set output 5 activeCONT<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 2529/12/2006• FCN 50 Save serial channel settings into FlashOperation.This command is used to save serial Channel settings from PLC’s serial communicationregisters and Modbus slave information into Flash memory .Included parameters are Ser1 mode and speed, Ser2 mode and speed andSlave ID and NET ID.Command is executed only if Bit accu equals 1 before instruction.BA RA WA VariaAffected No No No NoExample STR DP 001 ;When memory 1is set to 1FCN 50 ;save current serial channel parameters to Flash• FCN 51 Read serial channel settings from FlashOperationThis command is used to read serial Channel settings from PLC’s serial communicationregisters and Modbus slave information into Flash memory .Included parameters are Ser1 mode and speed, Ser2 mode and speed andSlave ID and NET ID.Command is executed only if Bit accu equals 1 before instruction.BA RA WA VariaAffected No No No YesExample STR DP 002 ;When memory 2is set to 1FCN 51 ;load serial channel parameters from Flash<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 2629/12/2006AutoLog <strong>20AN</strong> Instruction Manual• FCN 52 Save block of word memory variables into FlashOperation This command is used to save a block of word memories into Flash memory .Function parameters are defined in register accu (number of varaibles)and in word accu (word memories start address (must be in first page 0 - 4095)..Command is executed only if Bit accu equals 1 before instruction.BA RA WA VariaAffected No No No NoExample STR R M 111 ; Number of variables (max. 255)STR W M 111 ; Block start address; (from 0 to 4095 - number of variables)STR DP 001 ; When memory 1 is set to 1FCN 52 ; save block of word mwmories to Flash• FCN 53 Load block of word memory variables from FlashOperationThis command is used to load a block of word memories from Flash memoryinto PLC’s RAM memory. .Function parameters are defined in register accu (number of varaibles)and in word accu (word memories start address (must be in first page 0 - 4095).Command is executed only if Bit accu equals 1 before instruction.BA RA WA VariaAffected No No No YesExample STR R M 112 ; Number of variables (max. 255)STR W M 112 ; Block write start address; (from 0 to 4095 - number of variables)STR DP 002 ; When memory 2 is set to 1FCN 53 ; load block of word memries from Flash<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 2729/12/2006• FIN F nOperationIf the bit accumulator is 1, move the contents of the register accumulator into FIFOstore n (0 - 7). If there was room in the FIFO, set the bit accumulator to 1, if not,clear the bit accumulator to 0.BA RA WA VariableAffected Yes No No YesExample STR I 000 ;At the rising edge of input 0EQ M 000STR DP 000STR R C 012 ;enter the number 12FIN F 000 ;into FIFO 0.• FOU F nOperationIf the bit accumulator is 1, move the "oldest" number in FIFO store n (0 - 7) intothe register accumulator. If a number was available in the FIFO, setthe bit accumulator to 1, if not, clear the bit accumulator to 0.BA RA WA VariableAffected Yes Yes No YesExample STR I 000 ;At the rising edge of input 0EQ M 000STR DP 000STR R C 024 ;enter the number 24FIN F 000 ;into FIFO 0,STR R C 034 ;enter the number 34FIN F 000 ;into FIFO 0, move the numberFOU F 000 ;24 from FIFO 0 into the register acc.• GRT R C dOperationIf the constant d is greater than the register accumulator, the bit accumulator is setto 1; otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR R O 001 ;When register output 1GRT R C 100 ;is less than 100EQ O 000 ;output 1 is on.GRT R C 200 ;When RI 1 is less than 200EQ O 002 ;output 2 is on.• GRT R M/O nOperation If variable n is greater than the register accumulator, the bit accumulator is set to 1;otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR R C 100 ;When register memory 0GRT R M 000 ;is greater than 100,EQ O 000 ;output 0 is 1.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 2829/12/2006AutoLog <strong>20AN</strong> Instruction Manual• GRT W C dOperationIf the constant d is greater than the number in the word accumulator, the bitaccumulator is set to 1; otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR W M 001 ;When word memory 1GRT W C 04009 ;is less than 4009,EQ O 002 ;output 002 is on;GRT W C 01050 ;when WM 1 is less than 1050,EQ O 003 ;output 003 is on.• GRT W I/M/O nOperationIf variable n is greater than the number in the word accumulator, the bit accumulatoris set to 1; otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR W C 00500 ;When analog input 002GRT W I 002 ;is greater than 500,EQ O 033 ;output 33 is on.• IF TOperationIf the bit accumulator is 0, subsequent instructions up to the CONT instruction areskipped; if the bit accumulator is 1, the instructions are executed. Further IFinstructions can be placed between the IF and CONT instructions. The effect ofall IF instructions ceases at the first CONT instruction encountered.BA RA WA VariableAffected No No No NoExample STR I 010IF T ;If input 10 = 0,STR I 001 ;these instructions willEQ O 001 ;not be executedCONT• IF I/M/O/NI/NM/NO/DP/DN/BM/GM/NB/NG/P nOperationIf the variable is 0, subsequent instructions up to the CONT instruction are skipped;if the variable is 1, the instructions are executed. Further IF instructions can beplaced between the IF and CONT instructions. The effect of all IF instructionsceases at the first CONT instruction encountered.BA RA WA VariableAffected No No No NoExample IF DP 077 ;When memory 77 changesSTR I 000 ;from 0 to 1, these instructionsEQ SM 001 ;are executedCONT<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 2929/12/2006• IF S dOperationIf the current sequence register is at step d, subsequent instructions are executed;otherwise execution continues from the next CONT instruction. Further IFinstructions can be placed between the IF and CONT instructions. The effect of allIF instructions ceases at the first CONT instruction encountered.BA RA WA VariableAffected No No No NoExample STR R S 003 ;When the sequence registerIF S 098 ;is at step 98,STR NO 071 ;invert output 71.EQ O 071CONT• INC R M/O nOperationIf the bit accumulator is 1, add 1 to register variable n. If the variable was 255, thenew value is 0 and the bit accumulator is set to 1; otherwise the bit accumulator isreset to 0. If the bit accumulator was 0, the variable is not incremented. The valueof the variable is loaded into the register accumulator.BA RA WA VariableAffected Yes Yes No YesExample STR P 001 ;Increment register memory 0 once per second.INC R M 000• INC W M/O nOperationIf the bit accumulator is 1, add 1 to variable n and load the new value of the variableinto the word accumulator. If the variable was 65535, the new value is 0 and the bitaccumulator is set to 1; otherwise the bit accumulator is 0. If the bit accumulatorwas 0, the variable is not incremented but only loaded into the word accumulator.BA RA WA VariableAffected Yes No Yes YesExample STR P 001 ;Increment word memory 3INC W M 003 ;once per second.• INVOperationChanges the bit accumulator to its one's complement.BA RA WA VariableAffected Yes No No NoExample STR O 000 ;Bit accumulatorAND NO 000 ;is zero after thisINV;and one after this<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 3029/12/2006AutoLog <strong>20AN</strong> Instruction Manual• LES R C dOperation If the constant d is less than the register accumulator, the bit accumulator is set to 1;otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR R O 001 ;When register output 1LES R C 145 ;is between 146 and 154,EQ M 000GRT R C 155AND M 000 ;output 2 is 1.EQ O 002• LES R M/O nOperation If variable n is less than the register accumulator, the bit accumulator is set to 1;otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR R O 001 ;When register memory 2LES R M 002 ;is less than register output 1,EQ O 000 ;output 0 is 1.• LES W C dOperationIf the constant d is less than the number in the word accumulator, the bitaccumulator is set to 1; otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR W I 001 ;When constant 6000LES W C 06000 ;is less than analog input 01,EQ O 030 ;output 30 is 1.• LES W I/M/O nOperationIf variable n is less than the number in the word accumulator, the bit accumulator isset to 1; otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR W I 001 ;When word memory 4LES W M 004 ;is less than analog input 01,EQ O 030 ;output 30 is 1.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 3129/12/2006• LOAD C n dOperationIf the bit accumulator is 1, counter n is loaded with the initial setting d. After theinstruction, the bit accumulator contains the status of the counter (1 = counted out,0 = running). A setting can be defined for the counter with the programming device.If it is non-zero, it will be used; if it is zero, the value set in the program will be used.When the PLC is switched on, all counters are at zero.BA RA WA VariableAffected Yes No No YesExample STR NI 000 ;Delay of 100 secondsLOAD C 000 100 ;made withEQ O 000 ;a counter 0STR P 001DCR C 001• LOAD T n dOperationIf the bit accumulator is 1, timer n is loaded with the initial setting d. After theinstruction, the bit accumulator contains the status of the timer (1 = timed out,0 = running). A setting can be defined for the timer with the programming device.If it is non-zero, it will be used; if it is zero, the time set in the program will be used.When the PLC is switched on, all timers are at zero.BA RA WA VariableAffected Yes Yes No YesExample STR NI 000LOAD T 008 100 ;A 100-second delayEQ O 000 ;from input 0 to output 0• LOAD R T/C nOperationIf the bit accumulator is 1, timer/counter n is loaded with an initial setting equal tothe contents of the register accumulator. After the instruction, the bit accumulatorcontains the status of the timer/counter. A setting made with the programmingdevice or computer has no effect when this instruction is used.BA RA WA VariableAffected Yes No No YesExample STR NI 000 ;Delay from input to output,STR R M 000 ;time set viaLOAD R T 000 ;register memoryEQ O 000<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 3229/12/2006AutoLog <strong>20AN</strong> Instruction Manual• LOAD Q n dddOperationIf the bit accumulator is 1, move the contents of the register accumulator intoelement d (0 - 255) of shift register n (0 - 3).BA RA WA VariableAffected No No No YesExample STR R C 000 ;Clear the register accumulator.STR I 000 ;At the rising edge of input 0EQ M 000STR DP 000LOAD Q 000 002 ;clear element 2 of shift register 0.• MID R C dOperationSubtracts the constant d and the bit accumulator from the register accumulator,assuming that both are two-digit BCD numbers. If the result is less than 0, the bitaccumulator is set to 1; otherwise the bit accumulator is reset to 0. If the numbersare not BCD numbers, the result is indeterminate.BA RA WA VariableAffected Yes Yes No NoExample IF DP 000STR NM 000 ;M0 = 1 - NM0 = 0STR R M 015 ; Subtract 16 = 0001 0000B =MID R C 016 ;10 BCD (=16 DES) fromEQ R M 015 ;the 16-bit number inSTR R M 014 ;register memories 14,15.MID R C 000EQ R M 014CONT• MID R M/O nOperationSubtracts the variable n and the bit accumulator from the register accumulator,assuming that they are two-digit BCD numbers. If the result is less than 0, the bitaccumulator is set to 1; otherwise the bit accumulator is reset to 0. If the numbersare not BCD numbers, the result is indeterminate.BA RA WA VariableAffected Yes Yes No NoExample IF DP 000INVSTR R M 123MID R O 001EQ R M 123CONT;Reset bit accumulator<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 3329/12/2006• MID W C dOperationConvert the constant d (0 - 9999) to BCD format and subtract it and the bit acc.from the word accumulator, assuming that the word accumulator contains a BCDnumber. If the result is less than 0, the bit accumulator is set to 1; otherwise the bitaccumulator is reset to 0. If the number in the word accumulator is not a BCDnumber, the result is indeterminate.BA RA WA VariableAffected Yes No Yes NoExample IF DP 000 ;Reset bit accumulatorINVSTR W M 030 ;W M 30 = 0000 0011 0110 0011 B (363 BCD)MID W C 00054 ;const. = 0000 0000 0011 0110 B (36 BCD)EQ W M 030 ;W M 30 = 0000 0011 0010 0111 B (327 BCD)CONT• MID W M/O nOperationSubtract the variable n and the bit accumulator from the word accumulator,assuming that they are BCD numbers. If the result is less than 0, the bit accumulatoris set to 1; otherwise the bit accumulator is reset to 0. If the numbers are not BCDnumbers, the result is indeterminate.BA RA WA VariableAffected Yes No Yes NoExample IF DP 000 ;Reset bit accumulatorINVSTR W M 030 ;Subtract contents of word memory 45MID W M 045 ;(as a BCD number) from word memory 30.EQ W M 030CONT• MIN R C dOperationSubtracts the constant d and the bit accumulator from the register accumulator. Ifthe result is less than 0, the bit accumulator is set to 1; otherwise the bit acc. is resetto 0.BA RA WA VariableAffected Yes Yes No NoExample STR C 000 ;Subtract the constant 100STR R M 101 ;from the 16-bit number inMIN R C 100 ;register memories RM 100,101EQ R M 100STR R M 100MIN R C 000 ;If underflow occursEQ R M 100 ; subtract 1 from R M 12<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 3429/12/2006AutoLog <strong>20AN</strong> Instruction Manual• MIN R M/O nOperationSubtracts the variable n and the bit accumulator from the register accumulator. Ifthe result is less than 0, the bit accumulator is set to 1; otherwise the bit accumulatoris reset to 0.BA RA WA VariableAffected Yes Yes No NoExample STR C 000 ;Reset bit accumulator.STR R M 013 ;R M 12,13 (16-bit number) =MIN R O 001 ;R M 12,13 – R O 1EQ R M 013 ;If underflow occursSTR R M 012 ; subtract 1 from R M 12MIN R C 000EQ R M 012• MIN W C dOperationSubtract the constant d and the bit accumulator from the word accumulator. If theresult is less than 0, the bit accumulator is set to 1;otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No Yes NoExample STR C 000 ;Reset bit accumulator.STR W M 60 ;Subtract the constant 3500MIN W C 03500 ;from word memory 60.• MIN W I/M/O nOperationSubtract variable n and the bit accumulator from the word accumulator. If the resultis less than 0, the bit accumulator is set to 1;otherwise the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No Yes NoExample STR C 000 ;Reset bit accumulator.STR W M 60 ;Subtract value of word memory 106MIN W M 106 ;from value of word memory 60.• MUL R C dOperationMultiply the register acc. by the constant d. The least significant byte remainsin the register acc. and the most significant byte is stored in register output R O 244.BA RA WA VariableAffected No Yes No NoExample STR R M 000MUL R C 002<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 3529/12/2006• MUL R M/O nOperationMultiply the register accumulator by the variable n. The least significant byte remainsin the register accumulator and the most significant byte is stored in register outputR O 244.BA RA WA VariableAffected No No No NoExample STR R O 001 ;R O 1 * R M 3 = R M 5,4MUL R M 003EQ R M 005STR R O 244EQ R M 004• MUL W C dOperationMultiply the word accumulator by the constant d. The least significant word ofthe product remains in the word accumulator and the MSB/LSB eight bit variablesare stored in register outputs R O 230, 231.BA RA WA VariableAffected No No Yes NoExample STR W M 030MUL W C 00010 ;Contents of word memory 30 * 10EQ W M 010 ; WM 30 * 10 = WM10,11STR R O 230EQ R M 230STR R O 231EQ R M 231STR W M 115EQ W M 011• MUL W I/M/O nOperationMultiply the word accumulator by the variable n. The least significant word ofthe product remains in the word accumulator and the MSB/LSB eight bit variablesare stored in register outputs R O 230, 231.BA RA WA VariableAffected No No Yes NoExample STR W M 001 ;WM 1 * WM 2 = WM 10,11MUL W M 002EQ W M 010STR R O 230EQ R M 230STR R O 231EQ R M 231STR W M 115EQ W M 011<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 3629/12/2006AutoLog <strong>20AN</strong> Instruction Manual• NEXT S d eOperationIf the current sequence register has been at step d for e seconds, it moves on tothe next step.BA RA WA VariableAffected No No No NoExample NEXT S 000 010 ;The sequence registerNEXT S 001 010 ;moves around steps 0, 1, 2NEXT S 002 010 ;at intervals of 10 seconds.STR S 003 ;Back to start from step 3STEP S 000• OR I/M/O/NI/NM/NO/DP/DN/BM/GM/NB/NG/P nOperationSets the bit accumulator equal to the logical sum of its old value and the variable.BA RA WA VariableAffected Yes No No NoExample STR M 000OR NM 000 ;Set bit accumulator to 1.• OR S dOperationIf the bit accumulator is 1 before the instruction or if the current sequence registeris at step d, the bit accumulator is set to 1; otherwise it is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR S 027 ;If the sequence registerOR S 028 ;is at step 27 or 28,EQ R M 005 ;reset memory 5.• OR R C dOperation Sets the register acc. equal to the logical sum of its old value and the constant d.BA RA WA VariableAffected Yes No No NoExample STR R M 001 ;R M 1 = 00100011 BOR R C 128 ; = 10000000 BEQ R M 002 ;R M 2 = 10100011 B<strong>FF</strong>-<strong>Automation</strong> Oy


• OR R M/O/NM/NO nAutoLog <strong>20AN</strong> Instruction Manual Page 12 - 3729/12/2006OperationSets the register acc. equal to the logical sum of its old value and the variable.BA RA WA VariableAffected No Yes No NoExample STR R M 001 ;R M 1 = 00001111 BOR R M 002 ;R M 2 = 11110110 BEQ R M 003 ;R M 3 = 11111111 B• OR W C dOperation Set the word acc. equal to the logical sum of its old value and the constant d.BA RA WA VariableAffected No No Yes NoExample STR W M 045 ;W M 45 = 0001 1101 1111 0000 BOR W C 09006 ; = 0010 0011 0010 1110 BEQ W M 021 ;W M 21 = 0011 1111 1111 1110 B• OR W I/M/O nOperation Set the word accumulator equal to the logical sum of its old value and variable n.BA RA WA VariableAffected No No Yes NoExample STR W M 033 ;W M 33 = 1011 0110 0110 1100 BOR W M 024 ;W M 24 = 0000 0010 1111 0100 BEQ W M 012 ;W M 12 = 1011 0110 1111 1100 B• PLD R C dOperationAdds the constant d and the bit accumulator to the register accumulator, assumingthat both are BCD numbers. If the result is greater than 99, the bit accumulator isset to 1; otherwise the bit accumulator is reset to 0. If the numbers are not BCDnumbers, the result is indeterminate. NOTE The constant d which is a BCD numberis written in the program as a decimal number.Example: constant 16 = 0001 0000 (bit format)1 0 (BCD format)BA RA WA VariableAffected Yes Yes No NoExample STR R C 017 ; = 0001 0001B = 11 BCDPLD R C 025 ; = 0001 1001B = 19 BCD;Acc. = 0011 0000B = 30 BCD<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 3829/12/2006AutoLog <strong>20AN</strong> Instruction Manual• PLD R M/O nOperationAdds the variable n and the bit accumulator to the register accumulator, assumingthat each contains a BCD number. If the result is greater than 99, the bitaccumulator is set to 1; otherwise the bit accumulator is reset to 0. If the addend andaugend are not BCD numbers, the result is indeterminate.BA RA WA VariableAffected Yes Yes No NoExample STR I 000 ;Register memory 1 = 9,OR NI 000 ;bit accumulator = 1STR R C 016 ;acc. = 0001 0000B (10 BCD)PLD R M 001 ;+ 0000 1001B (9 BCD);+ 1B (bit acc.);acc. = 0010 0000B (20 BCD)• PLD W C dOperationConvert the constant d (0 - 9999) to BCD format and add it and the bit accumulatorto the word accumulator, assuming that both are BCD numbers. If the result isgreater than 9999, the bit accumulator is set to 1; otherwise the bit accumulator isreset to 0. If the numbers are not BCD numbers, the result is indeterminate.BA RA WA VariableAffected Yes No Yes NoExample STR W C 00313 ;W A = 0000 0001 0011 1001 B (139 BCD)PLD W C 00400 ;W const.= 0000 0001 1001 0000 B (190 BCD);W A = 0000 0011 0010 1001 B (329 BCD)• PLD W M/O nOperationAdd variable n and the bit accumulator to the word accumulator, assuming that eachcontains a BCD number. If the result is greater than 9999, the bit accumulator is setto 1; otherwise the bit accumulator is reset to 0. If the addend and augend are notBCD numbers, the result is indeterminate.BA RA WA VariableAffected Yes No Yes NoExample STR I 0 ;Word memory 003 = 4900 at the beginning,OR NI 0 ;set bit accumulator to 1STR W C 02450 ;W A =0000 1001 1001 0010 B (992 BCD)PLD W M 003 ;+ WM 3 =0001 0011 0010 0100 B (1324 BCD);+ BA =0000 0000 0000 0001 B (1 BCD);W A =0010 0011 0001 0111 B (2317 BCD)<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 3929/12/2006• PLU R C dOperationAdds the constant d and the bit accumulator to the register accumulator. If theresult is greater than 255, the bit accumulator is set to 1; otherwise the bitaccumulator is reset to 0.BA RA WA VariableAffected Yes Yes No NoExample STR P 001 ;Add 1 to register memory 123STR R M 123 ;once per second.PLU R C 000EQ R M 123• PLU R M/O nOperationAdds the variable n and the bit accumulator to the register accumulator. If the resultis greater than 255, the bit accumulator is set to 1; otherwise the bit accumulator isreset to 0. Using the bit accumulator in this way as a carry bit allows calculation withnumbers greater than 255.BA RA WA VariableAffected Yes Yes No NoExample STR C 000 ;Reset bit accumulator.STR R M 002 ;RM 22 = RM 12 + RM 2PLU R M 012EQ R M 022• PLU W C dOperationAdd the word constant d and the bit accumulator to the word accumulator. If theresult is greater than 65535, the bit accumulator is set to 1; otherwise it is reset to 0.BA RA WA VariableAffected Yes No Yes NoExample STR P 002 ;Add 1 to word memory 50STR W M 050 ;once per minute.PLU W C 00000EQ W M 050• PLU W I/M/O nOperationAdd variable n and the bit accumulator to the word accumulator. If the result isgreater than 65535, the bit accumulator is set to 1; otherwise the bit accumulator isreset to 0.BA RA WA VariableAffected Yes No Yes NoExample STR I 000 ;When I000 = 1,STR W M 034 ;WM 003 = WM 34 + WM 25 + 1PLU W M 025EQ W M 003<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 4029/12/2006AutoLog <strong>20AN</strong> Instruction Manual• PRI TXOperationIf the bit accumulator is 1 the text string, whos number is given in the registeraccumulator, is printed to the active output port. The bit accumulator is 1 after theinstruction if the characters were output (there was room in the output buffer).BA RA WA VariableAffected Yes No No NoExample STR P 001 ; Set bit accumulator to 1:STR R C 022 ; Set 22 to register accumulatorPRI TX ; Print with indirectly addressing; the text string number 22.• PRT C dOperationThe number of vacant character positions in the print buffer is returned inthe register accumulator, and selects the output port for printing(0=I 2 C, 1= Ser1, 2= Ser2, 3=Ser3).If there is room for more than 80 characters, the bit accumulator is set to 1;if not, the bit accumulator is reset to 0.BA RA WA VariableAffected Yes Yes No NoExample PRT C 002 ;Repeatedly prints the text:PRT T Still ;Still herePRT T here@In WinAlpro yu can write this:PRT C 000PRT (“Still here”) ;• PRT T cccccOperationIf the bit accumulator is 1, the five characters given in the instruction are output.If it is not desired to output as many as five characters, the output can be terminatedwith the @ character, in which case a carrier return and line feed will not be added atthe end, or with the # character, in which case a carrier return and line feed will beadded. Any characters that can be produced with the keyboard are valid as parametersexcept that CTRL-B (12 hex) is not acceptable as the second character. The bitaccumulator is 1 after the instruction if the characters were output (there was roomin the output buffer).BA RA WA VariableAffected Yes No No NoExample STR I 0.00EQ M 000STR DP 000PRT T inputPRT T 0 isPRT T on#or STR DP 000PRT (“Input 0 is on”)<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 4129/12/2006• PRT TX n/nameOperationIf the bit accumulator is 1 the text string number n or name is printed to the activeoutput port. The text strings can be edited with <strong>AL</strong>Pro / Symbol/Edit Text selectionThe bit accumulator is 1 after the instruction if the characters were output(there was room in the output buffer).BA RA WA VariableAffected Yes No No NoExample STR P 001 ; Set bit accumulator to 1:PRT TX STR003 ; Print the text string name STR003 .; to active output port• PRT R C dOperationIf the bit accumulator is 1, the constant d given as the instruction parameter is outputwith two digits. The constant d is assumed to be between 00 and 99. If the constantd is greater than 99, indeterminate characters will be output. If there was room forthe characters in the print buffer, the bit accumulator is 1 after the instruction.The number (0 - 99) must be coverted to BCD format before printing.BA RA WA VariableAffected Yes No No NoExample STR R C 020 ; century ( R C d)BCD R T ; convert to BCD formatEQ R M 000 ; save to auxuliary memorySTR R M 255 ; yearBCD R T ; convert to BCD formatEQ R M 001 ; save to auxuliary memoryPRT C 000 ; Put output to display unitSTR DP 001 ; Print once per secondPRT (,”Y”,,) ; place the cursor up leftPRT R M 000 ; century: 20PRT R M 001 ; & tens & ones• PRT R TOperationIf the bit accumulator is 1, the character in the register accumulator is output. If therewas room for the character in the output buffer, the bit accumulator is 1 afterthe instruction.BA RA WA VariableAffected Yes No No NoExample PRT C 000 ; Put output to display unitSTR R M 232 ;If a character has beenLES R C 000 ;received from the serial line,PRT R T ;echo it andEQ R RM 232 ;clear the character buffer.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 4229/12/2006AutoLog <strong>20AN</strong> Instruction Manual• PRT R M/O nOperationIf the bit accumulator is 1, the value of the variable n is output with two digits,assuming it to be a BCD number. If the bit accumulator is 0, it will be 0 after theinstruction. If the variable is not a BCD number, indeterminate characters willbe output.BA RA WA VariableAffected Yes No No NoExample STR P 001 ;Outputs the content of registerPRT R M 001 ;memory 1 once per second.• READ F nOperationRead the current number of elements in FIFO store n (0-7) into the register accumulator.If there are elements in the FIFO, set the bit accumulator to 1, if not, clearthe bit accumulator to 0.BA RA WA VariableAffected Yes Yes No NoExample STR I 000 ;At the rising edge of input 0EQ M 000STR DP 000STR R C 012 ;enter the number 12FIN F 000 ;into FIFO 0,STR R C 004 ;the number 4FIN F 000 ;into FIFO 0,STR R C 024 ;the number 24FIN F 000 ;into FIFO 0,READ F 000 ;number 3 into register acc.• READ R T/C nOperation The register accumulator is loaded with the remaining count in timer/counter n.If the timer/counter has counted out, the register accumulator will be 0.BA RA WA VariableAffected No Yes No NoExample STR NI 000LOAD T 020 100EQ O 000 ;Register output 0READ R T 020 ;will show theEQ R O 000 ;remaining time• READ S nOperation Selects sequence register n as the current sequence register.BA RA WA VariableAffected No No No NoExample READ S 002 ;Subsequent sequence register;instructions apply to sequence register 2.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 4329/12/2006• READ T/C nOperationThe status of the timer/counter (1=counted out, 0=running) is loaded into the bitaccumulator.BA RA WA VariableAffected Yes No No NoExample READ T 010 ;Output 0 changes stateEQ M 000 ;for a momentLOAD T 010 005 ;at intervals ofSTR DP 000 ;5 seconds.EQ O 000• RES F nFifo operates in data areas F0 WM1024-1151, F1 WM1152-1279,...,F7 WM1920-2047.OperationIf the bit accumulator is 1, clear FIFO store n (0 - 7) (delete contents).BA RA WA VariableAffected No No No YesExample STR I 000 ;At the rising edge of input 0EQ M 000STR DP 000RES F 000 ;clear FIFO 0.• RES Q nOperationIf the bit accumulator is 1, reset all elements of shift register n (0 - 3) to zero.BA RA WA VariableAffected Yes No No NoExample STR I 000 ;When input 0 is 1, reset allRES Q 002 ;elements of shift register 2.• RETOperationThe subroutine ends here, execution is then returned to main program.BA RA WA VariableAffected Yes Yes Yes YesThe states of the accumulators remain unchanged, so main program can use theaccumulator states after executing the subroutine.• SBR nOperation This is the starting instrucion of a subroutine. See page 12-44.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 4429/12/2006AutoLog <strong>20AN</strong> Instruction Manual• SHL Q n dddOperationIf the bit accumulator is 1, shift the elements of shift register n (0 - 3) one step tothe left. The number in the register accumulator is shifted into the vacated position(right end) of the shift register. The element shifted out of the shift register goes intothe register accumulator. d (0 - 255) is the length of the shift register - 1.BA RA WA VariableAffected No Yes No YesExample STR NI 000 ;The falling edge of input 0EQ M 000STR DP 000READ R C 003SHL Q 000 250 ;moves a 560-step conveyorSHL Q 001 250 ;one step to the left.SHL Q 002 060• SHR Q n dddSHR instruction uses word outputs (Q0 uses WO 512- 639, Q1 uses WO 640- 767 etc.) and theseword outputs can be used for other purposes only if SHR instruction is not used.OperationIf the bit accumulator is 1, shift the byte-sized elements of shift register n (0 - 3) onestep to the right. The number in the register accumulator is shifted into the vacatedposition (left end) of the shift register. The element shifted out of the shift registergoes into the register accumulator. d (0 - 255) is the length of the shift register - 1.BA RA WA VariableAffected No Yes No YesExample STR I 000 ;The rising edge of input 0EQ M 000STR DP 000STR R M 030SHR Q 000 200 ;moves a 300-step conveyorSHR Q 001 100 ;one step to the right.• STEP R TOperationIf the bit accumulator is 1, move the current sequence register to the step indicatedby the contents of the register accumulator. If the bit accumulator is 0, do nothing.BA RA WA VariableAffected No No No NoExample STR C 001 ;The sequence registerSTR R M 003 ;moves to the step indicatedSTEP R T ;by register memory 3.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 4529/12/2006• STEP S dOperationIf the bit accumulator is 1, the current sequence register moves to step d. If the bitaccumulator is 0, do nothing.BA RA WA VariableAffected No No No NoExample STR S 139 ;If at step 139,STEP S 000 ;move to step 0• STEP TOperationIf the bit accumulator is 1, the current sequence register moves on to the next step.If the previous step is 255, the new step is 0.BA RA WA VariableAffected No No No NoExample STR R S 000 ;Select sequence register 0STR P 000 ;(valid until the next selection).STEP T ;Sequence register moves to;next step 10 times per second.• STI I/M/O/BM/GM nOperationReads the state of binary input/output/memory to bit accumulator.Register accumulator is pointing to the bit variable to be read.BA RA WA VariableAffected Yes No No NoExample STR R C 012 ;The state of input I 12 is the bit accumulatorsSTI I ;state (read address is 12 decimal).• STI R M/O nOperationLoads the register accumulator with the variable whose address is the value ofthe variable given as the instruction parameter.BA RA WA VariableAffected No Yes No NoExample STR R C 010 ;= 00 001 010B = 10 decEQ R M 020 ;Read contents of RM 10STI R M 020 ;into the register accumulator.• STI W M/O/I nOperationLoad the word accumulator with the variable whose address is the value ofthe variable given as the instruction parameter. For accessible addresses seethe tables of the variables.BA RA WA VariableAffected No No Yes NoExample STR W C 010 ;= 0 000 000 000 001 010 B = 10EQ W M 020 ;Read contents of WM 10STI W M 020 ;into the word accumulator.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 4629/12/2006AutoLog <strong>20AN</strong> Instruction Manual• STOPOperationLast instruction of the program; the first program line will be executed next.Terminates the range of the IF instruction.BA RA WA VariableAffected No No No No• STPOperationThe PLC's main program ends with this command and all subroutine programsmust be written after the STP command.• STR I/M/O/NI/NM/NO/BM/GM/NB/NG/P nOperationReads the state of variable n into the bit accumulator. The variable is not affected.BA RA WA VariableAffected Yes No No NoExample STR I 000 ;Read state of input 0 into acc.• STR DP nOperationIf auxiliary memory n is 1 and was 0 at the start of the program cycle,the bit accumulator is set to 1. If the auxiliary memory is 0, or was already 1 atthe start of the program cycle, the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR I 000 ;Read state of input 0 into memoryEQ M 010STR DP 010 ;Rising edgeXOR O 005 ;inverts output 5.EQ O 005• STR DN nOperationIf auxiliary memory n is 0 and was 1 at the start of the program cycle, the bitaccumulator is set to 1. If the auxiliary memory is 1, or was already 0 at the start ofthe program cycle, the bit accumulator is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR I 001 ;At falling edge of input 1EQ M 001 ;decrement counter 3 by 1.STR DN 001DCR C 003<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction Manual Page 12 - 4729/12/2006• STR S/(NS) dOperation If the current sequence register is/(not) at step d, the bit accumulator is set to 1;otherwise it is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR S 024 ;When sequence register is atEQ O 125 ;step 24, O 125 is on.• STR R M/O/NM/NO/GM nOperationReads the value of a register variable into the register accumulator.BA RA WA VariableAffected No Yes No NoExample STR R M 210 ;Read contents of register memory 210 intoregister accumulator.• STR R C dOperationReads the constant d (0 - 255) into the register accumulator.BA RA WA VariableAffected No Yes No NoExample STR R C 019 ;Store 19 (decimal) in register accumulator.• STR R S nOperationReads the number of the current step of sequence register n (0 - 31) into the registeraccumulator. Register n is made the current sequence register, i.e. subsequentsequence register instructions will affect it.BA RA WA VariableAffected No Yes No NoExample STR R S 002 ;When sequence register 2 is atSTR S 029 ;step 29, output 5 is on.EQ O 005• STR C dOperation Reads the state of variable n into the bit accumulator. The accumulator is reset to 0,if d = 0; for other values of d, it is set to 1.BA RA WA VariableAffected Yes No No NoExample STR C 000 ;Initialize bit accumulator.STR R M 010PLU R M 011EQ R M 020<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 4829/12/2006AutoLog <strong>20AN</strong> Instruction Manual• STR Q nOperationRead the element whose position is given by the register accumulator, ofshift register n (0 - 3), into the register accumulator.BA RA WA VariableAffected No Yes No NoExample STR R C 005 ;Move the value of element 5STR Q 000 ;of shift register 0 into the register accumulator.• STR W I/M/O/GM nOperationRead the value of variable n into the word accumulator.BA RA WA VariableAffected No No Yes NoExample STR W I 001 ;Read value of input 1 (0 - 4095)into word acc.• STR W C dOperationRead the constant d (0 - 65535) into the word accumulator.BA RA WA VariableAffected No No Yes NoExample STR W C 00455 ;Initialize word accumulator to 455.• XOR I/M/O/NI/NM/NO/DP/DN/BM/GM/NB/NG/P nOperationSets the bit accumulator equal to the exclusive-or function of its old value andthe variable.BA RA WA VariableAffected Yes No No NoExample STR P 001XOR O 000 ;Output 0 is invertedEQ O 000 ;once per second.• XOR S dOperationIf the current sequence register is at step d and the bit accumulator is 0, or ifthe sequence register is not at step d and the bit accumulator is 1,the bit accumulator is set to 1; otherwise it is reset to 0.BA RA WA VariableAffected Yes No No NoExample STR R S 000 ;If only one of sequence registersSTR S 010 ;0 and 1 is at step 10,STR R S 001 ;memory 10 is set to 10.XOR S 010EQ M 010<strong>FF</strong>-<strong>Automation</strong> Oy


• XOR R M/O/NM/NO nAutoLog <strong>20AN</strong> Instruction Manual Page 12 - 4929/12/2006OperationSets the register accumulator equal to the exclusive-or function of its old valueand the variable.BA RA WA VariableAffected No Yes No NoExample STR R M 000 ;R M 0 = 01111011 BXOR R M 001 ;R M 1 = 10000011 BEQ R M 002 ;R M 2 = 11111000 B• XOR R C dOperationSets the register accumulator equal to the exclusive-or function of its old value andthe constant d.BA RA WA VariableAffected No Yes No NoExample STR R M 000 ;R M 0 = 01010101 BXOR R C 255 ; = 11111111 BEQ R M 001 ;R M 1 = 10101010 B• XOR W I/M/O nOperationSet the word accumulator equal to the exclusive-or function of its old valueand variable n.BA RA WA VariableAffected No No Yes NoExample STR W M 033 ;W M 33 = 1011 0110 0110 1100 BXOR W M 024 ;W M 24 = 0000 0010 1111 0100 BEQ W M 012 ;W M 12 = 1011 0100 1001 1000 B• XOR W C dOperationSet the word accumulator equal to the exclusive-or function of its old valueand the constant d.BA RA WA VariableAffected No No Yes NoExample STR W M 045 ;W M 45 = 0001 1101 1111 0000 BXOR W C 09006 ; = 0010 0011 0010 1110 BEQ W M 021 ;W M 21 = 0011 1110 1101 1110 B<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 5029/12/2006AutoLog <strong>20AN</strong> Instruction ManualSubroutinesThe PLC's main program ends with an STP instruction. It is possible to write subroutine programswhich start with the SBR n command (n is subroutine number), and ends with the RET command.The maximum number of subroutines is 32 (numbers 0 - 31). The STOP command must be appearafter the subroutines, this ends the PLC program. The PLC system program ignores all SBR and RETinstructions which appear before STP instruction. If the RET instruction is missing from a subroutinethe PLC executes the next subroutine(s) until the a RET command is found. If no RET command isfound, program executes until the STOP command is reached, and the PLC system program doesnot return to main program. The PLC now performs I/O updates and the main program starts againfrom line 1. Therefore the main program is executed only up to the first CSR instruction, the rest ofthe main program is not executed at all. If there is a CSR call for a subroutine that does not exist, thePLC interpretes the CSR instruction as a NOP instructionand continues normally.• STPOperationThe PLC's main program ends with this command and all subroutine programsmust be written after the STP command• CSR nOperationAffectedThe PLC executes the subprogram n if the bit accumulator is trueBit accumulator Register accumulator Word accumulator VariableThe states of the accumulators remain unchanged, so subroutine can use theaccumulator states.• SBR nOperationThis is the starting instruction of a subroutine• RETOperationAffectedExampleThe subroutine ends here, execution is then returned to main program.Bit accumulator Register accumulator Word accumulator VariableThe states of the accumulators remain unchanged, so main program can use theaccumulator states after executing the subroutine.Scaling subroutine for analogue variables. The scaling parameters are transferredin main program with the EQI instruction. The result after the subroutine callis retrieved with the STI instruction from word accumulator or from WM 101.STR C 001 ; set bit accumulator to 1CSR 001 ; call subroutine 1STP; main program end...SBR 01 ; start of subroutine 1EQ W M 102STR R M 100 ; scaling parameters start addressSTR C 001 ; set bit accumulator to 1STR W M 100 ; variable to be scaledFCN 010 ; call scaling functionEQ W M 101 ; save the result to WM 101RET...STOP<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 12-5129/12/200612.5 Terminal programming commandsADDRWRITEINSREADNEXTCLRDELPREVSTARTSTOPHINHOUTLISTFINDDISPInitiates input of a program address (= number of a program line). The address isentered as five octal digits. When the address is complete, the <strong>AL</strong><strong>20AN</strong> outputsthe instruction at the address given, or gives the 'ERROR 010' message to indicatethat there is no <strong>AL</strong> instruction on the program line specified.Writes the instruction prepared on the screen into the RAM program memory at theaddress shown at the beginning of the line, overwriting any previously existing instructionat the same address. If the new and the old instruction differ in length (for example, if oneof them is a timer setting instruction), the programming software shifts the remainder ofthe program accordingly.Writes the instruction prepared on the screen into the RAM program memory at theaddress shown at the beginning of the line, shifting any existing instruction at the sameaddress and the remainder of the program onwards to make room for the new instruction.Displays the instruction at the program address displayed. Used as a preparation todeleting an instruction.Displays the next program address and the instruction on it.Cancels the effect of the preceding commands and outputs the program addressand instruction currently being processed. Can be used at any time.Deletes the instruction at the RAM program address displayed at the beginning ofthe line. Does not work unless immediately preceded by a READ command.Displays the preceding program address and the instruction therein. If there are programlines in memory with no AutoLog instructions, the programming software skips overthem and outputs the first true AutoLog instruction encountered.Stores the logic program in RAM into EEPROM memory. This may take a while.Execution of the program then starts.Halts execution of the program. However, transfer of inputs and outputs continues;the status display of variables is thus operative even while the program is halted.Reads a logic program in the Intel hexadecimal format from the programming deviceinto RAM; the programming program then stores the program into EEPROM memory.Stores the logic program in RAM into EEPROM and sends it to the programmingdevice in the Intel hexadecimal format.Outputs the logic program starting at the program line displayed, until the STOPinstruction. Output can be stopped by hitting the space bar.Searches the program for the instruction entered into the display, starting at theprogram line displayed. If the instruction is found, the program line and the instructionare displayed. If the instruction is not found, an 'ERROR 040' message is given.Displays the state of a variable<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12-5229/12/2006AutoLog AN Instruction ManualThe programming software reacts to an incorrect key operation with a tone signal(for example, WRITE before the instruction is complete). Keying mistakes can becorrected with the CLR (N) key.Normally the PLC’s application program runs all the time. If changes are to be made tothe program, it is advisable to halt it with the STOP key while making the changes. Theprogram is started with the START key. The STOP and HIN commands halt execution ofthe program. The WRITE, INS, DEL, LIST, FIND, and HOUT commands halts executionuntil the function has been carried out.Program changes made with the programming device (WRITE, INS, READ/DEL) arequick, because they only affect the RAM memory. The logic program in RAM is storedinto EEPROM memory when the START (!) key is pressed.The fast program loop must be changed only when execution of PLC program isstopped.12.6 Programming pointerThe programming software keeps track of the address of the program memory locationcurrently affected by programming operations (the programming pointer). Theprogramming pointer can be located by pressing the CLR key (the program address, i.e.the program line number, and the instruction will be displayed). If there is no AutoLoginstruction at this address, the 'ERROR 010' message is given.The address can be changed by typing a new address or by stepping forwards orbackwards in the program. The address is also automatically updated when aninstruction is written into memory or deleted.The ADDR key moves the cursor to the start of the desired program line. The programline number is entered as five octal digits (0 - 7), whereupon the programming softwaredisplays the instruction at the address given, or gives an error message to indicate thatthere is no instruction on the program line specified.The NEXT key and the PREV (Previous) key move the programming pointer in eitherdirection, one program line at a time. However, when stepping backwards, the pointer ismoved back far enough so that a real instruction is found. If the pointer is at a two-byteinstruction, the correct pointer movement takes place automatically.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 12-5329/12/200612.7 Entering an instruction in memory by terminal programmingTo enter a new instruction in the program at the location indicated by the programmingpointer, first key in the instruction and then press either WRITE or INS. Example:Text displayedCommentsPress CLR (N).0002 EQ O 000 A new instruction is to be entered here.0002 EQ O 000 STR First key STR (A).0002 EQ O 000 STR I Then the variable name I (Q).0002 EQ O 000 STR I 000 Then the variable number, first 0.0002 EQ O 000 STR I 000 The second and third 0. The instruction is now completeand is entered in program memory with the WRITE key (X).0003 STR M 000 The instruction on the next program line is displayed.If the INS key had been used in the above example instead of the WRITE key, thedisplay would have been as follows:0002 EQ O 000 STR I 000 Now press the INS key (C).0003 EQ O 000 The instruction that was previously on program line 2, hasbeen pushed onwards to line 3, and the new instruction hasbeen written on line 2.If an attempt was made to enter a non-existent variable number into an instruction, theprogramming program of the PLC immediately issues an 'ERROR 030' message anddisplays the program line.If the new and the old instruction differ in length in the case of the WRITE command, andalways when the INS command is used, the programming software moves theinstructions on subsequent lines of the program forwards or backwards as required. TheSTOP instruction is always the last instruction to be shifted.If an attempt was made to enter an instruction when the programming space is alreadyfull, an 'ERROR 050' message is issued. The error is cancelled as soon as a sufficientnumber of instructions are deleted from the program.12.8 Deleting an instruction from memoryTo delete instructions from the program, use the DEL command (M). First place theprogramming pointer at the instruction to be deleted and then press the READ key (V).The DEL command will now delete the instruction in question and move back allsubsequent instructions as far as the STOP instruction, to fill the gap left by the deletedinstruction.Example:ext displayed Comments0010 AND I 000 Keys pressed: ADDR (Z),0,0,1,0.0010 AND I 000AND I 000READ key (V) pressed.0010 EQ O 000 DEL key (M) pressed. The instruction AND I 000 was deleted fromprogram memory and the remaining instructions were moved back one position.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12-5429/12/2006AutoLog AN Instruction Manual12.9 Locating an instruction in a program by terminal programmingFIND command [ ( ] searches for a given instruction, starting at the programming pointer.If the instruction is not found before the STOP instruction is encountered, an 'ERROR040' message is issued. Place the programming pointer at the desired point, enter thedesired instruction in its entirety (in the case of timer and counter setting instructions, thesetting value must also be given, although the FIND command does not make use of it).When the instruction is complete, press the FIND key; the programming software willdisplay the next point of occurrence of the instruction and the instruction itself. If the FINDkey is pressed before the instruction is complete, the PLC does not accept the command,and issues a short tone signal to indicate the error.12.10 Listing the program by terminal programmingIf a program listing is desired, either on the display or on paper, move the programmingpointer to the desired starting point and press the LIST key [&]. The programmingprogram will output the program in mnemonic format up to the STOP instruction. Outputcan be stopped by hitting the space bar [ ]. (The programming pointer will not be movedaway from the starting point by the LIST operation.)12.11 Storing the program by terminal programmingA program written into the program memory of the AutoLog <strong>20AN</strong> can be stored onto anexternal device for later requirements. The HOUT command [%] causes the program tobe stored from the RAM program memory to EEPROM memory, whereupon it is sent tothe serial line in Intel hexadecimal format.The HIN command [^] causes a logic program in Intel hexadecimal format to be read intothe PLC, where it is first stored in RAM; when the entire program has been received, theprogramming program stores the program into EEPROM memory. This may take a littlewhile.12.12 If there is no AutoLog program in memoryIf there is no logic program, the programming program reports this by issuing an 'ERROR010' message, and the indicator light on the CPU board flashes at a fast rate (5 Hz). Thefast flash means that there is no STOP instruction in the program, or that there is anunidentifiable instruction ahead of the STOP instruction. Rectify the program and start itwith the START command [!]. If the program is formally correct, it will start, and theindicator light changes to the normal flashing rate (0.5 Hz).If the STOP instruction in a program is overwritten while the program is running, the PLCno longer operates properly (unless there happened to be two successive STOPinstructions in program memory). This condition can be remedied by switching the PLCoff and back on again. Since no STOP instruction can be found in memory, theprogramming pointer will now stop at the first program line where no <strong>AL</strong><strong>20AN</strong> instructionis found. Enter a STOP instruction on this line.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 12-5529/12/2006To clear the entire program space, write a STOP instruction on program line 0000. ThisSTOP instruction will overwrite the first instruction of the old program (the remainingprogram lines are still intact), and the new program can now be written over the old one.12.13 Monitoring the operation of a program by terminal programmingWhen the DISP key [ ) ] is pressed, the cursor moves to the beginning of the next lineand awaits entry of a variable name and number. As soon as these are given, the state ofthe variable is displayed, as well as a dash [-] if it is possible to alter the variable. TheDISP operation is provided to allow variables to be monitored and changed.The variablecan be redisplayed with the RETURN key. To alter the variable, key in the new value (0or 1 for binary variables, a three-digit decimal number 000 - 255 for register variables).12.13.1 Monitoring register and word variablesTo select a register variable, press TAB (CONTROL-I) followed by the variable name andits number with three digits. To select a word variable, press TAB (CONTROL-I) twice,followed by the variable name and its number with three digits.R -> W -> R = 12.13.2 Monitoring timers and countersIn the case of timers and counters, two numbers are displayed after the variable number:the current content of the timer/counter (first), and its setting. If the value of a timer/counter is changed, the change affects the setting, not the current value. If the setting iszero, the logic program, when executing a Load instruction LOAD T or LOAD C, entersthe value in the program as the current value. If the setting is non-zero, the setting isentered as the current value of the timer/counter. Switch SW1 selects whether settingvalues are retained during a power failure. Example:Key pressed Command Display) DISP Cursor to start of new line.TAB R R Select a register variable.I T R T Select a timer.0 R T 0 Enter number0 R T 00 of timer.0 R T 000 = 100 225- Remaining time 100 * 10 ms.RETURN = 085 225- Now remaining 85 * 10 ms.1 = 085 225-1 Enter 150 as5 = 085 225-15 new0 = 085 225-150 setting.To check a sequence register, press the DISP key [ ) ] followed by R (TAB) and S [?] tosee the step at which the sequence register in question is and how long it has been atthat step. If a new step number (000 - 255) is now entered, the sequence register inquestion will move to that step and the time will be reset.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12-5629/12/2006AutoLog AN Instruction ManualExample:Key pressed Command Display) DISP Cursor to start of new line.TAB R R Select register variable.? S R S Select sequence register.0 R S 0 Enter number0 R S 00 of sequence register.0 R S 000 = 013 002- 13 seconds have been spent at step 2.RETURN = 025 002- Now 25 seconds.0 = 025 002-0 Move to2 = 025 002-02 step0 = 025 002-020 20.) DISP Cursor to start of new line.TAB R R Select register variable.? S R S Select sequence register.0 R S 0 Enter number0 R S 00 of sequence register.0 R S 000 = 008 020- 8 seconds have been spent at step 20.The running program is free to change the variables, and the latest change is alwaysvalid.12.14 Fast program loopA fast program loop can be written into the <strong>Programmable</strong> <strong>Logic</strong> <strong>Controller</strong> for executionat timer interrupts, at intervals of 5 ms. The executable program of the loop starts asprogram line 0000 and ends at an END instruction.When the fast program loop is in use, the PLC reads inputs 0 - 7 and writes to outputs 0 -7 every time before executing the fast loop.The differentiation of auxiliary memories 0 - 7 is timed by the fast loop.The maximum permissible length of the fast loop is 62 instructions, but it is advisable tokeep it as short as possible in order to avoid slowing down the main program more thannecessary.No PRT instructions are allowed in the fast loop.CAUTION! The END instruction must not be written while program execution is inprogress. The program must always be halted when instructions preceding the ENDinstruction are deleted, added, or changed.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog <strong>20AN</strong> Instruction ManualPage 12-5729/12/200612.15 Special keys and corresponding ASCII charactersKäsky Instr. ASCII HexSTR STR A 41JA AND S 53TAI OR D 44ETAI XOR F 46ON EQ G 47STOP STOP H 48AS LOAD J 4<strong>AL</strong>UE READ K 4BVH DCR L 4CJOS IF , 2CJTK CONT . 2EINV INV / 2FPRT PRT \(ö) 5CNOP NOP [ (Ä) 5BSTEP STEP ; 3BSEUR NEXT : 3AMuuttuja Varíable ASCII HexT I Q 51ET NI W 57L O U 55EL NO * 2AM M E 45EM NM R 52SL SO > 3ERL RO < 3CSM SM T 54RM RM Y 59BM BM h 68EB NB i 69SB SB g 67RB RB e 65GM GM + 2BEG NG n 6ESG SG l 6CRG RG r 72DP DP - 2DDN DN = 3DTX TX t 74P P ] (Å) 5DA T I 49N C O 4FS S ? 3FJ Q j 6AF F f 66Komento Command ASCII HexOSOITEKIRJKIRVLUKUSEURCLRPOISTOEDELSTARTSEISHOUTHINLISTAHAKUDISPADDRWRITEINSREADNEXTCLRDELPREVSTARTSTOPHOUTHINLISTFINDDISPZXCVBNMP!$%^&()5A5B4356424E4D502124255E262829Additio- ASCII Hexnal keysR TAB 09 selectregister variableW TAB TAB 09 09 selectword variablespace SPACE 20 enter instructionin text form<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12-5829/12/2006AutoLog AN Instruction ManualTAB/RTAB TAB/W!/START1Q/I W/NI E/Me/RB4$/STOPR/NMr/RG%/HOUT5T/SMt/TX&/LIST6/ /INV7( /FIND8[ /NOPY/RM U/O I/Ti/NB)/DISP9] /PO/C=/DN0P/PREV?/S+/GM\ /PRT^/HINA/STR S/AND D/ORF/XORJ/LOADf /F G/EQ H/STOPK/READ L/DCRj /Qg/SB h/BMl/SG*/NO>/SO


<strong>AL</strong> 14 Brick Instruction Manual<strong>FF</strong>-<strong>Automation</strong> OyPage 13-130/04/98Page 13-129/12/2006<strong>AL</strong><strong>20AN</strong> Instruction Manual13. TABLES13.1 ASCII-codescharacter Hex decimal character Hex decimal character Hex decimalNULSOHSTXETXEOTENQACKBELBSHTLFVT<strong>FF</strong>CRSOSIDLEDC1DC2DC3DC4NAKSYNETBCANEMRSUBESCFSGSRSUSSP!"#$%&‘()000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F20212223242526272829000102030405060708091011121314151617181920212223242526272829303132333435363738394041+,-./0123456789:;?@ABCDEFGHIJKLMNOPQRST2B2C2D2E2F303132333435363738393A3B3C3D3E3F404142434445464748494A4B4C4D4E4F5051525354434445464748495051525354555657585960616263646566676869707172737475767778798081828384VWXYZ[ (Ä)\ (Ö)](Å)^_`abcdefghijklmnopqrstuvwxyz{ (ä)| (ö)} (å)~DEL565758595A5B5C5D5E5F606162636465666768696A6B6C6D6E6F707172737475767778797A7B7C7D7E7F8687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127


<strong>FF</strong>-<strong>Automation</strong> OyPage 13-230/04/98Page 13-229/12/2006<strong>AL</strong> 14 Brick Instruction Manual<strong>AL</strong><strong>20AN</strong> Instruction Manual13.2 Decimal/Octal conversionsdec.codeoctalcodedec.codeoctalcodedec.codeoctalcodedec.codeoctalcodedec.codeoctalcodedec.codeoctalcode0001020304050607080910111213141516171819202122232425262728293031323334353637383940414243444500010203040506071011121314151617202122232425262730313233343536374041424344454647505152535455464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990915657606162636465666770717273747576771001011021031041051061071101111121131141151161171201211221231241251261271301311321339293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137134135136137140141142143144145146147150151152153154155156157160161162163164165166167170171172173174175176177200201202203204205206207210211138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183212213214215216217220221222223224225226227230231232233234235236237240241242243244245246247250251252253254255256257260261262263264265266267184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229270271272273274275276277300301302303304305306307310311312313314315316317320321322323324325326327330331332333334335336337340341342343344345230231232233234235236237238239240241242243244245246247248249250251252253254255346347350351352353354355356357360361362363364365366367370371372373374375376377


<strong>AL</strong> <strong>AL</strong><strong>20AN</strong> AutoLog 14 Brick Instruction <strong>20AN</strong> Käsikirja ManualPage Page Sivu 13-1 14-130/04/98 29/12/2006 04/01/9914. LIST OF <strong>AL</strong><strong>20AN</strong> PRODUCTS14.1 Basic boardCode Designation DescriptionDI - DO - AI - AO900760 <strong>AL</strong><strong>20AN</strong> 8 - 32 8 0 - 8 2900761 <strong>AL</strong><strong>20AN</strong> case 8 - 32 8 0 - 8 2 (With case)14.2 Expansion boards900775 DI16 16 0 0 0 (group isolated)900765 RIO8 8 8 0 0 (inputs group isolated)900770 RO16 0 16 0 0 (relay isolation)900772 DO32 0 32 0 0 (group isolated)900750 connection cable for expansion boards RJ45, 0.25 m900837 EXA8/4 0 0 8 414.3 Accessory boards900860 <strong>AL</strong>1093F clock and calendar/display/keypad (battery back-up)901017 <strong>AL</strong>1093D clock and calendar/display/keypad (battery back-up)901023 <strong>AL</strong>1094 display/keypad901019 <strong>AL</strong>1094R display/keypad900870 <strong>AL</strong>1094AF clock and calendar/display/keypad 2x20 characters 8 keys900880 <strong>AL</strong>1094FM clock and calendar/display/keypad 2x20 characters 16 keys900850 <strong>AL</strong>1095A clock and calendar/display/keypad 8x21 characters/ 128x64pixel graphic LCD display, 16 keys (battery back-up)900855 <strong>AL</strong>1095B clock and calendar/display/keypad 8x21 characters/ 128x64pixel graphic LCD display, 8 keys (battery back-up)902172 <strong>AL</strong>1096S graphic display(240 x 128), 5 function keys902174 <strong>AL</strong>1096T graphic display(240 x 128), touch screen (10 x 8)902178 <strong>AL</strong>1096PS graphic display(320 x 240), touch screen (40 x 30)902180 <strong>AL</strong>1096PE graphic display(320 x 240), touch screen (40 x 30)battery back-up, data saving model14.4 Analog/digital input modules, analog input A/D conversion is 12 bit900795 0 .. 5 mA current input module900799 0 .. 20 mA current input module900800 4 .. 20 mA current input module900785 0 .. 5 V voltage input module900786 0 .. 10 V voltage input module900790 -10 .. 10 V voltage input module900781 Pt100 temperature range -50 ... +150 °C900782 Pt100 temperature range 0 ... +500 °C900796 NTC temperature range -5 ... +50 °C900797 KTY10 temperature range -50 ... +150 °C900807 RMS25VAC RMS input module 0 ... 25 VAC900808 RMS0.25VAC RMS input module 0 ... 0.25 VAC900809 RMS40VAC RMS input module 0 ... 40 VAC900792 <strong>AL</strong>20 DIN I Digital input module 2 DI, isolated900793 <strong>AL</strong>20DIN Digital input module 3 DI<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 13-2 14-204/01/99 12/01/99 29/12/2006<strong>AL</strong> <strong>AL</strong><strong>20AN</strong> AutoLog 14 Brick Instruction <strong>20AN</strong> Käsikirja Manual14.5 Analog outputs on Main board0 .. .5V or 0 ... 10V voltage output, software defineable14.6 Converter for serial communication901225 <strong>AL</strong>6422 CNV - 1 full/half duplex signal converter(RS232C - RS422/485)903190 CNV - 2 half duplex signal converter (RS232C - RS485)901157 <strong>AL</strong>485 I RS 485 half duplex conversion module isolated901165 <strong>AL</strong>485 NI RS 485 half duplex conversion module not isolated903189 CNV-4 f/h duplex Signal Converter, RS232 - RS485/RS422900748 I2C Ext. I2C Extender14.7 Power supplies900630 Power unit 90-265 VAC/24 VCD, 1.2 A, 30 W900632 Power unit 90-265 VAC/24 VCD, 2.5 A, 60 W900634 Power unit 90-265 VAC/24 VCD, 5 A, 120 W901462 <strong>AL</strong>6405 Power supply unit for CNV - 1902218 <strong>AL</strong>-UPS <strong>AL</strong>-UPS Module for use with accumulator14.8 Programming and additional software941020 <strong>AL</strong>ProWin 1.x <strong>AL</strong>ProWin programming software, Windows operating system941060 MODBUS RTU developement kit for PC906611 Modbus Analyser (Windows)14.9 Programming and auxiliary cables941172 <strong>AL</strong>C2 Programming cable PC - <strong>AL</strong> 2000, length 2 m941173 <strong>AL</strong>C3 Programming cable PC - <strong>AL</strong> 2000, length 5 m941175 Cable <strong>AL</strong>1096 - PC, length 5 m941176 Cable <strong>AL</strong>1096 - AutoLog, length 5 m941510 <strong>AL</strong>9042 Cable AutoLog (D9P) - CNV1, length 2.5 m941177 Cable Modem (D9P) - AutoLog (D9P), length 2.5 m941178 Cable PC (D9S) - Modem (D9P), length 2.5 m941179 Cable AutoLog (D9P) - Radio modem (D15P), length 2 m941180 Cable AutoLog (D9P) - Radio modem (D15P), length 8 m941181 Cable PC/FCS (D9S) - CNV1, length 8 m901187 Cable <strong>AL</strong>2000S - Falcom GSM modem901189 Cable AutoLog 2000 - Ericsson GSM modem901193 Cable PC - CNV2 RS 232/485 converter, length 2.5 m901194 Cable CNV2 - <strong>AL</strong> (RJ45), length 2.5 m903195 Programming cable PC - <strong>AL</strong>14Brick/<strong>AL</strong><strong>20AN</strong>, length 2.5 m900741 Cable AutoLog 14/20 - Wavecom GSM modem900742 Cable AutoLog 14/20 - Ericsson GSM modem900750 <strong>AL</strong><strong>20AN</strong>, cable for I/O board<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong> <strong>AL</strong><strong>20AN</strong> AutoLog 14 Brick Instruction <strong>20AN</strong> Käsikirja ManualPage Page Sivu 13-1 15-114-130/04/98 29/12/200604/01/9915. LIST OF INSTRUCTIONS• STR I/O/NI/NO n• STR M/BM/GM/NM/NB/NG/P n• STR DP/DN n• STR S d• STR R M/O/NM/NO/GM n• STR R C d• STR R S n• STR C n• STR Q n• STR W I/M/O/GM n• STR W C d• AND I/O/NI/NO n• AND M/BM/GM/NM/NB/NG/DP/DN/P n• AND S d• AND R M/O/NM/NO n• AND R C d• AND W I/M/O n• AND W C d• OR I/O/NI/NO n• OR M/BM/GM/NM/NB/NG/DP/DN/P n• OR S d• OR R M/O/NM/NO n• OR R C d• OR W I/M/O n• OR W C d• XOR I/O/NI/NO n• XOR M/BM/GM/NM/NB/NG/DP/DN/P n• XOR S d• XOR R M/O/NM/NO n• XOR R C d• XOR W I/M/O n• XOR W C d• EQ M/O/BM/GM n• EQ R M/O/GM n• EQ SM/SO/SB/SG n• EQ RM/RO/RB/RG n• EQ R SM/SO n• EQ R RM/RO n• EQ W M/O/GM n• EQ W SM/SO n• EQ W RM/RO n• INV• IF T• IF I/O/NI/NO n• IF M/BM/GM/NM/NB/NG n• IF DP/DN/P n• IF S d• CONT• DEC R M/O n• DEC W M/O n• INC R M/O n• INC W M/O n• BIN R T (BIN)• BIN W T• BCD R T (BCD)• BCD W T• PLU R M/O n• PLU R C d• PLU W I/M/O n• PLU W C d• PLD R M/O n• PLD R C d• PLD W M/O n• PLD W C d• MIN R M/O n• MIN R C d• MIN W I/M/O n• MIN W C d• MID R M/O n• MID R C d• MID W M/O n• MID W C d• MUL R M/O n• MUL R C d• MUL W I/M/O n• MUL W C d• DIV R M/O n• DIV R C d• DIV W I/M/O n• DIV W C d• DCD R M/O n<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 14-215-204/01/99 12/01/99 29/12/2006<strong>AL</strong> <strong>AL</strong><strong>20AN</strong> AutoLog 14 Brick Instruction <strong>20AN</strong> Käsikirja Manual• LOAD T n d• LOAD C n d• LOAD R T/C n• LOAD Q n ddd• STEP T• STEP S d• STEP R T• READ T/C n• READ S n• READ R T/C n• READ F n• DCR C n• NEXT S d e• EQU R M/O n• EQU R C d• EQU R TX n• EQU W I/M/O n• EQU W C d• GRT R M/O n• GRT R C d• GRT W I/M/O n• GRT W C d• LES R M/O n• LES R C d• LES W I/M/O n• LES W C d• PRI TX• PRT C• PRT T ccccc• PRT R T• PRT R C d• PRT R M/O n• PRT TX n/name• STI I/M/O/BM/GM n• STI R M/O n• STI W I/M/O n• EQI M/O/BM/GM n• EQI R M/O n• EQI W M/O n• CLO R M/O n• BYT I/M/O/BM/GM n• BIT M/O/BM/GM n• END• STOP• SHR Q n d• SHL Q n d• RES Q n• RES F n• FIN F n• FOU F n• FCN n• CSR n• SBR n• RET• STP<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong> <strong>AL</strong><strong>20AN</strong> AutoLog 14 Brick Instruction <strong>20AN</strong> Käsikirja ManualPage Page Sivu 13-3 15-314-3AUTOLOG INSTRUCTIONSFinnish English Finnish EnglishAS LOAD STOP STOPBCD BCD STP STPBIN BIN STR STRBIT BIT TAI ORBYT BYT VH DCRCLO CLO VIRHE ERRORCSRCSRDCD DCD VariablesDECDECEND END T IEQU EQU ET NIETAI XOR L OFCN FCN EL NOFIN FIN SL SOFOU FOU RL ROGRT GRT M MINC INC EM NMINV INV SM SMJA AND RM RMJAK DIV DP DPJOS IF DN DNJTK CONT BM BMKER MUL EB NBLES LES SB SBLUE READ RB RBMID MID GM GMMIN MIN EG NGON EQ SG SGONI EQI RG RGPLD PLD P PPLU PLU A TPRI PRI TX TXPRT PRT N CRES RES F FRET RET F FSBR SBR J JSEURNEXTSHL SHL Variable typesSHRSHRSTEP STEP R RSTI STI W W30/04/98 29/12/200604/01/99<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 14-415-404/01/99 12/01/99 29/12/2006<strong>AL</strong> <strong>AL</strong><strong>20AN</strong> AutoLog 14 Brick Instruction <strong>20AN</strong> Käsikirja ManualAUTOLOG INSTRUCTIONSEnglish Finnish English FinnishAND JA STEP STEPBCD BCD STI STIBIN BIN STOP STOPBIT BIT STP STPBYT BYT STR STRCLO CLO XOR ETAICONTJTKCSR CSR VariablesDCDDCDDCR VH I TDEC DEC NI ETDIV JAK O LEND END NO ELEQ ON SO SLEQI ONI RO RLEQU EQU M MERROR VIRHE NM EMFCN FCN SM SMFIN FIN RM RMFOU FOU DP DPGRT GRT DN DNIF JOS BM BMINC INC NB EBINV INV SB SBLES LES RB RBLOAD AS GM GMMID MID NG EGMIN MIN SG SGMUL KER RG RGNEXT SEUR P POR TAI T APLD PLD TX TXPLU PLU C NPRI PRI S SPRT PRT F FREAD LUE Q JRESRESRET RET Variable typesSBRSBRSHL SHL R RSHR SHR W W<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong> <strong>AL</strong><strong>20AN</strong> AutoLog 14 Brick Instruction <strong>20AN</strong> Käsikirja ManualPage Page Sivu 13-5 15-514-530/04/98 29/12/200604/01/99The memory map of <strong>AL</strong><strong>20AN</strong>, addresses in decimalI O M GM BM255 255 255 255239EXA84+DIN12812796959695DI DO3231DIN870323187000 0R O R M R GM255 255 25519112800 0DP and DNstates alsoavailable fromthese memoriesTstateR T, Tactualvalue7916840reserved forcontrollers8 bitaux memoriesreserved forsystem usereserved forAl1095 graphicsCstateS31...R C, Cactualvalue15087 ...0Q3210F76543210P210W O W M409565535W GM W I255 255255W M 128-2557W M 0-127R M 0-25500000TR TW T1254 2551254 255Indirectly addressed wordmemories 000 - 65535 andword outputs 000-4095 (=4k)(Commands STI and EQI)R M 3W M 1R M 2LoHiR M 1W M 0R M 0LoHi<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 14-615-604/01/99 12/01/99 29/12/2006<strong>AL</strong> <strong>AL</strong><strong>20AN</strong> AutoLog 14 Brick Instruction <strong>20AN</strong> Käsikirja ManualThe behaviour of <strong>AL</strong><strong>20AN</strong> memories on power failureAddresses in decimalWill retain their status duringpower failure if desiredS31I239EXA84+DIN9695O M GM BM255 255 255 2551921919695192191969519219196951921919695TstateR T, Tactualvalue79Will be reset afterpower failureState not affected bypower failureReserved for systemuse870Q3Q210DI DO0 1 23231DIN8703231870 0 0 0 00161587C R C, Cactualstate value15F7654320 1R O R M R GMW OW M255 255 2554095 65535191W GM255255 255128W M 128-25596W I795W M 0-127R M 0-25512700 00 0 0 0TR TW TIndirectly addressableword memories 000 - 65535and word outputs 000 - 4095(instructions STI and EQI)<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong><strong>20AN</strong> AutoLog Instruction <strong>20AN</strong> Käsikirja ManualPage Sivu 16-129/12/2006 04/01/9916. ADJUSTMENT OF AN<strong>AL</strong>OG INPUTS<strong>AL</strong><strong>20AN</strong> PLC CPU card has 8 analog inputs and these are adjusted at the factoryaccording the order definings. The measured signal type is selected individually forevery input and the hardware adjustment is made by connection module. The resolutionof the analog inputs are 12 bits.In case you need to change the input measurement module to another, you mustchange the analog input module which corresponds to the desired input signal and theinput must be readjusted. Also in the case you need to change the scaling of an analoginput within the existing range or you need readjust the analog input, a softwarecommand has to executed via <strong>AL</strong>Pro programming software. The adjustment takesplace using the register outputs of the PLC (like in an <strong>AL</strong>2000).RegisteroutputMeaning ofvariableR O 220 Adjustment step 0 ... 5R O 222 Input number to be adjusted 0 ... 7Min / max.values8 bit 16 bitCalculation of the valuefor adjustment variablesR O 224 Lower adjustment value high byte 0 ... 15 (0 ... 4000) 500 = 1 * 256 +R O 225 Lower adjustment value low byte 0 ... 255 244R O 226 Upper adjustment value high byte 0 .... 15 (0 ... 4000) 3500 = 13 * 256 +R O 227 Upper adjustment value low byte 0 ... 255 172The initialization of adjustment step is made through register ouput R O 220.The permitted adjustment steps are:Before step 1 both calibration values can be inserted (R O’s 224, 225, 226, 227)Step 1: Start adjustmentStep 2: Set the lower adjustment value for the inputBefore going to step 3 the lower calibration value must be insertedStep 3: Read the lower adjustment valueStep 4: Set the upper adjustment value for the inputBefore going to step 5 the upper calibration value must be insertedStep 5: Read the upper adjustment valueAS the result of succesful/unsuccesful adjustment of input PLC’s system program writesinto register output R O 220 the result value:0 adjustment was succesfuln > 5 error code<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 16-204/01/99 29/12/2006<strong>AL</strong><strong>20AN</strong> AutoLog Instruction <strong>20AN</strong> Käsikirja ManualThe result of adjustment is that the zero point value from the PLC’s analog inputcorresponds the minimum value of input and high value in PLC corresponds the highvalue of input. The value can be seen in the PLC as a number from 0 to 4096 (as a rawvalue).16.1 What is needed for adjustmentYou need the <strong>AL</strong>Pro or <strong>AL</strong>ProWin software, a PC, an accurate mA-meter, an accurateV-meter, an adjustable resistance reference and when adjusting current inputsmillamper source.For making the readings of the analog inputs you have to use the PC and the <strong>AL</strong>Prosoftware. For the adjustment of the analog inputs of <strong>AL</strong><strong>20AN</strong> CPU only one instructionhas to be downloaded to the PLC; the STOP instruction. Through the <strong>AL</strong>Pro debug(watch table) function you can see the values of all <strong>AL</strong><strong>20AN</strong>’s analog inputs.How to read the input values using the PC and <strong>AL</strong>Pro1. Connect the <strong>AL</strong><strong>20AN</strong> to the PC and start the <strong>AL</strong>Pro software.2. If you want to read inputs in values from 0 to 1000, write the following program,otherwise you see the values from 0 to 4000.STR W I 000 This program was made for the analog input 0. If youDIV W C 004 want to include all analogue inputs at once, you canEQ W M 000 add similar instructions for all the rest of theSTOPanalog inputs3. Compile program by choosing Compile from the main menu.4. Transfer the program to the PLC by choosing Write prog to PLC from theTransfer submenu5. Choose Debug from the Online submenu.6. Choose Start/Stop from the Debug main menu.7. Start the program execution by Start F7 command from Start/Stop submenu.Now you have started the execution of the program you have written before.Check that the status light is blinking indicating normal operation.8. Choose Monitor from Degug main menu.9. Choose Add Variable from Monitor submenu. A box appears on the screen.Write W M 0 in the box and press . Now you can see the variableW M 0 in uppdate box on the screen. You can insert several variables to theuppdate box and after that you exit by from the insert box.<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong><strong>20AN</strong> AutoLog Instruction <strong>20AN</strong> Käsikirja ManualPage Sivu 16-329/12/2006 04/01/9910. Press F9 key in order to start the updating of the values you want to Monitor.In the update screen you can see values of variables, for example:;W M 0 =2 (the numbers depend on the real input;W I 8 =120 value of analog input)In case you have written a program for monitoring all analogue inputs at thesame time you have to add add all the necessary monitor lines for all the analoguevariables.11. Now you can start the adjustment procedure.16.2 Current inputI -You need to have an adjustable current source and a mA meter with enough accuracy(0.1%). Connect the adjustable current source to the analogue input number 1 (terminalsSIGN+, SING- and I-)Analogue input 01SIGN -SIGN +I +CON 101114113112111mAAdjustablecurrent sourceNote! When adjusting analog input 0 insertnumber 0 into R O 222 = 0.Other inputs must be adjusted withcorresponding numbers in R O 222.(Input 1, R O 222 = 1.)16.3 Voltage inputYou need an adjustable voltage source and a V meter with enough accuracy (0.1%).Connect the adjustable voltage source to the analogue input (terminals SIGN+, SINGandI-).Analogue input 02CON 101I -SIGN -SIGN +I +124123122121VAdjustableVoltage sourceNote!When adjusting analog input 2 insertnumber 1 into R O 222 = 2.Other inputs must be adjusted withcorresponding numbers in R O 222.(Input 7, R O 222 = 7.)<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 16-404/01/99 29/12/2006<strong>AL</strong><strong>20AN</strong> AutoLog Instruction <strong>20AN</strong> Käsikirja Manual16.4 Temperature input with PT100 sensorYou need an adjustable resistance reference 0.1 ... 250 Ω with an accuracy of 0.1%.Connect the adjustable resistance in the following way to terminals I+, SIGN+, SIGN- andI-.Analogue input 02CON 101I - 124SIGN - 123SIGN + 122AdjustableresistancereferenceNote! When adjusting analog input 0insert number 0 into R O 222 = 0.Other inputs must be adjusted withcorresponding numbers in R O 222.I +121The adjustment of an analog input is made as follows:1. Start the adjustment by setting number one (1) to R O 220. The adjustment program moves to step two (2) and waits you to insert the loweradjustment values into R O 224 and R O 225.2. Adjust the level of the analog signal to lower adjustment value.In order to make the adjustment of the Pt100 input as accurate asbossible over the measurement range, it is advisable to take the lowervalue about +10% higher than minimum measure value. This due to nonlinearity of Pt100 sensor.3. When the signal value corresponding to the lower adjustment value canbe read on <strong>AL</strong>Pro’s debug screen, set into R O 220 a value of three (3).Now the adjustment program reads the signal value and moves to stepfour (4) to insertion of the upper adjustment value into register outputsR O 226 and R O 227.4. When the signal value corresponding to the upper adjustment valuecan be read on <strong>AL</strong>Pro’s debug screen, set into R O 220 a value of five(5). Now the adjustment program reads the signal value, calculates thevalues of the adjustment parameters and saves the values to theFLASH memory. After that the adjustment program informs the user ifthe adjustment was succesful by writing into R O 220 the value zero(0), or if the result was unsuccesfull the error code. From the errorcodes the user can check what the problem was.<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong><strong>20AN</strong> AutoLog Instruction <strong>20AN</strong> Käsikirja ManualPage Sivu 16-529/12/2006 04/01/99The error codes for analogue input adjustment are as follows:027 FLASH verification error028 FLASH write error128 input signal low > input signal high129 adjustment value low > adjustment value high130 input signal high > 4000140 input address too highThe Pt100 sensor is nonlinear. The following temperatures corresponds to the resistancevalues given in the table (DIN 43 760) below:°CΩDiff. Ω°CΩDiff. Ω°CΩDiff. Ω-50-45-40-35-30-25-20-15-10-505101520253035404580.3182.2984.2786.2588.2290.1992.1694.1296.0698.04100101.95103.90105.85107.79109.73111.67113.61115.54117.470.400.400.390.390.390.390.390.390.390.390.390.390.390.390.390.380.390.390.390.39556065707580859095100105110115120125130135140145150121.32123.24125.16127.07128.98130.89132.80134.79136.60138.50140.39142.29144.17146.06147.94149.82151.70153.58155.45157.310.390.380.390.380.380.380.380.380.380.380.370.390.370.380.370.370.370.380.380.37160165170175180185190195200205210215220225230235240245250255161.04162.90164.76166.61168.46170.31172.16174.00175.84177.68179.51181.34183.17184.99186.82188.63190.45192.26194.07195.880.370.370.370.370.370.370.370.370.370.370.370.370.370.360.370.360.360.360.360.36In order to make the adjustment of thePt100 input as accurate as possible overthe measurement range, differentadjustment points have to be used. Insteadof adjusting the O<strong>FF</strong>SET at the lowestvalue we use a 10% point as theadjustment point for the low end of themeasurement range. In the same way weuse the 90% point as the adjustment pointfor the high value. This increases theoverall accuray.The curve in picture is exaggerated.<strong>FF</strong>-<strong>Automation</strong> Oy


Sivu Page 16-604/01/99 29/12/2006<strong>AL</strong><strong>20AN</strong> AutoLog Instruction <strong>20AN</strong> Käsikirja ManualIn the following table the adjustment points are calculated for the different standardPt100 measurement ranges available for <strong>AL</strong><strong>20AN</strong>.PT100:Module number 900781 900782Temp. range °C -50 ... +150 0 ... +500Resolution °C 0.20 0.50O<strong>FF</strong>SET point 10% °C -30.0O<strong>FF</strong>SET point 20% °C +100Resistor value Ω 88.22 138.50Calibration constant (low) 400 800GAIN point 80% °C +400.0GAIN point 90% °C +130.0Resistor value Ω 149.82 247.04Calibration constant (high) 3600 3200On the PC you should see the following values when the adjustment is correct:<strong>AL</strong>14AN O<strong>FF</strong>SET GAINmodule 10% 90%900781 400 3600The offset and gain values can be any vales inside the measuring range.For example: Offset = 50% and Gain = 60% and corresponding values to calibrationvariables and reference signals. So you can get very accurate values in/near range from45% to 65%. This range can be calibrated to give raw readingsat 50% gives 10% of hole range (4000) (=400) andat 60% gives 90% of hole range (4000) (=3600).<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong><strong>20AN</strong> Instruction Manual Page A-129/12/2006A. DIMENSION<strong>AL</strong> DRAWINGSH101H208H102H207H103H206H104H205H105H204H106H203213,5 mmCON303 CON101SW1H108H1075 mmIC3 IC4IC1IC2IC10H202H201B1MOD3MOD2MOD1MOD0MOD6 MOD4MOD7 MOD5RX TXRX 12VSER2SER1CON501CON1TXCON201CON403CON502CON503 J1 J2CON401 CON402CON302CON301RUN2IC 3,5 mm2EXT I C5 mm107,5 mmThe height of CPU borad is 35mm, the tallest component on the board is the analogue input module.Figure A.1 Dimensions of <strong>AL</strong><strong>20AN</strong><strong>FF</strong>-<strong>Automation</strong> Oy


Page A-229/12/2006<strong>AL</strong><strong>20AN</strong> Instruction ManualCON104CON103CON102CON10115B15A14B14A13B13A12B12A11B11A10B10A9B9A8B8A7B7A6B6A5B5A4B4A3B3A2B2A1B1A0B0AH9H10H11H12H13H14H15H16H1H2H3H4H5H6H7H8C11 C10 C9 C8 C7 C6 C5 C4 C3 C18 C17 C16 C15 C14 C13 C12K8 K7 K6 K5 K4 K3 K2 K1 K16 K15 K14 K13 K12 K11 K10 K997.3107.3IC8IC5IC6IC7CON2FROM CPUCON1J11-2 3-4 ADDR1 1 321 0 480 1 640 0 80TO EXT203.3204.5213.5Figure A.2 Dimensions of expansion board RO16 27B27A26B26A25B25A24B24A23B23A22B22A21B21A20B20A COM1716151413121110 5.0 107.5 CON1CON2FROM CPUwww.<strong>FF</strong>-<strong>Automation</strong>.comTO EXT5.0J1 1234561-2 3-4 5-6 ADDR 1-2 3-4 5-6 ADDR1 1 1 32 0 1 1 641 1 0 40 0 1 0 721 0 1 48 0 0 1 801 0 0 56 0 0 0 885.0160.05.0Figure A.3 Dimensions of expansion board RIO8<strong>FF</strong>-<strong>Automation</strong> Oy


C2<strong>AL</strong><strong>20AN</strong> Instruction Manual Page A-329/12/2006 GND1514131211100908 GND0706050403020100 97,3107,5CON1CON2FROM CPUwww.<strong>FF</strong>-<strong>Automation</strong>.comJ11-2 3-4 ADDR1 1 321 0 480 1 640 0 80TO EXT114,6115,9125,0Figure A.4 Dimensions of expansion board DI16 COM232231230229228227226225COM224223222221220219218217 COM216215214213212211210209COM208207206205204203202201 5.01 1 107.5 ☺HC1 ☺ ☺ ☺ ☺CON1FROM CPUJ1 1 2 3 4J1 1-2 ADR 32J1 3-4 ADR 64www.<strong>FF</strong>-<strong>Automation</strong>.comTO EXT5.0CON25.05.0160.0Figure A.5 Dimensions of expansion board DO32<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-429/12/2006<strong>AL</strong><strong>20AN</strong> Instruction Manual5108.52ICIC105IC3MOD104MOD102JP2MOD103MOD101IC2MOD105MOD107X1MOD106MOD108IC1IC103IC102IC10113413313213112412312212111411311211110410310210184838281RUNRUN2IC141142143144151152153154161162163164171172173174858687885107.5Figure A.6 Dimensions of EXA8/4 analog expansion board<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong><strong>20AN</strong> Instruction Manual Page A-529/12/20068min.17the key isthe tallestcomponenton the board0123456784Figure A.7 Dimensions of display/keypad unit <strong>AL</strong>109430 7Led 0Led 17464 5580the key isthe tallestcomponenton the board9164174min.17Figure A.8 Dimensions of display/keypad unit 1094R<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-629/12/2006<strong>AL</strong><strong>20AN</strong> Instruction Manual2602041679IC3IC16501 2 34345 6 721IC235295Figure A.9 Dimensions of display/keypad unit <strong>AL</strong> 1094AF15015 158 6652312216001 2 335 354 5 6 78 9 A BC D E F432131 40Figure A.10 Dimensions of display/keypad unit <strong>AL</strong> 1094FM<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong><strong>20AN</strong> Instruction Manual Page A-729/12/2006Figure A.11 Dimensions of display/keypad unit <strong>AL</strong>1093D6316614DIS11060 1 2 3 48 9 A B C5 6 7D E FDisplayFigure A.12 Dimensions of display/keypad unit <strong>AL</strong>1093FCutout<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-829/12/2006<strong>AL</strong><strong>20AN</strong> Instruction ManualDisplayFigure A.13 Dimensions of display/keypad unit <strong>AL</strong>1095ACutoutDisplayCutoutFigure A.14 Dimensions of display/keypad unit <strong>AL</strong>1095B<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>AL</strong><strong>20AN</strong> Instruction Manual Page A-929/12/2006Cutout:180.0±0.2 x 132.4±0.2Figure A.15 Dimensions of graphic display - keypad/touchscreen unit <strong>AL</strong>1096S/TCutout:193.6±0.3 x 151.8±0.3Figure A.16 Dimensions of graphic display - touchscreen unit <strong>AL</strong>1096PS/PE<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-1029/12/2006<strong>AL</strong><strong>20AN</strong> Instruction Manual40.55 4 3 2 1115Vout ADJ.90.0DC ONN L67893.8Figure A.17 Dimensions of Power Unit 90-265VAC/24VDC, 2.5A, 60WFigure A.18 Dimensions of Power Unit 90-265VAC/24VDC, 5A, 120W<strong>FF</strong>-<strong>Automation</strong> Oy

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!