⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ab_trbl.h

📁 基于EthernetIP协议的应用程序,可以读取AB公司Controllogix系列Ethernetip协议PLC数据. 此软件代码可用于工业控制.
💻 H
📖 第 1 页 / 共 2 页
字号:
   ** either a response ComBuf arrives or the response timeout expires.
   **
   ** In the case of TREQ_UCMM_CLIENT_REQUEST, the original request ComBuf
   ** is ALWAYS deallocated by the service and the request ComBuf pointer
   ** will ALWAYS be NULL on return.
   **
   ** In the case of TREQ_UCMM_CLIENT_REQUEST_RECYCLE, the original request
   ** ComBuf will be returned in ALL cases including normal completion and
   ** all error conditions.  The "recycle" service executes more slowly
   ** because multiple internal task ownerships of the original request
   ** ComBuf must be relinquished before the request tribble can be returned.
   ** No additional memory storage is required for the "recycle" service as
   ** compared to the "non-recycle" service.  The "recycle" service should
   ** only be used if the original ComBuf contents are needed for re-use
   ** or are difficult to re-create.
   **
   ** Tribble Type:
   **
   **    um_ClientReqTrrblType
   */

   TREQ_UCMM_CLIENT_REQUEST,           /* Send Request, Get Response     */
   TREQ_UCMM_CLIENT_REQUEST_RECYCLE,   /* same but return request ComBuf */


   /*
   ** UCMM Timer Expired.
   **
   ** This tribble request code indicates that a UCMM timer has
   ** expired.  There is a separate request code for CLIENT and for SERVER
   ** timer expiration.
   **
   ** Tribble Type:
   **
   **    um_TimeoutTrrblType
   */

   TREQ_UCMM_CLIENT_TIMER_EXPIRED,
   TREQ_UCMM_SERVER_TIMER_EXPIRED,


   /*
   ** UCMM Send ACK
   **
   ** This tribble request code indicates that the server UCMM should send
   ** a request ACK to the client UCMM.  This would be used in the case
   ** where the request is sent via fixed tag 0x88 and the response is not
   ** immediately available (such as NVS write operations).
   **
   ** Tribble Type:
   **
   **    CD_PacketTrrblType
   */

   TREQ_UCMM_SERVER_SEND_ACK,
   
   
   /*
   ** UCMM Client abort request.
   **
   ** This tribble request code commands all active UCMM Client Requests
   ** to be aborted. When this request is processed by the UCMM Client,
   ** all active client transaction requests are aborted by immediately
   ** dissociating each of the Client Request Tribbles from their
   ** corresponding client transaction record, deallocating the transaction
   ** record, storing the return status in the request tribble, and
   ** attempting to return the tribble to the requesting object.
   ** If the request type was "recycle" a delay may occur while waiting
   ** for ownership(s) of the request ComBuf to be relinquished by the
   ** unscheduled transmit task.  This request is provided for complex
   ** client applications that may launch many concurrent UCMM requests
   ** and may have to support dynamic application reconfiguration operations
   ** that would result in a need to "cancel" all outstanding client requests.
   ** When processing this request, all aborted request tribbles are returned
   ** to their respective original requestor task(s).
   **
   ** Tribble Type:
   **
   **    GS_TrrblType            (Client)
   */

   TREQ_UCMM_CLIENT_ABORT_REQUESTS,


   /*
   ** UCMM Halt and Restart.
   **
   ** The TREQ_UCMM_HALT tribble request commands the UCMM to immediately
   ** abort all active transaction records (both Client and Server) and
   ** to also set a mode flag indicating that all further UCMM packet
   ** traffic and client requests are to be rejected.  This mode must
   ** persist while a dynamic change of MacId, or some other significant
   ** communications device (CD) reconfiguration, is in progress.
   **
   ** The TREQ_UCMM_RESTART tribble request commands the UCMM to set the
   ** mode flag to allow reception of UCMM traffic and to resume normal
   ** operation.  This command is issued after the completion of a
   ** reconfiguration of the communications device (CD).
   **
   ** Tribble Type:
   **
   **    GS_TrrblType
   */

   TREQ_UCMM_HALT,
   TREQ_UCMM_RESTART,


/*---------------------------------------------------------------------------
** Message Router specific codes
**---------------------------------------------------------------------------
*/

   /*
   ** Message router table registration and de-registration requests.
   **
   ** Tribble Type:
   **
   **    MR_RegistrationTrrblType
   */

   TREQ_REGISTER_OBJECT,
   TREQ_DEREGISTER_OBJECT,


