09.07.2015 Views

Man_AL32_eng_v9723_2.. - FF-Automation

Man_AL32_eng_v9723_2.. - FF-Automation

Man_AL32_eng_v9723_2.. - FF-Automation

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

AutoLog 32 Instruction <strong>Man</strong>ual26/10/2001AL 32v. 9723ProgrammableLogic controllerInstruction <strong>Man</strong>ual<strong>FF</strong>-AUTOMATION OYHEAD O<strong>FF</strong>ICESERVICE CENTEREräkuja 2Meijerikuja01600 VANTAA 37650 ValkeakoskiTel. +358-9-5306310 Tel. +358-3-5846390Fax. +358-9-53063130 Fax. +358-3-5846711http://www.ff-automation.come-mail:info@ff-automation.com<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual26/10/20019. CONTROLLERS .....................................................................................................................9-19.1 Register memories of controllers .................................................................................9-19.2 Control algorithm..........................................................................................................9-29.3 Controller types ............................................................................................................9-39.4 Controller tuning...........................................................................................................9-49.5 Three point controllers .................................................................................................9-510. DATA COMMUNICATION ..................................................................................................10-110.1 Terminal / printout......................................................................................................10-210.2 MODBUS Communication .........................................................................................10-210.3 Modem - AL16AN ......................................................................................................10-511. OPERATION OF THE PROGRAMMABLE LOGIC CONTROLLER...................................11-111.1 Switching on and special supply conditions ...............................................................11-111.2 Start of program execution ........................................................................................11-211.3 START command ......................................................................................................11-211.4 Remedies for problem situations ...............................................................................11-31<strong>2.</strong> PROGRAMMING ................................................................................................................12-11<strong>2.</strong>1 Programming methods ..............................................................................................12-11<strong>2.</strong>2 <strong>AL32</strong> variables ..........................................................................................................12-31<strong>2.</strong>3 Error messages .........................................................................................................12-41<strong>2.</strong>4 <strong>AL32</strong> Instructions .......................................................................................................12-51<strong>2.</strong>5 Terminal programming commands..........................................................................12-411<strong>2.</strong>6 Programming pointer ...............................................................................................12-421<strong>2.</strong>7 Entering an instruction in memory by terminal programming ..................................12-431<strong>2.</strong>8 Deleting an instruction from memory.......................................................................12-431<strong>2.</strong>9 Locating an istruction in a program by terminal programming.................................12-441<strong>2.</strong>10 Listing the program by terminal programming .........................................................12-441<strong>2.</strong>11 Stroring the program by terminal programming .......................................................12-441<strong>2.</strong>12 If there is no AutoLog program in memory ..............................................................12-441<strong>2.</strong>13 Monitoring the operation of a program by terminal programming............................12-451<strong>2.</strong>14 Fast program loop....................................................................................................12-461<strong>2.</strong>15 Special keys and corresponding ASCII codes .........................................................12-4713. TABLES...............................................................................................................................13-113.1. ASCII-codes...............................................................................................................13-113.<strong>2.</strong> Decimal / Octal conversions ......................................................................................13-214. LIST OF <strong>AL32</strong> PRODUCTS................................................................................................14-114.1 Basic boards ..............................................................................................................14-114.2 Expansion boards ......................................................................................................14-114.3 Analog input modules ................................................................................................14-114.4 Analog outputs ...........................................................................................................14-114.5 Converters for serial communication .........................................................................14-114.6 Accessory boards ......................................................................................................14-214.7 Power supplies...........................................................................................................14-214.8 Programming cables..................................................................................................14-214.9 Programming software...............................................................................................14-214.10 Other programs................................................................................................14-215. LIST OF INSTRUCTIONS...................................................................................................15-1Commands of Autolog English-> Finnish...................................................................15-3Commands of Autolog Finnish-> English...................................................................15-4The behaviour of AL16AN memories on poer failure, addresses in decimal.............15-5The memory map of AL16AN, addresses in decimal ...............................................15-6<strong>FF</strong>-<strong>Automation</strong> Oy


26/10/2001AutoLog 32 Instruction <strong>Man</strong>ual16. Instructions for the adjustment of the analog inputs of <strong>AL32</strong>AN and <strong>AL32</strong>EXA .................16-116.1 Adjustment potentiometers on the <strong>AL32</strong>AN and <strong>AL32</strong>EXA boards...........................16-116.2 <strong>AL32</strong>AN .....................................................................................................................16-116.3 <strong>AL32</strong>EXA ...................................................................................................................16-216.4 What is needed for adjustment..................................................................................16-216.5 How to read the input values using the PC and ALPro (DOS version)......................16-316.6 Current input..............................................................................................................16-416.7 Voltage input..............................................................................................................16-516.8 Temperature inputs with Pt100 sensor......................................................................16-616.9 Temperature inputs with KTY10 sensor (Thermistor) (PTC).....................................16-9APPENDIX A DIMENSIONAL DRAWINGS............................................................................... A-1Figure A.1 Dimensions of <strong>AL32</strong>DI................................................................................... A-1Figure A.2 Dimensions of <strong>AL32</strong>AN ................................................................................. A-2Figure A.3 Dimensions of <strong>AL32</strong>PL .................................................................................. A-3Figure A.4 Dimensions of expansion board <strong>AL32</strong>EX ...................................................... A-4Figure A.5 Dimensions of expansion board <strong>AL32</strong>EXA.................................................... A-4Figure A.6 Dimensions of expansion board <strong>AL32</strong>EXO ................................................... A-5Figure A.7 Dimensions of expansion display/keypad AL1094 ........................................ A-5Figure A.8 Dimensions of expansion display/keypad AL1094R...................................... A-5Figure A.9 Dimensions of expansion display/keypad AL1094AF ................................... A-6Figure A.10 Dimensions of expansion display/keypad AL1093D...................................... A-6Figure A.9 Dimensions of expansion display/keypad AL1093F ..................................... A-7Figure A.10 Dimensions of expansion display/keypad AL1095A ...................................... A-7Figure A.11 Dimensions of expansion display/keypad AL1095B ...................................... A-8Figure A.12 Dimensions of graphic display - keypad/touchscreen AL1096S/T ................ A-8Figure A.13 Dimensions of graphic display - keypad/touchscreen AL1096PS/PE............ A-9Figure A.14 Dimensions of AL9624/3.5 power supply .................................................... A-10Figure A.15 Dimensions of AL9624/8 power supply ....................................................... A-10<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 1 - 126/10/20011. SYSTEM COMPONENTSThe AL 32 product family includes three types of basic boards (digital ( AL 32DI),analog (AL 32AN), and pulse counter (AL 32PL) boards), expansion boards (digital(AL 32EX), (AL 32EXO) and analog (AL 32EXA) boards), and relay output boards(RE 16 and RE 16H). Further, display and keypad units (AL 1093C/D, AL 1094, AL1094R, and AL1096) are available to provide a user interface.<strong>AL32</strong>DI-16 digital inputs, 16 digital outputs -RS 232C serial businterface-Contains user program-Controls expansionboards-Adapts external signals to match the ProgrammableLogic Controler-Amplifies the output signalsof the Programmable Logic Controller to meet externalcircuit requirementsSame as AL 32DI, and additionally:-6 individually adjustableanalog inputs (Pt 100, KTY 10, current, voltage)-1 analog output (one of the 6 analog inputs can then onlybe used for current or voltage measurement)-2 registervariables with screwdriver adjustmentSame as AL 32DI, and additionally:-4 mutually independent100 kHz pulse counters<strong>AL32</strong>AN-16 digital inputs, 16 digital outputs-Adapts external signalsto match the Programmable Logic Controller-Amplifies the output signals of the Programmable LogicController to meet external circuit requirements-8 individually adjustable analog inputs (Pt 100, KTY 10,current, voltage)-4 analog outputs (voltage 0 - 5 V or 0 -10 V)<strong>FF</strong>-<strong>Automation</strong> Oy


Page 1 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>AL32</strong>PLSame as <strong>AL32</strong>DI,and additionally:- 4 mutually independent 100 kHz pulse counters<strong>AL32</strong>EX<strong>AL32</strong>EXA- 16 digital inputs - 8 individually adjustable analog inputs- 16 digital outputs (Pt100, KTY10, current, voltage)- Adapts external signals to match - 4 analog outputs (voltage 0 - 5 V or 0 - 10 V)the Programmable Logic Controller- Amplifies the output signals of theProgrammable Logic Controllerto meet external circuit requirements<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 1 - 326/10/2001<strong>AL32</strong>EXO- 32 digital outputs- Adapts external signals to match the PLC- Amplifies the output signals of the PLC to meetexternal circuit requirementsBasic boards, expansion boards, display and keypad units, and relay output boards can be mounted togetheras shown in the example below. The maximum complement is one expansion board, one relayoutput board, and one display and keypad unit to one basic boardAL 32ANAL1093AAL 32EXRE16<strong>FF</strong>-<strong>Automation</strong> Oy


Page 1 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ualAL1094AL1094R-4 digit LCD display- 8 keys (0 ... 7)- 4 LED indicator lights- Connection to AutoLog’s I 2 C bus-2x16 chracter LCD display with backlight- 4 keys (0 ... 3)- 2 LED indicator lights- Connection to AutoLog’s I 2 C busAL1094F- 2x20 character alphanumeric display- clock/calendar- 8 keys- 4 indicating leds, buzzer and one 24VDC300 mA output for external indicating ligth- AL1904AF can display text (using the PRT instruction)- Unit can be fitted with client designed front plate.- Output O 4 = buzzer, output O 5 = control output for external indicating ligth .- Connection to Autolog’s I 2 C busAL1093D- 2x 16 character LCD display with backlight- Clock and calendar with battery backup- 16 keys (0 ... F)- Connection to AutoLog’s I 2 C bus<strong>FF</strong>-<strong>Automation</strong> Oy


Page 2 - 126/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>2.</strong> SPECIFICATIONS<strong>2.</strong>1 Basic boards (AL 32DI, AL 32AN, AL 32PL)AL 32DI:InstructionsLogic, arithmetic, compare, timer, counter, step drive, and reporting instructionsNumber of instructions About 260Program capacity 2048/4096 logic instructions.4096 instruction capacity needs special EEPROMProgrammingInstruction list; relay diagram also possible when using PCProgramming device Terminal or microcomputer with RS232C interfaceCycle time3 ms + 20 ms per instruction (average). In addition, a program loop to beexecuted every 5 ms can be programmed.Auxiliary memory 256 x 1 bit; 64 of these with differentiation256 x 1 bit (BM)256 x 1 bit common memory (GM)224 x 1 bit internally accessible outputs256 x 8 bit register memory255 x 8 bit internally accessible output256 x 16 bit word memory direct addressable, indirect 2048 pcs.256 x 16 bit word output direct addressable, indirect 1024 pcs.Timers4 timers 0.01 s to <strong>2.</strong>55 s, set by program4 timers 0.1 s to 25.5 s, set by program8 timers 1 s to 255 s, set by program64 timers 0.1 s to 25.5 s, set by programCounters16 counters, 0 to 255, set by programSequence registers 32 sequence registers, steps 0 to 255Shift register4 pcs, places 0 - 255 8 bit registersFIFO register8 pcs, 256 places 8 bit registersControllers8 PID controllers with programmable parametersSerial interfaceMemory retentionDigital inputsDigital outputsTiming controlBattery backupOne, for asynchronous communication at 300/1200/2400/4800/9600 Bd,e.g. terminal/barcode camera/RCU/AL bus/MODBUS, or for programming(with terminal or PC)The program is held in memory (EEPROM or EPROM)The single-bit auxiliary memories M0-77, outputs O0-47, timers, counters,and sequence registers (0 - 3) are reset after a power failure.Register memories, auxiliary memories M100-377, outputs O50-277,register outputs, word variables, FIFOs, and shift registers retain theircontents if desired.16 inputs at 24 V DC, 8 mA max. Inputs are not isolated16 outputs at 24 to 60 V DC, 0.5 A max. Outputs are not isolatedConnection for clock/calendar/display/keypad unit2 years (full battery in storage condition), app. 10 years in normal use.NOTE! Register memories0 - 255 and word memories0 - 127 are located in samememory area<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 2 - 226/10/2001AL 32AN:In addition to the features of the AL 32DI:Analog inputsSix, individually adaptable for Pt100/KTY10 temperature signals, currentsignals 4 - 20 mA/0 - 20 mA, or voltage signals 0 - 5 V/0 - 10 V, and2 register variables with screwdriver adjustmentAnalog outputOne, 0 - 5 V or 0 - 10 V (obtainable by jumper connections fromanalog input 0; the maximum number of available temperature inputs willthen be 5, and a current or voltage signal can be applied to input 0)Analog signal precision 0.1 % (10 bit resolution)AL 32PL:In addition to the features of the AL 32DI:Pulse sensor inputs Four, mutually independentInput signal Pulse train, single-phase or two-phase (90°)Input frequency50 kHz max. with a 24 V sensor, or a 5 V sensor with an open-collector output100 kHz max. with a 5 V sensor with an active (totem-pole) outputSensor type to be used NPN or active (totem-pole)Reset pulse inputs T0(A), T1(B), T2(C), T3(D), read interval 5.5 msUpdate of pulse counters At intervals of 5 - 5.5 msUpdate of comparisondata at outputsAt intervals of 5 - 5.5 msFast program loop not available<strong>2.</strong>2 Expansion boards (AL 32EX, AL 32EXA)AL 32EX:Digital inputs16 at 24 V DC, 8 mA max.Digital outputs16 at 24 V DC (resolution: supply voltage 2 V), 0.5 A max.Galvanic isolation The inputs and outputs are not isolatedConnections tobasic boardRibbon cable, 0.5 m max.AL 32EXA:Analog inputsEight, individually adaptable for Pt100/KTY10 (temperature signals),current signals 4 - 20 mA/0 - 20 mA, or voltage signals 0 - 5 V/0 - 10 VAnalog outputsFour, 0 - 5 V or 0 - 10 VAnalog signal precision 0.5 % (8 bits)Updating of analog inputs Controlled by system program of PLC, all inputs per program cycleUpdating of analog outputs Controlled by system program of PLC, all inputs per program cycleProgrammingRequires a logic program for processing the analog inputs and outputs<strong>AL32</strong>EXOThe outputs in <strong>AL32</strong>EXO board are updated when R M 228 = <strong>2.</strong>Expansion boards can be connected 1 to 3 pieces to one <strong>AL32</strong> main board.<strong>AL32</strong>EXO boards can't be used with <strong>AL32</strong>EX or<strong>AL32</strong>EXA boards.Digital outputsAddress of board is defined with jumpers J100 and J101.Board reserves 2 addresses.4 x 8, 24 VDC digital outputs (FET), outputs are not isolatedPossible addresses of the outputs are O 16 ... 47, O 48 ... 79, O 80 ... 111Max. current/output(s) 2 A, the sum current in 8 output group must not exceed 4 A<strong>FF</strong>-<strong>Automation</strong> Oy


