logo资料库

安川机器人motoplus开发软件说明书.pdf

第1页 / 共166页
第2页 / 共166页
第3页 / 共166页
第4页 / 共166页
第5页 / 共166页
第6页 / 共166页
第7页 / 共166页
第8页 / 共166页
资料共166页,剩余部分请下载后查看
1 Outline
1.1 Preface
1.2 Function Outline
1.3 MotoPlus Specification
1.4 Specific Data Type for MotoPlus
1.5 Notes
2 Task
2.1 Multitasking
2.2 State Transitions of Task
2.3 Task Scheduling Method
2.4 Management of Ready-Queue
2.5 Application Task Control
2.6 Processing Time Measurement
2.7 Limit on Protection Regarding Task Control
2.7.1 Limit on Number of Files Which User Can Load
2.7.2 Limit on Memory Size
2.7.3 Limit on Task Start-up
2.7.4 Function to Check Execution Status of Man-Machine Task
2.8 List of Task Control API
3 User Watchdog
3.1 Function Outline
3.2 Usage Outline
3.3 User Watchdog API List
4 Ethernet Communications
4.1 Socket
4.2 Client Server Model
4.3 UDP Communication
4.4 TCP Communication
4.5 List of Socket Library Functions
4.6 Operation of Structure and IP Address
4.6.1 Sockaddr Structure
4.6.2 Sockaddr_in Structure
4.6.3 Function for IP Address Operation
4.7 About Byte Order
4.8 Flow of Socket Library System Call
4.8.1 Flow of Socket Library System Call with UDP
4.8.2 Flow of Socket Library System Call with TCP
4.9 Note for Ethernet Programming
5 Data Transmission with Programming Pendant
6 RS232C Communication Control
7 Event Control
7.1 Task Creation
7.2 Event Notification
8 Robot System Control
8.1 System Information
8.2 Variables
8.3 I/O
8.4 Robot Operation
8.5 System Monitor API List
8.6 System Control API List
9 Sensor Control
9.1 Outline of Provided Functions
9.1.1 Path Correction Function
9.1.2 Interpolation-Motion Forced Change Function
9.1.3 Speed Override Function
9.1.4 Increment Value Move Function
9.2 Outline of Operation
9.3 Timing of Path Correction Process
9.4 Details of Giving and Receiving Command and Changing Operating Conditions by SKILLSND (Including Path Correction)
9.5 Sensor Control API List
10 Robot Operation Control Service
10.1 Increment Value Move Function
10.2 Robot Operation Control API List
11 Servo Control
11.1 Function Outline
11.1.1 Feedback Speed/Torque Retrieve Function
11.1.2 Torque Limit Function/Torque Control Function
11.2 Example of Usage
11.2.1 Detecting Workpiece Position
11.2.2 Holding Workpiece with Unknown Size
11.3 Servo Control API List
12 Memory Pool Control
12.1 Memory Pool Control API List
13 File Control
13.1 Rules for File Name and Size
13.2 Rules for USB Drive and USB Memory Stick
13.3 Access Right When Opening a File
13.4 Available Task Priority
13.5 File Control API List
14 Existing File Control
14.1 Existing File Access API List
15 Programming
15.1 Rules
15.2 C Coding Rules
15.3 Program Execution
15.4 MotoPlus Coding Rules
15.5 Restrictions on Programming
15.5.1 Usable ANSI-C Standard Functions
15.5.2 Task Priority and Usable API
15.6 Note for Programming
15.7 Phenomena during Debugging, Potential Coding Problems, and Examination Methods
15.7.1 Programming Pendant Display Freezes with “Starting up system Start Online Process”, and DX200 Does Not Start
15.7.2 MotoPlus Application Is Seemingly Not Running
15.7.3 Alarm 4479: “MOTOPLUS MM TASK WATCHDOG ERROR” Occurs
15.7.4 Programming Pendant Display or Key Response Is Slow
15.7.5 Programming Pendant Communication Error Occurs and Servo Power of DX200 Turns Off (Hang-up Status)
16 Sample Programs
16.1 Outline of Sample Programs
16.2 Display of Hello World
16.3 Task Control Sample Program
16.4 User Watchdog Sample Program
16.5 Ethernet Sample Programs
16.5.1 Preparations
16.5.2 UDP Server Sample Programs (DX200 Side)
16.5.3 UDP Client Sample Program (Windows PC Side)
16.5.4 TCP Server Sample Programs (DX200 Side)
16.5.5 TCP Client Sample Program (Windows PC Side)
16.6 Robot System Monitor Samples and Control Programs
16.6.1 Variables, I/O Access Sample Program
16.6.2 User Variable Access Sample Program
16.7 Serial Communication (RS232C)
16.7.1 Preparations
16.7.2 Operation Check
16.7.3 Sample Code
16.8 Sensor Control Sample Program
16.9 Servo Control Sample Program
16.10 File Control Sample Program
16.10.1 Operation Check
16.10.2 Sample Program
16.11 Existing File Access Sample Program
16.11.1 Preparation
16.11.2 Operation Check
16.11.3 Sample Program
16.12 Coordinate Coversion Sample Program
17 Alarm List
DX200 OPTIONS INSTRUCTIONS Programmer’s Manual For New Language Environment MotoPlus Upon receipt of the product and prior to initial operation, read these instructions below thoroughly, and retain for future reference. MOTOMAN INSTRUCTIONS MOTOMAN- INSTRUCTIONS DX200 INSTRUCTIONS DX200 OPERATOR’S MANUAL( for each purpose) DX200 MAINTENANCE MANUAL (Volume 1) (Volume2) The DX200 operator’s manual above corresponds to specific usage. Be sure to use the appropriate manual. The DX200 maintenance manual above consisits of “Volume1” and “Volume2”. YASKAWA ELECTRIC CORPORATION MANUAL NO. HW1482095 2 1/166
HW1482095 MANDATORY • This manual explains MotoPlus of the DX200 system. Read this manual carefully and be sure to understand its contents before handling the DX200. • General items related to safety are listed in the Chapter 1: Safety of the DX200 Instructions. To ensure correct and safe operation, carefully read the DX200 Instructions before reading this manual. CAUTION • Some drawings in this manual are shown with the protective covers or shields removed for clarity. Be sure all covers and shields are replaced before operating this product. • The drawings and photos in this manual are representative examples and differences may exist between them and the delivered product. • YASKAWA may modify this model without notice when necessary due to product improvements, modifications, or changes in specifications. If such modification is made, the manual number will also be revised. If your copy of the manual is damaged or lost, contact a YASKAWA representative to order a new copy. The representatives are listed on the back cover. Be sure to tell the representative the manual number listed on the front cover. • • YASKAWA is not responsible for incidents arising from unauthorized modification of its products. Unauthorized modification voids your product’s warranty. ii HW1482095 2/166
HW1482095 NOTES FOR SAFE OPERATION Read this manual carefully before installation, operation, maintenance, or inspection of the DX200. In this manual, the Notes for Safe Operation are classified as “DANGER”, “WARNING”, “CAUTION”, “MANDATORY”, or “PROHIBITED”. DANGER Indicates an imminent hazardous situation which, if not avoided, could result in death or serious injury to personnel. WARNING Indicates a potentially hazardous situation which, if not avoided, could result in death or serious injury to personnel. CAUTION Indicates a potentially hazardous situation which, if not avoided, could result in minor or moderate injury to personnel and damage to equipment. It may also be used to alert against unsafe practices. MANDATORY Always be sure to follow explicitly the items listed under this heading. PROHIBITED Must never be performed. Even items described as “CAUTION” may result in a serious accident in some situations. At any rate, be sure to follow these important items. NOTE To ensure safe and efficient operation at all times, be sure to follow all instructions, even if not designated as “DANGER”, “WARNING” and “CAUTION”. iii HW1482095 3/166
HW1482095 WARNING • Before operating the manipulator, check that servo power is turned OFF when the emergency stop buttons on the front door of the DX200 and the programming pendant are pressed. When the servo power is turned OFF, the SERVO ON LED on the programming pendant is turned OFF. Injury or damage to machinery may result if the emergency stop circuit cannot stop the manipulator during an emergency. The manipulator should not be used if the emergency stop buttons do not function. Fig. : Emergency Stop Button • Once the emergency stop button is released, clear the cell of all items which could interfere with the operation of the manipulator. Then turn the servo power ON. Injury may result from unintentional or unexpected manipulator motion. Fig. : Release of Emergency Stop TURN • Observe the following precautions when performing teaching operations within the P-point maximum envelope of the manipulator: – Be sure to lock out the safeguarding when going inside. Also, display the sign that the operation is being performed inside the safeguarding and make sure no one closes the safeguarding. – View the manipulator from the front whenever possible. – Always follow the predetermined operating procedure. – Keep in mind the emergency response measures against the manipulator’s unexpected motion toward you. – Ensure that you have a safe place to retreat in case of emergency. Improper or unintended manipulator operation may result in injury. • Confirm that no person is present in the P-point maximum envelope of the manipulator and that you are in a safe location before: – Turning ON the DX200 power – Moving the manipulator with the programming pendant – Running the system in the check mode – Performing automatic operations Injury may result if anyone enters the P-point maximum envelope of the manipulator during operation. Always press an emergency stop button immediately if there is a problem. The emergency stop buttons are located on the right of the front door of the DX200 and the programming pendant. iv HW1482095 4/166
HW1482095 CAUTION • Perform the following inspection procedures prior to conducting manipulator teaching. If problems are found, repair them immediately, and be sure that all other necessary processing has been performed. – Check for problems in manipulator movement. – Check for damage to insulation and sheathing of external wires. • Always return the programming pendant to the hook on the DX200 cabinet after use. The programming pendant can be damaged if it is left in the manipulator’s work area, on the floor, or near fixtures. • Read and understand the Explanation of the Warning Labels in the DX200 Instructions before operating the manipulator. Definition of Terms Used Often in This Manual The MOTOMAN is the YASKAWA industrial robot product. The MOTOMAN usually consists of the manipulator, the controller, the programming pendant, and the manipulator cables. In this manual, the equipment is designated as follows: Equipment DX200 Controller DX200 Programming Pendant Cable between the manipulator and the controller Manual Designation DX200 Programming Pendant Manipulator cable v HW1482095 5/166
HW1482095 Descriptions of the programming pendant keys, buttons, and displays are shown as follows: Equipment Programming Pendant Character Keys /Symbol Keys Manual Designation The keys which have characters or its symbol printed on them are denoted with [ ]. ex. [ENTER] [Axis Key] and [Numeric Key] are generic names for the keys for axis operation and number input. When two keys are to be pressed simultaneously, the keys are shown with a “+” sign between them, ex. [SHIFT]+[COORD] The menu displayed in the programming pendant is denoted with { }. ex. {JOB} Axis Keys /Numeric Keys Keys pressed simultaneously Displays Description of the Operation Procedure In the explanation of the operation procedure, the expression “Select • • • “ means that the cursor is moved to the object item and the SELECT key is pressed. Registered Trademark In this manual, names of companies, corporations, or products are trademarks, registered trademarks, or brand names for each company or corporation. The indications of (R) and TM are omitted. vi HW1482095 6/166
HW1482095 1 Outline ............................................................................................................................................ 1-1 1.1 Preface .............................................................................................................................. 1-1 1.2 Function Outline................................................................................................................. 1-1 1.3 MotoPlus Specification ...................................................................................................... 1-3 1.4 Specific Data Type for MotoPlus ....................................................................................... 1-4 1.5 Notes ................................................................................................................................. 1-5 2 Task ................................................................................................................................................ 2-1 2.1 Multitasking........................................................................................................................ 2-1 2.2 State Transitions of Task................................................................................................... 2-1 2.3 Task Scheduling Method ................................................................................................... 2-2 2.4 Management of Ready-Queue .......................................................................................... 2-2 2.5 Application Task Control.................................................................................................... 2-3 2.6 Processing Time Measurement......................................................................................... 2-3 2.7 Limit on Protection Regarding Task Control...................................................................... 2-4 2.7.1 Limit on Number of Files Which User Can Load .................................................. 2-4 2.7.2 Limit on Memory Size........................................................................................... 2-4 2.7.3 Limit on Task Start-up .......................................................................................... 2-4 2.7.4 Function to Check Execution Status of Man-Machine Task................................. 2-5 2.8 List of Task Control API..................................................................................................... 2-6 3 User Watchdog ............................................................................................................................... 3-1 3.1 Function Outline................................................................................................................. 3-1 3.2 Usage Outline.................................................................................................................... 3-1 3.3 User Watchdog API List..................................................................................................... 3-2 4 Ethernet Communications............................................................................................................... 4-1 4.1 Socket................................................................................................................................ 4-1 4.2 Client Server Model ........................................................................................................... 4-1 4.3 UDP Communication ......................................................................................................... 4-2 4.4 TCP Communication.......................................................................................................... 4-2 4.5 List of Socket Library Functions......................................................................................... 4-3 4.6 Operation of Structure and IP Address.............................................................................. 4-3 4.6.1 Sockaddr Structure............................................................................................... 4-3 4.6.2 Sockaddr_in Structure.......................................................................................... 4-4 vii HW1482095 7/166
HW1482095 4.6.3 Function for IP Address Operation .......................................................................4-4 4.7 About Byte Order ...............................................................................................................4-5 4.8 Flow of Socket Library System Call ...................................................................................4-5 4.8.1 Flow of Socket Library System Call with UDP......................................................4-5 4.8.2 Flow of Socket Library System Call with TCP ......................................................4-6 4.9 Note for Ethernet Programming.........................................................................................4-6 5 Data Transmission with Programming Pendant..............................................................................5-1 6 RS232C Communication Control....................................................................................................6-1 7 Event Control ..................................................................................................................................7-1 7.1 Task Creation.....................................................................................................................7-1 7.2 Event Notification...............................................................................................................7-1 8 Robot System Control.....................................................................................................................8-1 8.1 System Information............................................................................................................8-1 8.2 Variables............................................................................................................................8-1 8.3 I/O ......................................................................................................................................8-1 8.4 Robot Operation.................................................................................................................8-1 8.5 System Monitor API List.....................................................................................................8-2 8.6 System Control API List.....................................................................................................8-3 9 Sensor Control ................................................................................................................................9-1 9.1 Outline of Provided Functions............................................................................................9-1 9.1.1 Path Correction Function......................................................................................9-1 9.1.2 Interpolation-Motion Forced Change Function .....................................................9-2 9.1.3 Speed Override Function......................................................................................9-2 9.1.4 Increment Value Move Function...........................................................................9-3 9.2 Outline of Operation...........................................................................................................9-4 9.3 Timing of Path Correction Process ....................................................................................9-5 9.4 Details of Giving and Receiving Command and Changing Operating Conditions by SKILLSND (Including Path Correction).............................................................................9-5 9.5 Sensor Control API List....................................................................................................9-10 10 Robot Operation Control Service ................................................................................................10-1 10.1 Increment Value Move Function ....................................................................................10-1 10.2 Robot Operation Control API List...................................................................................10-1 viii HW1482095 8/166
分享到:
收藏