Nets

The subsystem is intended for integration of separate microcontrollers and computers into an industrial net.

Functions of a subsystem:
    - The organization of topology of a net;
    - Integration of various manufacturers into one net;
    - A guarantee of time of the answer;
    - Granting the centralized mode of access to a net (Master/Slave);
    - Tuning of parameters of work of a net;
    - Tuning of a configuration of a net;
    - Processing interruptions;
    - Control of an exchange (hangups, statistics, reruns, a status of exchange and so forth);

Served physical interfaces:
    - UART/USART (RS-232, RS-422/485);
    - SPI.

In LG.RTOS each physical interface is served by the separate module of the organization of an exchange.
All modules of the organization of an exchange have own initiator.

System LG.RTOS manipulates following objects of an exchange:
    - A command pack (has a constant format set by system);
    - A data pack (has a format set by the user);
    - Synchronization bytes.

The representative of the module of an exchange in system is the Descriptor of the Module.
The descriptor of the module is an object of a pseudo-class on ANSI-C.

The Descriptor
encapsulates:
    - Parameters of an exchange;
    - procedures - reactions to events of an exchange:
        - Handler of end of a data pack;
        - Handler of hangup.

The exchange begins with transfer of a command pack and further is executing without participation of the user.
At the end of an exchange the system is executing the following actions.
 If there is a user procedure
- reaction to ending
of an exchange then she is executing (
parameter of procedure is the adress of the data of a pack). Otherwise the system
executes standard actions providing ending of an exchange.   For example, at detection of hangup of an exchange the current pack
comes back into queue.

The status of an exchange (norm, fail, hangup and so forth) is accessible to the user.
The user can define(but it is not necessarily) procedures - reactions to events of an exchange.  If user redefines system methods
he can take control upon oneself  and create own strategy of the organization of an exchange.
 

1. Module of the UART/USART.
The module provides transfer of the information through universal the transceiver between microcontrollers
and-or between microcontrollers and industrial computer (leading net point) .
The module provides multibatch data exchange and supports the following protocols:
    - ModBus/RTU;
    - XModem-CRC (expanded protocol);
    - The LG.RTOS-protocol of fast data transfer.

The user can control the following parameters of an exchange:
    - Quantity UART/USART;
    - Ports / ports and pins of input-output UART/USART;
    - A configuration of a net;
    - Quantity of packs;
    - The sizes of packs;
    - Speed of an exchange;
    - A format of the frame (8/9-bits);
    - A multiprocessor communication mode.


2. Module of the SPI (Serial Peripheral Interface).
The module provides transfer of data arrays between several microcontrollers through the SPI.
The module provides a monobatch mode of an exchange and is intended for the organization of a net
of controllers in borders of the block (an intra-block highway).

The user can control the following parameters of an exchange:
    - Ports / ports and pins of input-output SPI;
    - A configuration of a net;
    - The size of pack;
    - Speed of an exchange.

The user can redefine system methods - reactions to events of an exchange and create own strategy of the
organization of an exchange.

The Conclusion.
Modules of the given subsystem provide simple realization of industrial networks and :
   - lower expenses;
   - reduce time of designing;
   - increase reliability of products.
 

Hosted by uCoz