Page 2 - 326/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>2.</strong><strong>2.</strong> Display and keypad units AL 1093D/F, AL1094 /R, AL1095A/B, AL1096S/TAL 1093D/ F:DisplayTiming controlBattery backupIndicator lightsKeypad2 x 16 character LCD display with backlightContains clock and calendarFor clock/calendar (load life about 5 years)6 LEDs, controlled by bit outputs16 keys (0 - F), each key can control one bit outputAL 1094:DisplayKeypadIndicator lights4 digit LCD display8 keys, each key can control one bit output4 LEDs, controlled by bit outputsAL 1094R/F:DisplayKeypadIndicator lights2 x 16 character LCD display with backlight (R); 20x16 char. (F)4 keys, each key can control one bit output (R); 7 keys (F)2 LEDs, controlled by bit outputs (R); 4 LEDs, buzzer and 1 output (F)AL 1095A/B:DisplayTiming controlBattery backupIndicator lightsFunction keysSupported characters8x21 character LCD display / 128x64 pixel graphic display with backlightContains clock and calendarFor clock/calendar (load life about 5 years)8 LEDs, controlled by bit outputs16 keys (0 - F; A-type), 4 keys (0 - 3; B-type)Scandinavian / cyrillic character set supported, selectable by jumperAL 1096S/T:Display240 x 128 STN graphic LCD-display with backlight(display area 108 x 58 mm)Function keys5 function keys (S type), Touch Screen (T type)Supply voltage 24VDC + 10% - -15%, 0.35ASerial portRS232/RS422/RS485, 9600 to 19200 bps for connection to the PLCor configurationPLC Protocols Autolog, AEG Modicon, Allen Bradley, Siemens, Omron ....Connection to PLCThrouhg RS232 COM1 or RS232/422/485 COM2AL 1096PS/PE:DisplayTouch ScreenSupply voltageSerial ports320 x 240 STN blue mode graphic LCD-display with backlight(display area diagonal 5,7 inch)Touch Screen, max. 40x30 switches24VDC + 10% - -15%, power consumption below 10 WCOM1: RS232; COM2 RS232/RS422/RS485, 9600 to 19200 bps forconnection to the PLC or configurationPLC Protocols Autolog, AEG Modicon, Allen Bradley, Siemens, Omron ....Connection to PLCThrouhg RS232 COM1 or RS232/422/485 COM2<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 2 - 426/10/2001<strong>2.</strong>4 Relay output boards (RE 16, RE 16H)RE 16:Relay outputs 16ConnectionsScrew connections for <strong>2.</strong>5 mm2 leadsContacts16 N.O., floatingMaterial: AgCdO 16 contactsAir gap: 0.3 mmVoltage rating250 V AC or 300 V DCMax. continuous current 2 A (8 A VDE)Max. switching current 8 A ( 10 ms)Spark suppression 10 nF + 33 WLeakage current 0.8 mA at 250 V, 50 HzRelay test voltage 4000 V rms (coil to contacts)Mechanical life2 x 107 switching cyclesSupply voltage19 to 36 V DC or 18 to 25 V AC, 100 mASupply connection Screw connections for <strong>2.</strong>5 mm2 leadsCoil voltageNominally 24 V/12 mA (19 V/9 mA to 36 V/16 mA) DCCoil driveNPN transistor (open collector) or contact closureQuenching diode Provided on board, or not, depending on board version. When used witha basic <strong>AL32</strong> board with VDIODE connected, the quenching diode is notrequired; otherwise it is.Environmental requirements:Operating temperature +5 to +45 °CStorage temperature -20 to +50 °C (non-condensing)HumidityDegree of protection IP 20 (unprotected)RE16H:Relay outputs 16, isolated in groups (8 + 8) 8 contactsIn other respects, the specifications of the RE 16 board apply.<strong>2.</strong>5 AL 32 Operating environment and storageSupply voltage20 to 32 V DC, 0.5 A max., or 18 to 21 V AC, 0.5 A max.Degree of protection IP 20 (unprotected)Operating temperature +5 to +45 °CStorage temperature -20 to +50 °C (non-condensing)<strong>FF</strong>-<strong>Automation</strong> Oy


Page 2 - 526/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 3 - 126/10/20013. COMPONENT LAYOUTSAL 32DIJ1 Power input connectorJ2, J3 Connectors for digital outputsJ4, J5 Connectors for digital inputsJ8 Connector for expansion unitJ9 Connector for display/keypad unitJ11 Switch for batteryJ12 Switch for watchdogJ15, J16 Connectors for relay boardJ101 Connector for serial lineJ611 Test pointTP5, T24 Voltage pointsLD1-8, LD17-24 Indicator lights for dig. inputsLD9-16, LD25-32 Indicator lights for dig. outputsLD33 Operation indicator lightSW1 DIP switchIC1 ProcessorIC2 System program EEPROMIC3 Logic program EEPROMIC4 Data RAMB1 BatteryJ11B1J2J4J12J15LD9 LD11 LD13 LD15LD10 LD12 LD14 LD16J611SW1LD2 LD4 LD6 LD8LD1 LD3 LD5 LD7J8F1J101J1LD33TP5IC4 IC2 IC3RS485IC1J3J5J16LD25 LD27 LD29 LD31LD26 LD28 LD30 LD32TP24LD18 LD20 LD22 LD24LD17 LD19 LD21 LD23J9AL 32AN:In addition to the componentsof the AL 32DI:J206, 606, 607 Analog input/output selectionJ600 Connector for analoginput/output 0J601-605 Connectors foranalog inputs 1-5 (J601analog input 1, J602 analoginput 2, etc.)P201-212 AdjustmentpotentiometersAnaloginput012345OffsetP201P202P203P204P205P206P213 Analog outputadjustmentGainP207P208P209P210P211P212J11B1J2LD9 LD11 LD13 LD15LD10 LD12 LD14 LD16J4J611J15J12LD2 LD4 LD6 LD8LD1 LD3 LD5 LD7SW1J101J8F1J1IC4 IC2 IC3LD33RS485TP5IC1J9TP24J3LD25 LD27 LD29 LD31LD26 LD28 LD30 LD32J5J14J16LD18 LD20 LD22 LD24LD17 LD19 LD21 LD23J605J604P211 P205P212P206P210P204P601P600TP15P207P201 P209P203P208P202P213J603R 6 R 5 R 4R 1 R 2 R 3J600 J601 J602J206J606J607P600-601 Adjustment potentiometers for register variablesR1-6 Adapter modules for analog inputs (R1 analog input 1, R2 analog input 2, etc.)<strong>FF</strong>-<strong>Automation</strong> Oy


Page 3 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>AL32</strong>PLIn addition to the components of the AL 32DI:J501 Input conn. for pulse counter AJ502 Input conn. for pulse counter BJ503 Input conn. for pulse counter CJ504 Input conn. for pulse counter DJ505 Pulse counter supply connectorJ509, J510 Operating mode selector switchLD500 LED for pulse input AS1LD501 LED for pulse input AS2LD502 LED for pulse input BS1LD503 LED for pulse input BS2LD504 LED for pulse input CS1LD505 LED for pulse input CS2LD506 LED for pulse input DS1LD507 LED for pulse input DS2IC51 Counter for pulse input AIC52 Counter for pulse input BIC53 Counter for pulse input CIC54 Counter for pulse input DJ2J1J3J505 J504 J503LD9 LD11 LD13 LD15LD10 LD12 LD14 LD16F1LD25 LD27 LD29 LD31LD26 LD28 LD30 LD32LD506 LD504LD507 LD505J12TP5J11J611IC52IC57IC4 IC2 IC3B1SW1IC51IC56J509 J510J8IC1LD1 LD2 LD3 LD4 LD5 LD6 LD7 LD8LD33LD17LD18 LD19 LD20 LD21 LD22 LD23 LD24LD501 LD503LD500 LD502J4J101J9J5J501J502<strong>FF</strong>-<strong>Automation</strong> Oy


Page 3 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>AL32</strong>EXOJ10J10 Ribbon cable connector to basic boardJ2, J3 Connectors for digital outputsJ4, J5 Connectors for digital outputsJ6 Power input connectorLD20-57 Indicator lights for digital outputsLD37LD36LD35LD34LD33LD32LD31LD30LD27LD26LD40LD41LD42LD43LD44LD45LD46LD47LD50LD51LD25LD24LD23LD22LD21LD20J100J101010001J100J101Outputaddresses16 … 4748 … 7980 … 111LD52LD53LD54LD55LD56LD57<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 4 - 126/10/20014. SWITCHES4.1 Basic boards AL 32DI, AL 32AN, AL 32PLThe following switches are provided on all basic boards.DIP switch SW 1SW1654321IC4 IC2 IC3J8DIP ON O<strong>FF</strong>1 EEPROM not write protected EEPROM write protected2 Serial line:(Mode selected by R M 215 )- for controller printouts- Modbus- RCU (not in <strong>AL32</strong>PL)- programming deviceSerial line:Used for programmingDIP 300 bd 1200 bd 9600 bd Rate determinedby R M 22934O<strong>FF</strong>O<strong>FF</strong>ONO<strong>FF</strong>O<strong>FF</strong>ONONONDIP ON O<strong>FF</strong>NOTE: The systemprogram reads the DIPswitch settings and valuesof register memories229 and 215 after everyprogram cycle. Thismeans that settings suchas line communicationparameters can bechanged withoutswitching off.5 Data memory cleared whencontroller is switched on6 Program capacity for 4096locig instructions.Special EEPROMData memory retainedduring power failureProgram capacity for 2048locig instructions.If DIP switch 6 is in ONposition and EEPROMallows only 2048 instructions,PLC halts systemprogram execution.Pin strip J11<strong>FF</strong>-<strong>Automation</strong> Oy


Page 4 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ualPin strip J12J12Jumper as shown to activatewatchdog timerIC6Pin strips J610, J611, TP5, and TP24 are test points for service purposes.(See Chapter 3, Component layouts.)4.1.1 AL 32ANPin strips J206, J606, and J607I16I17J206 J607 J606321J600J600 is a normal analoginput (analog input 0, alsousable as a tempe-ratureinput)I16I17J206 J607 J606321J600Pins 71 and 74 of J600are an analog output, andpins 72 and 73 are ananalog input (I/U input).Pin strips TP15 and J14 are test points for service purposes. (See Chapter 3, Componentlayouts.)4.1.2 AL 32PLPin strips J509 and J510Counting mode selected by jumpers as follows:J509J5104x2x1x1 PHASETwo-phase signal:4x = 4 pulses per sensor signal cycle(jumpered as shown)2x = 2 pulses per sensor signal cycle1x = 1 pulse per sensor signal cycleSingle-phase signal:- up counting<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 4 - 326/10/20014.2 Expansion boards<strong>AL32</strong>EXAAnalog outputs 0 - 5 VAnalog outputs 0 - 10 VPin strip J14 is a test point for service purposes. (See Chapter 3, Component layouts.)<strong>AL32</strong>EXOThe addresses of the outputs on<strong>AL32</strong>EXO boards are defined byjumpers J100 and J101.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 4 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 5 - 126/10/20015. INDICATOR LIGHTS5.1 Basic boards AL 32DI, AL 32AN, AL 32PLAn amber LED indicator light indicatesthe functional state of thecontroller as follows:LIGHT PROGRAM STATE CAUSED BY ACTIONSteady light or dark, i.e.duty cycle 100 % or 5%Program halted.Outputs retain their statesProgram halted withprogramming deviceProgram can be startedwith START (!) characterSlow flashing (0.5Hz),duty cycle 50 %Program runningController is operatingnormallyCombined slow andfast flashing rateProgram runningUnsteady supply power.Flashing rate will return tonormal 4 minutes afterthe disturbance.Check quality of supplypowerFast flash,duty cycle 90 %Program halted.Outputs cleared to zeroLow supply voltage, hasfallen below 17 V and notrisen again over 20 VCheck 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 has been removed,or END instructionhas been relocated duringprogram executionSwitch controller poweroff and back on, correctthe program and startexecution<strong>FF</strong>-<strong>Automation</strong> Oy