/*---------------------------------------------------------------------------
** Connection establishment specific codes
**---------------------------------------------------------------------------
*/

   /*
   ** App open, app open complete & app close.
   **
   ** App open & close handshaking indications from the connection manager
   ** to an application task.
   **
   ** Tribble Type:
   **
   **    CM_AppOpenCloseTrrblType
   */

   TREQ_APP_OPEN,
   TREQ_APP_OPEN_COMPLETE,
   TREQ_APP_CLOSE,


   /*
   ** Transport creation/reservation, operation startup and deletion.
   **
   ** Reserving a transport allocates all required resources at the
   ** communications device level but does not start operation.
   ** Deleting a transport stops its operation and frees the resources.
   **
   ** Tribble type:
   **
   **    CD_TransportTrrblType
   */

   TREQ_RESERVE_TRANSPORTS,
   TREQ_START_TRANSPORTS,
   TREQ_DELETE_TRANSPORTS,


   /*
   ** Close all connections.
   ** Allow connections to be accepted.
   **
   ** Request the connection manager to close down all existing connections
   ** and keep new connections from being accepted. Also the matching
   ** request to let connections start up again.
   **
   ** This pair of requests are to be used during non-volatile update
   ** and similar operations when handling connected traffic would
   ** disrupt operations. They should also be used to quiet things down
   ** when resetting the communications device. A full reset consists of
   ** the following sequence:
   **
   **    1a) Issue a TREQ_CLOSE_ALL_CONNECTIONS request tribble
   **        to the connection manager object (CM)
   **    1b) Wait for completion.
   **    2a) Issue a TREQ_INIT_COMM_DEV request tribble
   **        to the communications device object (CD)
   **    2b) Wait for completion.
   **    3)  Issue a TREQ_SET_MAC_ID request tribble
   **        to the communications device object (CD)
   **    4)  Issue a TREQ_ALLOW_CONNECTIONS request tribble
   **        to the connection manager object (CM)
   **
   ** Tribble Type:
   **
   **    GS_TrrblType
   */

   TREQ_CLOSE_ALL_CONNECTIONS,
   TREQ_ALLOW_CONNECTIONS,


   /*
   ** Open a connection.
   **
   ** Request the connection manager to originate a connection to
   ** another object on another node.
   **
   ** Tribble Type:
   **
   **    CM_OpenTrrblType
   */

   TREQ_OPEN_CONNECTION,


   /*
   ** Close a connection.
   **
   ** Request the connection manager to close any connection
   ** (whether we originated it or not...)
   ** Normal close conditions or timeout causing the close.
   **
   ** Tribble Type:
   **
   **    CM_CloseTrrblType
   */

   TREQ_CLOSE_CONNECTION,
   TREQ_TIMEOUT_CONNECTION,


   /*
   ** Inquire about, disable or enable a connection
   ** identified by class, instance and connection points.
   **
   ** Tribble Type:
   **
   **    CM_InquireTrrblType
   */

   TREQ_INQUIRE_CONNECTION,
   TREQ_ENABLE_CONNECTION,
   TREQ_DISABLE_CONNECTION,


/*---------------------------------------------------------------------------
** Class 3 reception and transmission specific codes
**---------------------------------------------------------------------------
*/

   /*
   ** Transport Class 3 support.
   **
   ** These tribble request codes indicate the following:
   ** - Reception of newly received data from a class 3 connection.
   **   Data is in attached combuf. This can be a request from a client
   **   or a response from a server. It is up to the object receiving
   **   the data to determine the context. (The transport number in
   **   the tribble can help here...)
   **   Also used by the server to return response data for a given request.
   **   (If given to the unscheduled transmit task it performs the
   **    a TREQ_WRITE_CLASS3_TX_DATA followed by a TREQ_TX_CLASS3_VERIFY.)
   ** - Reception of duplicate data packet from a class 3 connection.
   ** - Transmit a request packet on the connection. (client)
   ** - Transmit a response (verification of a request packet)
   **   on the connection. (server)
   **   The verification may or may not include data,
   **   depending on how the connection has been set up.
   ** - Client timed out waiting for a response. Retry if any are left.
   **   Let the connection timer handle closing the connection when we
   **   run out of retries.
   ** - New transmit data for an existing class 3 transport is attached.
   **   The data in the attached combuf DOES NOT include the transport
   **   or ControlNet packet headers. Save the data, but do not transmit
   **   it just yet. The data will be transmitted when triggered by the
   **   application or when an Rx verification is required by the
   **   reception of duplicate data. The data is either the request packet
   **   for client transports or the response packet for server transports.
   **
   ** TREQ_RX_CLASS3_PACKET      Newly received data attached
   ** TREQ_RX_CLASS3_DUPLICATE   Duplicate data arrived (not attached)
   ** TREQ_TX_CLASS3_REQUEST     Send a request packet (client)
   ** TREQ_TX_CLASS3_RESPONSE    Send a response packet (server)
   ** TREQ_CLASS3_CLIENT_TIMEOUT Timed out waiting for response packet
   ** TREQ_CLASS3_TX_DATA        Combuf contains new transmit data
   **
   ** Tribble Type:
   **
   **    CD_PacketTrrblType
   */

   TREQ_RX_CLASS3_PACKET,
   TREQ_RX_CLASS3_DUPLICATE,
   TREQ_TX_CLASS3_REQUEST,
   TREQ_TX_CLASS3_RESPONSE,
   TREQ_CLASS3_CLIENT_TIMEOUT,
   TREQ_WRITE_CLASS3_TX_DATA,


