Академический Документы
Профессиональный Документы
Культура Документы
Table of contents
1 Introduction........................................................................................................................................... 4
1.1 Learning objectives................................................................................................................. 4
1.2 Safety notices and symbols....................................................................................................5
2 Installing Automation Studio................................................................................................................ 6
2.1 Installation wizard....................................................................................................................6
2.2 licensing...................................................................................................................................7
3 Starting Automation Studio.................................................................................................................. 8
5 Automation Studio.............................................................................................................................. 11
5.1 "Coffee machine" example project........................................................................................11
5.2 Automation Studio help system............................................................................................ 12
5.3 The workspace......................................................................................................................14
5.4 The basic concept.................................................................................................................21
5.5 Developing a concept........................................................................................................... 22
5.6 Software management in the Logical View.......................................................................... 24
5.7 Hardware management in the Physical View....................................................................... 24
5.8 Managing configurations in the Configuration View............................................................. 25
5.9 The relationship between functionality and task...................................................................26
6 Configuring the hardware...................................................................................................................30
6.1 Adding I/O modules from the Hardware Catalog..................................................................31
6.2 Map variables to the I/O channels........................................................................................32
6.3 The I/O configuration............................................................................................................ 33
6.4 Configuring network interfaces............................................................................................. 34
6.5 Build the project.................................................................................................................... 35
7 Initial installation of the controller...................................................................................................... 36
9 Programming...................................................................................................................................... 40
9.1 Programming languages....................................................................................................... 40
9.2 Initialization and cyclic subroutines.......................................................................................41
9.3 Variables and data types...................................................................................................... 42
9.4 The cross reference list........................................................................................................ 44
9.5 Creating an application......................................................................................................... 45
9.6 Import, export and team functions........................................................................................46
10 Updates and licenses.......................................................................................................................48
10.1 Hardware and software upgrades.......................................................................................48
10.2 Technology Guarding..........................................................................................................49
11 Summary...........................................................................................................................................50
1 Introduction
Automation Studio is the project development environment used specifically for B&R automation com-
ponents. This includes controllers, motion control components, safety modules and visualization appli-
cations. By clearly structuring projects and being able to manage all of the different configurations and
variants of a machine, it provides optimal support for working together in teams.
This training module will use simple exercises to demonstrate the use of the wide range of tools available
in Automation Studio. In addition, it will frequently refer to the extensive Automation Studio help system,
an invaluable reference for completing the exercises in this training module.
This training module uses simple exercises to demonstrate the wide range of tools available in Automa-
tion Studio. In addition, it will frequently refer to the extensive Automation Studio help system, an invalu-
able reference for completing the exercises in this training module.
You will learn how to create and configure projects in Automation Studio.
You will learn how to develop small programs and declare process variables.
You will learn the steps to follow in order to commission a B&R controller.
You will learn how to set up hardware configurations and use the simulation features in Au-
tomation Studio.
You will learn how to navigate the Automation Studio help system.
You will learn how to use the Automation Studio user interface and the various editors avail-
able.
You will learn about the options for configuring modules with Automation Studio's hardware
management features.
Danger: Disregarding these safety guidelines and notices can result in severe injury, death or
substantial damage to equipment.
Warning: Disregarding these safety guidelines and notices can result in severe injury or sub-
stantial damage to equipment.
Caution: Disregarding these safety guidelines and notices can result in injury or damage to
equipment. This information is important for preventing errors.
Help: References to additional document sources are provided here. (help system, data sheets,
user's manuals)
Automation Studio is installed automatically when the Automation Studio DVD is inserted into the
computer's DVD drive. It is also possible to start the installation manually by running the Install.exe file.
The installation wizard guides the user through the installation process. After selecting the language for
installation, a number of installation options are available. These include viewing version information,
calling system requirements, etc.
Figure 2: Automation Studio installation: Selecting the Figure 3: Automation Studio installation: Installation options
installation language and version information
2.2 licensing
The full range of functions are available in Automation Studio for 30 working days after instal-
lation. After this time, the program is locked until the software is registered.
The licensing window is opened when starting SafeDESIGNER. This is where the serial number
from the Automation Studio license agreement can be entered.
When Automation Studio is started for the first time, the start page is displayed in the workspace.
From the Start Page, you can create a new project or open an existing one.
It also includes the "Getting started" section for users to learn more about working with Automation
Studio. The start page can be opened at any time by selecting <Help> / <Show start page> from the
main menu; it is also displayed after a project is closed.
This section will take advantage of the support offered by the Automation Studio help system to create
a new project, transfer it to ARsim (Automation Runtime simulation) and test it using Automation Studio.
Exercise: Creating a new project with the support of the help system
The corresponding section of the help system can be opened directly from the start page in Automation
Studio.
Figure 8: The Automation Studio start Figure 9: Steps for creating the first project
page
1) Click on the How do I create a control project? link on the start page.
The language used for the help system can be specified by selecting <Tools> / <Options> from
the main menu (English or German).
The help system is a useful aid for creating a new project, designing a program and then trans-
ferring the project to the simulated target system where it can be tested. Some of the elements
of Automation Studio have already been introduced during the course of this first project. The
next few sections will provide additional information about the structure of an Automation Studio
project with the help of an example project.
It is possible to display the help system and Automation Studio at the same time if a PC has
a second monitor. If a second monitor is not available, the keyboard shortcut <ALT> + <TAB>
can be used to switch back and forth between them.
5 Automation Studio
This section will use an example project to explain a bit more about Automation Studio and the structure
of projects.
An Automation Studio installation includes several example projects. This training module will use one
of these example projects to explain the Automation Studio environment and some of the many different
functions available.
1) Open the Automation Studio example project from the start page.
After following these steps, the "CoffeeMachine" example will be unzipped and opened in Au-
tomation Studio.
The Automation Studio help system is an invaluable resource throughout the development, configuration
and commissioning of a project. It serves as a reference guide for using Automation Studio and its
editors, creating programs or visualization applications, configuring drives and much more. In addition,
the Automation Studio help system provides access to all B&R hardware documentation.
"Help favorites" make it possible to manage and store helpful pages within an individualized structure.
You can save the help favorites to a separate file. In this way, help favorites can be managed as needed
and even passed on to other people.
Managing favorites
1 Saving and opening
Help favorites can be saved to a file by se-
lecting "Save" or "Save as" from the File
menu. Any new help favorites are automat-
ically saved in this file.
2 List of help favorites
The Help Favorites can be managed in a
tree structure. The entries can be moved
and renamed. Clicking on one of the en-
tries will open the corresponding help
page.
Figure 15: Managing help favorites 3 Toolbar
The "Help contents" and "Help favorites"
buttons in the toolbar switch between the
Favorites view and the navigation tree in
the Automation Studio help system. The
navigation tree remains synchronized if a
favorite is selected in the Favorites view.
Automation Studio is divided into several different areas, each with a specific function.
When a project is opened in Automation Studio, the different windows are all docked to the main program
window. Clicking on a window's title bar and dragging it away from the main window will undock it so
that it can be moved to another location.
To create more space on the screen, for example when working with
visual programming editors, the Project Explorer and all other dock-
able windows can be hidden automatically. Figure 18: Using the pin symbol to hide
windows
Clicking on the pin icon in the title bar of the Project Explorer or any of the other dockable windows will
toggle the auto-hide function.
The default window layout in Automation Studio can be restored by selecting <Window / Reset
window layout> from the main menu.
5.3.3 Workbooks
Workbook mode presents a clear way of displaying open windows and a convenient way to switch be-
tween them. Windows can be overlapping or arranged above or next to one another.
If several editors are open at the same time, each one is displayed in a separate workbook.
An overview for keeping track of open workbooks is available by clicking on the drop-down symbol on
the right side of the title bar.
Many of the functions that can be accessed from menus can also be accessed from the tool-
box or keyboard shortcuts. Settings are displayed depending on the object highlighted in the
properties dialog box.
Toolbox window
The Toolbox window provides access to program and configuration elements, programming functions
or hardware modules depending on the editor that is selected.
Figure 23: Toolbox - Ladder Catalog: Figure 24: Toolbox - Hardware Catalog: Figure 25: Toolbox - Object catalog:
Programming functions, commands, Hardware modules and infrastructure Programs and configuration files
functions and function blocks components
The Smart Edit feature combines a range of intelligent functions that provide additional support in Au-
tomation Studio editors.
Auto-complete
Pressing <TAB> will automatically complete the entry of some
terms.
This feature is supported by the following elements:
Code snippets
The <CTRL> + <q>, <k> keyboard shortcut can be
used to insert code snippets into a program. Code
snippets are ready-made bits of source code that
can be managed by the user in the code snippet
manager.
Editors include a wide range of other useful features for keeping track of program code as
well:
Tooltips
Syntax coloring
Coloring for modified lines of code
Collapsed or expanded code segments
Opening variable declarations and function implementations directly from the program code
The software being developed for an Automation Studio project can be organized in the Logical View
(see 5.6 "Software management in the Logical View" on page 24) in such a way that it mirrors the
structure of the machine.
This provides a very clear overview of how the software is organized since there is a direct relationship
between the application and the machine.
Once software components are finished being programmed and configured, they can then be assigned
to different hardware configurations (see 5.8 "Managing configurations in the Configuration View" on
page 25).
The advantage here is that different variants of a single machine type can be managed in a single
Automation Studio project. These machine variants may vary with regard to the software and hardware
that they use (5.7 "Hardware management in the Physical View" on page 24).
The "CoffeeMachine" example can be used to illustrate the path from an initial design concept to a full
representation of the software and hardware components in Automation Studio.
How the software structure is represented in Automation Studio is based on the machine and its func-
tional units.
The software can now be structured according to the coffee preparation process.
System Designer
System Designer provides a visual representation of the Physical View. In System Designer, the control
components can be arranged just as they would be in the actual machine. I/O modules are added and
removed in the same way as in the Physical View (see 6.1 "Adding I/O modules from the Hardware
Catalog" on page 31).
Figure 35: Opening System Designer by selecting the icon in the Physical View toolbar
A configuration consists of hardware and software. Only one configuration can be [Active] at a time.
When a configuration is activated by double-clicking on it, the hardware assigned to it is displayed in
the Physical View.
The software configuration lists the software elements that can be transferred to the target system for
the active configuration.
There are several different ways to software to the software configuration:
5.9.2 "Automatic assignment when creating a program"
5.9.3 "Adding existing programs manually"
Figure 38: Opening the software configuration from the CPU's shortcut menu
Figure 39: When added, the software object is automatically assigned to the
software configuration of the active configuration
The order and priority of programs can be changed by moving the corresponding objects as
necessary directly in the software configuration.
If a new hardware configuration is added to a project, its software components must be added to the
software configuration manually.
To do so, the Logical View must first be active in the Project Explorer while the software configuration
is open.
An object can then be assigned by moving it from the Logical View to the necessary position in the
software configuration using drag-and-drop.
This procedure makes it easy to assign individually selected programs to a particular configu-
ration.
Figure 41: Adding a new configuration in the Configuration View using the toolbox
The tasks that have to be completed in the wizard when adding a new configuration are identical
to those for creating a new project.
This section is based on the project created in 4 "Creating a new project" on page 9.
This project already includes a configuration based on ArSim and a Ladder Diagram program with two
variables.
7) Creating a CompactFlash1
Requirements:
CompactFlash adapter
CompactFlash with 512 MB
X20 CPU (e.g. X20CP1486)
Digital input and output module (X20DI9371 and
X20DO9322)
A point-to-point connection between the PC and the
X20 CPU with a crossover Ethernet cable
This task consists of multiple subtasks that will be explained in detail in the next few sections.
1 Systems that don't have a CompactFlash are installed either via the USB remote install function or via the
transfer of the operating system in BOOT mode. More information about the variants can be found in train-
ing module TM213 - Automation Runtime or in the corresponding user's manual.
When using an X20 system, I/O modules can be added directly to the X2X Link interface.
To add I/O modules, the interface must first be selected in the Physical View. The I/O modules can then
be moved from the Hardware Catalog to the desired position using drag-and-drop.
Selecting the X2X interface filters the modules in the Hardware Catalog so that only the ones
that match this interface are shown. The results list is filtered by setting further filter categories.
It is also possible to search for a particular module by entering all or part of its model number.
Communication \ X2X
I/O mapping is another way of referring to the assignment of variables being used in the control program
to a module's I/O channels.
Variables can be allocated to an I/O channel in the I/O mapping editor that is opened using the shortcut
menu in the relevant module, by selecting <Open> / <I/O Mapping> or by double-clicking on the relevant
I/O module.
The ever-increasing functionality of remote B&R I/O modules continues to result in more and more areas
of application in which the modules can be used.
The I/O configuration can be used to configure I/O modules without having to do any programming.
The I/O configuration can be opened by selecting <I/O Configuration> from the shortcut menu of the
relevant module or by selecting <Open> / <I/O Configuration> from the main menu.
Selecting one or more I/O modules or interfaces in the Physical View will update the Properties window
located at the bottom right of the Automation Studio window. The Properties window shows all of the
configuration options that can be applied to the selected components. Individual property categories can
be opened directly in workbooks.
Figure 46: The Properties window is updated immediately when selecting one or more modules.
The data sheet for the selected I/O module can be accessed directly from the Physical View. To
do this, select the I/O module in the Physical View. To open the Automation Studio help system,
press the <F1> key. The data sheet for the selected module appears. The data sheet contains
technical information, configuration options, related examples and details of the status LEDs.
Automation Studio requires a network connection in order to communicate with the controller.
The following requirements are necessary to make this possible:
PC and controller on the same subnet
The assigned IP addresses may be used and are known.
If the PC is already running on a network, it is always a good idea to make a note of the current
network settings in order to restore them later if necessary.
Please contact the network's system administrator for detailed information about chang-
ing network settings.
The network properties can be opened using the shortcut menu for the desired Ethernet interface for the
controller. It is then possible to configure the parameters for the network interface as needed.
Getting started \ Creating programs in Automation Studio \ X20 CPU example project
Configuring Ethernet settings on the target system
Configuring Ethernet settings on the PC
Configuring the online connection
Programming \ Building and transferring projects \ Establishing a connection to the target system
Communication \ Ethernet \ AR configuration \ Interface configuration
Once a program has been completed, it must first be built before it can be transferred to the target system.
Rebuilding a configuration
When you recompile (Rebuild) a configuration (by pressing <CTRL>+<F7>), all the software objects in
the active configuration are created again, even if their source files have not changed since the last time
they were compiled.
Before a target system can be put into initial operation2, it is necessary to set up a CompactFlash card in
Automation Studio. This process partitions the CompactFlash card, transfers the operating system and
configures the necessary system settings.
A CompactFlash card and CompactFlash adapter are needed for this step. It is also possible
to include the Automation Studio project's source files with the CompactFlash data. This option
can be enabled in the configuration's properties (Configuration View).
Automation software \ Getting started \ Creating programs in Automation Studio \ X20 CPU
example project
Generating the data for a CompactFlash card
Once the CompactFlash card has been inserted into the X20 CPU, the controller can be started by turning
it on. If the network settings have already been configured (see 6.4 "Configuring network interfaces" on
page 34), then it is now possible to establish a connection to the controller.
2 The user memory may be built into the device or be a CompactFlash depending on the device type. Devices
with integrated user memory can be initialized using an online connection or the USB remote install func-
tion. Details can be found in the "Installation and startup" section of TM213 - Automation Runtime and the
Automation Studio help system.
The previous section explained how to configure the network interface settings for the PC and the con-
troller. These settings only have to be configured once before a connection can be made.
There are two ways to establish a connection:
Automatically browsing the network
Manually configuring the connection
The configuration dialog box for the controller's connection settings is opened by selecting <Online /
Settings> from the main menu.
If the network settings for the controller found on the network don't match those on the PC, the
entry will be marked in red. IP parameters can be changed temporarily from an entry's shortcut
menu. The temporarily changed settings can be added to the project configuration directly. If
the changes are not downloaded, the original projects settings will be used again after restarting
the controller.
Manual configuration
If it is not possible to browse the network, for example if SNMP broadcasts are blocked, it is possible
to set up an online connection manually.
If a connection exists between the PC and the controller, its status will be shown in the Automa-
tion Studio status bar.
Figure 54: An existing online connection to the controller has been established. The controller is in RUN mode.
It is now possible to use the online connection to transfer the project or perform diagnostics
on the controller.
Clicking on one of the texts in the overview image will open a description of the relevant settings
for the Automation Studio project and the PC.
Additional information can also be found in the following sections of the help system:
Programming \ Building and transferring projects \ Establishing a connection to the target sys-
tem
Programming \ Building and transferring projects \ Establishing a connection to the target sys-
tem \ Ethernet connections \ Browse for targets
Communication \ Ethernet \ Network settings
Communication \ Ethernet \ FAQ
Communication \ Ethernet \ Online communication
9 Programming
A program is a POU (program organization unit, as defined in the IEC 61131 standard) that possesses
the ability to directly access all global variables, functions and function blocks.
Several different programming languages are available in Automation Studio for creating programs. It is
also possible to combine several of these programming languages within a single project.
All text-based programming languages in Automation Studio use the same editor. As a result, diagnostic
tools always have the same features and are always operated in the same way. This high degree of
uniformity simplifies workflows and increases productivity.
Function blocks included in B&R standard libraries can be called and used in all of the pro-
gramming languages.
Programming \ Programs
Initialization subroutine
When the cyclic system is started, each task executes its initialization subroutine. This Init program can
contain program code which calculates and describes variable values.
Cyclic subroutine
The program's cyclic subroutine starts once the task's initialization subroutine has completed. Variables
which are described there retain their values until they are overwritten or until the system is restarted.
Exit subroutine
A task's exit program is only called when the task is uninstalled (deleted). If resources (e.g. memory,
interfaces, etc.) were requested in the initialization or cyclic subroutine, then these resources must be
freed up properly.
It is also possible for the user to create user-defined data types that
are based on basic data types. In Automation Studio, these user-
defined data types (or derived data types) are declared in a file with
the extension .typ.
Figure 58: Data type declaration file
The software can be structured as required using packages in the Logical View. This facilitates the simple
encapsulation of data and functionality.
This structure determines the scope and visibility of the declared variables and data types. In this way,
a variable can be defined logically at the appropriate place using the position of the .var file.
Automation Studio controls the visibility of the variables using the position of the .var file.
A variable always has a data type as one of its properties. The variable declaration can contain additional
properties for the variable.
Constants are variables whose values cannot be changed while a program is being executed. A constant
is assigned its initial value when the software is created (Value column).
Remanent and permanent variables (Retain column) are protected in buffered memory (SRAM) so
that they can be reloaded after a system restart (warm restart). Unlike remanent variables, permanent
variables are also protected against a cold restart.
In both cases, buffering (battery or rechargeable battery) in the CPU or backplane is responsible for
keeping the data safe.
3 Program organization units are defined in the IEC 61131-3 standard and referred to as POUs. POUs corre-
spond to programs functions and function blocks into which the control project is divided.
In order for variables to be stored in the permanent memory area, they have to be defined as Retain
and Global in the variable declaration window.
Frequent search tasks can be handled easily with the help of the
cross reference list.
This list contains all of the variables that are being used in a particular
program. This list also provides information about where and how
each variable is used in a program (e.g. read or write access).
The general project settings contain an option that, when enabled,
will automatically generate the cross reference list when the project
is built. This setting is found on the "General" property page after
selecting <Project> / <Settings> from the main menu.
Cross-reference list functions become available after the project has
been built.
9.5.1 Libraries
The standard libraries delivered with Automation Studio make it possible for users to access many dif-
ferent system functions. They allow, for example, physical interfaces to be freely programmed, reports
to be used in a targeted manner and hardware to be configured with a high level of flexibility. Numerous
example programs, which show how the libraries can be used, are available for import.
Programming
Libraries
Examples
mapp technology unites configuration and programming. Functionality is implemented in the application
program using standard libraries. In addition, mapp provides configuration interfaces that allow the func-
tionality of mapp components to be influenced without configuring their implementation in the application
software.
Working in a team means that the various responsibilities have to be divided up between team members.
Automation Studio includes functions designed to help teams work more efficiently:
Passing on project data via export with small file sizes
Taking on project data via import
Working with source control systems
Project management
Automation Studio Project \ Project Import / Export
Distributed development
Using source control systems
Completed software components can be exported and imported so that they can be shared or reused in
other projects. Exports are performed individually for each package in the Logical View.
If a package includes dependencies to libraries, they can be entered in the properties of the package.
These properties are checked when importing a package so that any required libraries are added au-
tomatically.
Prepared examples are available in Automation Studio as packages for B&R standard libraries that can
be imported into an existing project whenever needed.
The import procedure is started by selecting <Insert> / <Add object> from the main menu.
Programming \ Examples
There are other functions in addition to the creation of the CompactFlash and the calling of the System
Diagnostics Manager in Automation Studio via the "Tools" menu. This section briefly explains the function
of the Upgrades dialog box as well as Technology Guarding.
The ability to upgrade components makes it possible to update hardware and motion libraries as well as
upgrade to newer versions of Visual Components or Automation Runtime.
Upgrading components online is handled directly in Automation Studio.
The upgrade process is started by selecting the <Tools> / <Upgrades> menu. A dialog shows available
upgrades.
11 Summary
Automation Studio is more than just a programming tool. It provides support for the user throughout the
entire life cycle of a machine from the initial concept all the way to the finished project.
Whether it's being able to structure the software according to the different parts of the machine, working
with different configurations to design several different variants of the same machine or working together
concurrently in a team on the same project Automation Studio always has the right tools for the job
at hand.
Automation Studio is an invaluable resource for programmers, service technicians and maintenance
engineers for every stage of a machine's life cycle.
Training modules