Page 5 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ualEvery digital input and output line has an individual indicator light showing thestate of the line (lit = 1, dark = 0). The indicator lights are located adjacent to theappropriate input or output terminal strip (amber = input, red = output), as shownin the figure below.I0 I1 I2 I3 I4 I5 I6 I7O7O6O5O4O3O2O1O0I0 I1 I2 I3 I4 I5 I6 I7 GNDGND O7O6O5O4O3O2O1O05.2 Expansion boards AL 32EX and AL 32EXAAL 32EX: The digital inputs and outputs have indicator lights arranged in the sameway as on the basic boards.AL 32EXA:Indicator lights for supplyvoltages (+5 V adjacent toribbon cable connector,+24 V adjacent to terminalstrips)5.3 Expansion board <strong>AL32</strong>EXOThere are 32 binary outputs on<strong>AL32</strong>EXO board. Maximum 3bords can be connected to one<strong>AL32</strong> PLC. <strong>AL32</strong>EXO card can’tbe used with <strong>AL32</strong>EX or <strong>AL32</strong>EXAboards.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 126/10/20016. INSTALLATION AND CONNECTIONS6.1 Environmental requirementsBecause the inputs and outputs of the <strong>AL32</strong> series PLC are unprotected. The serialconnectors RS232 and parallel with is not isolated from PLC’s internal voltages. TheRS485 serial communication is isolated by aditional isolation module from PLC’s internalvoltages. To ensure proper function of <strong>AL32</strong> must the circumstances of installingplace be carefully considered.Operating temperature + 5 to + 45°CMoisture, corrosive gases, liquids and conductive dust may not exist in thespace, where PLC boards are installed.The PLC boards don't resist heavy vibration very well.The distance from electromagnetic fields generating devices, such as electricmotors, switch gears, thyristors, welding equipment switched power suppliesand power converters/inverters has to be wide enough.PLC boards are quite immune against light sources, but the possible erasingwindow on the system program EPROM has to be well covered.If some item above or any other feature in surrounding may cause errors to PLCfunction it is advisable to install the PLC in the steel plate enclosure. It is alsoad-visable to 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 with extinguishdiodes.6.2 Field wiring6.<strong>2.</strong>1 Earthing/groundingThe metal parts of the PLC enclosure must be connected to the plant’s logic ground.6.<strong>2.</strong>2 Power supply connectionsNormally no functional grounding is necessary when 24 volt floating voltage system isused with the PLC’s power supply connection. It is important that the 24 volt wiring iscarefully kept isolated from ground level and 230 volt supply voltages.The basic boards, AL 32DI, AL 32AN and AL 32PL receives the +24 V DC supplyvoltage from an external, isolated power supply unit (such as AL 9624/3.5 or AL9624/8). The controller converts this to the +5 V and +15 V supplies it requires.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ualThe pulse counters of the pulse counter board also require their own +5 V referencevoltage (from a separate power supply) or +24 V DC (from the power connector ofthe basic board), depending on the type of pulse sensors used.Expansion boards AL 32EX, AL 32EXA receive their +5 V supply voltage from thebasic board through the ribbon cable. The expansion boards further require a +15 Vsupply, which is generated on the expansion board from +24 V DC wired from thebasic board to the terminal strip of the expansion board.The expansion board <strong>AL32</strong>EXO receives + 5 V supply voltage from the basic board,the 24 VDC voltage for loads must be wired from external power supply unit.The +24 V DC supply voltage to the relay output boards is taken from an externalpower supply unit. The RE 16 board further requires a connection to the VDIODEterminal of the basic board.6.<strong>2.</strong>3 Digital inputsThe digital inputs are unisolated in <strong>AL32</strong> PLC series. Only potential free contacts orNPN type inductive/capacitive sensors may be connected to PLC. The supplyvoltage for the NPN sensors is normally taken from PLC's terminals.It is recommendedto use twisted pair shielded cables in input wiring. The cabling should beinstalled separate from the 220/380 VAC power cabling. The cable shields may beconnected to logic ground only at one point, normally at the end on the PLCencloseure.If there is heavy electromagnetic disturbances, the PLC's inputs andoutputs can be isolated from field equipments with relays or with optoelectronicsmodules. Look at chapter 6.3.1.6.<strong>2.</strong>4 Digital outputsThe digital outputs are unisolated in <strong>AL32</strong> PLC series. Only lowpowered 24 VDCcontrol relays, LED indicating lights or 24 volt indicating lights may be connected toPLC. The supply voltage for loads is taken from PLC's supply pwer unit.It isrecommended to use twisted pair shielded cables in output wiring. The cablingshould be installed separate from the 220/380 VAC power cabling. The cable shieldsmay be connected to logic ground only at one point, normally at the end on the PLCencloseure.If there is heavy electromagnetic disturbances, the PLC's inputs andoutputs can be isolated from field equipments with relays or with optoelectronicsmodules. Look at chapter 6.3.<strong>2.</strong>6.<strong>2.</strong>5 Analog inputs/outputsThe analog inputs and outputs are unisolated in <strong>AL32</strong>AN board. If active transducersare used, it should be checked that the output circuits of the transducers aregalvanically isolated from it’s supply voltages. If you can’t be sure of isolation, it isadvisable to furnish the transducer with an external galvanic isolator. The supplypower for passive transducer is normally taken from PLC’s power unit. Theimpedance of <strong>AL32</strong>AN PLC’s analog input is 2509<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 326/10/2001It is recommended to use twisted pair shielded cables in input/output wiring. Cablingshould be installed separately from the 230/400 VAC power cabling. Cable shieldsmay be connected to logic ground only at one point, normally at the end on the PLCenclosure.6.3 Connection examples digital inputs / outputsThere are 16 digital inputs and ouputs on <strong>AL32</strong>DI, <strong>AL32</strong>AN, <strong>AL32</strong>PL board andAL 32EX expansion board. Terminal strips and indicator LEDs are provided for thedigital inputs/outputs.6.3.1 Connecting binary inputsConnection potential free switch orNPN sensor to binary input6.3.2 Connecting loads to binary outputsThere are 16 binary outputs on <strong>AL32</strong>DI, <strong>AL32</strong>AN and <strong>AL32</strong>PL board.Terminal strips for 1x1,5 mm 2 wire are provided.Connection of load totransistor output+ 24VDC- 24VDC<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual6.3.3 Optoelectronic / relay isolation of inputs and outputsSince the inputs and outputs of the AL 32 series are not isolated, it is advisable toprovide external isolation in an environment prone to disturbances. A suitablesolution is the use of PHOENIX digital optical input interface modules and relayoutput modules. The Modules protect the PLC against the static discharges and cutthe circulating fault currents. The modules are mechanically fully protected DIN railunits.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 VAC10 - 125 VDC3 A24 V24 V24 V24 VOE modules are input modules and REL modules are relay output modules.PHOENIX modules: DEK-OE input module and DEK-REL type output module<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 526/10/2001The figure below shows how Phoenix DEK-... -interface modules may be connectedto <strong>AL32</strong> series PLC board’s input/output points.N (-)~ ( + )13141314DEK-REL-...SENDEK-REL-...SENA1A2A1A2A1A2DEK-OE-...VAC/DC+A0A1A2DEK-OE-...VAC/DC+A0~ ( + )N (-)FIELDPHOENIXDEK...CONTROL31 I000O00032 I001O001333435 J4J236373839 GND GND191817161514131211Power supplyAutoLogJ1+24VGNDGND+24VGNDVDIODE654321<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 626/10/2001AutoLog 32 Instruction <strong>Man</strong>ual6.4 Analog inputsThe AL 32AN board provides 2 register variables with screwdriver adjustment and0 - 6 individually adaptable analog inputs that can be used for the measurement oftemperature, current or voltage signals *). The AL 32EXA board provides 8 additionalindividually adaptable analog inputs. The number of available analog inputs isdefined according to adapter modules. Every measured signal / range needs its ownindividual adapter module (Look chapter 14. 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.Temperature measurement with a PT100 sensorThe current (I+ - I-) flows through the PT100 sensor.The measurement is made by inputs sign+ and sign-+-I+signsign+ThermistorKTY 10,11 or 15Temperature measurement with a KTY 10, 11 or 15thermistorGNDI-Voltage measurementTwo ranges are available: 0...5V or 0...10V.Current measurementTwo ranges are available: 0...20mA or 4...20mA.*) Exeption: Analog input 0. Jumpers J206, 606 and607 can be used to connect it as an analog input oroutput. If analog output 0 is in use, the remainingpins (connector J600) can only be used as a currentor voltage input.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 726/10/20016.4.<strong>2.</strong> Adjustment of the analog inputsOccasionally you might need to replace an input module of an <strong>AL32</strong> with a module foranother measurement range. In order to carry out the necessary adjustments youneed to proceede in the way described in chapter 16.6.4.3. Analog inputs of AL 32EXA boardIn order to read the analog inputs of the expansion board, you must load into thePLC's register memory R M 228 number 1. If you connect a EX32 board, the value is0 and in case of <strong>AL32</strong>EXA board the value is 1. The PLC's system program uppdatesall inputs and outputs every program cycle.6.4.4. Reading analog inputs by means of word variablesThe values of analog inputs on basic board are obtained in the form of word inputs(W I) as shown below (underlined bits).High byte0000xxxxLow bytexxxxxx00The analog input has a resolution of 10 bits. Its value is seen in steps of 4, as thenumbers 0, 4, 8, ..., 409<strong>2.</strong> If the value is desired in steps of 1 (0, 1, 2, ..., 1023),program as follows:STR W I 1DIV W C 4The table below shows the word input and register input variables corresponding tothe analog inputs.Analog input 0Analog input 1Analog input 2Analog input 3Analog input 4Analog input 5Analog input 6Analog input 7Word inputWord input 0Word input 1Word input 2Word input 3Word input 4Word input 5Word input 6Word input 7Register inputR I 0, R I 100R I 1, R I 101R I 2, R I 102R I 3, R I 103R I 4, R I 104R I 5, R I 105R I 6, R I 106R I 7, R I 107The values of the analog inputs (underlined bits)are obtained at the register inputs as follows:Example: R I 0 R I 100xxxxxxxx 0000xx00MSB LSB<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 826/10/2001AutoLog 32 Instruction <strong>Man</strong>ual6.5 Analog outputsThe AL 32AN board has one and the AL 32EXA has four analog outputs. Theanalog outputs are voltage outputs (0 - 5 V or 0 - 10 V).6.5.1 Connection examplesAL16AN or <strong>AL32</strong>EXA<strong>AL32</strong>AN: Analog input 0 can be changned into ananalog output by putting jumpers on connectorsJ206, J606, and J607 (refer to Chapter 4,SWITCHES).NOTE: Pins 72 and 73 can then still be used as acurrent or voltage input but not as a temperatureinput.6.5.<strong>2.</strong> Analog outputs of <strong>AL32</strong>EXA boardIn order to write into the analog outputs of the expansion board, you must load intothe PLC's register memory R M 228 number 1. If you connect a EX32 board, thevalue is 0 and in case of <strong>AL32</strong>EXA board the value is 1. The PLC's system programuppdates all outputs every program cycle.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 926/10/20016.6 Pulse inputsThe AL 32PL board has four pulse counters capable of counting at a rate of up to 100kHz. The signal to be counted can be either a single-phase pulse train, or atwo-phase signal, e.g. from an incremental sensor, with a 90 phase shift. With atwo-phase input signal the board can detect the direction of movement and separatea full cycle of the input signal into 1, 2, or 4 pulses. With a single-phase input signalthe counter always counts up. The counters are mutually independent.The current contents and pulse rates of the counters are available in the registermemories of the controller. The system program compares the momentary contentsof the counters with the end limits and preliminary limits set by the logic program. Theresults of the comparison are available in certain memory locations of the controller.The comparison results can also be sent direct to controller outputs. The updatingcycle time is then 5 ms on average, and 5.5 ms as a maximum. The pulse rate datais updated at intervals of 0.5 s.The input to each counter consists of four screw terminals for the two pulse signalsand supply power for the sensor.The logic program informs the system program whether the comparison data are sentdirect to controller outputs. The comparison results can in any case be seen in GM.NOTE: The fast program loop and the RCU function cannot be used on thepulse counter board.6.6.1 Connection of sensor signalsPower supplyNC NCSensor DDS2 DS1Sensor CCS2 CS124/5V GND 24/5V GND 24/5V GND 24/5V544 543 542 541534 533 532 531 524 523 522 521J505 J504 J503<strong>AL32</strong>PLJ501J502501 502 503 504511 512 513 514The pulse counters are reset by means of digital inputs I0 - I3 (by setting the inputsto "0"). The table below shows which input affects each counter.Counter A I0 Counter B I1Counter C I2 Counter D I3AS2 24/5V BS2AS1 GND BS1Sensor AGNDSensor B<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 1026/10/2001AutoLog 32 Instruction <strong>Man</strong>ual6.6.<strong>2.</strong> Using the countersThe system program updates GM memories GM0 ... 31 and register memoriesR M 64 ... R M 95 between the program cycles.GM 0GM 1GM 2GM 3GM 4GM 5GM 6GM 7GM 8GM 9GM 10GM 11GM 12GM 13GM 14GM 15GM 16GM 17GM 18GM 19GM 20GM 21GM 22GM 23GM 24GM 25GM 26GM 27GM 28GM 29GM 30GM 31CounterABCDSignificanceDistance > ToleranceDistance >Deceleration distanceDirection forward, i.e. the end point is aheadThe counter has been resetDistance > ToleranceDistance >Deceleration distanceDirection forward, i.e. the end point is aheadThe counter has been resetDistance > ToleranceDistance >Deceleration distanceDirection forward, i.e. the end point is aheadThe counter has been resetDistance > ToleranceDistance >Deceleration distanceDirection forward, i.e. the end point is aheadThe counter has been resetR M 66 - 64R M 67R M 70 - 68R M 71R M 74 - 72R M 75R M 78 - 76R M 79R M 82 - 80R M 83R M 86 - 84R M 87A Pulse rate BIN/BCD (0 - 400000)Distance from end point (0 - 255)Current counter content BIN/BCD (0 - 500000 - 999999)B Pulse rate BIN/BCD (0 - 400000)Distance from end point (0 - 255)Current counter content BIN/BCD (0 - 500000 - 999999)C Pulse rate BIN/BCD (0 - 400000)Distance from end point (0 - 255)Current counter content BIN/BCD (0 - 500000 - 999999)<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 1126/10/2001R M 90 - 88R M 91R M 94 - 92R M 95D Pulse rate BIN/BCD (0 - 400000)Distance from end point (0 - 255)Current counter content BIN/BCD (0 - 500000 - 999999)The following memory locations can be used to control the operation of the counters:GM 64GM 65GM 66GM 67GM 68GM 69GM 70GM 71GM 72GM 73GM 74GM 75GM 76GM 77GM 78GM 79GM 80GM 81GM 82GM 83GM 84GM 85GM 86GM 87GM 88GM 89GM 90GM 91GM 92GM 93GM 94GM 95A Comparison data to outputs O 0 - O 2Counter in BIN/BCD formatPulse rate in BIN/BCD formatCounter to be reset by next reset pulseSet counter contents to equal (RM 70 - 68)Start counterClear comparison outputs (O 0, O 1, and O 2)B Comparison data to outputs O 4 - O 6Counter in BIN/BCD formatPulse rate in BIN/BCD formatCounter to be reset by next reset pulseSet counter contents to equal (RM 78 - 76)Start counterClear comparison outputs (O 4, O 5, and O 6)C Comparison data to outputs O 8 - O 10Counter in BIN/BCD formatPulse rate in BIN/BCD formatCounter to be reset by next reset pulseSet counter contents to equal (RM 86 - 84)Start counterClear comparison outputs (O 8, O 9, and O 10)D Comparison data to outputs O 12 - O 14Counter in BIN/BCD formatPulse rate in BIN/BCD formatCounter to be reset by next reset pulseSet counter contents to equal (RM 94 - 92)Start counterClear comparison outputs (O 12, O 13, and O 14)The preliminary and end limits of the counters can be set with register memories R M 96 -R M 127. The values are transferred to the counters at the end of the program cycle.Counter A B C DR M 98 - 96R M 102 - 100R M 103R M 106 - 104R M 110 - 108R M 111R M 114- 112R M 118 - 116R M 119R M 122 - 120R M 126 - 124R M 127End pointDeceleration distanceEnd point tolerance<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 1226/10/2001AutoLog 32 Instruction <strong>Man</strong>ualThe system program makes the comparisons as follows:GM0 (=L0) := CA (EPA - TA) or CA (EPA + TA)GM1 (=L1) := CA (EPA - DDA) or CA (EPA + DDA)GM2 (=L2) := CA EPAGM8 (=L4) := CB (EPB - TB) or CB (EPB + TB)GM9 (=L5) := CB (EPB - DDB) or CB (EPB + DDB)GM10 (=L6) := CB EPBCX = Contents of counter XDDX = Deceleration distance of counter XEPX = End point of counter XTX = End point tolerance of counter Xwhere X is A, B, C, or D.GM16 (=L8) := CC (EPC - TC) or CC (EPC + TC)GM17 (=L9) := CC (EPC - DDC) or CC (EPC + DDC)GM18(=L10) := CC EPCGM24(=L11) := CD (EPD - TD) or CD (EPD + TD)GM25(=L12) := CD (EPD - DDD) or CD (EPD + DDD)GM26(=L14) := CD EPDCXEPXTXGM0, 8, 16, 24DDXGM1, 9, 17, 25GM2, 10, 18, 26The following program transfers the pulse count and count rate of counter A of the <strong>AL32</strong> to the AL 1093 Display and keypad unit. The counter is reset by means of input 0.STR R C 000EQ R M 240STR R C 001EQ R M 212STR C 001EQ GM 065EQ GM 066EQ GM 069PRT("COUNTER:",R M 70,R M 69,R M 68,,"f:",R M 66, R M 65&R M 64,,)STR I 000INVEQ GM 067STOPThe display will show:COUNTER:500000f:000000 12:30<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 1326/10/20016.7 Relay outputsEach type of relay output board has 16 relay outputs. The outputs are individuallyisolated on the RE 16 board, and groupwise isolated (8 + 8) on the RE 16H board.6.7.1 Connection examplesRE16:Connection of motors to relay outputsNominal Voltage250 AMax connecting Current 8 AMax continuous CurrentInto resistive Load 2 ARE16211 212 213 214220VAC~M220VAC~MRE16:Connection of motors to relay outputsNominal Voltage250 AMax connecting Current 8 AMax continuous Currentinto resistive Load 2 AThe total Current for Outputsin same galvanic Group mustnot exceed 8 ARE16H181182187188189 190MMMM220VAC~220VAC~<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 1426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual6.8 Serial communicationThe AL 32 series board has one RS232 serial connection. An additional RS485 conversionboard can be connected parallel with RS23<strong>2.</strong> Only one of these can be usedat a time. The function of serial communication is defined by DIP switch (SW1) andregister memories R M 215 and R M 229.6.8.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 N/C7 RTS8 CTS9 N/C6.8.2 Interconnection cablesIBM PC/XTCannon DB25STxD 2RxD 3CTS 5GND 7IBM AT/ TOSHIBA 1000Cannon DE9STxD 3RxD 2CTS 8GND 5MODEMCannon DE25PRxD 3TxD 2GND 7DTR 20DCD 8RTS 4CTS 5ORAL 32xxCannon DE9P2 RxD3 TxD4 DTR5 GND6* Required if correct operationalso in older <strong>AL32</strong> versionsAL 32xxis desiredCannon DE9P2 RxD3 TxD4 DTR5 GND6*AL 32xxCannon DE9P2 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


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 1526/10/20016.5.2 AL 323 and CNV-1 Signal level converter boardThe CNV-1 provides isolation of the serial communication signal and conversion ofthe voltage level of the signal. The signal level can be +5 V, RS-232C orRS-422/485. Isolation is neccessary when the devices communicating through theline are fed from power sources at differing potentials. The output of the RS-422/485inter-face is in a high-impedance state when not transmiting, and several PLC’s canthus be connected to the same bus. The communication cable to the CNV-1 boardcomes from the 9 pin SER1 (RS232) connector of the AL 3<strong>2.</strong>The CNV-1 signal level converter board is described in more detail in a separateinstruction: CNV-1.The figure below shows an example of the use of the CNV-1: the connection of AL 32controller via an RS-232C interface to RS422 board.AL 32AL 16AL 14board in PC<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 1626/10/2001AutoLog 32 Instruction <strong>Man</strong>ual6.6 Terminal strip numbering and power connection diagramsSupply Power Connection to <strong>AL32</strong> Basic and Expansion boards.Power Supply, such asAL9624/3,5 or AL9624/8GNDGNDO10..O17GNDI10..I17+24VDC*)*)This Connectionto be made whenOutput Loads areinductiveVDIODEGND24V outputGNDGND24V inputGNDO0..O7GNDI0..I7GND +24VDC392 391<strong>AL32</strong>EXATai+24VDCGND153 151152<strong>AL32</strong>EXVDIODE<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 1726/10/2001Terminal strip numbers and power connection to AL 32DI PLC board.Digital inputsDigital outputsI 000I 001I 002I 003I 004I 005I 006I 007GND313233343536373839J4J8SW1J2191817161514131211O 000O 001O 002O 003O 004O 005O 006O 007GNDJ101RS485LEDJ1654321+24 VDC inputGNDGND+24 VDC outputGNDVDIODEJ9I 008I 009I 010I 011I 012I 013I 014I 015GND414243444546474849J5J3292827262524232221O 008O 009O 010O 011O 012O 013O 014O 015GND<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 1826/10/2001AutoLog 32 Instruction <strong>Man</strong>ualTerminal strip numbers of AL 32AN Basic board.Digital inputsDigital outputsI 000I 001I 002I 003I 004I 005I 006I 007GND313233343536373839J4J8SW1J2191817161514131211O 000O 001O 002O 003O 004O 005O 006O 007GNDJ101LEDRS485J1654321+24 VDC inputGNDGND+24 VDC outputGNDVDIODEJ9I 008I 009I 010I 011I 012I 013I 014I 015GND414243444546474849J5Analog input/J607J606output I+71SIGN+ 720 SIGN- 73 J600I-74Analog inputsI+75SIGN+176SIGN-J601 77I-78I+79SIGN+ 802SIGN- 81 J602I-82Jumper plugs J206, J606, J607B C AJ206PXXX Analog trimmer potentiometersP213P207P201P208P202P209P203Measuring range modulesfor analog inputsJ600 is a normal analog input (analog input 0, also usable for Pt100/Kty10)P601P600P212P206P211P205P210P204J3J605J604J603102101100999897969594939291292827262524232221O 008O 009O 010O 011O 012O 013O 014O 015GNDAnalog inputsI-SIGN-SIGN+ 5I+I-SIGN-SIGN+I+4I-SIGN-SIGN+I+3Pins 71 and 74 of J600 are an analog output, and pins 72 and 73 arean analog input (I/U-input)<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 1926/10/2001Terminal strip numbers and power connection to AL 32PL PLC board.Digital inputsI 000I 001I 002I 003I 004I 005I 006I 007GNDJ4313233343536373839B1J611J11J2191817161514131211Digital outputsO 000O 001O 002O 003O 004O 005O 006O 007GNDJ12SW1J8J9J101LD33IC1IC4 IC2 IC3TP5F1J1654321+24 VDC inputGNDGND+24 VDC outputGNDVDIODEI 008I 009I 010I 011I 012I 013I 014I 015GNDPulse inputsAS1AS2GND+24/5VBS1BS2GND+24/5VJ5414243444546474849J501501502503504IC51IC56292827262524232221544543542541534533532531511 524512 523513 522514 521J502J503J509 J510IC52 IC57J504J3J505O 008O 009O 010O 011O 012O 013O 014O 015GNDPower supplyfor pulse inputs+24/5VGNDN/CN/CPulse inputs+24/5VGNDDS2DS1+24/5VGNDCS2CS1J509 and J510 select the operating mode of the counters<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 2026/10/2001AutoLog 32 Instruction <strong>Man</strong>ualTerminal strip numbers of AL 32EX expansion board.Inputs OutputsI 024 131129O 024I 025 132128O 025I 026 133127O 026I 027 134126O 027I 028 135125O 028I 029 136124O 029I 030 137123O 030I 031 138122O 031GND (24-31) 139121GND (24-31)I 032 141119O 032I 033 142118O 033I 034 143117O 034I 035 144116O 035I 036 145115O 036I 037 146114O 037I 038 147113O 038I 039 148112O 039GND (32-39) 149111GND (32-39)153152151GND+24 VVDIODETerminal strip numbers of AL 32EXA expansion board.Output 0 +- +Output 1 -+Output 2 - +Output 3 -I +SIGN +Input 0SIGN -I -I +SIGN +Input 1SIGN -I -I +SIGN +Input 2SIGN -I -I +SIGN +Input 3SIGN -I -301302303304305306307308311312313314321322323324331332333334341342343344J0J1J2J3J4J5M0M1M2M3P207P201P208P202P209P203P210P204J12321J11P213P217P216P215P214P212P206P211P205M7M6M5M4J10J9J8J7J6394393392391384383382381374373372371364363362361354353352351N/CN/CGND+24VinI -SIGN -SIGN +I +I -SIGN -SIGN +I +I -SIGN -SIGN +I +I -SIGN -SIGN +I +Input 7Input 6Input 5Input 4Analog input offset trimmers: P201-P206, P214, P216Analog input gain trimmers: 207-P212, P215, P217Analog output gain trimmers: P213Analog input selection modules: M0 -M7Analog outputs, switch J121- 2: 0 . . 10V2 - 3: 0 . . 5V<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 6 - 2126/10/2001Terminal strip numbers of AL 32EXO expansion board.J10LD37LD40LD36LD41LD35LD42LD34LD43LD33LD44LD32LD31LD30LD27J100J1010 01 00 1Outputaddress16 … 4748 … 7980 … 111LD45LD46LD47LD50LD26LD51LD25LD52LD24LD53LD23LD54LD22LD55LD21LD56LD20LD57<strong>FF</strong>-<strong>Automation</strong> Oy


Page 6 - 2226/10/2001AutoLog 32 Instruction <strong>Man</strong>ualTerminal strip numbers of RE 16 expansion board.RE16RE15J4245244243GND+24VVDIODEJ3J2RE14RE13RE12RE11RE10RE9RE8RE7RE6RE5RE4RE3RE2RE1J1242241240239238237236235234233232231230229228227226225224223222221220219218217216215214213212211O17O16O15O14O13O12O11O10O7O6O5O4O3O2O1O0Terminal strip numbers of RE 16H expansion board.RE16RE15J5202201GND24AC/DCRE14J4RE13RE12RE11RE10RE9J2200199198197196195194193192191COM1COM1O17O16O15O14O13O12O11O10RE8J3RE7RE6RE5RE4RE3RE2J1190189188187186185184183182181COM0COM0O7O6O5O4O3O2O1O0RE1<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 7 - 126/10/20017. RESERVED VARIABLE LOCATIONS7.1 Memories reporting on or controlling the operation of the PLCR M 128 to 191 Operating register memories of contollers / AL1095R M 206 Counter for accepted Modbus messagesR M 207 Send delay for Modbus response, default 50 ms = 50R M 208 The Version Code of connected Display/Keypad UnitR M 209 Character last received from keypadR M 210 Serial line data l<strong>eng</strong>th + parity in terminal modeR M 211 Test dataR M 212 Selection of language versionR M 213R M 214R M 215 Serial line mode: programming/terminal/printout/MODBUSR M 224 Three-position controllers: ReservedR M 225 Three-position controllers: Open bitsR M 226 Three-position controllers: Close bitsR M 227 Three-position controllers: Pulse intervalR M 228 Identification number of connected expansion boardR M 229 Serial line Baud rate 300/1200/2400/4800/9600/28800R M 230 Word variable: Multiplication/Division (MSB)R M 231 Word variable: Multiplication/Division (LSB)R M 232R M 233R M 234R M 235R M 236R M 237R M 238R M 239R M 240R M 241R M 242R M 243R M 244R M 245R M 246R M 247R M 248R M 249R M 250R M 251R M 252R M 253R M 254R M 255Character last received from user terminalPrevious character (last - 1) from user terminalPrevious character (last - 2) from user terminalPrevious character (last - 3) from user terminalPrevious character (last - 4) from user terminalPrevious character (last - 5) from user terminalPrevious character (last - 6) from user terminalPrevious character (last - 7) from user terminalSelection of display dataAccumulated POWFAIL interruptsClock settingAddress of PLC in computer communicationMultiplication high byte, Remainder (8 bit)Left half of digit displayRight half of digit displayClock/calendar: monthClock/calendar: day of monthClock/calendar: weekdayClock/calendar: hoursClock/calendar: minutesClock/calendar: secondsClock/calendar: six-minute units from midnightClock/calendar: year<strong>FF</strong>-<strong>Automation</strong> Oy


Page 7 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual7.<strong>2.</strong> Memory locations to be initializedR M 210 Terminal mode: data configuration0 8 bits, no parity1 7 bits, parity EVEN2 7 bits, parity ODD3 8 bits, parity EVEN4 8 bits, parity ODDR M 212 Selection of language version0 English1 FinnishR M 215 Serial line mode0 Programming device1,2 Terminal/printout4 MODBUS computer interfaceR M 228 Identification number of connected expansion board0 <strong>AL32</strong>EX1 <strong>AL32</strong>EXA2 <strong>AL32</strong>EXOR M 229 Serial line Baud rate0 300 Bd1 1200 Bd2 2400 Bd3 4800 Bd4 9600 Bd6 28800 Bd<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 7 - 326/10/2001R M 240 Display/keypad unit function mode0 Mode 0. Normal display mode2 Mode 1. Displays the contents of RM 245 and RM 246.4 Mode <strong>2.</strong> RM 245 and RM 246 controls 7 segment display.8 Mode 3. The left display = the content of RM 245 (charactersA ... F in hexadecimal format), the right display =content of RM 246 (numbers 0 ... 99)16 The whole display area is reserved for character output ( the unitdoes not show the time)32 The change of content of variables is disabled (the B key)128 The display is blocked (all output into the display is disabled,the last output remains)O 211 Function of the serial line (RS 323/RS 485, connector J101)0 The state of CTS handshake is shown in output O 209 andRTS handshake can be written into output O 208.1 PLC's system program controls handshake signals.7.3 Memory locations reserved for controllersRegister memory locations R M 128 - 191 are reserved for controller use, and locationsR M 224- 227 for three-point controller use. Refer to Chapter 9. CON-TROLLERS.With AL1095 display/keypad unit register memories 128 - 190 is used to displaygraphical objects ( 8 graphs). This means that if you use graph 0 you can’t use controller0 and so on.7.4 Memory locations reserved for pulse countersOn an AL 32PL board, register memory locations R M 64 - 127, GM locationsGM 0 - 31 and GM 64 - 95 are used for the pulse counter function.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 7 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 8 - 126/10/20018. DISPLAY/KEYPAD UNITSThere are several display/keypad units available for the AL 32 series PLC, all of whichcan be connected to the PLC board via I 2 C interface..8.1 AL1096 Display/Keypad UnitsAL 1096PS/PEAL 1096SAL1096T- 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 AL1095A/B Display/Keypad UnitsDIS1DIS10123LED1LED2LED3LED4LED5LED6LED7LED80 1 2 34 5 6 78 9 A BC D E FAL1095AAL1095B- Connection to PLC’s I 2 C bus by system cable, l<strong>eng</strong>th 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 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual8.3 AL1093 Display/keypad UnitsThere are three versions of the AL1093 unit. These are AL1093C, AL1093D andAL1093F. All AL1093 units have 2 x 16 character alphanumeric display, 16-key hexadecimalkeypad and 6 LED indicator lights. AL1093 units can be connected to anyAutolog PLC. In addition to displaying the values and time/date information, the AL1093unit can also display text (using the PRT instruction). The LCD display is backlit. Theclock and calendar functions are battery backed-up.All AL1093 models are front panel mounted and models D and F can be fitted withclient-designed face plate.AL1093C / D AL1093FDIS10 1 2 3 48 9 A B C5 6 7D E F8.4 AL1094 / R / AF Display/keypad UnitsThe AL1094 display/keypad unit withoutclock and calendar functions. It has a 4-digit 7-segment display, four LED indicatorsand a 4-key keypad. The unit can befitted with client designed face plate.04152637The AL1094R display/keypad unit without clockand calendar functions. It has 2 x 16 characteralphanumeric display, two LED indicators and a4-key keypad. In addition to displaying the valuesand time/date information, the AL1094R unit canalso display text (using the PRT instruction). Theunit can be fitted with client designed face plate.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 8 - 326/10/2001The AL1094AF 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 AL1904AF can display text (using the PRT instruction). The unit canbe fitted with client-designed front plate. Output O 236 = buzzer, output O 237 = controloutput for external indication light .AL1094AF8.5 Reading The KeypadR O 209:Example:The ASCII code of the last character from keypad is stored in the registermemory R M 209, when the keypad is connected to PLC’s I 2 Cconnector .PLC receives a character from keypad.STR R M 209 ; Read the character from keypadLES R C 000 ; If value 0EQ R RM 209 ; reset the bufferPRT R T ; and output the characterSTOPThe keypad status is stored in the bit ouputs O 240 ... O 255. When no key is beingpressed, all outputs are set to ‘0’. When a key is pressed, the output corresponding to thatkey is set to ‘1’. The keys and their corresponding outputs are shown below.Output 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255key 0 1 2 3 4 5 6 7 8 9 A B C D E F8.6 Control of LED IndicatorsThe LED indicators / other outputs from display are controlled by the bit outputs O 232 ...237. The LEDs and their corresponding bits are shown below.Output 232 233 234 235 236 237 238 239Led 0 1 2 3 4 5 6 7<strong>FF</strong>-<strong>Automation</strong> Oy