/*---------------------------------------------------------------------------
** Buffer Fragment mapper specific codes
**---------------------------------------------------------------------------
*/

   /*
   ** Register an application data area with the Buffer Fragment mapper.
   **
   ** Tribble Type:
   **
   **    BF_RegisterTrrblType
   */

   TREQ_REGISTER,


   /*
   ** Mapping entry handling requests
   **
   ** Add, remove or activate/deactivate one mapping entry from the
   ** object data to app data area mapping/translation table.
   ** Inquire about 1 or 2 mappings or reserve them for use
   ** by a class 1 connection.
   **
   ** Tribble Types: (respectively)
   **
   **    BF_AddTrrblType
   **    BF_DeTrrblType
   **    BF_ActivteTrrblType
   **    BF_DeTrrblType
   **    BF_InquireTrrblType
   **    BF_InquireTrrblType
   */

   TREQ_ADD_MAPPING,
   TREQ_DELETE_MAPPING,

   TREQ_ACTIVATE_MAPPING,
   TREQ_DEACTIVATE_MAPPING,

   TREQ_INQUIRE_MAPPINGS,
   TREQ_RESERVE_MAPPINGS,


   /*
   ** Request a messaging read/write of a mapped piece of application memory.
   **
   ** Tribble Type:
   **
   **    BF_AccessTrrblType
   */

   TREQ_ACCESS_MAPPED_DATA,


/*---------------------------------------------------------------------------
** ControlNet Connection object specific codes
**---------------------------------------------------------------------------
*/

   /*
   ** Enable/disable originated connection requests.
   **
   ** Tribble Type:
   **
   **    CC_TrrblType
   */

   TREQ_ENABLE_CONNECTIONS,
   TREQ_DISABLE_CONNECTIONS,


/*---------------------------------------------------------------------------
** Non-Volatile Storage object specific codes
**---------------------------------------------------------------------------
*/

   /*
   ** Read/write non-volatile storage requests.
   **
   ** Find/read/write segments of non-volatile storage.
   **
   ** Tribble Type:
   **
   **    NV_SegmentTrrblType
   */

   TREQ_NV_FIND_DATA,
   TREQ_NV_READ_DATA,
   TREQ_NV_WRITE_OPEN,
   TREQ_NV_WRITE_DATA,
   TREQ_NV_WRITE_CLOSE,


   /*
   ** Get segment attributes.
   **
   ** Tribble Type:
   **
	**    NS_SegmentAttrTrrblType
   */

   TREQ_NV_GET_ATTRIBUTES,

   /*
   ** Used to request objects to erase thier non-volatile storage
   ** using the services of the NVS object
   */

   TREQ_CLEAR_ATTRIBUTE_STORAGE,


/*---------------------------------------------------------------------------
** Debug object specific codes
**---------------------------------------------------------------------------
*/

   /*
   ** Process debug object request.
   **
   ** Used for internal debug object requests.
   **
   ** Tribble Type:
   **
   **    CD_PacketTrrblType
   */

   TREQ_PROCESS_REQUEST,


/*---------------------------------------------------------------------------
** DOS Application specific codes
**---------------------------------------------------------------------------
*/

   /*
   ** Example app requests.
   **
   ** These are passed between the interactive task which collects
   ** command lines from the keyboard and from script files and the
   ** command interpreter task that parses and processes the command lines.
   **
   ** Tribble Type:
   **
   **    EA_CommandTrrblType
   */

   TREQ_NEW_COMMAND,


/*---------------------------------------------------------------------------
** User specific codes
**---------------------------------------------------------------------------
*/

#include "abu_trbl.h"

   /*
   ** One final code to end the enumeration.
   ** (This way the user portion can end with a comma...)
   */

   TREQ_LAST_TREQ
}
TrrblRequestType;



#endif  /* inclusion lock */

/****************************************************************************
**
** End of AB_TRBL.H
**
*****************************************************************************
*/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -