(cifTelegram card_id rcv_task snd_task cmd ext fmt_string parse_string [args ...])
The target card ID (0..3).
The ID of the target CIF firmware task that is to process the message. This value is protocol-dependent. Different message functions are available through the various target tasks.
The sending task id, normally 16 (the HOST user), but may be dependent on the protocol and specific function.
The message command specifier, as defined for the particular protocol and function.
The message command specifier extension, if required by the command.
A string describing how to map the supplied parameters to the appropriate binary message. See the cifTelegramFmt command for details of this synopsis.
A string describing how to map the binary response message into a set of ASCII parameters. See the cifTelegramFmt command for details of this synopsis.
Command-dependent list of parameters.
(cifTelegram card_id return_value)
where return_value depends on the message response and parse_string; or one of the following errors:
(error "cifTelegram DR_ERR_CARD_INVALID (time) invalid card: card_id") (error "cifTelegram -1 (time) formatBinBuffer format_error_msg") (error "cifTelegram -1 (time) createBinFormat format_error_msg") (error "cifTelegram -1 (time) messageError message_error_code") (error "cifTelegram -1 (time) replyMailboxError device_error_code") (error "cifTelegram -1 (time) sendMailboxError device_error_code")
The text string corresponding to the message_error_code and device_error_code can be obtained by issuing an errorDescription command, like this:
This command provides access to the CIF message data interface. It creates a binary message based on the supplied format string and parameters, sends the message to the CIF card, and creates an ASCII response from the binary response message according to the supplied parse control string.
The CIF message interface provides access to many items of data not available through the card's shared memory interface. This includes the shared memory data itself, card commands and diagnostics, and access to fieldbus device data that is not transmitted as part of the process data image. This fieldbus data is sometimes referred to as explicit messaging or device attributes, and generally takes the form of slower variable length packets that are interspread with the deterministic fieldbus packets of process data.
The parameters of this command are completely dependent on the various functions available for the different protocols. The format and parse control strings must be precise, and can become quite complex. To facilitate use, a set of protocol-specific commands have been defined using the type command. For example, the dnm.cfg, ibm.cfg, and prf.cfg files contain command definitions for most of the functions available for the deviceNet™, interBus™ and profibus™ protocols respectively. The synopsis for these commands is described by the associated description string (typeDesc), and these commands are made available to the driver by using the include filename command in the configuration file.
See the examples in cifTelegramFmt and protocol-specific configuration files.
Copyright © 1995-2010 by Cogent Real-Time Systems, Inc. All rights reserved.