Application manual - FlexPendant SDK
Overview
About this manual
Usage
Who should read this manual?
Prerequisites
Organization of chapters
References
Revisions
Product documentation, M2004
General
Product manuals
Technical reference manuals
Application manuals
Operating manuals
Safety
Safety of personnel
Safety of regulations
1 Introduction
1.1. About creating controller applications
Flexible user interfaces
Local vs Remote client
Ease-of-use on the factory floor
.NET and Visual Studio
Robustness and performance
1.2. Documentation and help
Introduction
Application manual
SDK Reference Help
FlexPendant StyleGuide
RobotStudio Community
MSDN
1.3. Terminology
About terms and acronyms
Definitions
2 Installation and development environment
2.1. Installation overview
About this section
Supported platforms
Requirements for installing and using FlexPendant SDK
About the FlexPendant SDK installation
RAB 5.11 to 5.12
RAB 5.10
What is installed?
Working with several versions
FlexPendant applications
Installation procedure
2.2. How to obtain and install a license key for RAB 5.09 or earlier
Overview
Install licence key
2.3. How to set up your PC to communicate with robot
Overview
Why is a connection needed?
Ethernet network connection
Service port connection with automatic IP address
Serial connection to the Console port
Service port connection with fixed IP address
Related information
2.4. Development environment
Overview
Microsoft .NET and Microsoft Visual Studio
Visual design support and Databinding
Choosing a programming language
Integration with Visual Studio
2.5. Two development models - virtual and real
About this section
Virtual robot technology
Requirements for virtual environment
Requirements for real environment
Virtual test and debug
Real tests necessary
Porting the application from virtual to real IRC5
Deployment to customer
2.6. Conversion of Visual Studio 2005 projects to Visual Studio 2008
Overview
3 Run-time environment
3.1. Overview
About this chapter
Software architecture
FlexPendant platform
Controller API
3.2 Running FlexPendant Applications
3.2.1. Components, assemblies and dlls
Building blocks
One or several assemblies
3.2.2. Deployment of FlexPendant application to a robot system
Proxy assembly
Download to real controller
Using the command window
FTP deployment
Restart the FlexPendant
Deploy application to virtual IRC5
3.2.3. Communication between FlexPendant and controller
COM technology
Resource identification
Hard real-time demands
3.2.4. Understanding the FlexPendant application life cycle
Overview
TAF - Application host framework
Starting a custom application
Application life cycle
Illustration
Limited resources
3.2.5. FlexPendant TpsView attribute
Overview
Project wizard settings
Visual appearance
Application name
Application icon
TaskBar icon
Application assembly
Class name
Application location
Application type
Startup type
Related information
3.2.6. ITpsViewSetup and ITpsViewActivation
ITpsViewSetup
Install and Uninstall
ITpsViewActivation
Activate and Deactivate
Simple code examples
3.3. Release upgrades and compatibility
About this section
Matching FlexPendant SDK and RobotWare release
RobotWare upgrades
Prepared for change
4 Developing Controller applications
4.1. Introduction
About this chapter
Basic approach
4.2. Analysis and design
About this section
Object oriented software development
Object oriented Analysis and Design
Analysis based on communication and use cases
Design is about managing complexity
Do you need to do design?
As complex or as easy as you wish
4.3. Controller events and threads
Overview
Controller events
GUI and controller event threads in conflict
Invoke method
4.4. User Authorization System
Overview
Accessing UAS from custom applications
Grants and Groups
MessageBox feedback
GetCurrentGrants and DemandGrant
4.5. Exception handling
Overview
Try-catch-finally
Typecasting
.NET Best Practices
4.6. How to use the online help
Overview
5 Using the FlexPendant SDK
5.1 Introduction
5.1.1. About this chapter
Overview
5.1.2. System features supporting the use of customized screens
Flexible user interfaces
Configure the FlexPendant
Additional Test View
View On Operating Mode Change
Use RAPID instruction to launch FlexPendant SDK application
5.2 Setting up a new project
5.2.1. Using the project template in Visual Studio
Overview
Setup procedure
Add any missing references
5.2.2. Setting up design support for FlexPendant controls
Overview
Procedure
5.3 Building the user interface
5.3.1. Introduction to visual design support
What is visual design support?
Why special controls for the FlexPendant?
Illustration
Hands on - Hello world
Hands on - step 2
Visual design and user experience
5.3.2. GUI controls and memory management
Overview
How to avoid memory leaks
Coding the Dispose method
Freeing allocated memory for a GUI control
5.3.3. Container style
Overview
Empty or Form?
Empty
Form
How to build the command bar
Adding a view to a custom application
Launching the view
5.3.4. Command bar
Overview
How to add menu items
How to add menu item event handling
5.3.5. FlexPendant fonts
Overview
TpsFont
5.3.6. The use of icons
Overview
FlexPendant controls with images
PictureBox and ImageList
The TpsIcon class
5.3.7. TabControl
Overview
Illustration
How to add tab images
How to add an event handler using the Properties window
Disposing TabControl
5.3.8. Button, TextBox and ComboBox
Overview
Using Button
Using TextBox
Using ComboBox
5.3.9. AlphaPad
Overview
Launching the AlphaPad
Adding event handlers
Validating the result at the Closing event
Using the result at the Closed event
Removing the AlphaPad control
5.3.10. ListView
Overview
Illustration
Using properties to control appearance
ABB specific properties
5.3.11. CompactAlphaPad and NumPad
Using CompactAlphaPad
Using NumPad
5.3.12. GTPUMessageBox
Overview
Design issues
Simple code example
Using a callback
5.3.13. GTPUFileDialog
Overview
File dialog types
Illustration
Implementation details
Example
5.3.14. Data of RAPID data and IO signals
What is databinding?
FlexPendant SDK classes to be used as binding sources
RapidDataBindingSource
SignalBindingSource
GUI example
How to use the Visual Studio designer for
SuspendBinding/ResumeBinding
5.4 Launching other views
5.4.1. Using launch service
Overview
Installing ITpsViewSetup
Launching standard views
LaunchView / CloseView example
Launching custom applications
5.4.2. Using standard dialog box to modify data
Overview
Creating the dialog box
Type checking
5.5 Using the Controller API
5.5.1. ABB.Robotics.Controllers
Controller API
CAPI domains
CAPI and controller domains
What controller functionality is provided?
Releasing memory
FlexPendant SDK reference documentation
5.5.2. Accessing the controller
Overview
Controller instance
Subscribing to controller events
Creating a backup
Dispose
5.5.3. Rapid domain
5.5.3.1. Working with RAPID data
Overview
Providing the path to the RAPID data
Direct access
Hierarchical access
Accessing data declared in a shared module
Creating an object representing the RAPID data value
IRapidData.ToString method
IRapidData.FillFromString method
String format
Writing to RAPID data
Letting the user know that RAPID data has changed
Add subscription
Handle event
Read new value from controlller
RapidData disposal
5.5.3.2. Handling RAPID arrays
Overview
ArrayData object
Array dimensions
Array item access by using indexers
Array item access using enumerator
5.5.3.3. ReadItem and WriteItem methods
Overview
ReadItem method
WriteItem method
5.5.3.4. UserDefined data
Overview
Creating UserDefined object
Reading UserDefined data
Writing to UserDefined data
Implement your own struct representing a RECORD
Creating ProcessData type
Implementing ProcessData struct
Implementing IRapidData methods
Property implementation
5.5.3.5. RAPID symbol search
Overview
SearchRapidSymbol method
Search properties
Default instance
Data type argument
Symbol name argument
Example 1
Example 2
Example 3
SearchRapidSymbol example
Search for UserDefined RAPID data - example
5.5.3.6. RAPID execution
Start and Stop RAPID programs
RAPID execution change event
ResetProgramPointer method
5.5.3.7. Modifying modules and programs
Overview
Load modules and programs
Save and unload RAPID program
Save module
ProgramPointer and MotionPointer
ModifyPosition method
5.5.4. IO system domain
Overview
Accessing signals
Getting signals using SignalFilter
Reading IO signal values
Digital signal
Analog signal
Writing IO signal values
Digital signal
Analog signal
Listening to signal changes
Start and stop subscriptions
Avoiding threading conflicts
Finding out the new value
5.5.5. Event log domain
Overview
Access the controller event log
Access event log categories
Access event log messages
MessageWritten event
5.5.6. Motion domain
Overview
MotionSystem object
Accessing Mechanical units
Jogging
Mechanical unit properties and methods
DataChanged event
5.5.7. File system domain
Overview
Accessing files and directories
Controller and FlexPendant file system
Loading controller files
Saving files
Getting multiple files and directories
Using search patterns
5.5.8. System info domain
Overview
SystemInfo class
System options
Additional options
6 Robust FlexPendant applications
6.1. Introduction
Overview
Technical overview of the FlexPendant device
How large can a custom application be?
6.2. Memory management
Garbage collection and Dispose
Application Framework usage - ITpsViewSetup
How to program the Dispose method - example
Discover memory leaks
6.3. Performance
About performance
Less code means faster code
Fewer controller accesses means faster code
Fewer objects means faster code
Transferring files
Application Framework usage - ITpsViewActivation
Excessive string manipulation is costly
Avoid Control.Refresh
Avoid boxing and unboxing
Foreach
Reflection is performance demanding
Efficiently parsing Xlm
6.4. Reliability
Overview
Error handling in .NET applications
SDK exception classes
Thread affinity
Invoke
Memory leaks
Utilizing multi-threading
Lock statement
Multicast delegates
7 FlexPendant - Debugging and troubleshooting
7.1. Debugging
Introduction
Exception error codes
7.2. Debug output
Overview
Enable debug output
FlexPendant Command Server
Trace and Debug
7.3. Debugging the virtual FlexPendant
Overview
Debugging procedure
Attach to Process
Windows Task Manager
Launching debugger programatically
7.4. Debugging the FlexPendant device
Overview
Prerequisites
Setting up the network
Debugging procedure
FlexPendant SDK User Forum
7.5. Troubleshooting FlexPendant applications
Overview
FlexPendant application does not start
Important support information
8 Localizing a FlexPendant application
8.1. Adding support for several languages
Introduction
Get started
1 Create project for text resources
2 Prepare main project for localization
3 Build satellite assembly
4 Test a localized application
9 Deployment of a FlexPendant SDK application
9.1. Overview
Introduction
Making a product
Deployment of a FlexPendant SDK product
9.2. Deployment of an application without a license
Overview
No license and no localization
No license but localization
9.3. Deployment of a licensed application
Overview
Procedure for making an additional option
Installing the option at the customer
Related information
9.4. Deployment using FTP
Overview
Procedure