CPM2A_OPERATION MANUAL (W352-E1-3) (986749), страница 24
Текст из файла (страница 24)
The procedure is performed beginning with theinitial display. (Clear the memory before entering a new program.)Note If an error occurs while inputting the program, refer to 5-3 Programming ConsoleOperation Errors for details on correcting the error. Refer to the relevant SupportSoftware Operation Manual for details on errors that appear when operating theSSS or SYSMAC-CPT Support Software.(1) Inputting the Self-holding Bit1, 2, 3...1. Input the normally open condition IR 00000.(It isn’t necessary to input leading zeroes.)LDWRITE00000LD0000000001READNOP (000)2.
Input the OR condition IR 20000.ORC2A0A0A0A0WRITE00001OR2000000002READNOP (000)3. Input the normally closed AND condition C000.(It isn’t necessary to input leading zeroes.)ANDNOTCNTWRITE00002AND NOTCNT 00000003READNOP (000)4. Input the OUT instruction IR 20000.OUTC2A0A0A0A0WRITE00003OUT2000000004READNOP (000)(2) Inputting the One-second Timer1, 2, 3...LD1. Input the normally open condition IR 20000.C2A0A0A0A0WRITE00004LD2000000005READNOP (000)2. Input the normally closed AND condition T002.(It isn’t necessary to input leading zeroes.)ANDNOTTIMC2WRITE12600005AND NOTTIM 00200006READNOP (000)SectionProgramming Example4-53. Input the 1-second timer T001.TIMB1WRITE00006TIM00100006 TIM DATA#00004.
Input the SV for T001 (#0010 = 1.0 s).B1A0WRITE(3) Inputting theTwo-second Timer00006 TIM DATA#001000007READNOP (000)The following key operations are used to input the 2-second timer.1, 2, 3...LD1. Input the normally open condition IR 20000.C2A0A0A0A0WRITE00007LD2000000008READNOP (000)2. Input the normally closed AND condition T002.(It isn’t necessary to input leading zeroes.)ANDNOTTIMC2WRITE00008AND NOTTIM 00200009READNOP (000)3. Input the 2-second timer T002.TIMC2WRITE00009TIM00200009 TIM DATA#00004. Input the SV for T002 (#0020 = 2.0 s).C2A0WRITE(4) Inputting the 10-countCounter1, 2, 3...LD00009 TIM DATA#002000010READNOP (000)The following key operations are used to input the 10-count counter.1. Input the normally open condition IR 20000.C2A0A0A0A0WRITE00010LD2000000011READNOP (000)2.
Input the normally open AND condition T001.(It isn’t necessary to input leading zeroes.)ANDTIMB1WRITE00011ANDTIM 00100012READNOP (000)127SectionProgramming Example4-53. Input the normally closed condition IR 20000.LDCNOT2A0A0A0A0WRITE00012LD NOT2000000013READNOP (000)4. Input the counter 000.CNTA0WRITE00013CNT00000013 CNT DATA#00005. Input the SV for counter 000 (#0010 = 10 counts).B1A0WRITE00013 CNT DATA#001000014READNOP (000)(5) Inputting the Flicker Output1, 2, 3...LD1. Input the normally open condition IR 20000.C2A0A0A0A0WRITE000014LD2000000015READNOP (000)2. Input the normally closed AND condition T001.(It isn’t necessary to input leading zeroes.)ANDNOTTIMB1WRITE00015AND NOTTIM 00100016READNOP (000)3. Input the OUT instruction IR 01000.(It isn’t necessary to input leading zeroes.)OUTB1A0A0A0WRITE(6) Inputting the END(001)Instruction0100000017READNOP (000)Input END(01).
(The display shows three digits in the function code, but only thelast two digits are input for CPM2A PCs.)FUNA12800016OUT000017FUN (0??)100017END (001)WRITE00018READNOP (000)BSectionProgramming Example4-54-5-4 Checking the ProgramCheck the program syntax in PROGRAM mode to make sure that the programhas been input correctly.1, 2, 3...1.
Press the CLR Key to bring up the initial display.CLR000002. Press the SRCH Key. An input prompt will appear requesting the desiredcheck level.SRCH00000PROG CHKCHK LBL(0Ć2)?3. Input the desired check level (0, 1, or 2). The program check will begin whenthe check level is input, and the first error found will be displayed. If no errorsare found, the following display will appear.A000017PROG CHKEND (001)00.1KWNote Refer to 5-4 Programming Errors for details on check levels and theprogramming errors that may be displayed during a program check.4. Press the SRCH Key to continue the search.
The next error will be displayed. Continue pressing the SRCH Key to continue the search.The search will continue until an END(01) instruction or the end of ProgramMemory is reached.If errors are displayed, edit the program to correct the errors and check the program again. Continue checking the program until all errors have been corrected.4-5-5 Test Run in MONITOR ModeSwitch the CPM2A in MONITOR mode and check the operation of the program.1, 2, 3...1. Set the Programming Console’s mode switch to MONITOR mode.MONITORRUNPROGRAM<MONITOR>BZ2. Press the CLR Key to bring up the initial display.CLR000003.
Force-set the start input bit (IR 00000) from the Programming Console tostart the program.LDMONTRSET00000LD0000000000^ OFF00000ONThe cursor in the lower left corner of the display indicates that the force set isin progress. The bit will remain ON as long as the Set Key is held down.4. The output indicator for output IR 01000 will flash ten times if the program isoperating correctly. The indicator should go OFF after ten one-secondflashes.There is a mistake in the program if the output indicator doesn’t flash. In thiscase, check the program and force set/reset bits to check operation.129SECTION 5Test Runs and Error ProcessingThis section describes procedures for test runs of CPM2A operation, self-diagnosis functions, and error processing to identifyand correct the hardware and software errors that can occur during PC operation.5-15-25-35-45-55-65-7Initial System Checks and Test Run Procedure .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5-1-1 Initial System Checks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5-1-2 Flash Memory Precautions . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . .5-1-3 CPM2A Test Run Procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Self-diagnostic Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5-2-1 Identifying Errors . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5-2-2 User-defined Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5-2-3 Non-fatal Errors . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5-2-4 Fatal Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5-2-5 Communications Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Programming Console Operation Errors .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Programming Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Troubleshooting Flowcharts . . . . .
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Maintenance Inspections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Battery Replacement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . .132132132132133133134134135135136136137145146131SectionInitial System Checks and Test Run Procedure5-15-1Initial System Checks and Test Run Procedure5-1-1 Initial System ChecksCheck the following items after setting up and wiring the CPM2A, but before performing a test run.ItemPower supply andI/O connectionsPoints to checkIs the wiring correct?Are the terminals securely tightened?Are there any shorts between crimp terminals or wires?Refer to 3-4 Wiring and Connections for details.Connecting cablesAre the cables all connected correctly and locked?Refer to 3-4 Wiring and Connections for details.Protective labelNoteHas the protective label been removed?1.
Always clear memory before beginning to program the CPM2A. Althoughmemory is cleared before the CPU Unit is shipped, the contents of the DM,HR, AR, and counter areas may change in transit. See 4-4-2 ClearingMemory for details on the All Clear operation.2. See 1-3-3 Operating Mode at Startup to determine what mode the CPM2Awill enter when the power is turned on.5-1-2 Flash Memory PrecautionsObserve the following precautions to protect the flash memory and ensureproper operation.1, 2, 3...1. If changes are made in the read-only DM area (DM 6144 through DM 6599)or PC Setup (DM 6600 through DM 6655), the PC’s operating mode must bechanged to write the new contents to flash memory. If backup battery ischanged before the changes are written to flash memory, the changes willbe lost.The changes can be saved by switching the CPM2A to RUN or MONITORmode or turning the CPM2A off and then on again.2.
When contents of the program, read-only DM (DM 6144 through DM 6599),or PC Setup (DM 6600 through DM 6655) have been changed, startup processing will take up to 1,200 ms longer than usual. Be sure to take this onetime startup delay into account if it may affect operations.3. If one of the following three operations is performed in MONITOR or RUNmode, the CPM2A’s cycle time will be extended by up to 1,200 ms and interrupts will be disabled while the program or PC Setup is being overwritten.• Program changes with the online edit operation• Changes to the read-only DM area (DM 6144 through DM 6599)• Changes to the PC Setup (DM 6600 through DM 6655)A “SCAN TIME OVER” error won’t occur during these operations.
Be sure totake this delay in the CPM2A’s I/O response times into account when performing online editing.5-1-3 CPM2A Test Run Procedure1, 2, 3...1321. Power Supply Applicationa) Check the CPM2A’s power supply voltage and terminal connections.b) Check the I/O devices’ power supply voltage and terminal connections.c) Turn on the power supply and check that the “PWR” indicator lights.d) Use a Programming Device to set the CPM2A to PROGRAM mode.SectionSelf-diagnostic Functions5-22.
I/O Wiring Checksa) With the CPM2A in PROGRAM mode, check the output wiring by turningon the output bits with the force set and force reset operations.Refer to 4-4-24 Force Set, Reset for details.b) Check the input wiring with the CPM2A’s input indicators or a Programming Device’s monitor operations.3.