Page 8 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual8.7 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 theprevious line.HT (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 beginningof the next line.LF (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 the firstline.CR (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 that position.Ifthe cursor is at the beginning of a line, it goes to the end ofthe previous line.,"Y",,1B 5901 08Moves the cursor to line 1, column 8.Line 1...4, column 1...40, maximum numbers along displays.8.8 Display ModesAll display/keypad units have several display modes. Some modes are not availablefor every unit (e.g. those without clock and calendar functions and reduced keypads).The display modes are outlined below and defined by register output R M 240.R M 240:Content02481632128FunctionMode "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)Mode "6" display locked (doesn’t allow any changes in display )8.8.1 Normal display mode - Mode '0' (R M 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


AutoLog 32 Instruction <strong>Man</strong>ualPage 8 - 526/10/2001'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 memoryThe value of register variable is updated continuously into the display.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 AL1093, AL1094AF, AL1095)<strong>FF</strong>:<strong>FF</strong> R M 245 and R M 246 in hex D or F15:30 hours:minutes.... etc.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 8 - 626/10/2001AutoLog 32 Instruction <strong>Man</strong>ual8.8.2 Data Display Mode '1' [R M 240 = 2]This mode is available for all models. In this mode the contents of R M 245 and R M 246are sent to the display. In this mode it is not neccessary use the ‘D’ key to change thedisplay mode (as with mode ‘0’) each time after power-up.Example: I 000 connects the display control program and the contents of R M 245 andR M 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 M 240 ; chosen for displaySTR I 000 ; set input on (=ON)STR R C 002 ; the control code for mode '1' isEQ R SM 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.8.3 7-Segment mode - mode '2' (R M 240 = 4)This display mode is available only for the AL1094 with 7-segment display. In this modeR M 245 controls the right hand side of the 7-segment display, so that seven of the eightbits controls a segment each, and the eighth bit controls the minus sign as shown in thediagram below.R M 245: bit 7 6 5 4 3 2 1 0segment x g f e d c b aSegments are illuminated by writing the sum of the corresponding values into R M 245Segment Number Segment Numberabcd1248efgx163264128For example, to display segments e, cand d, the sum of corresponding numbers(16+8+4=28) should be written intoregister output R M 245.STR R C 028EQ R O 245 ; Display segments e, c and d8.8.4 Text Display Mode ‘4’ (R M 240 = 16)This mode is available only for the AL1094R, AL1093, AL1094AF and AL1095 with alphanumericdisplays. The entire display will be reserved for text produced by the PRTinstruction.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 8 - 726/10/20018.8.5 Normal Mode with Key 'B' Function Disabled. Mode ‘5’ (R M 240 = 32)This mode is available only for the AL1094F/R, AL1093C/D/F and AL1095 models withalphanumeric displays. The unit functions otherwise normally but the changes of contentof variables are disabled.8.8.6 Display Lock Mode ‘6’ (R M 240 = 128)This mode is available only for the AL1094R, AL1093C/D/F and AL 1095A/B with alphanumericdisplays. Current display information will be retained and no changes will beallowed.8.9 Program examples8.9.1 Printing Date InformationSTR I 001EQ M 000STR DP 000 ; printPRT R M 248 ; datePRT T .@ ; pointPRT R M 247 ; monthPRT T .19@ ; point and hundreds of yearPRT R M 255 ; year ( 0 - 99)8.9.2 Real Time Control with R O 253 (6 minutes from midnight)STR R M 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.9.3 Display Step Registers 0 and 1 (0 ... 99)STR R C 002 ; set register outputs R O 245 and 246EQ R M 240 ; display mode '1' valueSTR R S 000 ; read step register’s 0 step into register accumulatorBCD; convert to BCD formEQ R M 245 ; save the value into display variableSTR R S 001 ; read step register’s 1 step into register accumulatorBCD; convert to BCD formEQ R M 246 ; save the value into display variableSTOP<strong>FF</strong>-<strong>Automation</strong> Oy


Page 8 - 826/10/2001AutoLog 32 Instruction <strong>Man</strong>ual8.9.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.9.5 Setting 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 SM 242 ; transfer time to real time clockSTR S 001 ; if in stepSTR R C 001EQ R SM 242 ; disable reading of real time clockSTR R C 001 ; check if reading of real time clockEQU R M 242 ; is disabledAND P 000 ; pulse, interval 0.1 secondSTEP T ; go to next stepSTR R C 96 ; set yearBCD R TEQ R M 255STR R C 3 ; set monthBCD R TEQ R M 247STR R C 10 ; set dayBCD R T ; of monthEQ R M 248STR R C 9 ; set hourBCD R T ; part of timeEQ R M 250STR R C 25 ; set minuteBCD R T ; part of timeEQ R M 251CONTSTOPSequences 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


AutoLog 32 Instruction <strong>Man</strong>ual Page 9 - 126/10/20019. CONTROLLERS9.1 Register memories of controllersThe system software of the AL 32 Programmable Logic Controller includes eightDirect Digital Controllers (DDC) with PID characteristics. The controller parameters areheld in register memories.ControllerNo.12345678StatusActualvalueSetpointDtimeItimeGaintermOutputAux.128136144152160168176184129137145153161169177185130138146154162170178186131139147155163171179187132140148156164172180188133141149157165173181189134142150158166174182190135143151159167175183191Register memories R M 128, 136...184 indicate to the controller program if thecontroller is in operation, in manual or automatic mode, or not in operation. This isdetermined by the lowest two bits as follows:0 controller not in operation1 controller operating in automatic mode3 controller operating in manual modeFor example, in order to activate controller No. 2 in automatic mode, the number '1' iswritten into register memory R M 136. The contents of register memory R M 142 willfrom then on be generated in accordance with the control algorithm and parameters.Three-point control outputs will also be written into register memories R M 225 and226.The controller program computes the control algorithm once and then leaves thecontroller in manual mode (for example, in the case of controller No. 2, by writing '3'into R M 136). This is done in order to allow the user to determine the control interval.If the logic program continually writes '1's into the status memory, the control intervalwill be the shortest possible, or 0.8 seconds.If it is desired to control the controller output either from the terminal or with the logicprogram, the sequence in the logic program where '1' is written into the status memoryis removed. Return to automatic control will not cause a bump in the controller output,because the controller program continually monitors the output.If a controller is deactivated by writing '0' into register memory R M 136, the remainingregister memories for that controller, R M 137 - 143 became available for otherpurposes.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 9 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual9.2 Control algorithmThe following control algorithm is used:DY = P * {e( t i ) - e( t i-1 ) + D * [ e( t i ) - 2e( t i-1 ) + e( t i-2 )] + e( ti )/ l }P = gain (0 - 1)I = integration time constantD = differentiation time constante = errorGain PThe numerical value 128 corresponds to a gain of 0.5.Figure 1 Figure 2Figure 1P = 100 P = 150I = 20 I = 20D = 2 D = 2Figure 2P = 100 P = 20I = 2 I = 2D = 2 D = 2Set pointOutputFigure 1 shows how increasingthe gain gives faster controlaction.Figure 2 shows how reducingthe gain stabilizes the oscillationcaused by a short integration time.The sum of the proportional, derivative and integral terms is multiplied by the gain P.The gain thus weakens or str<strong>eng</strong>thens the effects of these coefficients.Effect of integration time constant IFigure 1 Figure 2Figure 1P = 150 P = 150 P = 150I = 20 I = 12 I = 12D = 2 D = 2 D = 2Figure 2P = 100 P = 100 P = 100I = 120 I = 12 I = 2D = 2 D = 2 D = 2Set pointOutput<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 9 - 326/10/2001The figures show the behaviour of the same process for two different values of gainP, and varying integration time I. If the gain is high, an overshoot will take place even ata longer integration time.If the integration time I is too short for the process in question, an oscillation of the typeshown in the right-hand figure will occur.Effect of differentiation time constant DThe effect of the differentiation time is critical, as illustrated in the figures below.Derivative control is unsuitable for many types of systems, and it is often not at allnecessary to use it.D = 0 D = 2 D = 5 D = 109.3 Controller typesSet pointOutputThe figure below shows how the resulting control output of the different basic controllertype varies with time after a step change.t t tP controller PI controller PID controller- The P controller has constant gain, and the result is often unsatisfactory, especially ifthe gain is low.- In PI control the apparent gain changes and corrects the error with time.- In PID control the variations of the error are exaggerated in order to obtain rapid errorcorrection. The step response becomes faster.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 9 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual9.4 Controller tuningIn a control system, suitable values must be found for the controller parameters P, I,and D. Suitable parameters for a control loop can be determined by purely mathematicalmethods or by means of a Bode diagram, but these methods are often laborious.Usually, controllers are tuned on the basis of experimental data from the controlsystem. Two simple and effective methods are described below.- The step response method: The delay and rise time of the step responseof the process are determined, and thecontroller settings are determined on this basisT t U 0P controller: U P = = cT s Y 0PI controller:U P = 1.25 cT I = 3 T tPID controller: U P = 1.25 cT I = 3 T tT D = 0.42 T t- The oscillation method: The gain and oscillation cycle time at the point ofoscillation are determined, and the controller settingsare determined on this basis.P controller:PI controller:PID controller: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 theprocess oscillatesT cr = cycle time of process oscillationThese methods yield reasonable starting points for the controller parameter values;these can then be refined as necessary during actual operation.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 9 - 526/10/2001A special program is provided for controllers. This AR program runs on IBM PC compatiblecomputers. The program simulates analog and three-point controllers. The controlleroperation can be monitored with "recorders", and the resulting graphs can bestored on disk. The program is accompanied by an operating manual, which alsocontains general information on controllers.The PLC programming program (ALPro) can also be used for monitoring controllervariables, collecting historical data, and for documentation.9.5 Three-point controllersAll controllers also provide three-point control outputs in the form of bit data in registermemories R M 225 and 226.ControllerNo.12345678Close outputR M 225 bit01234567Open outputR M 226 bit01234567The pulse interval, i.e. the dead time that the controller will wait for the processresponse to settle, is programmed into register memory R M 227. The time range is from0.1 s to 25.5 s, corresponding to the numbers 1 - 255. Register memory R M 224 isreserved for internal use by the controller program.A typical application, controlling the temperature of the circulating water in a centralheating system, is illustrated on the next page.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 9 - 626/10/2001AutoLog 32 Instruction <strong>Man</strong>ualThe mixing valve is controlled by pulses driving the actuator motor. The dead time in anapplication of this kind can be several seconds, as a change in the water temperaturewill not be immediately felt by the sensor. It is pointless to give further drive pulses tothe valve before the settled effect of the previous action is known. The dead time can beaccounted for when tuning the controller by means of the step response method.Example Temperature control of circulating water by 3-point control.Desired value R I 002Actual value R I 001Mixing valveBoilerO 001 'open'O 002 'close'Logic program for water heating:STR R C 050 ; Integration time (50/255*1500 s)EQ R M 140STR R C 002 ; Differentiation timeEQ R M 139STR R C 110 ; Gain (110/255*2)EQ R M 141STR R I 002 ; Set point, e.g. from a potentiometerEQ R M 138STR R I 001 ; Actual value from temperature sensorEQ R M 137STR P 001 ; Keep controller in automatic modeSTR R C 001 ; with one second pulseEQ R SM 136STR R C 010 ; Pulse interval 1 sEQ R M 227STR R M 226 ; Read 'open' bitsBIT M 020 ; Convert to bits (controllers 1 - 8)STR M 021 ; Use bit for controller 2EQ O 001 ; to open valveSTR R M 225 ; Read 'close' bitsBIT M 020 ; Convert to bitsSTR M 021 ; Use bit for controller 2EQ O 001 ; to close valveSTOP<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 10 - 126/10/200110. DATA COMMUNICATIONSThe AL 32 board has an RS-232C level connector for data communication (a 9-pin DINtype connector) and parallel with it a module isolated RS485 connector (J400). The datacommunication operating mode is determined by means of a DIP switch and registermemories. The used connector (J101/J400) is selected with jumper. The switches canbe set to override the effect of the register memories.Refer to Chapter 4. SWITCHES.B1SW1IC4IC2LD2 LD4 LD6 LD8LD1 LD3 LD5 LD7J8LD33IC1J4J101RS485Register memory Effect AlternativesR M 215 Operating mode 0 = programming device1,2 = terminal / printout4 = MODBUS computer bus (slave)2 or 4 = modemR M 229 Baud rate 0 = 300 Bd1 = 1200 Bd2 = 2400 Bd3 = 4800 Bd4 = 9600 Bd6 = 28800 BdThe following items should be checked, if serial communication is not working:Settings of DIP switchSetting of R M 229Setting of R M 215Setting of DIP switch 2( R M 229 setting is active only if swithces 3 and 4 are in 'on' position)( Be sure that the baud rate is correct)( Check that operating mode is correct)( DIP switch 2 selects if the serial connection is used for communicationor for programming)( Check that you connected the wires correctly)( If CNV-1 is used)Cable connectionsCNV-1 jumpersModem settings and connections, if one is usedSubstation's address ( In R M 243, address is decimal number)<strong>FF</strong>-<strong>Automation</strong> Oy


Page 10 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual10.1 Terminal / PrintoutThe characters received from the serial line are available for reading in registermemories R M 232 - 239 as follows:RegistermemoryR M 232R M 233...R M 239ContentLast character receivedLast but one.... etc.Last but 7thBy using PLC’s PRT instruction PLC’s application program can print characters into theserial port for printer or modem etc.10.2 MODBUS CommunicationThe MODBUS protocol allows the Programmable Logic Controller to be connected tothe serial line of a computer or another PLC (e.g. AL 2000). In this serial connection, theAL 32 always operates as the slave.Before the bus is used, certain settings must be made at the PLC. Thus, if the addressof the PLC is 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 memories:R M 215 = 4 ; ModeR M 243 = 2 ; AddressThe serial line has the following characteristics:- asynchronous- RS-232C (or with CNV-1, RS-422 with high-impedance output)- 1 start + 8 data + 2 (1) stop bits (Transmission 2, receive 1 stop bits)- rate 300/1200/2400/4800/9600/28800 Bd10.<strong>2.</strong>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 or memory03 Read register outputs or memories 15 Write binary outputs or memoriesor read word outputs or memories 16 Write register outputs or memories04 Read register inputs 08 Loop back test return- slave addresses 1 - 255, and address 0, which the slave recocnizes for functions 5,6,15 and 16.( sending write commands to address 0 means broadcasting to all slaves)<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 10 - 326/10/2001- Error CheckingAll MODBUS communication is subject to the following error checks on slave unit:- CRC16 Checksum - Command Validity Check- Address Validity Check - Message L<strong>eng</strong>th Check- Framing Check - Message Integrity CheckMessages may be transmitted at rates of 300,1200,4800,9600 or 28800 baud. Thecomposition of the message frames is shown below:SLAVEADDRESSFUNC-TIONMEMORYADDRESSDA- TA CRC16CHECKSUMSTART(1 bit)DATA( 8 BITS)STOP(2 bits)- a pause of about 50 milliseconds indicates end of message- response time to command:The message is processed between program cycles, and the time will thus vary; inad-dition there is a delay of 0.1 - 2 s depending on the message l<strong>eng</strong>th and baud rate.- Modbus parameters:R M 215 ; Serial line mode (4 = Modbus slave)R M 229 ; Baud rate (4 = 9600 Bd)R M 207 ; Send delay for Modbus response (milliseconds); default 50 milliseconds (= 50)R M 206 ; Counter for accepted Modbus messagesWhen the Modbus slave mode is defined, the system program set the data configurationto 8 bits, NONE parity, 2 stop bits on transmission and 1 stop bit on receive.The register variables (R M, R I, R O) are 8-bit variables, but they are transferred as16-bit words with the high byte set to zero.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 10 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ualBinary outputs and memories as well as register outputs and memories are distinquishedfrom each other by means of the Modbus data address, such that references tomemory variables are 1024 = 400H higher in the address 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 address conversion istransparent when AL 2000and AL16AN PLCs areused 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 OperationModbusreadModbuswriteAddressOffsetAddress inControl softwareAddress inFCS softw.Binary output (O)Binary memory (M)General memory (GM)Binary memory (BM)Binary input (I)Register input (R I)Register output (R O)Register memory (R M)Word output (W O)Word memory (W M)Word input (W I)Additional word memory (W M)Additional word output (W O)Step register010101010204030303030403030305, 1505, 1505, 1505, 1506, 1606, 1606, 1606, 1606, 1606, 1606, 16010242048307200010242048307210247168614481920000101025020490307300001000014000141025420494307331025471694614548193SDO 0001SDO 1025SDO 2049SDO 3073SDI 0001SAI 0001SAO 0001SAO 1025SAO 2049SAO 3073SAI 1025SAO 7169SAO 6145SAO 8193RS485 data communication, connector J9 (pins D-, D+ and GND), should be activatedin same way as RS232C data communication, but binary output O 211 must be set on.When output O 211 is on the PLC system program can control the direction of data flow.When O 211 is on, RTS-, CTS-handshakes are also activated for RS232C-communications.When O 211 is off, the PLC's application program can read CTS state from output O 209and write the RTS state to output O 208. With this selectable feature the PLC'sapplication program can control the behaviour of the output device, when the PLC's PRTinstruction is used.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 10 - 526/10/200110.3 Modem - AL 32Two-wire carrier modems are typically used on dialled lines in the public telephonenetwork. Modems to the following CCITT recommendations are suitable for ProgrammableLogic Controller applications:* V.22 (1200 bit/s)* V.22bis (2400/1200 bit/s)* V.32 (9600/4800 bit/s)If it is desired that the Programmable Logic Controller should be able independently tocall, for example, the central control room, the modem must be of the auto-dialling type,using the "AT" command set (alternatively V.25bis).PRT commands of the PLC are used for dialling a telephone number, for example:ATDP 123456. The modem gives the "CONNECT" response when a connection hasbeen successfully set up. The details of the "AT" command set can be found in themanual of the modem.Transmission errors are not uncommon in the telephone network at speeds higher than1200 bit/s. If PRT commands are used for data transmission, rather than an errorcorrectingprotocol such as Modbus, it is advisable to use an error-correcting modem, ortake other precautions against disturbances caused by transmission errors.Only type approved modems may be connected to the public telephone network!CONTROLsoftwareAL 32MODEMMODEMDial-upConnection<strong>FF</strong>-<strong>Automation</strong> Oy


CP U2000SDIC32DC AIC8 DIC32DCPage 10 - 626/10/2001AutoLog 32 Instruction <strong>Man</strong>ualBaseband modems are mostly used on short distance connections (telephone cablel<strong>eng</strong>th not exceeding 15 km). A 4-wire connection is generally used, allowing thenetwork to be branched.ControlsoftwarelMasterMODEMRS-232CRxTxPrivatenetworkRS-232CpermanentlineTx Rx Tx Rx Tx RxModemDS 28565 4 7 2 38 7 5 3 2serial connectornumberingModemModemDS 2856 DS 285655AL 16ANAL 32AL 2000Slave 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 supply arrangementsof the modems with a view to battery back-up.AL2000AL 32SRM-64-wirelineSRM-6MODEMMODEMmax.15kmAutoLog 2000I n order touse a modem with the Programmable Logic Controller, the data communi-cationprotocol (R M 215 = 2 or 4) and the transfer rate (R M 229) of the PLC must first bedefined.The sample program on the next page shows how the PLC can contact the modem.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 10 - 726/10/2001STR R C 000 ; Commands in EnglishEQ R M 212STR R C 002 ; Terminal communicationEQ R M 215STR R C 001 ; 1200 BdEQ R M 229STR S 000 ; Set up connectionAND I 000STEP S 001 ; Dial numberSTR S 001PRTSTEP S 002EQ R RM 232EQ R RM 233EQ R M 000("ATE0V0DP123456",)NEXT S 002 030 ; Timeout control in case of errors.NEXT S 003 060STR S 004STEP S 001STR R M 232 ; Check if connectionEQU R C 013 ; has been madeAND S 002STEP S 010STR R M 233EQU R C 049AND S 010STEP S 011STR S 011 ; Data transferPRT ("<strong>AL32</strong> 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 015AT = character structure and speed sampleD = diallingP = pulse, T = toneE0 = no echo, V0 = digit responces (not words)PRT ("ATH0",)STEP S 016EQ R RM 232EQ R RM 233NEXT S 016 005 ; PLC begins to waitSTR R M 232 ; for the next callEQU R C 013AND S 017STEP S 019AND S 019STEP S 000NEXT S 017 005 ; If call was not successfullySTR S 018 ; cleared, repeat hang-up procedureSTEP S 012STOP<strong>FF</strong>-<strong>Automation</strong> Oy


Page 10 - 826/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 11 - 126/10/200111. OPERATION OF THE PROGRAMMABLE LOGICCONTROLLER11.1 Switching on and special supply conditionsThe incoming supply power is smoothed and any spikes are suppressed. The events immediatelyafter switching on and in response to supply voltage variations are describedbelow.Voltage, UMax.+32 V+24 V+20 V(b+17 V+14 V(c1. <strong>2.</strong> 3. 4.5.(aTime, s1. Bit outputs are at zero (cleared).<strong>2.</strong> The chopper circuit starts; the supply voltage is converted to a +5 V regulated supply forthe logic processor and the rest of the electronics. The POWFAIL signal from the voltagemonitor is active.3. The POWFAIL signal is deactivated. The logic processor does not start regular programexecution until POWFAIL has been inactive for at least 600 ms.4. The Programmable Logic Controller operates normally.If the supply voltage falls below +17 V for any reason, the Programmable Logic Controllerresponds as follows:5. The POWFAIL signal is activated. The logic processor suspends normal operation and awaitsthe development of the supply voltage, and the power fail counter (R M 241) is incremented by 1.a) The supply voltage falls below +14 V.The Reset signal stops the processor and protects the memory circuits (reset light is on).b) The supply voltage falls below +17 V and rises again to a value above +20 V withinless than 20 ms.The logic processor resumes program execution. Power fail counter (R M 241) isincremented by 1 to indicator a brief power interruption.The indicator light on thebasic board flashes at a combined slow (0.5 Hz) and fast (5 Hz) rate for 4 minutes.c) The supply voltage falls below +17 V but not below +14 V and rises again to a valueabove +20 V within a longer time than 20 ms.The logic processor stops program execution, all outputs of the PLC are cleared,and the logic processor flashes the indicator light at a very fast rate while awaitingthe return of supply power. When the supply voltage again rises, the logicprocessor resumes program execution in the same way as after an ordinary switch-on,but flashes the indicator light at a combined slow and fast rate for 4 minutes.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 11 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual11.2 Start of program executionWhen the PLC is started, bit memories 0-63, bit outputs 0-39, register outputs 0-31,timers, counters, and step registers 4-7 are cleared, and depending on the position ofthe SW1 switch DIP 5 on the board, bit memories 64-191, bit outputs 64-191, step registers8-31, register outputs 32-255, register memories, shift registers and word variablesare also cleared. If SW1 switch DIP 5 is in position that defines to save the register andword memory values and there is no battery backup, the memories gets random valuesand the function can be very strange after power failure.Next, the logic program stored in an EEPROM is transferred to RAM memory.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 memoriesthrough which the logic program can tell:−−−what the serial interface is to be used for, if not programmingthe Baud rate of the serial interface, if not defined by the switchesthe language selection, English or Finnish.All kinds of communication in the PLC (computer, Modbus, user terminal) can commenceafter the second program cycle.The bit accumulator is '1' at the start of the first two program cycles, and zero for allfurther cycles.11.3 START commandWhen program execution is initiated with the START command from the programmingdevice, the following takes place:−−−−the states of outputs and memories remain unchangedthe logic program is transferred from the EEPROM to RAMthe logic program is checked, and started if it is OK.after the second program cycle the parameters are read from the registermemories.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 11 - 326/10/200111.4 Remedies for problem situationsProblems with the cooperation of the programming device and the PLC:- Set SW1 switch DIP 2 on board to 0 (O<strong>FF</strong>).- Set the Baud rates of the programming device and the PLC to the same value with DIPs3 and 4.- Check the type of the interconnection cable.- If the programming device is an IBM PC or equivalent, the correct programming program to use isALProWin or ALPro (previously AL, the on-line program - not AX).- When using the AL program, remember to use CAPITALS, i.e. to have Caps Lock ON.- Check the operation of serial communication by pressing CLR (N). One program line or an errormessage must appear on the screen; if the AL program is used, a program line or an error messageshould also appear at the bottom of the screen.- Check that the correct serial port is used in PCs (COM1/COM2).- Check that supply power for the programming device is taken, as far as possible, from the sameoutlet/phase/fuse as for the PLC.Switch off both the PLC and the PC for a moment and restart them.The instructions/variables PRT, P, GM cannot be found in the AL program; operation isotherwise normal.- An alternative keyboard arrangement is being used (KEYBxx program), which "misplaces" someof the characters required for programming.- Any missing ASCII codes can be found by pressing + + to restore thedefault (US) keyboard. Now try the characters \, [, ], + on the keyboard. Press + + to restore the alternative keyboard.- In the beginning of every progran cycle the register accumulator holds the value of program cycletime in milliseconds<strong>FF</strong>-<strong>Automation</strong> Oy


Page 11 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 12 - 126/10/20011<strong>2.</strong> PROGRAMMING(Paragraph 1<strong>2.</strong>1 discusses the available alternative programming methods. Since separate documentationis provided for the programming programs, they are only briefly outlined below.The other paragraphs describe the internal features of the Programmable Logic Controller; thisinformation also applies to terminal programming.)1<strong>2.</strong>1 Programming methodsThe programming device can be any IBM compatible PC computer or a dump terminal.The program is transferred through the programming cable to the PLC. When programmingwith a PC, the AlPro programming program is used. With the programming program,the PLC program 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 tothe PLC). The built-in programming features of the PLC are utilized during terminalprogramming.The <strong>AL32</strong> Programmable Logic Controller incorporates a programming program(information on the operation of instructions and commands) and an RS-232C interface.Accordingly, the following alternative programming methods are available:- the ALProWin programming program- the ALPro programming program- a terminal- a PROM programmerA complete program for the PLC can be produced using a terminal, but it is decidedlyeasier to write, edit and otherwise handle a program with the programming programALProWin or ALPro, which run on a personal computer. The programming program 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 EEPROM memory. When a logic program istransferred from the PLC to a programming device, the program is first stored from RAM to EEP-ROM, and then transferred to the programming device.The logic program is stored in an EEPROM memory circuit. When power is applied to the ProgrammableLogic Controller, the program is read into RAM for execution.1<strong>2.</strong>1.1 Programming with a PROM programmerWhen a number of PLCs with identical functions are required, programming is easiestto do by duplication. First program one PROM using one of the programming programsor a terminal and then copy the finished program into the program memories of the remainingPLCs with a PROM programmer.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual1<strong>2.</strong>1.2 Programming with ALProWin/ALProThe program, with comments, is first written in plain text form using the text editor ofALProWin. (Any other text editor producing ASCII text will do just as well.) The programis then compiled with ALProWin compiler into a form that the Programmable LogicController understands, stored on a diskette, and transferred into the memory of the PLCwhen desired.Further features of ALProWin: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.ALProWin contains HELP screens describing the functions in discrete Help file.Available in English language versions.A free version of the program, ALProWin-demo or ALPro-demo, is also available (similarto ALProWin / ALPro proper, but the l<strong>eng</strong>th of the program that can be written is limited)as well as a manual (ALProWin / ALPro Programming manual).1<strong>2.</strong>1.3 Fast program loopA fast program loop can be written into the Programmable Logic Controller 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 l<strong>eng</strong>th 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 END instructionare deleted, added, or changed.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 12 - 326/10/20011<strong>2.</strong>2 AL 32 variables1<strong>2.</strong><strong>2.</strong>1 One bit variablesI Input, 32 off. Numbered from 00 to 15 and from 24 to 39.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.O Output, 32 off. Numbered from 00 to 15 and from 24 to 39.ouputs 040 - 255 can also be used as one-bit auxiliary memory.NOOne’s complement of output.SM, SB, SG, SL Conditional set of memory or output, 256 off. Used in conjunction with EQ instruction.RM, RB, RG, RL Conditional reset of memory or output, 256 off. Used in conjunction with EQ instruction.DP Change of auxiliary memory from 0 to 1, 64 off. Numbered 00 - 63.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, 64 off. Numbered 00 - 63.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.TTimer, 80 off. Numbered 00 - 79. The resolution and range ofthe timers varies as follows:resolutionrangeT 00 - 03 10 ms 0,02 to 2,55 sT 04 - 07 100 ms 0,2 to 25,5 sT 08 - 15 1 s 2 to 255 sT 16 - 79 100 ms 0.2 to 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 00 to 15. The counters count down;their range is 255 . . 0.In the PRT instruction C refers to to a numerical value.1<strong>2.</strong>1.2 Register variables or 8 bit variablesR IRegister input, 8 off. Numbered from 00 to 07. Used as analog inputs.R NIOne’s complement of register input.R M Register memory, 256 off. Numbered from 000 to 255.The registers are 8 bits wide. Some of the registers are reserved for special uses.R NMOne's complement of register memory.R ORegister output, 1 off (R O 0); reg. outputs 001 - 255 can be used as aux. memories.R NOOne's complement of register output.R SMConditional setting of register memory. Used in conjunction with the EQ instruction.R SOConditional setting of register output. Used in conjunction with the EQ instruction.R RMConditional resetting of register memory. Used in conjunction with the EQ instruction.R ROConditional resetting of register output. Used in conjunction with the EQ instruction.R TRegister timer. Identical with the timers listed above; T or R T is used asthe variable according to the instruction. Also refers to the register accumulatorin some instructions.R CRegister constant 000 - 255 (decimal), except register counter with the READ andLOAD instructions. C or R C is used as the variable according to the instruction.Q Queue, 4 off. Numbered from 0 to 3. The queue l<strong>eng</strong>th 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 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual1<strong>2.</strong><strong>2.</strong>3 Word variables or 16 bit variablesW IWord input, 8 off. Numbered from 000 to 007. Used as (10-bit) analog inputs.W M Word memory, 2048 off. Directly addressable numbered from 000 to 255.Indirectly addressable 1536 pcs (ONI and STI instructions). Certain addressesoverlaps with FIFO storages. The memories are 16 bits wide.Memories 000 to 127 overlap register memories 000 to 255.W O Word output, 1024 off. Directly addressable numbered from 000 to 255.Indirectly addressable 512 pcs (ONI and STI instructions). Certain addressesoverlaps with queue storages. The memories are 16 bits wide.Word outputs can be used as auxiliary memories.W SMConditional setting of word memory.W SOConditional setting of word output.W RMConditional resetting of word memory.W ROConditional resetting of word output.W TWord accumulator.W CWord constant 0 - 9999 (decimal).NOTE! Refer to chapter 15 at the end part of this manual:- AL 32 series PLC’s memory and I/O map- AL 32 series PLC’s data retention during power failure1<strong>2.</strong>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 32 Instruction <strong>Man</strong>ual Page 12 - 526/10/20011<strong>2.</strong>4 <strong>AL32</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 I/M/O/NI/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 - 626/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 32 Instruction <strong>Man</strong>ual Page 12 - 726/10/2001 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 <strong>2.</strong>08 ;Turn on outputs <strong>2.</strong>15 and <strong>2.</strong>09<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 826/10/2001AutoLog 32 Instruction <strong>Man</strong>ual BYT I/M/O/BM/GM nOperation Converts 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 32 Instruction <strong>Man</strong>ual Page 12 - 926/10/2001 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. 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 DCD R I/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<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 1026/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 32 Instruction <strong>Man</strong>ual Page 12 - 1126/10/2001 DIV R I/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 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 NoExample STR W M 025DIV W C 01040 DIV W I/M/O nOperation Divide 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 011ENDOperationLast 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 - 1226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 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 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 R M/O 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 32 Instruction <strong>Man</strong>ual Page 12 - 1326/10/2001 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 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 - 1426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 32 Instruction <strong>Man</strong>ual Page 12 - 1526/10/2001 EQU R I/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 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 NoExampleW M 001EQU W C 01000EQ O 001 ;There may be severalEQU W C 02000 ;successive comparisonsSTR 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.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 1626/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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.CAUTION! The FCN instruction must not be used in the fast program loop!BA RA WA VariableAffected Yes No Yes Non 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 msBefore 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 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


AutoLog 32 Instruction <strong>Man</strong>ual Page 12 - 1726/10/2001 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 I/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 - 1826/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 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 executedCONTIF 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<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 12 - 1926/10/2001 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 - 2026/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 I/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 0.001 ;When analog input 01LES W C 06000 ;is less than 6000,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 32 Instruction <strong>Man</strong>ual Page 12 - 2126/10/2001 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 - 2226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 I/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 32 Instruction <strong>Man</strong>ual Page 12 - 2326/10/2001 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 - 2426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual MIN R I/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 RM 244.BA RA WA VariableAffected No Yes No NoExample STR R M 000MUL R C 002<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 12 - 2526/10/2001 MUL R I/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 - 2626/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 I/M/O/NM/NO nAutoLog 32 Instruction <strong>Man</strong>ual Page 12 - 2726/10/2001OperationSets 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 - 2826/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 32 Instruction <strong>Man</strong>ual Page 12 - 2926/10/2001 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 I/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 - 3026/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 32 Instruction <strong>Man</strong>ual Page 12 - 3126/10/2001 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 - 3226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 <strong>2.</strong><strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page 12 - 3326/10/2001 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 <strong>2.</strong>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 - 3426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 l<strong>eng</strong>th 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 l<strong>eng</strong>th 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 32 Instruction <strong>Man</strong>ual Page 12 - 3526/10/2001 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 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 - 3626/10/2001AutoLog 32 Instruction <strong>Man</strong>ualSTOPOperationLast 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 NoSTPOperationThe 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 32 Instruction <strong>Man</strong>ual Page 12 - 3726/10/2001 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 C dOperation Reads 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 I/M/O/NM/NO 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 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 - 3826/10/2001AutoLog 32 Instruction <strong>Man</strong>ual 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 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


AutoLog 32 Instruction <strong>Man</strong>ual Page 12 - 3926/10/2001 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 R I/M/O/NM/NO nOperationSets 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 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 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<strong>FF</strong>-<strong>Automation</strong> Oy


Page 12 - 4026/10/2001AutoLog 32 Instruction <strong>Man</strong>ualSubroutinesThe 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 of themain program is not executed at all. If there is a CSR call for a subroutine that does not exist, the PLCinterpretes 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 subroutineRETOperationAffectedExampleThe 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 EQI instruction from word accumulator or from WM 105.STI W M InAddrr ; Read value to be scaledEQ W M 104STR C 001 ; set bit accumulator to 1CSR 001 ; call subroutine 1STR W M 105EQI W M AddressSTP; main program end...SBR 01 ; start of subroutine 1STR R M 100 ; scaling parameters start addressSTR C 001 ; set bit accumulator to 1STR W M 104 ; variable to be scaledFCN 010 ; call scaling functionEQ W M 105 ; save the result to WM 105RET...STOP<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 12 - 4126/10/20011<strong>2.</strong>5 Terminal programming commandsADDRWRITEINSREADNEXTCLRDELPREVSTARTSTOP(HIN)(HOUT)LISTFINDDISPInitiates input of a program address (= number of a program line). The address is enteredas four octal digits. When the address is complete, <strong>AL32</strong>AN outputs the instructionat the address given, or gives the 'ERROR 010' message to indicate that there is noAL 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 l<strong>eng</strong>th (for example, if oneof them is a timer setting instruction), the programming program 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 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 at it. If there are programlines in memory with no AutoLog instructions, the programming program 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 - 4226/10/2001AutoLog 32 Instruction <strong>Man</strong>ualThe programming program reacts to an incorrect key operation with a tone signal (for example,WRITE before the instruction is complete). Keying mistakes can be correctedwith the CLR (N) key.Normally the program runs all the time. If changes are to be made to the program, it isadvisable to halt it with the STOP key while making the changes. The program is startedwith the START key. The STOP and HIN commands halt execution of the program. TheWRITE, INS, DEL, LIST, FIND, and HOUT commands halt execution until the functionhas 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.1<strong>2.</strong>6 Programming pointerThe programming program keeps track of the address of the program memory locationcurrently affected by programming operations (the programming pointer). The programmingpointer can be located by pressing the CLR key (the program address, i.e. the programline number, and the instruction will be displayed). If there is no AutoLog instructionat this address, the 'ERROR 010' message is given.The address can be changed by typing a new address or by stepping forwards or backwardsin the program. The address is also automatically updated when an instruction iswritten into memory or deleted.The ADDR key moves the cursor to the start of the desired program line. The programline number is entered as four octal digits (0 - 7), whereupon the programming programdisplays 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 either direction,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 32 Instruction <strong>Man</strong>ualPage 12 - 4326/10/20011<strong>2.</strong>7 Entering an instruction in memoryTo 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, the displaywould 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 <strong>2.</strong>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 and displaysthe program line.If the new and the old instruction differ in l<strong>eng</strong>th in the case of the WRITE command, andalways when the INS command is used, the programming program moves the instructionson subsequent lines of the program forwards or backwards as required. The STOPinstruction 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.1<strong>2.</strong>8 Deleting an instruction from memoryTo delete instructions from the program, use the DEL command (M). First place the programmingpointer at the instruction to be deleted and then press the READ key (V). TheDEL command will now delete the instruction in question and move back all subsequentinstructions as far as the STOP instruction, to fill the gap left by the deleted instruction.Example:Text 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 - 4426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual1<strong>2.</strong>9 Locating an instruction in a programFIND 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 program will displaythe 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.1<strong>2.</strong>10 Listing the programIf 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 programming programwill output the program in mnemonic format up to the STOP instruction. Output canbe stopped by hitting the space bar [ ]. (The programming pointer will not be moved awayfrom the starting point by the LIST operation.)1<strong>2.</strong>11 Storing the programA program written into the program memory of the AutoLog 32 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.1<strong>2.</strong>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 the indicatorlight 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 STOP instructionsin program memory). This condition can be remedied by switching the PLC off andback on again. Since no STOP instruction can be found in memory, the programmingpointer will now stop at the first program line where no AutoLog 32 instruction is found.Enter a STOP instruction on this line.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 12 - 4526/10/2001To 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 remaining programlines are still intact), and the new program can now be written over the old one.1<strong>2.</strong>13 Monitoring the operation of a programWhen 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 stateof the 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).1<strong>2.</strong>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 = 1<strong>2.</strong>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 is enteredas the current value of the timer/counter. Switch SW1 selects whether setting valuesare 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 - 4626/10/2001AutoLog 32 Instruction <strong>Man</strong>ualExample: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 <strong>2.</strong>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.1<strong>2.</strong>14 Fast program loopA fast program loop can be written into the Programmable Logic Controller for executionat timer interrupts, at intervals of 5 ms. The executable program of the loop starts as programline 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 l<strong>eng</strong>th 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 END instructionare deleted, added, or changed.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 12 - 4726/10/20011<strong>2.</strong>15 Special keys and corresponding ASCII charactersInstr. Käsky ASCII HexVar. Muuttuja ASCII HexSTRANDORXOREQSTOPLOADREADDCRIFCONTINVPRTNOPSTEPNEXTSTRJATAIETAIONSTOPASLUEVHJOSJTKINVPRTNOPSTEPSEURASDFGHJKL,./\ (Ö)[ (Ä);:4153444647484A4B4C2C2E2F5C5B3B3AINIONOMNMSOROSMRMBMNBSBRBGMNGSGRGDPDNPTCSQFTETLELMEMSLRLSMRMBMEBSBRBGMEGSGRGDPDNPANSJFQWU*ER>


Page 12 - 4826/10/2001AutoLog 32 Instruction <strong>Man</strong>ualTAB/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


Page 13 - 126/10/2001AutoLog 32 Instruction <strong>Man</strong>ual<strong>FF</strong>-<strong>Automation</strong> Oy13. TABLES13.1 ASCII-codescharacterASCII codeHexcodedecimalcodecharacterASCII codeHexcodedecimalcodecharacterASCII codeHexcodedecimalcodeNULSOHSTXETXEOTENQACKBELBSHTLFVT<strong>FF</strong>CRSOSIDLEDC1DC2DC3DC4NAKSYNETBCANEMRSUBESCFSGSRSUSSP!"#$%&‘()*000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A00010203040506070809101112131415161718192021222324252627282930313233343536373839404142+,-./0123456789:;?@ABCDEFGHIJKLMNOPQRSTU2B2C2D2E2F303132333435363738393A3B3C3D3E3F404142434445464748494A4B4C4D4E4F50515253545543444546474849505152535455565758596061626364656667686970717273747576777879808182838485VWXYZ[ (Ä)\ (Ö)](Å)^_`abcdefghijklmnopqrstuvwxyz{ (ä)| (ö)} (å)~DEL565758595A5B5C5D5E5F606162636465666768696A6B6C6D6E6F707172737475767778797A7B7C7D7E7F8687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127


Page 13 - 226/10/2001<strong>FF</strong>-<strong>Automation</strong> OyAutoLog 32 Instruction <strong>Man</strong>ual13.2 Decimal/Octal conversionsdec.codeoctalcodedec.codeoctalcodedec.codeoctalcodedec.codeoctalcodedec.codeoctalcodedec.codeoctalcode0001020304050607080910111213141516171819202122232425262728293031323334353637383940414243444500010203040506071011121314151617202122232425262730313233343536374041424344454647505152535455464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990915657606162636465666770717273747576771001011021031041051061071101111121131141151161171201211221231241251261271301311321339293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137134135136137140141142143144145146147150151152153154155156157160161162163164165166167170171172173174175176177200201202203204205206207210211138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183212213214215216217220221222223224225226227230231232233234235236237240241242243244245246247250251252253254255256257260261262263264265266267184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229270271272273274275276277300301302303304305306307310311312313314315316317320321322323324325326327330331332333334335336337340341342343344345230231232233234235236237238239240241242243244245246247248249250251252253254255346347350351352353354355356357360361362363364365366367370371372373374375376377


AutoLog 32 Instruction <strong>Man</strong>ualPage 14- 126/10/200114. LIST OF AL 32 PRODUCTS14.1 Basic BoardsCode Designation DescriptionDI - DO - AI -AO - PC901007 <strong>AL32</strong>DI 16 - 16901028 <strong>AL32</strong>AN 16 - 16 - 6 - 1 *)901006 <strong>AL32</strong>PL 16 - 16 - 0 - 0 - 4DI = Digital InputDO = Digital OutputAI = Analog InputAO = Analog output*) Analog input 0 can be used as ananalog output plus an I/U input14.2 Expansion boards901010 <strong>AL32</strong>EX 16 - 16 - 0 - 0901034 <strong>AL32</strong>EXA 0 - 0 - 8 - 4901018 <strong>AL32</strong>EXO 0 - 32 - 0 - 014.3 Analog input modules901058 0 to 20 mA Current input901059 4 to 20 mA Current input901078 0 to 5 V Voltage input901080 0 to 10 V Voltage inputNOTE When ordering analogboards, please specify the types andranges of inputs and outputs desiredPt100, Resolution (°C) Temperature rangeKTY10 AL16 AN <strong>AL32</strong>EXA901050 0.125 0.5 0 to + 127.5 °C Pt 100901052 0.125 0.5 0 to + 255.0 °C Pt 100901054 0.125 0.5 - 40 to + 87.5 °C Pt 100901074 0.25 1 - 55 to + 200.0 °C Pt 100901076 0.25 1 125 to + 380.0 °C Pt 100901090 0.125 0.5 - 20 to + 107.0 °C Kty 10, 11, 15901092 0.125 0.5 - 40 to + 87.5 °C Kty 10, 11, 15901094 0.1 0.4 0 to + 10<strong>2.</strong>3 °C Kty 10, 11, 15901095 0.1 0.4 - 40 to + 6<strong>2.</strong>3 °C Kty 10, 11, 15901096 0.2 0.8 - 40 to + 164.7 °C Kty 10, 11, 15901097 0.1 0.4 0 to + 10<strong>2.</strong>3 °C Pt 100901098 0.1 0.4 40 to + 6<strong>2.</strong>3 °C Pt 100901099 0.5 2 - 50 to + 461.5 °C Pt 10014.4 Analog outputs901060 0 to 5 V Voltage output901061 0 to 10 V Voltage output14.5 Converters for serial communication901157 AL485 RS-485 conversion module, optic isolated901225 CNV1 Signal converter board, RS232 RS422/485, full/half duplex903190 CNV-2 RS232 RS485 half duplex conversion module (RJ45)<strong>FF</strong>-<strong>Automation</strong> Oy


Page 14 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual14.6 Accessory boards900860 AL1093F Clock and Calendar/Display/Keypad 2x16 Characters, 16 Function Keys901017 AL1093D Clock and Calendar/Display/Keypad (With Surface Mounting Plate)2x16 Characters, 16 Function Keys901017 AL1093DC Clock and Calendar/Display/Keypad (for Customers front Plate)2x16 Characters, 16 Function Keys901023 AL1094 Display/Keypad901019 AL1094R Display/Keypad900870 AL1094F Clock and Calendar/Display/Keypad (for Customers front Plate)900850 AL1095A Clock and Calendar/Display/Keypad, 16 keys900855 AL1095B Clock and Calendar/Display/Keypad, 4 keys902172 AL1096/S Graphic Display (240 x 128), 5 function keys902174 AL1096/T Graphic Display (240 x 128), touch screen (10 x 8)902178 AL1096PS STN Graphic Display/Touch Panel (320 x 240), 40x30 Switches902180 AL1096PE STN Graphic Display/Touch Panel (320 x 240), 40x30 Switches, Centr.14.7 Power supplies901383 AL9624/3.5 24 V DC/3.5 A power supply901380 AL9624/8 24 V DC/8 A power supply901462 AL6405 Power supply for CNV-114.8 Programming cables941172 ALC2 Programming cable PC - AutoLog, l<strong>eng</strong>th 2 m941173 ALC5 Programming cable PC - AutoLog, l<strong>eng</strong>th 5 m941510 AL9042 Cable AutoLog(D9P) - CNV1, l<strong>eng</strong>th <strong>2.</strong>5 m941177 Cable Modem(D9P) - AutoLog(D9P), l<strong>eng</strong>th <strong>2.</strong>5 m901179 Cable AutoLog(D9P) - Radiomodem(D15P), l<strong>eng</strong>th 2 m903194 Cable CNV2 - AutoLog (RJ45), l<strong>eng</strong>th <strong>2.</strong>5 m14.9 Programming software941020 ALProWin 1.x ALProWin programming software for Windows941004 ALPro3.x programming program ALPro 3.x for Dos941010 ALPro update update from program AL/AX or ALG to ALProWin 1.x / ALPro3.x941011 ALPro update update from ALPro1(2).x to ALPro3.x14.10 Other Programs941060 MODBUS RTU Development Kit for PC906611 Modbus Analyser906603 Modbus Test Program for PC, Dos<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 15 - 126/10/200115. LIST OF INSTRUCTIONSSTR I/O/NI/NO nSTR M/BM/GM/NM/NB/NG/P nSTR DP/DN nSTR S dSTR R I/M/O/NI/NM/NO nSTR R C dSTR R S nSTR C nSTR Q nSTR W I/M/O nSTR W N dAND I/M/O/NI/NM/NO nAND BM/GM/NB/NG/DP/DN/P nAND S dAND R I/M/O/NI/NM/NO nAND R C dAND W I/M/O nAND W C dOR I/M/O/NI/NM/NO nOR BM/GM/NB/NG/DP/DN/P nOR S dOR R I/M/O/NI/NM/NO nOR R C dOR W I/M/O nOR W C dXOR I/M/O/NI/NM/NO nXOR BM/GM/NB/NG/DP/DN/P nXOR S dXOR R I/M/O/NI/NM/NO nXOR R C dXOR W I/M/O nXOR W C dEQ M/O/BM/GM nEQ R M/O nEQ SM/SO/SB/SG nEQ RM/RO/RB/RG nEQ R SM/SO nEQ R RM/RO nEQ W M/O nEQ W SM/SO nEQ W RM/RO n 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 I/M/O n PLU R C d PLU W I/M/O n PLU W C d PLD R I/M/O n PLD R C d PLD W M/O n PLD W C d MIN R I/M/O n MIN R C d MIN W I/M/O n MIN W C d MID R I/M/O n MID R C d MID W M/O n MID W C d MUL R I/M/O n MUL R C d MUL W I/M/O n MUL W C dINVDIV R I/M/O nDIV R C dDIV W I/M/O nDIV W C dDCD R I/M/O n<strong>FF</strong>-<strong>Automation</strong> Oy


