SMAR - Tutorial on the as-i Technology

Embed Size (px)

Citation preview

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    1/18

    WHO WE ARE SYSTEM302 SUPPORT TECHNICAL ARTICLE NEWS TRAINING INDUSTRY SOLUTIONS AWARDS/RECOGNITION

    Tutorial on the AS-i Technology

    1. Introduction

    2. AS-i Associations

    3. Benefits

    4. Vers ions and Specifications

    5. Characteristics

    6. Connectivity

    7. TheActuator Sensor Interfa ce system

    8. Safety at Work

    9. AS-i Limitations

    10. Standards and Regulations

    11. Refer ences

    1. Introduction

    In 1990, in Germany, a consortium of succ essful companies created a bus sys tem for netw orking sensors and actuators calledActuator Sensor Interface (ASInterface or in short AS-i).

    This system w as meant to meet some requirements based on the experience of their ow n f ounding members and to supply the market whose hierarchy is

    oriented. Hence, the AS-i netw ork was conceived to complement the other existing systems and to simplify and speed up the connection between s ensors

    actuators and their controllers.

    Figure 1.1: Technological Scenario Source: ATADE, F.H. (2004)

    Back to Top

    2. AS-i Associations

    TheAS-International Association w as founded in 1991 as a user group for manufacturers and users of the AS-Interface system, w hose objective is turn the into a w orld standard for the bit-oriented field of industrial automation pertaining to the Sensor Bus c ategory. The AS-Interface UK Expert Alliance s upports

    promotes the technology in UK.

    The group provides to its members the latest market and technology information, including support to technical information, product certification, activities, cours

    Home About SMAR Contact Us Site Ma

    Select the language:Search... G

    Find your Product: :: by function :: by t echnology :: by name

    http://-/?-http://www.smar.com/en/news.asphttp://www.smar.com/en/training/http://www.smar.com/en/industries/index.asphttp://www.smar.com.cn/http://www.smar.com.mx/http://www.smar.com/http://www.smar.com.br/http://www.smar.com/en/index.asphttp://www.smar.com/en/sitemap.asphttp://www.smar.com/en/contactus.asphttp://www.smar.com/en/about.asphttp://www.smar.com/en/index.asphttp://www.as-interface.com/http://www.as-interface.net/http://-/?-http://-/?-http://-/?-http://-/?-http://-/?-http://-/?-http://-/?-http://-/?-http://www.smar.com/en/awards.asphttp://www.smar.com/en/industries/index.asphttp://www.smar.com/en/training/http://www.smar.com/en/news.asphttp://www.smar.com/en/technicalarticles/http://www.smar.com/en/support.asphttp://www.smar.com/en/system302/http://www.smar.com/en/about.asp
  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    2/18

    exhibitions and other events. Further details on http://ww w .as-interface.net orhttp://ww w .as-interface.com.

    In 1999 the AS-i netw ork w as regulated by the EN 50295/IEC 62026-2 standard . The associat ionsAS-International Associ ation orAS-Interface UK Expert Alli aare open to new members interested in developing certified products.

    Back to Top

    3. Benefits

    An industrial system formed by AS-i netw orks is considered to be the most economical and ideal for communication between actuators and sensors. The benefits

    using an AS-i network range f rom hardware s avings to the commissioning of an AS-i netw ork itself.

    Figure 3.1 illustrates some factors that should be considered w hen choosing an industrial netw ork and each particular benefit w hen using AS-i networks.

    Figure 3.1: Criteria for choosing the industrial network

    Source: AS-International Association (2008)

    Under this approach, the benefits may be summarized as f ollows:

    Simplicity

    An AS-i netw ork is very simple and needs only one cable to connect the input and output modules from any manufacturer. AS-i users do not need deep know ledg

    industrial systems or c ommunication protocols. Unlike other digital networks, the AS-i netw ork does not need terminators or equipment description f iles. Simplicity i

    strong point.

    Performance

    AS-i systems are ef ficient and very fast, making them able to replace large and high-costs systems. There are AS-i masters specially designed to communicate

    legacy control sys tems and provide a smooth integration of existing technologies. Best of all is that this is ac complished in a simple and reliable w ay.

    Flexibility

    Expansibility is v ery easy to get just connect a module, address it and then connect the netw ork cable. Check if the pow er supply LED is connected and

    connection to the next module is enabled. The AS-i netw ork supports any cabling technology: star, bus, tree, ring or other configuration up to 100 m of c able. Or

    by adding repeaters it is poss ible to expand the system up to 300 m. The AS-i netw ork is easy to install, since it needs no terminators at the ends.

    Cost

    AS-i netw orks typically reduce cabling and installation costs by 50% in comparison to other conventional netw orks (Figure 3.2). The use of a single cable

    connection to discrete devices reduces the need for cabinets, conduits and trays. The savings obtained in the network are really s ignificant, since using few ca

    brings dow n installation and commissioning cos ts and engineering time.

    http://-/?-http://www.as-interface.com/http://www.as-interface.net/
  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    3/18

    Figure 3.2: a) Conventional systems; b) AS-i network.Source: Stonel Corpora tion

    Cost savings w ith hardware and the AS-i network viability for especial applications are show n in Figure 3.3.

    Figure 3.3: AS-i system economic viabilitySource: AS-international Association (2008)

    Back to Top

    4. Versions and Specifications

    Original Specification (1994, Version 2.04)

    In the early netw orks, the slave modules interlinking the f inal elements enabled the connection of four digital inputs and four digital outputs, resulting in a total of

    inputs and 124 outputs on a single netw ork (AS-i 2.0 or AS-i 1 specs) . However, that architecture had only a maximum 31 slaves.

    Its main features w ere related to the automatic substitution of a netw ork module and the update time was easily calculated by multiplying the number of I/O nodes

    the deterministic update time for each node (approximately 150 microseconds).

    This simplified calculation does not include the Management Phase w hich is negligible for typical insta llations.

    Enhancements (1998, Ve rsion 2.11)

    Follow ing its introduction the users quickly adopted the technology, driving the demand f or additional functionalities and features. As a consequence, these dema

    w ere addressed w ith certain specification enhancements and the specification for the AS-i 2.1 (or AS-i 2) w as released. The new functionalities added are:

    Increase the number of possible binary devices f rom 31 to 62 at one master. The maximum

    bus capacity increased to 248 + 186 I/O, but the cycle time changed to 10 ms.

    An additional bit on the status record is used to signal peripheral errors. The indication of

    the slave performance w as standardized and expanded.

    The number of s lave profiles increased f rom 15 to 225 with the addition of new ID codes.

    Better analog signals treatment, thereby broadening the spectrum of action of AS-i

    networks.

    The chips f or the AS-i netw ork vers ion 2.1 are made by tw o consortiums: Siemens and Festo, the joint developers of the SAP4.1 chip, compatible pin by pin w ith

    SAP4, and the group of eight other members (Bosch, Hirschmann, ifm electronic, Leuze, Lumberg, Klockner Moeller, Pepperl+Fuchs , and Schneider Electric) , w

    developed the A2SI chip. Both chips provide all f unctionalities of 2.1 version.

    Additional Capabilities (2005/2007, Version 3.0)

    Up to 2005, the AS-i netw ork success w orldwide, w ith approximately 10 million nodes in operation, promoted the introduction of new requirements f or the netw

    Furthermore, the increased usage of Ethernet based industrial protocols called for a low -level solution that overcome the inherent shortcomings of Ethernet restricted topology, large data frame, costly usage of sw itches etc). This specification addressed the users requirements by defining new prof iles for binary

    analog data plus the introduction of a serial data transmission profile (3.0 or AS-i 3 specs) . The follow ing is an incomplete list of the new capabilities

    Binary I/O nodes supporting extended addressing mode (A/B) w ith 4 inputs and 4 outputs;

    Binary I/O nodes supporting extended addressing mode (A/B) w ith 8 inputs and 8 outputs;

    Configurable (8, 12 or 16 bits) f ast analog channel;

    Full Duplex bit serial data channel.

    With these new capabilities, AS-i becomes the ideal partner network f or of the currently available Ethernet based industrial protocols. Gateways to Ethernet//IPPROFINET, Modbus/TCP and others are available.

    Some controls experts have v oiced the opinion that w ithin the next 10 years networking solutions positioned betw een AS-Interface and Ethernet w ill not be use

    any new installation.

    Back to Top

    5. Characteristics

    http://-/?-http://-/?-
  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    4/18

    The nameActuator Sensor Interface is a simple and elegant solution to integrate discrete sensors and actuators on process control systems. This netw ork hseries of features, as follow s:

    Compatibility: Sensors and Actuators f rom different manufacturers may be connected to a standard digital serial interface;

    Access procedure: Cyclic polling, single-master system;

    Addressing:Slaves receive a permanent address fr om the master or hand-held type;

    Topology:Without restrictions (linear, ring, star or tree structure);

    Medium: Two unshielded, non-twisted cables (2 x 1,5 mm) f or data and electrical pow er (usually 24 Vdc), typically up to 200 mA per slave, up to 8A p

    bus;

    Fast installation: electromechanical interface w ith piercing technology;

    Cable length: range 100 m, scaleable by repeater up to 300m;

    Signals: Data and electrical pow er via the s ame line, max. 8 A poss ible;

    Number of slaves: Up to 62 slaves per netw ork (version 2.1);

    Data: 4 inputs and 4 outputs for each slave; f or more than 31 slaves, only 3 outputs (maximum of 248 binary inputs/outputs per network).

    Useful load: 4 bits/slave/message transmitted. All slaves arerequested sequentially by the master and receive 4-bit data. Each slave responds immediat

    w ith 4-bit data;Cycle time : Max. 5 ms and 10 ms according to 2.0 and 2.1 s pefications, respectively;

    Error detection: Eff ective error detection and retransmission of incorrect telegrams;

    AS-Interface chip: 4 I/O configurable for data, 4 output parameters and 2 control outputs;

    Master functions: Cyclic slave scanning, data transmission for slaves and f or the c ontrol unit (PLC or PC). Netw ork initialization, slave identification,

    transferr ed slave and data diagnostic. Also, r eports errors to the controller and addresses the replaced slaves;

    Valves: Installed directly on the application, reducing piping and increasing the actuator response speed;

    Low cost: Low connec tion cost per s lave and eliminates PLC input and output modules;

    Reliability: Highly reliable operational level in aggressive industrial environments;

    Open standard: Developed by renowned industries aff iliated to the A S-i International Association, w hose transmission protocol is standardized;

    Optional: output power supply cable and stop control.

    Back to Top

    6. Connectivity

    The AS-i network can be connected to main control level by two w ays. The first one is the direct connection (Figure 6.1, left). In this case, the master is part of a or PC being executed in the time cycle determined by these devices. An AS-i master can be built by any manufacturer, as it is an open standard.

    The second way is connecting it w ith a gatew ay betw een a higher-level network and the AS-i network (Figure 6.1, right). There are other couplers for other

    netw orks, such as Profibus, Interbus, FIP, DeviceNet, CAN, etc.

    .

    Figure 6.1 Interconnection with other digital networks.Source:AS-International Association (2008)

    Back to Top

    7. TheActuator Sensor Interface system

    The nameActuator Sensor Interface represents its ow n concept. Although technically meaning a bus, the term interfaceshow s that it provides a simple program faccessing field sensors and actuators.

    The AS-i industrial netw orks w ere designed to be applied on automated environments to replace the traditional actuator and sensor sw itch (on/off ) connections f o

    single bus. In addition it can also be c onnected to sensor and ac tuator buses that perf orm an analog conversion or vice vers a.

    Traditionally, these connections are made of tw isted pairs that connect each actuator and sensor, one by one, to the corres ponding controller, typically a P

    Programmable Logic Controller.

    The AS-i system is conf igured and controlled by a master that programs the interface betw een a controller and the A S-i system. The master continually exchan

    information with all sensors and actuators linked to the AS-i bus in a pre-determined and cyclic w ay.

    Figure 7.1 illustrates the entire AS-i s ystem enhancing its main components: cable, AS-i pow er supply w ith its decoupling circuit, the AS-i master and slave.

    Interface 1: betw een the slave and the sensors and actuators;

    Interface 2: betw een the devices (pow er supply, master and slave) and the transmission medium;

    Interface 3: betw een the master and the host, in other w ords, any entity that accesses the AS-i netw ork from an upper level.

    http://-/?-http://-/?-
  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    5/18

    Figure 7.1: Components and i nterfaceSource: SANCHES, L.B. (2004)

    7.1 Transmission Medium

    AS-Interface is a standard and open network sy stem (EN 50295) that connects actuators and sensors in a very simple w ay. A single cable connects the actua

    and sensors w ith the upper control levels.

    The connection of the elements can be done in tree structure, s tar, line, or a combination of both. Since there are no conventional connections and w ith the reduc

    of ter minal block and connector links, cos ts and mounting time, as w ell as errors, decrease.

    In the simple connection technique using parallel cables, each devices contact is connected separately to the ends and terminal blocks of sensors and actuators.

    AS-i network substitutes the traditional arrangement of multiple cables, passage boxes, conduits, trails, and cable ducts f or a single cable specially developed for

    AS-i network.

    The AS-i network features a single pair of w ires that transmits the data and electrical power to the sensors and actuators (usually 24Vdc) at the same time.maximum network conf iguration includes 62 slaves that are ac cessed cy clically by a master on the upper control level. The response time is short f or e

    connected slave: 10 ms.

    Formerly, sensors and actuators w ere connected to the c ontroller via the terminals, connectors and terminal blocks. AS-i enables the reduction of installation

    maintenance costs, w ith a standard tw isted cable that allows the exchange of data and electrical power betw een devices. Slaves are connected directly to the

    w ithout additional w iring. A flexible tw o-w ay cable was designed as standard for the AS-i netw ork. There is also a round shape cable for use only under

    manufacturer specification.

    7.1.1 Standard Flexible Cable

    This H05VV-F 2X1.5 high voltage flex ible cable complies w ith the CENELEC or DIN VDE 0281 standar ds, it is inexpensive and easy to get .

    Figure 7.2: Typical AS-i cables

    Source:AS-International Association (2008) e Turck Networks.

    The unshielded, non-tw isted AS-i cable has tw o parallel conductors that convey data and power to the slaves. Its external jacket is yellow and has a character

    geometric shape that w as designed to avoid fixation w ith reversed polarity (Figure 7.3).

    -

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    6/18

    . .Source: LIAN, S.C.P. (2003)

    The cable does not need cutting or s tripping to be connected. This practice generally causes undesirable voltage drops and is a constant bad contact source. On

    other hand, it has an interesting way to be installed, w hich favors costs s avings in its implementation.

    This is a simple principle: the contact w ith the internal conductors is done by c onductive blades that penetrate in the plastic insulation to reach the internal co

    w ires.

    The internal shielding has a healing property that closes it w hen the blades are disconnected, w ithout being seen when being cut lengthw ise. Evidently the shie

    remains perforated, but w ithout the risk of a short c ircuit. Figures 7.4a and 7.4b illustrate the concept.

    Figure 7.4: a) Module and bus coupling; b) Perforation pinsSource: SILVA, W.A.C.M (2008) and AS-International Associ ation (2008).

    In addition to the power s upply available to slaves through the yellow cable that became a sort of registered trademark for the AS-i system and serves almo

    purposes, some slaves may need a supplementary pow er supply, especially the most pow erful actuators. An additional black cable w ith the same properties is u

    only for s upplying power. It also uses the same previous penetration technique and supplies up to 24 Vdc.

    When selecting an adequate transmission media, tw o relevant electrical considerations should be done: the DC resistance on the pow er supply and the transmis

    features on the frequency band used on the communication. At least 2A of current must be available f or transmission on the slave power supply. Within th

    requirements, other cables can be used on specific cases, like for conducting larger currents or the need for movable cables. Besides these tw o types of ca

    there is also a red version f or until 230 Vac.

    7.1.2. Round Cable

    This cable w as designed specifically f or the AS-i, w ith almost similar electrical features, but w ith a specific t ype of installation. This cable can be shielde

    unshielded, but preferably the unshielded are used, w ith the following characteristics (at a f requency of 167 kHz):

    R: < 90 m/m

    C: < 80 pF/m

    Z : 70 to 140

    G: 5 S/m

    It is also recommended a cable with a transv ersal cross- section of 2 x 1.5 mm2.

    Figure 7.5: Unshielded round cables

    Source:AS-Interface Association

    7.1.3 Connections of the AS-i line

    Any connection to the AS-i line shall meet the following requirements, w hether a conventional technology or an insulation piercing technology is used:

    Contact resistance maximum of 6 m;

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    7/18

    Minimum allowable current of 1.5 Inom (minimum of 3A for a general AS-i line);

    Contact voltage range of 10 V to 70 Vdc;

    Shock and vibrations in compliance w ith item 7.4 of IEC 60947-5-2;

    Strain relief in compliance w ith annex E of IEC 60947-5-2 ;

    If a clamp or a screw terminal connector is used for connections, its capability shall be at least a 2 x 1.5 mm2. If plug connectors are used, the D.2 type accordin

    annex D of IEC 60947-5-2 is preferred.

    7.1.4 Cable Length

    The maximum length for an AS-i netw ork cable shall not exceed 100m w ithout the use of repeaters. A maximum of tw o repeaters to extend the length of the lin

    300 m is permitted. Four repeaters may be used to extend the line to 500 m if the master is centrally positioned on the first line segment.

    The length of AS-i line is calculated by adding the line length to tw o times (2x) the length of the connection accessories.

    Example: 50 m of y ellow cable and 5 tap-offs w ith 2m of cable gives a netw ork length of 50 + 2 x (5 x 2) = 70 m netw ork.

    Figures 7.6 and 7.7 show solutions for extender and repeater connections to extend the AS-i line.

    Figure 7.6: Solution w ith one extender and one repeater

    Source:AS-Interface Association

    Figure 7.7: Solution with tw o repeaters

    Source: AS-International Associ ation (2008).

    7.2 Power Supply

    The AS-i power supply has four functions, as follows :

    7.2.1 Power Supply

    The power supply unit w orks w ith a voltage of 26.5 V to 31.6 Vdc, and supplies a current of 0 A to 8 A (typical current per slave is 200 mA) under normal opera

    conditions. The pow er supplied to the slaves and partially to the master through two w ires is the same used to transmit AS-i data, and can be connected to any p

    on the netw ork. On long lines, the v oltage drops must be taken into account but s hould not exceed 3 V on a w hole 100 m cable. The unit has an internal over

    protection circuit w ith current limit.

    7.2.2 Balancing

    The power supply unit also balances the AS-i netw ork, w hich is operated as a non-grounded symmetrical system. For noise immunity the A S-i cable must installe

    symmetrical as possible through the balancing circuit show n in Figure 7.8. The s hielding connection must be at an adequate point on the machine or the system.

    at this point it can be connected to the sy stem ground (GND).

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    8/18

    Figure 7.8: AS-i pow er supply simplified diagram

    Source: SANCHES, L.B. (2004)

    7.2.3 Data Decoupling

    The third function of the pow er supply unit is decoupling data, w hich is normally done by the decoupling networ k on the pow er supply module. This netw ork cons

    of tw o inductors of 50 H each (L1 and L2) and tw o resistors of 39 each in parallel. The inductors perform a differentiation job on the voltage pulses to convertcurrent pulses generated by the transmitters connected to the netw ork. At the same time, they prevent short circuits on the cable. The coupling between

    inductors shall be as close as possible to 1, meaning that the mutual inductance must tend to 200 H.

    7.2.4 Safety

    The fourth function is related to safety. The AS-i system was designed as a system for low voltages w ith safe separation (Protective Extra Low Voltage). In ow ords, according to the relevant IEC standards, safe separation betw een the power supply and the AS-i netw ork is required.

    7.3 Redundancy

    This situation is not very common on AS-i netw ork, since it is a system w here prevail discrete communication and also robustness, determinism and simplicity.

    redundancy can w ork at the master and the power s upply levels. So far there is no redundancy at the cables and slaves levels.

    A netw ork may have a redundant master. It will stay in monitoring mode and will take over control w hen noticing a failure or lack of c ommunication on the part o

    active master. In regard to the power supply, this is also possible with a pow er extender, w hen tw o power supplies are connected in a redundant mode.

    7.4 Interface 1: Sensors and Actuators

    7.4.1 The AS-i Slave

    The AS-i slave, as shown in Figure 7.1, represents the link betw een the AS-i transmission s ystem and Interface 1, to w hich the sensors and actuators

    connected. The slave powers the sensors/actuators and handles communication between them and the master. When the AS-i specification w as developed, it

    clear that the slave needed to be small and compact as w ell extremely inexpensive to be able to be integrated directly to the sensors and actuators. This ca

    achieved only through the use of a highly integrated circuit, w hich originated the famous AS-i chip.

    The AS-i slave chip allow ed for s ensors and actuators to be integrated to the AS-i bus as a slave device that r ecognizes the master output command and sends

    in response. A great number of sensors and actuators used recently in automation allow low cost per connection in AS-i slave chips. In the case of analog dev

    the data exceed 4 bits of useful information per cycle: the data are divided and sent in several cycles.

    An AS-i chip can be used in two possible w ays:

    Embedded in sensors and ac tuators, w ith the elements integrated to the AS-i (Figure 7.9) and every data bit and parameter available to the device (senso

    actuator).

    Figure 7.9: Sensor or actuator with integrated AS-i.Source:AS-International Association (2008).

    Another w ay is using the AS-i slave chip embedded in modules w here conventional sensors and actuators may be connected. Figure 7.10 shows a mod

    w ith two inputs for sensors and two inputs for binary actuators.

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    9/18

    Figure 7.10: Module 2I/2O for conventional sensors/actuatorsSource: AS-Interface Associ ation.

    7.4.1.1 Structure of the AS-i Slave

    Regardless of w hether the slave is implemented using the integrated circuit or some other w ay, it w ill have the structure show n in figure 7.11, w hereby

    connections for interf ace 1 may be physical or logical, and those for interface 2 must be physically present.

    In the supply voltage the data path is separated from the pow er path by an inductance.

    In order to implement it in a integrated circuit (IC), this inductance is realized electronically and guarantees that the slave sustains a highly-enough resistance on

    communication data frequency band. The supply voltage is f urnished on the Vout terminal.

    Figure 7.11: AS-i slave architectureSource: SANCHES, L.B. (2004).

    In the receiver the voltage pulses detected on the AS-i cable are f iltered, digitized and w ritten to the receive r egister. A t the same time the received signal is subje

    to various plausibility checks to ensure that no noise pulses have corrupted the master request.

    In the sender the information from the send register is encoded and sent out over the AS-i cable as a current pulse sequence acc ording to the APM modulation.

    The sequence controller finally decodes the master requests, checks them for err ors, carr ies out the commands encoded in them and if appropriate causes a rep

    be sent. The sequence controller also has a memory w hich is used for recording the slave address and w hich can store it f or an unlimited time without pow er (

    volatile).

    The slave has the following registers and flags:

    Address register: This 5 bit-wide register contains the curr ent slave address. If the address sent in a master request agrees w ith the address contain

    in this register, then this s lave w ill reply. After a RESET the register is loaded w ith the address c ontained in the non-volatile memory. Its c ontents can be

    changed by the master using the commands Delete Address or Address Assignment.Identification register s: These 4 bit-w ide registers contain the I/O configuration and the ID Codes of the slaves. They are permanently stored and loade

    from the non-volatile memory after a RESET. They are (w ith the exception of the ID Code 1) f ixed at the time the slave is manufactured and cannot be

    modified.

    Data output registe r: The Data Output register is 4-bits w ide and contains the data from the last Data Request, w hich w as received w ithout any err

    by the slave. Those bits that are allocated to an output in accordance w ith the I/O configuration are output on the respective data port, and the information

    from the other bits is ignored. After a RESET the register is loaded w ith the default value FHex.

    Parameter output register: This 4 bit-wide register contains the parameters from the last w rite parameter request f rom the master that w as received

    w ithout error by the slave. The bits are output on the corresponding parameter ports.

    Receive register: This 12 bit-wide receive register contains the last message sent by the master f or further processing in the on the sequence control.

    Send register: This 5 bit-wide send register has the s lave response to be sent.

    Status register: This 3 bit-wide register indicates certain slave status c onditions or errors :

    Flag S0: is set during address storage if the new address has not yet been permanently stored.

    Flag S1: is set if the input FID reports a peripheral error.

    Flag S3: is set if an err or has occ urred w hile reading the address from the permanent memory.

    Synchronization flag: Ifthe slave has correctly received a master request, decoded it and, if appropriate, acknowledged w ith a reply, the

    Synchronization flag is set. In the synchronized state the master pause is monitored after the master request f or one bit time, and the slave response ca

    start after a tw o bit times.

    Data exchange blocked flag: This flag is set by a RESET, and it is reset by errorless receipt of the f irst parameter request to its ow n slave address. Th

    prevents data requests from being accepted as long as the parameter ports have not been loaded w ith the nominal parameters. This behavior is necess a

    for preventing misunderstandings betw een the master and slave. It could happen, for ex ample, that due to poor electrical contact on the AS-i cable a s la

    w ithout the master knowing it receives no supply voltage for a brief time and performs a RESET. Then the parameters ports are reset, and any associ

    functions of the slave are set to the default state. As a consequence, the slave could respond differently than the master expects.

    7.4.2 Interface 1

    As show n in Figure 7.11, the interface 1 has f our data ports w hich, depending on the selected I/O Configuration, can be either as inputs ports, as outputs ports o

    directional communication. A data strobe output is also provided, w hich signals when output data are present and w hen input data are expected.

    For actuator slaves it is recommended that the time-out monitor, also called a w atchdog and w hich is integrated in the slave IC, be activated. If, w hile a timing mem

    is running, no new correctly rec eived Data Request arrives at the address of the slave, the actuator can use the w atchdog to place the system in a safe s

    Such time-out monitoring allow s a variety of error possibilities to be covered, suc h as hardw are faults in the master, interference on transmission cable or loss of

    address in the slave, and makes the AS-i s ystem safer. Normally, a time-out period is specified fr om 40 to 100 ms.

    In addition to the data ports, w hich are provided for cyc lical data exchange with the master, additional ports are available w hich are used for (ac yclic) param

    output. Here again an additional strobe ouput indicates w hen a new parameter message has arrived.

    The FID input is used to signal peripheral errors. If the slave electronics detect an error (such as overloaded supply voltage caused by an external short), this in

    can be used to display the event locally, through LEDs and to r eport it to the master using the s tatus register. The master makes an entry in the list of peripheral er

    and sets a collective flag.

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    10/18

    Finally, a DC voltage is provided to the connected sensor or actuator on the Vout port w hich is generally within the tolerance range of 24V +10/-15%.

    7.5 Interface 2: Transmission system

    Interface 2 includes the specifications necessary f or an eff ective data exchange between the elements connected to the AS-i bus. It defines the w ay to acces

    the physical medium, the data exchange on the electrical level and how to deal w ith some communication errors, as w ell as the time requests on the transactions.

    7.5.1 Network structures

    The topology for AS-i netw orks is left to the users discretion to simplify the project. The restriction is not observed if the maximum limit for the cable length is 100

    longer lengths are required, repeaters are used to extend the netw ork range, provided the limit of 62 s laves and one master is observed. No terminal impedanc

    needed, simplifying the installation. Structures in tr ee, linear, star or ring are possible (Figure 7.12).

    Figure 7.12: Physical network topologiesSource: AS-International Associ ation (2008)

    7.5.2 Modulation

    The selection of an adequate modulation for the AS-i should be taken into consideration the follow ing requirements w hich led to the c reation of a new modula

    procedure known asAlternating Pulse Modulation (APM). The most important is:

    The message signal superimposed on the supply v oltage for the s ensors and actuators must be direct current f ree;

    The slaves sender (and w here possible the masters sender) must be able to generate the signal in a simple, i.e. cost- eff ective and space-sav ing manne

    Since the AS-i cable has impedance w hich increases greatly over the f requency, the message signal must be relatively narrow -banded.

    High levels of noise radiation are also unacceptable.

    The result w as Alternating Pulse Modulation (APM), a procedure f or ser ial transmission in the base band and is show n in Figure 7.13. The bit sequence is

    encoded into a bit-sequence that performs a phase change w henever the signal changes (Manchester coding). The result is a send current that in conjunction

    the single inductor in the system uses dif ferentiation to generate the desired signal voltage level on the AS-i cable.

    Each rise in the s end current thus results in a negative voltage pulse and each drop to a positive voltage pulse. In this w ay it is quite simple to generate signals in

    slaves that have a higher voltage than their actual supply voltage. This eliminates inductors from the slaves and keeps the integrated electronics small

    inexpensive. On the receiver side these voltage signals are detected on the line and converted back into the send bit- sequence. The receiver synchronizes i

    w ith the first detected negative pulse, w hich it interprets as a start bit of message.

    If the voltage pulses approach sin2 pulses, the r equirements for low limit f requency and low noise emission are met at the same time. This is done by meansuitable shaping of the send current pulses, w hich are generated like the integral of a sin2 pulse. Using this modulation procedure and the available topologies

    times of 6s are attainable, w hich allows a gr oss transmission rate of 167 kbit/s.

    Since the cables do not have terminators, the message pulses have a large amplitude variation. The A S-i represents an extremely r obust sys tem able to deal w ith

    problem caused by c able end reflections that reach the higher frequencies.

    Figure 7.13: AS-I network modulation signalSource:SANCHES, L.B. (2004).

    7.5.3 Access procedur es

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    11/18

    Since the AS-i w as designed to replace star type 2-point connections (traditional cable tree), a bus access procedure w as selected w hich reproduces this topo

    and is able to ensure a defined response time (the master-slave access w ith cyclical polling). The master sends a telegram that is received at a particular s

    address, and the s lave contacted at this address replies w ithin the provided time. This operation is described like a transaction. The transmission system only ena

    the connection to a bus w ith one master and a maximum of 62 slaves.

    The procedure chosen for AS-i allow s the construction of very simple and thereby cost-eff ective slaves w hile providing at the same time the greatest poss

    flexibility and integrity. In case of a brief disturbance on the line, for example, the master can repeat telegrams to the address w hich received either no reply o

    invalid reply. This means it is not neces sary to repeat the entire cycle ov er again.

    7.5.4 AS-i mess ages

    There are two types of A S-i messages: those sent by the master and the slave responses. Figure 7.14 illustrates a transaction and the periods of time involved

    AS-i message consists of a master request, a master pause, a slave response and a slave pause. All master requests are exactly 14 bit times in length, and all s

    responses have a length of 7 bit times. A bit time corresponds to a uniform 6s.

    Figure 7.14: Structure of an AS-i. messageSource: SICK Industrial Sensors (2010).

    The master pause is allow ed to be at least 2 and maximum of 10 bit times in length. If the slave is synchronized, it c an begin to send its response after as soon

    bit times. If it is not sy nchronized, it r equires 2 bit times longer, since is monitoring the master pause during this time for any additional information before it can ac

    the poll as valid. If the master, howev er, has not received the start bit f or the slave response af ter 10 bit times, it can assume that there is no response forthcom

    and it can begin w ith the next request. The pause (slave pause) betw een the end of a slave r esponse and the next master request should be no more than 1.5

    bit times in length.

    A master poll of a standard slave consists of :

    Start Bit (ST). Identifies the beginning of the master request. Its value is alway s 0.

    Contro l Bit (SB). Identifies the type of request: 0 for data, parameter request or address assignment; and 1 for command request.

    Address (A4..A0). Address of the contacted slave address requested (5 bit).

    Information (0, D3D0). These 5 bits contain in order to the type of request, the information to be transferr ed to the slave.

    Parity Bit (PB). The number of all "1" in the master call has to be even.

    End Bit (EB). Identifies the end of the master request. Alw ays has value 1.

    The slave response consists of:

    Start Bit (ST). Identifies the beginning of the slave response. Its value is alw ays 0.

    Information (D3..D0). These 4 bits represent the properly information sent to the master.

    Parity Bit (PB). The number of all 1 in the slave r esponse has to be even.

    End Bit (EB). Alw ays w ith value 1, it signals the end of the slave response.

    AS-i Specification Version 2.1 (1998) created the possibility of connecting 62 slaves to an AS-i netw ork instead of previous 31. To make this possible, an inform

    field bit is used for select bit, as it is known. Hence, the slaves connected to the bus w ere divided in tw o groups of a maximum 31 slaves: group A and grou

    Therefore, a slave, besides having an address, received a distinguishing type: A orB. This change was introduced in a way to avoid losing the compatibility of

    version slaves with new v ersion masters.

    The former slaves can be addressed normally, but occupy tw o addresses each. They do not distinguish slave A from s lave B and do not recognize a selectio

    as such, but as normal information bit. The masters adapted to the new version have w ays to identify the s lave type and send requests properly. This w ill be sfurther on.

    7.5.5 Data integrity and error r espons e

    Reliable error recognition is of great importance for a faultless communication over the AS-i c able, w hich is generally unshielded. Since the AS-i telegrams in

    transactions are quite short, t he error detection is diff erent fr om the one normally applied to other f ield netw orks. The master request contains 11 bits of data t

    checked, and the slave response has 4 bits. The addition of bits f or checking message errors w ould drastically reduce the achievable netw ork transmission rate.

    So instead AS-i performs greater checking on the bit transmission itself. This makes use of the knowledge of redundancies in the code and the fixed lengths of

    telegrams. As a result the follow ing errors can be distinguished:

    Start bit error;

    Alternating error;

    Pause error;

    Information err or.

    Parity err or;

    End bit error; and

    Telegram length error.

    Each master request and each slave response is subjected to these checks. If one of the errors named is detected, the request is considered faulty or the respo

    is invalid.

    7.5.6 Analog Signals

    AS-i supports the transmission of analog signals and the digitalized analog signal value is s eparated in multiple parts and transmitted in s everal cy cles. A n an

    input signal of 12-bit data requires 6 c ycles, f orming the total transmission time of 30 ms (in the version 2.1 of the AS-i specif ication).

    An A /D conversion circ uit must be integral part of the slave device w ith analog I/O signals. This circuit w ill execute not only A/D convers ion, but also freeze

    converted value until all bits are totally transmitted, and only then w ill be ready for a new analog signal sample.

    The AS-International defined a standard for analog signal transmissions (defined on the profile S-17 of the AS-Interface specif ication). To facilitate its use, some P

    already off er funct ional blocks to be applied with analog signal values.

    To ensure data consistency betw een master and slave, a handshake bit was defined in the profile, w hich is inverted by the slave and returned. Thus the master

    check if the slave has responded and the slave may check if the master w ants the last request to be repeated or if it w ants the next data. On the other hand

    reduces the useful load on each frame to 3 bits per cyc le, while ensuring the right transmission of data even w ith disturbances. For analog inputs, the ma

    requests and the slave responds; f or analog outputs, the slave requests and the master responds.

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    12/18

    Figure 7.15: Analog value transmission sequence.Source:ATAIDE, F.H. (2004).

    7.6 Interface 3: The AS-i Master

    The AS-i master represents the bridge to the users controller or to a host fieldbus system. It organizes data traffic on the AS-I cable independently, so that at

    interfaces to the c ontroller and to the connected sensors and actuators the sy stem behaves like a traditional cable tree, w hile allow ing additional user f unctions sas the transmission parameter settings or monitoring and diagnostics information.

    The AS-i specification divides the master into three layers, w hich describe the master from the AS-i cable to the host interface (Figure 7.16).

    Figure 7.16: AS-i Master Structure in layers

    Source: SANCHES, L.B. (2004)

    The physical transmission of the requests from the master is specified by the interf ace 1 and has basically the same characteristics of t he slave.

    The lower logic layer is the transmission layer, w hich is responsible for the transmission and reception of individual telegrams. The automatic telegram repetition w

    the slave response fails is possible and ensures the upper layers integrity.

    The sequence control or execution control is just above the transmission layer and passes requests f or data transmission to the latter. The s equence control con

    the sequence telegrams. In addition to the actual sequence control, the sequence c ontrol layer processes functions that are requested by the host through the ma

    layer. In addition to the sequence control, the sequence control layer processes f unctions that are requested by the host through the master layer.

    The highest layer is the master layer, in which the AS-I functions are adapted to the respective host system. This layer is w here profiles are formed w hich allo

    restriction of the master functions usable by the host.

    7.6.1 Master Requests

    The AS-i master connects the interfaces 2 and 3 through messages sent to the slaves, one by one. In the following section are show n some possible f ew requ

    that the master can perform to a given slave through the interfac e 2, and the behavior expected from the slave to cope w ith these requests or, in reality

    responses.

    Figure 7.17 show s all possible requests a master can make to a slave, per AS-i specif ication 2.1, w hich accepts the extended addressing. One can notice

    presence of a select bit on the requests. This bit replaces the bit previously used on the exc hange of c ommon data. The addition of this new bit made pos

    addressing twice as much the initial number of s laves: 62. The slaves then, besides having an address betw een 0 and 31 gained an A or B ty pe, that is define

    the select bit.

    Figure 7.17: Master requests based on specification 2.1Source: BECKER et al. (2002

    These requests are analyzed one by one, as follow s.

    Read I/O configuration: With this request the master can read the set I/O configuration of a slave. This is sent in the slave response to this request and is u

    together w ith the slave Read ID-Code requests f or unambiguous identification of a s lave. The I/O configuration refers to the data ports on Interface 1 of the s

    and is defined as show n in Figure 7.18. In this def inition IN means a process input, OUT a process output, I/O a bi-directional behavior of the port, and TRI indic

    high-impedance outputs w ith no funcion. The latter state is ass umed w hen during the reset a read error of the slaves data memory means that no unambiguous

    configuration could be determined.

    Wherever an output OUT (and no bi-directional behavior) is def ined, this means that the corresponding information bit in the slave response is undefined. Likew

    the information bit from master request remains w ithout meaning wherever an input (IN) is def ined, even though the bit is sent.

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    13/18

    Figure 7.18: I/O configuration.Source: BECKER et al. (2002)

    This I/O configuration allows unneeded information to be hidden. At the same time the I/O configuration is used together w ith the ID Codes for identification o

    slaves. This reference is the slave profile. The I/O configuration is 4 bits long, is fixed by the manufacturer and is stored in the slave so that it cannot be changed.

    Read ID Code: The slave ID code compliant w ith the version 2.1 of the s pecification has tw o other codes, besides the original ID code read by the master on

    Read ID Code request: "Extended ID Code 1" and "Extended ID Code 2". Together they identify diff erent slaves. The slaves compliant w ith the new specifica

    have the ID code A in hexadecimal, w hile an ID code B indicates a safety at w ork slave. All of the s laves with an ID code equal to A also have tw o oth

    codes.

    Read Extended ID Code 1: This command is similar to the prev ious one and reads the s lave extended code 1. The user c an change this part of the ID Code.

    Read Extended ID Code 2: This code extends the slave configuration possibilities and, as the original ID code, cannot be modified by the user, being expli

    defined by the manufacturer.

    A slave prof ile issued by the combination of the ID codes and the I/O configuration contains a parameter behavior def inition, data ports and other additional s

    characteristics.

    Data Request: This command is most commonly used on the A S-i to attribute slave output values on the interf ace 1 and get input values in response. As said befthe ports behavior is defined by the I/O configuration. The data ports can be used in various w ays, not only as binary inputs and outputs of process variables. T

    also are used as additional configurations and as digitalized representation of analog process v ariables.

    Para meter Request: This command is used by the master to send the bit pattern for the parameter outputs on Interface 1 that control certain functions in the sl

    The last sent parameter value is stored in the slave until it is overw ritten by a new one or reset.

    For a standard slave 4 bits of parameter data are available, and 3 bits for a slave in extended addressing mode, since one of them is used as selection bit

    parameter request to address 00HEX is not possible, since the s lave w ould interpret this as an addressing request.

    Address Assignment: This command allows the master to permanently set the slave address w ith the previous address 00HEX to a new value.

    The slave sends a recognition response and starts the recording of the non-volatile memory, w hich cannot last longer than 500 ms. During the process the s

    begins responding to the requests on the new address. This request allows replacing damaged slaves w ithout restarting the network.

    Reset Sla ve: This command can be used to set a slave to its base state. It has the same effect as the reset after applying supply voltage or the reset on the re

    input of Interface 1. It does not last longer than 2 ms.

    Delete Operating Address: The command Delete Address is used to temporarily delete the operating address of a slave and is needed in conjunction

    Address Assignment because the Address Request can only be performed by a slave having an operating address 00HEX. For example, to change a s

    address the Delete Address request is used first and next the Address Assignment.The slave acknowledges error- free receipt of Delete Address w ith

    reply 00HEX and can be reached from this point on under the new address. Deleting the operating address in this manner is not permanent. To restore the ori

    address s tored in non-v olatile memory after executing this c ommand, use the command Reset_AS-I Slave.

    Read Status: This request is used to read out the status register of the corresponding slave. Its content is sent in the slave response to this request. The sta

    register of a slave contains three flags whose meanings are as follows :

    S0: "Address Volatile". This flag is set w hen the slave-internal routine for permanently storing the slave address is running.

    S1: "Peripheral Error". This flag is set w hen the slave has detected a high input on the interface 1 FID port, w hich indicates an external failure on the

    equipment.

    S3: "Read er ror non-volatile me mory". This flag is set w hen a read error occurs during a reset w hile reading the non-volatile memory.

    The bit S2 is not used yet and is reserved for future enhancements. The master can use the information from status register for diagnostic purposes. Slav

    accor ding to Specification 2.0 do not support the flag Peripheral error. When the master is communicating with a slave having extended ID Code 2 equal to FHE

    ignores flag S1.

    Broadcast: command requests containing 15HEX are defined as broadcast commands. These are characterized by the fact that they do not need to be replie

    by the slaves. For this reason, they ar e atypical of normal AS-i data communication and until now only t he broadcast command Reset is def ined.

    7.6.2 Transmis sion Layer

    This layer, also known as transmission control, exchanges individual telegrams w ith the slaves. It receives a remittance r equest from the sequence control, toge

    w ith the data that w ill be sent via the communication channel w ith the addition of the start bit, the parity bit and the end bit, which generate the master fr

    (telegram). This telegram is sent according to the time requirements of the transmission system, as described on 7.5 section.

    The function for data transmission offers the sequence control, tw o transmission methods: one-time transmission or repeatable transmission.

    In the first case, if there is no response f rom the slave after the w aiting time limit, or, if the res ponse is not a valid one, the transmission control reports the e

    immediately to the upper layer, w ithout resending the telegram.

    In the second one, the error is only reported after a second unsuccessful try. On the other hand, if the transaction is successful, the transmission control provid

    the sequence control w ith the data sent by the slave w ithout the additional start, end and parity bits. The transmission control also reports anAS-i Power Fai l (Asignal to indicate that the supply voltage on the line is too low .

    Figure 7.19 illustrates the state machine that models the transmission control behavior. The MT initials come from multiple transmission and means thattransmission control resends a telegram in case of error on the f irst one.

    Alternately, ST means single transmission, and the error is reported after the first failure. The status transitions occur in function of logical operations represenby the operators in italic andand or. The inputs and outputs are separated by a s lash (/)

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    14/18

    Figure 7.19: Transmission controlSource: SANCHES, L.B. (2004)

    7.6.3 Data fields and lists on the s equence control

    The execution control or sequence control generates AS-i telegrams in the correct s equence, using the individual frame sending service executed by the lower la

    To this effect, it has a set of data and lists that keeps the image of the AS-i netw ork and its slaves constantly updated, which is used by the upper layer to imple

    the interface w ith the host.

    These data fields are presented as follow :

    Input Data Image (IDI): This field contains the copies of the most recent slave data rec eived by the data request. Each slave occ upies 4-bit memory.

    Output Data Image (ODI): This field contains the most recent data w ritten by the host to be sent to the slaves by a data request. Here also are required 4 bi

    each one of the 62 slaves.

    Anal og Input Data Image (AIDI): This field contains the most recent data received from the slave analog inputs according to the 7.3 and 7.4 profiles, like the

    data.

    Anal og Output Data Image (AODI): This field, like the previous one, contains the most recent data to be s ent to the analog outputs.

    Configuration Data Image (CDI): This field contains the I/O and ID codes for each slave. Therefore, 2 bytes are required for each s lave.

    Permanent Configuration Data (PCD): This field is similar to the previous one, although in a non-volatile area. The ID codes or I/O configuration of a slave ab

    from the netw ork are filled w ith the F value (hexadecimal).

    Para meter Image (PI): This area is reserved f or each slave 4-bit parameter. Therefore, tw o slaves occupy one byte.

    Permanent Parameter: This field keeps the parameters conf igured for each slave and is in a non-volatile area, like the PCD.

    List of Detected Slaves (LDS): Each slave corresponds to one bit in this list and is activated w hen the slave is detected correctly.

    List of Activated Slaves (LAS): In this list the bit corresponding to the slave is activated when the slave is activated correctly.

    List of Projected Slaves (LPS): This list is on the non-volatile memory and represents the slaves that are supposed to be connected to the A S-i network w hen

    turned on.

    List of Peripheral Fault (LPF): In this list the bit corresponding to the slave is activated w hen a high signal is detected on the slave FID pin (section 7.4).

    In addition to these data fields, the execution control reports the master conditions to the host through the flags. The flags are the f ollowing:

    Config_OK: This flag is set w hen nominal and actual conf igurations are in agreement. This Config_OK flag enables simple monitoring of the configuration

    LDS.0: Indicates the presence of a slave w ith address 0, w hich is not allowed on the normal operation;

    Auto_Address_Enable:Indicates that the automatic addressing is enabled;

    Auto_Address_Available:Indicates that there are c onditions to execute the automatic addressing*;

    Mode: Indicates if the master is on Configuration mode (1) or Protected mode (0).

    Normal_Operation: Indicates that the master is transiting cyclically betw een the normal operation stages;

    AS-i Power Fail (APF): Indicates voltage on the bus below the low er limit;

    Offline_Ready: Activates w hen the offline phase is complete;

    Periphery_OK: No slave is reporting a periphery error;

    Offline: When activated by the user, sw itches the master from a sequence control to off line phase;

    Data Exchange Active: Enables data exchange betw een the master and the slaves.

    *For the sake of terminology, a distinction is made betw een this flag and the previous one. The first one is user-def ined and permits the auto addressing, prov

    certain conditions are met, w hich is indicated by the Auto Address Available flag.

    Its noting that four of these f lags are user enabled - host - and aff ect the master behavior: the tw o last ones in the list, Auto Address Available and Mode. Al

    others flags c annot be altered by the user and are controlled by the master.

    The master behavior is divided in several stages, or phases, w hich are executed by the execution control.

    Figure 7.19 illustrates the status device that shapes the execution control behavior. The dotted area indicates the normal operation mode, i.e., w hen the ma

    performs a cyclic data exchange w ith the configured slaves and keeps the "Input Data Image" up to date and the data ports according to the " Output Data Imarea. Besides the exchange of input and output data carried out during the Data Exchange stage, information is exchanged in the normal operation cycle of

    netw ork management in the other tw o stages.

    The operational detailing on each stage w ill permit to grasp the execution of the entire control process behavior, and, consequently, most part of the master behav

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    15/18

    Figure 7.20: Execution control stages

    Source: SANCHES, L.B. (2004)

    7.6.4 Transmis sion Phases

    Af ter the supply voltage has been turned on, the master cycles through v arious transmission phases. First initialization takes place in the of fline phase, f ollowed

    the detection stage, when the slaves c onnected to the bus are identified. After being detected, the slaves are activated on the next stage and are ready to enter

    normal operation cycle (dotted line in Figure 7.20), w hich is f ormed by a data exchange phase, a management phase and f inally an inclusion phase. A s w ell as

    cycle of data exchange, management and inclusion phases is identified as a normal operation, the off line phase composes the master initialization, w hereas

    detection and activation phases compose the master s tart-up.

    Initialization

    Initialization during the of fline phase places the master in base s tate. The data in the "Input Data Image" for all slaves are set to zero (inactive inputs), and the " OuData Image" to one (inactive outputs). This ensures that the state of the slave outputs does not change w hen the master is turned on.

    The sequence control can be brought to any other state to the offline phase by setting the offline flag. The offline flag thus has the function of resetting the comp

    netw ork and the master.

    Startup

    In startup operation the sequence control detects all the connected s laves and activates them.

    In the detection phase the master sends requests to read the s lave I/O Configuration and ID codes, one by one. Slaves that respond to all requests are entered in

    List of Detected Slaves (LDS). Their I/O Configuration and their ID codes are stored in the Configuration Data Image (CDI).

    In the activation phase the master operation modes are considered as follow s:

    Configuration mode (also c alled as project mode);

    Protected mode.

    In configuration mode all detected slaves (w ith exception of the zero address) are activated by a "Parameter Request", where all slave output parametersw ritten, and a Data Requestw ritten on the corresponding slave ports. If the slave r esponds correctly to these tw o requests it is activated and is included onLAS. In protected mode only the detected slaves w hich are also listed in the List of Projec ted Slaves (LPS) and w hose I/O configuration and ID Codes agree w ithprojected configuration are activated. The master thus exchanges data only w ith the pre-configured slaves. At the end of the activation phase a check is made to

    w hether the nominal (detected) and actual configuration (projected) agree and then Config OKflag is set. Figures 7.21 and 7.22 show f low sheets that simulatemaster behavior on the detection and ac tivation phases.

    Figure 7.21: Detection phase flow sheetSource: SANCHES, L.B. (2004)

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    16/18

    Figure 7.22: Activation phase flow sheet

    Normal Operation

    The normal operation is w here the actual data with the connected sensors and actuators takes places. A cycle consists of data exchange, managementinclusion phase.

    7.6.5 Function seque nce in the m aster

    In normal operation after the detection and activation phase is concluded, there is cyc lical communication betw een the master and all connected slaves. Such a c

    consists of the data exchange phase, the (optional) management phase and the inclusion phase. On each cycle, the management phase is attributed an A

    transaction, and the s ame happens in the inclusion phase. This mechanism makes possible to keep a high s canning speed of all slaves, updating their output data

    reading the input data in a same transaction, w ithout harming the management operation on the netw ork that occurs in the tw o other phases, w hich can be compl

    in multiple cycles.

    Figure 7.23 illustrates the behavior of the master during the Data Exchange phase. Note that the communication w ith a certain s lave must fail along the 3 c ycle

    that it is removed from the lists of detected slaves (LDS) and activated slaves (LA S). This guarantees that the netw ork w ill operate adequately even in s ituat

    subject to noises that cause f ailures. In this last case, the Config OKflag is deactivated.

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    17/18

    Figure 7.23: Simplifi ed flow sheet of the data exchange phase.

    Af ter the Data Exchange phase is c ompleted, the management phase may begin. In the management phase acyclical telegrams are sent to the slaves. Unlike

    Data Exchange phase, w hen all activated slaves are accessed bef ore the next phase, only one telegram is sent and the functions requiring more than one teleg

    to be completed are executed through several cyc les.

    During the management phase the master uses as many requests as possible to execute the tasks required by the host. If there is no function to be executed,

    master may send status-reading telegrams, dumb telegrams or even send no telegrams in this phase.

    Af ter the management phase, comes the inclusion phase, w hen all new slaves are searched at the end of each cycle. During each cycle, a s lave is requested.

    request is carried out by the transmission control w ithout repeat in case of error, because the error is not critical. If an activated slave responds, or there i

    response, the next slave is requested at the f ollowing activation phase. If a non-activated slave responds, its ID codes are requested on the next phases and

    LDS is then updated.

    On the next phase, depending on the master operation mode, the slave is activated and moves into the LAS. The activation is carried out by sending a requ

    parameter to the slave for update according to the Parameter Image (PI) field. Finally, on the last stage the master sends a data request by sending input

    according to the "Input Data Image".

    Hence, a slave inclusion occurs the same w ay as f or the start-up procedures. If a slave w ith 0 address is detected during the inclusion phase, even if a proje

    slave is not present, the automatic addressing is blocked by the deactivation of the "Auto_Address_Available" flag. The same happens when a located slave is

    projected. The Config OK flag is s et at the end of each inclusion phase. Immediately next, the Data Exchange phase of a new cycle begins.

    It is important noticing that each phase of the normal operation cycle alternates betw een the type A and the type B slave groups. Before the c reation of the exten

    addressing, this did not happen, because the tw o types of slave did not exist. After the version 2.1, howev er, the cycle occurs alternately, as show n in Figure 7

    It is worth mentioning that the slaves compliant w ith the old specification are accessed in every c ycle, since they do not have A/B differentiation. Therefore, the

    scanning cycle on the extended address is tw ice as large as the previous one, but the old-specification slaves continue to perform the exchange of data in the s

    time as the previous cycle.

    Figure 7.24: Normal operation of the execution control with extended addressingSource: SANCHES, L.B. (2004)

    7.6.4 The maste r layer and the Interface 3

    The master interf ace w ith the host (interface 3) is only defined in a logical way , w hile the implementation is up to the manufacturer to carry out. It is specified by

    standards only as functions that should be executed by the master. The master layer is the one that adapts these functions to the specific host. As explained ea

    the host is normally a fieldbus sys tem with an upper hierarchy, like a PLC or a PC. So, accessing the master and thus an A S-i netw ork is done in many ways . I

    host is a PC, for example, the master may be on a board connected to the main board and is accessed through drives that implement the function defined by

    interface 3 and are adapted for this system on the master layer. The possibilities are virtually innumerable.

    If the host is a PLC, the master is nearly alw ays an external module, regarded as an ordinary I/O module, w hich is access ed by adequately mapped memory ar

    The interface is implemented in a different w ay. The same reasoning applies to the AS-i gatew ays. On the market, there are AS-i gatew ays f or Profibus

    DeviceNet, Modbus, and others.

    There are few functions that make possible the eff ective data exchange between the master and the slave. Most of them access the master data fields that mai

    an updated image of the netw ork to collect the information they need. Those carrying the data exc hanged are executed on the management phase, w hich may se

    telegram on each cycle.

    The functions:

    "Read Input Data",

    "Write Output Data",

    They acces s the "Input Data Image" and Output Data Image" fields to retur n or w rite data adequately .

    "Write Parameter"

    It w rites a set of parameters on Parameter Image and also executes a request of parameter scr ipt on the management phase. Thus, w hen a request

    Read Parameter

    is performed by the host, the slave must be access ed directly, but only on the parameter image, w hich is alway s updated w ith the slave real parameters.

    In addition to these f unctions there are:

    "Get LDS",

    "Get LAS",

    "Get LPS",

    They return the corres ponding lists and also access the adequate data fields on the execution control.

    The permanent data are access ed by:

    "Get LPS";

    "Get Permanent Parameter";

    "Get Permanent Configuration";

    And it is recorded by the corresponding

  • 7/27/2019 SMAR - Tutorial on the as-i Technology

    18/18

    "Set LPS",

    "Set Permanent Parameter",

    "Set Permanent Configuration".

    Note that the functions that r ecording data permanently bring the master to the of fline phase and reinitiate its behavior.

    It is also possible to read the configuration fields through the functions:

    "Read Actual Configuration Data",

    "Read Parameter Image".

    The functions:

    "Project Actual Configuration Data",

    "Project Actual Parameters"

    They imp