Page 15 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ualLOAD T n dLOAD C n dLOAD R T/C nLOAD Q n dSTEP TSTEP S dSTEP R TREAD T/C nREAD S nREAD R T/C nREAD F nSTI I/M/O/BM/GM nSTI R M/O nSTI W M/O nEQI M/O/BM/GM nEQI R M/O nlEQI W M/O nCLO R M/O nBYT I/M/O/BM/GM nBIT M/O/BM/GM nDCR C nENDNEXT S d eSTOPEQU R I/M/O nEQU R C dEQU W I/M/O nEQU W C dGRT R I/M/O nGRT R C dGRT W I/M/O nGRT W C dLES R I/M/O nLES R C dLES W I/M/O nLES W C dSHR Q n dSHL Q n dRES Q nRES F nFIN F nFOU F nFCN nCSR nPRT CPRT T cccccPRT R TPRT R C dPRT R I/M/O nSBR nRETSTP<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 15 - 326/10/2001COMMANDS OF AUTOLOGEnglish 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 C NPLU PLU S SPRT PRT F FREAD LUE Q JRESRESRET RET Variable typesSBRSBRSHL SHL R RSHR SHR W W<strong>FF</strong>-<strong>Automation</strong> Oy


Page 15 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ualCOMMANDS OF AUTOLOGFinnish 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 TPRT PRT N CRES RES S SRET RET F FSBR SBR J JSEURNEXTSHL SHL Variable typesSHRSHRSTEP STEP R RSTI STI W W<strong>FF</strong>-<strong>Automation</strong> Oy


<strong>FF</strong>-<strong>Automation</strong> OyINI39241507164ONOMNMGM BM255 255 255 255192 192 192 19264632423161564630 0 0 0R O, R NO R M, R EMR SO, R RO R SM, R RM25564 6463 63255Will retain their status durignpower failure if desiredWill be reset afterpower failureState not affected bypower failureT R T, Tstate actual value1587430W O1023stateC R C, Cactual value150W M 128-2047W M2047S31...10Q3210F76543210P210TR TW TIndirectly addressableword memories 2048 pcs,word outputs 1024 pcs,(instructions STI and ONI)AutoLog 32 Instruction <strong>Man</strong>ual255255R IR NI702610W I700W M 0-1270R M 0-255The behaviour of AL 32memories on power failure.Addresses in decimal26/10/2001Page 15 - 5


O MNO NMSO SMRO RM255 255GM BM255 2551 bit aux.memoriesDP and DNstates alsoavaliable fromthese memoriesS7...43...0PThe memory map of AL 32Addresses in decimal26/10/2001Page 15 - 664 0 12 0 1 255<strong>FF</strong>-<strong>Automation</strong> OyINI392415039241506300 0R O, R NO R M, R NMR SO, R RO R SM, R RM255 255T R T, Tstate actual value15MSB of 10 bitanalog input8 bit aux.memoriesC R C, Cstate actual value15RESERVED REGISTER MEMORIESR M R M R M R M63874301271912550J3210F76543210252 253 2540 1 252 253 254 255W O, W SOW M, W SMW ROW RM10232047W M 128-2047TR TW TAutoLog 32 Instruction <strong>Man</strong>ualR IR NI5000064128192reserved for PIDcontrollersreserved for systemprogram255WI50 0W M 0-1272550R M 0-255W M 1W M 0R M 3R M 2R M 1R M 0LoHiLoHi


AutoLog 32 Instruction <strong>Man</strong>ualPage 16 - 126/10/200116. Instructions for the adjustment of the analoginputs of <strong>AL32</strong>AN and <strong>AL32</strong>EXAAll analog inputs are adjusted in the factory to be in accordance with the measuringrange indicated on the input measurement modules. In case you need to change theinput measurement module to another you have to make an adjustement procedure inorder to ensure that the <strong>AL32</strong>AN or <strong>AL32</strong>EXA is providing you with the right information.In this chapter you are guided through the complete procedure step by step for alldifferent types of analog inputs.Note! If you need to adjust the inputs of the expansion unit <strong>AL32</strong>EXA you have first towrite the <strong>AL32</strong>EXA board identification number in R M 228 and download it to the<strong>AL32</strong>AN. The system program of <strong>AL32</strong>AN transfers the analog inputs on the <strong>AL32</strong>EXAunit to the Register Input Variables RI 08...RI 15.16.1 Adjustment Potentiometers on the <strong>AL32</strong>AN and <strong>AL32</strong>EXA boards:<strong>AL32</strong>AN<strong>AL32</strong>EXAInput O<strong>FF</strong>SET GAIN Test pin J14 Input O<strong>FF</strong>SET GAIN Test pin (J14)0 P201 P207 2 0 P201 P207 21 P202 P208 3 1 P202 P208 32 P203 P209 4 2 P203 P209 43 P204 P210 5 3 P204 P210 54 P205 P211 6 4 P205 P211 65 P206 P212 7 5 P206 P212 78 (GND) 8 (GND)6 P600 9 6 P214 P215 97 P601 10 7 P216 P217 10Inputs 6 and 7 on the <strong>AL32</strong>AN board are potentiometer adjustable register inputs. They can beused e.g. to provide timers with srew driver adjustment.16.2 <strong>AL32</strong>AN:The values of analog inputs on the <strong>AL32</strong>AN board are obtained in the form of word inputs(W I) as shown below (underlined bits).High byte0000xxxxLow bytexxxxxx00The analog input has a resolution of 10 bits. Its value is seen in steps of 4, as the numbers0, 4, 8, ..., 409<strong>2.</strong> If the value is desired in steps of 1 (0, 1, 2, ..., 1023), program asfollows:STRW I 001DIV W C 004EQ W M 001<strong>FF</strong>-<strong>Automation</strong> Oy


Page 16 - 226/10/2001AutoLog 32 Instruction <strong>Man</strong>ualThe table below shows the word input and register input variables corresponding to theanalog inputs on the <strong>AL32</strong>AN board.Word inputRegister inputAnalog input 0 W I 0 R I 0, R I 064Analog input 1 W I 1 R I 1, R I 065Analog input 2 W I 2 R I 2, R I 066Analog input 3 W I 3 R I 3, R I 067Analog input 4 W I 4 R I 4, R I 068Analog input 5 W I 5 R I 5, R I 06916.3 <strong>AL32</strong>EXA:The values of analog inputs on the <strong>AL32</strong>EXA board are obtained in the form of registerinputs (R I). The analog input has a resolution of 8 bits.The table below shows the register input variables corresponding to the analog inputchannels on the <strong>AL32</strong>EXA board.Analog input 0 R I 08Analog input 1 R I 09Analog input 2 R I 10Analog input 3 R I 11Analog input 4 R I 12Analog input 5 R I 13Analog input 6 R I 14Analog input 7 R I 15Register input16.4 What is needed for the adjustmentYou need the ALPro or ALPro2 software, a PC, an accurate mA-meter, an accurateV-meter and a adjustable resistance reference (decade resistor).For making the readings of the analog inputs you have to use the PC and the ALProsoftware. For the adjustement of the analog inputs of the basic <strong>AL32</strong>AN only oneinstruction has to be downloaded to the <strong>AL32</strong>AN; the STOP instruction. For theadjustement of the analog inputs on the <strong>AL32</strong>EXA you have first to write the <strong>AL32</strong>EXAboard identification number in R M 228 and down load it to the <strong>AL32</strong>. The systemprogram of <strong>AL32</strong> transfers the analog inputs on the <strong>AL32</strong>EXA unit to the Register InputVariables RI 08...RI 15.Through ALPro Debug-function you can see the values of all inputs as well as theregister inputs where you have the information of the analog inputs on the <strong>AL32</strong>EXAboard.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 16 - 326/10/200116.5 How to read the input values using the PC and ALPro (DOS version)1 Connect the <strong>AL32</strong> to the PC and start the ALPro software.2 Write the following program:STR W I 000DIV W C 004EQ W M 000STR R C 001EQ R M 228STOPThis program was made only for the analog input 0. If you wantto include all the analog inputs at once you can add the similarinstructions for all the rest of the analog inputs.R M 228 contents the identification number of <strong>AL32</strong>EXA board.3 Compile the program by choosing Compile from the main menu.4 Transfer the program to the PLC by choosing Write prog to PLC from the submenu.5 Choose Debug from the main menu.6 Choose Start/Stop from the Debug main menu.7 Choose Start F7 from the submenu. Now you have started the execution of theprogram you have written before. Check on the PLC that the status LED is blinking.In the Debug window you can see your program on the left hand side. On theright hand side you can follow certain variables. You have to select which variablesyou want to watch.8 Choose Watch from the main menu9 Choose Add variable from the sub menu10 A box appears on the screen. Write W M 0 in the box and press 11 Press F9 in order to start the updating of the values you want to watch. On theright part of the screen you can see:; W M 0= 0002 (the numbers depend on the real input value); R I 8 = 120 (this is for the <strong>AL32</strong>EXA)In case you have written a program for watching all of the analog inputs at thesame time you have to add all the necessary watch lines for all the analog values.12 Now you can start the adjustment procedure<strong>FF</strong>-<strong>Automation</strong> Oy


Page 16 - 426/10/2001AutoLog 32 Instruction <strong>Man</strong>ual16.6 Current inputsYou need to have an adjustable current source and a mA meter with enough accuracy(0.1%). Connect the adjustable current source to the analog input number 0 (terminals+sign and -sign). Input module from 0 to 20 mA.Analog input 0J600I-SIGN-SIGN+747372Adjustablecurrent sourceNote!This refers to the AnalogInput number 0. For otherinputs check the numberof the potentiometer inthe table on page 16 - 1.I+71MmA1 Adjust the current source to the lowest value in the measuring range(0 mA or 4 mA) using the mA-meter.2 Check the O<strong>FF</strong>SET point value. It should be near zero value, not greaterthan <strong>2.</strong> The O<strong>FF</strong>SET point can't be changed.3 Adjust the current source to the highest value (20 mA) using the mA-meter.4 Adjust the GAIN by turning the potentiometer P207 until you can seethe value 1023 (255 for <strong>AL32</strong>EXA) in the PC.With current modules (0 - 20 and 4 - 20 mA) only gain (P207) is adjustable.Proceede to the following Analog Input Channel and repeat the procedure described.Table for offset valuesModule Offset Maximumrange current currentvalue 0 mA 20 mA0 - 20 mA < 2 (8) 1023 (4092)4 - 20 mA < 2 (8) 1023 (4092)<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 16 - 526/10/200116.7 Voltage inputsYou need to have an adjustable voltage source and a V-meter with enough accuracy(0.1%). Connect the adjustable voltage source to the analog input number 0 (terminals+sign and -sign). Input module from 0 to 10 VDC.Analog input 0J600I-SIGN-SIGN+I+74737271VAdjustablevoltage sourceNote!This refers to the AnalogInput number 0. For otherinputs check the numberof the potentiometer inthe table on page 16 - 1.1 Adjust the voltage source to the lowest value in the measuring range(0 V) using the V-meter.2 Check the O<strong>FF</strong>SET point value. It should be near zero value, not greaterthan <strong>2.</strong> The O<strong>FF</strong>SET point can't be changed.3 Adjust the current source to the highest value (10 VDC) using the V-meter.4 Adjust the GAIN by turning the potentiometer P207 until you can seethe value 1023 (255 for <strong>AL32</strong>EXA) in the PC.Proceede to the following Analog Input Channel and repeat the procedure described.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 16 - 626/10/2001AutoLog 32 Instruction <strong>Man</strong>ual16.8 Temperature inputs 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:Analog input 0J600I-74SIGN-SIGN+I+737271Adjustable ResistanceReferenceThe following temperatures correspond to the resistance values given in the table(DIN 43 760) below:°C Ω Diff.-30 88.22 0.39-25 90.19 0.39-20 9<strong>2.</strong>16 0.39-15 94.12 0.39-10 96.09 0.39-5 98.04 0.390 100 0.395 101.95 0.3910 103.90 0.3915 105.85 0.3920 107.79 0.3925 109.73 0.3830 111.67 0.3935 113.61 0.3940 115.54 0.3945 117.47 0.3950 119.40 0.3955 121.32 0.3960 123.24 0.3865 125.16 0.3970 127.07 0.3875 128.98 0.3880 130.89 0.3885 13<strong>2.</strong>80 0.3890 134.70 0.3895 136.60 0.38100 138.50 0.38105 140.39 0.37110 14<strong>2.</strong>29 0.39115 144.17 0.37120 146.06 0.38125 147.94 0.37°C Ω Diff.130 149.82 0.37135 151.70 0.37140 153.58 0.38145 155.45 0.38150 157.31 0.37155 159.18 0.37160 161.04 0.37165 16<strong>2.</strong>90 0.37170 164.76 0.37175 166.61 0.37180 168.46 0.37185 170.31 0.37190 17<strong>2.</strong>16 0.37195 174.00 0.37200 175.84 0.37205 177.68 0.37210 179.51 0.37215 181.34 0.37220 183.17 0.37225 184.99 0.36230 186.82 0.37235 188.63 0.36240 190.45 0.36245 19<strong>2.</strong>26 0.36250 194.07 0.36255 195.88 0.36260 197.69 0.36265 199.49 0.36270 201.29 0.36275 203.08 0.36280 204.88 0.36285 206.67 0.36<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 16 - 726/10/2001°C Ω Diff.290 208.45 0.35295 210.24 0.36300 21<strong>2.</strong>02 0.36305 213.80 0.36310 215.57 0.35315 217.35 0.36320 219.12 0.36325 220.88 0.35330 22<strong>2.</strong>65 0.36335 224.41 0.35340 226.17 0.36345 227.92 0.35350 229.67 0.35°C Ω Diff.355 231.42 0.35360 233.17 0.35365 234.91 0.35370 236.65 0.34375 238.39 0.35380 240.13 0.35385 241.86 0.35390 243.59 0.35395 245.31 0.34400 247.04 0.35405 248.76 0.35410 250.48 0.35The PT100 sensor is a non linear sensor. The characteristic temperature/resistancecurve for a PT100 sensor is shown in the figure.RO<strong>FF</strong>SET10%The curve is here exaggered.The non linearity of the sensoris reduced in the AL16.GAIN90% °CIn order to make the adjustment of the PT100 input as accurate as possible over themeasurement range different adjustment points have to be used. Instead of adjustningthe O<strong>FF</strong>SET at the lowest value we use a 10 % point as the adjustement point for thelow end of the measurement range. In the same way we use the 90% point as the adjustmentpoint for the high value. This increases the overall accuracy.<strong>FF</strong>-<strong>Automation</strong> Oy


Page 16 - 826/10/2001AutoLog 32 Instruction <strong>Man</strong>ualIn the following table you have the adjustment points calculated for the different standardmeasurement ranges available:PT100:Module Temp.range Resolution O<strong>FF</strong>SET Resist GAIN Resistnumber (°C) (°C) Point value Point value<strong>AL32</strong>AN <strong>AL32</strong>EXA 10 % (W) 90 % (W)(°C)(°C)901054 -40 .. +87.5 0.125 0.50 -27 89.40 +75 128.98901050 0 .. +127.5 0.125 0.50 +13 105.07 +115 144.17901074 -55 .. +200 0.25 1.0 -30 88.22 +175 166.61901052 0 .. +255 0.25 1.0 +26 110.12 +230 186.82901076 +125 .. +380 0.25 1.0 +151 157.69 +355 231.42901097 0 .. +10<strong>2.</strong>3 0.10 0.40 +10 103.90 +92 135.46901098 -40 .. +6<strong>2.</strong>3 0.10 0.40 -30 88.22 +52 120.16901099 -50 .. +461.5 0.50 <strong>2.</strong>0 +2 100.78 +410 250.48On the PC you should see the following values when the adjustment is correct:O<strong>FF</strong>SET GAIN10 % 90 %<strong>AL32</strong>AN 102 922<strong>AL32</strong>EXA 26 2301 Select from the decade resistor the value corresponding tothe O<strong>FF</strong>SET Point (10 % of the full range)2 Adjust the O<strong>FF</strong>SET point by turning the P201 potentiometer(Note! This refers to the Analog Input # 0. For other inputs checkthe number of the potentiometer in the table below). You can checkthe measured value in the PC by comparing with the table above.3 Adjust the decade resistor to the gain point (90 % of the full range).4 Adjust the GAIN by turning the potentiometer P207 until you can seethe value corresponding to the GAIN Point in the PC.5 Now go back to the O<strong>FF</strong>SET adjustment (see point 2 above) and repeatthe procedures described in point 2,3 and 4.Note! The adjustment of the GAIN effects the adjustment of the O<strong>FF</strong>SET. You have to repeat the adjustmentprocedure a couple of times until you have found the right final adjustement values.Proceede to the following Analog Input Channel and repeat the procedure described.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ualPage 16 - 926/10/200116.9 Temperature inputs with KTY10 sensor (Thermistor) (PTC)You need an adjustable resistance reference 0.1....4999 Ω with an accuracy of 0.1%.Connect the adjustable resistance in the following way:Analog input 0J600I-74SIGN-SIGN+I+737271Adjustable ResistanceReferenceThe following temperatures correspond to the resistance values given in the table below:°C Ω-50 1068-45 1112-40 1159-35 1208-30 1261-25 1316-20 1373-15 1434-10 1496-5 15620 16295 169910 177115 184520 192225 200030 208035 216240 224645 233250 2419°C Ω55 250860 259865 269070 278375 287780 297385 307090 316895 3266100 3366105 3467110 3568115 3670120 3772125 3876130 3979135 4083140 4188145 4293150 4397RThe KTY10 sensor is a nonlinear sensor. The characteristictemperature/resistancecurve for a KTY10 sensor isshown in the figure.The curve is here exaggered.The non linearity of the sensoris reduced in the AL16.O<strong>FF</strong>SET10%GAIN90%°C<strong>FF</strong>-<strong>Automation</strong> Oy


Page 16 - 1026/10/2001AutoLog 32 Instruction <strong>Man</strong>ualIn order to make the adjustment of the KTY10 input as accurate as possible over themeasurement range different adjustment points have to be used. Instead of adjustningthe O<strong>FF</strong>SET at the lowest value we use a 10 % point as the adjustement point for thelow end of the measurement range. In the same way we use the 90 % point as the adjustmentpoint for the high value. This increases the overall accuracy.In the following table you have the adjustment points calculated for the different standardmeasurement ranges available:KTY10:Module Temp.range Resolution O<strong>FF</strong>SET Resist GAIN Resistnumber (°C) (°C) Point value Point value<strong>AL32</strong>AN <strong>AL32</strong>EXA 10 % (W) 90 % (W)(°C)(°C)901090 -20 .. +107.5 0.125 0.5 -7.3 1496 +94 3266901092 -40 .. +87.5 0.125 0.5 -27 1316 +75 2877901094 0 .. +10<strong>2.</strong>3 0.1 0.4 +10 1771 +92 3168901095 -40 .. +6<strong>2.</strong>3 0.1 0.4 -30 1261 +52 2419901096 -40 .. +164.7 0.2 0.8 -20 1373 +144 4293On the PC you should see the following values when the adjustment is correct:O<strong>FF</strong>SET GAIN10 % 90 %<strong>AL32</strong>AN 102 922<strong>AL32</strong>EXA 26 2301 Select from the decade resistor the value corresponding tothe O<strong>FF</strong>SET Point (10 % of the full range)2 Adjust the O<strong>FF</strong>SET point by turning the P201 potentiometer(Note! This refers to the Analog Input # 0. For other inputs checkthe number of the potentiometer in the table below). You can checkthe measured value in the PC by comparing with the table above.3 Adjust the decade resistor to the gain point (90 % of the full range).4 Adjust the GAIN by turning the potentiometer P207 until you can seethe value corresponding to the GAIN Point in the PC.5 Now go back to the O<strong>FF</strong>SET adjustment (see point 2 above) and repeatthe procedures described in point 2,3 and 4.Note! The adjustment of the GAIN effects the adjustment of the O<strong>FF</strong>SET. You have to repeat the adjustmentprocedure a couple of times until you have found the right final adjustement values.Proceede to the following Analog Input Channel and repeat the procedure described.<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page A-126/10/2001A. DIMENSIONAL DRAWINGS1624ribbon cable connector,tallest component on the board160155Batteryribbon cable connectorfor expansion board55112195200Figure A.1 Dimensions of <strong>AL32</strong>DI<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-226/10/2001AutoLog 32 Instruction <strong>Man</strong>ual24Ribbon cable connector,tallest component on the board16J2J1J3J605J604J603J11160B1SW1IC4 IC2 IC3IC15J4J101RS485J9J5J600 J601 J6025 5145228266,5271,5Figure A.2 Dimensions of <strong>AL32</strong>AN<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page A-326/10/200124Ribbon cable connector,tallest component on the board16J2J1J3J505 J504 J503F1IC52IC57160B1SW1IC4 IC2 IC3IC51IC56J8IC15J4J101J9J5J501J5025 5112195266,5271,5Figure A.3 Dimensions of <strong>AL32</strong>PL<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-426/10/2001AutoLog 32 Instruction <strong>Man</strong>ualRibbon cableconnector, tallestcomponent on board1624160155Ribbon cableconnector forbasic board55135140Figure A.4 Dimensions of expansion board <strong>AL32</strong>EXRibbon cableconnector, tallestcomponent on board1624160155Ribbon cableconnector forbasic board55135140Figure A.5 Dimensions of expansion board <strong>AL32</strong>EXA<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page A-526/10/2001Figure A.6 Dimensions of expansion board <strong>AL32</strong>EXOFigure A.7 Dimensions of display/keypad unit AL1094Figure A.8 Dimensions of display/keypad unit 1094R<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-626/10/2001AutoLog 32 Instruction <strong>Man</strong>ualFigure A.9 Dimensions of display/keypad unit AL 1094A<strong>FF</strong>igure A.10 Dimensions of display/keypad unit AL1093D<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page A-726/10/2001Display CutoutFigure A.11 Dimensions of display/keypad unit AL1093FDisplay CutoutFigure A.12 Dimensions of display/keypad unit AL1095A<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-826/10/2001AutoLog 32 Instruction <strong>Man</strong>ualDisplay CutoutFigure A.13 Dimensions of display/keypad unit AL1095BCutout:180.0±0.2 x 13<strong>2.</strong>4±0.2Figure A.14 Dimensions of graphic display - keypad/touchscreen unit AL1096S/T<strong>FF</strong>-<strong>Automation</strong> Oy


AutoLog 32 Instruction <strong>Man</strong>ual Page A-926/10/2001Cutout:193.6±0.3 x 151.8±0.3Figure A.15 Dimensions of graphic display - touchscreen unit AL1096PS/PE<strong>FF</strong>-<strong>Automation</strong> Oy


Page A-1026/10/2001AutoLog 32 Instruction <strong>Man</strong>ualFigure A.16 Dimensions of AL9624/3.5 power supplyFigure A.17 Dimensions of AL9624/8 power supply<strong>FF</strong>-<strong>Automation</strong> Oy

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

Saved successfully!

Ooh no, something went wrong!