Write With Abort Endpoint

Requires: Base Development System

Writes an element to a Messenger channel or signals the channel to abort. The endpoint waits if the channel is full. This endpoint is the same as the Write endpoint except that it has an abort input and an aborted? output. You can use the abort capability of the Messenger channel to close a channel abruptly, ignoring any data left in the channel buffer. You must use this endpoint together with the Read With Abort endpoint.

You can drop this endpoint on the block diagram by right-clicking a terminal or a wire and selecting Create»Channel Writer»Messenger»Write With Abort.

Details  Example

timeout in ms is the time, in milliseconds, that this endpoint has to write the specified data to the channel. The default value is -1, which means there is no time limit.
wait for ack specifies whether this endpoint waits until a reader endpoint acknowledges receiving the message before writing the next element. The default is FALSE.
element specifies the data to write to the channel.
abort specifies whether to abort this channel. The default is FALSE. If abort is TRUE, this endpoint marks the channel as closed and ignores further calls to read. Meanwhile, the aborted? output returns TRUE on the next call of this endpoint.
size specifies the maximum number of elements that can be buffered in the channel. The default is unlimited. The channel size is initialized on the first call to the writer endpoint, after which the endpoint ignores the size input.
timed out? returns TRUE if the amount of time specified by timeout in ms elapses.
channel is the channel wire that connects this endpoint to a reader endpoint.
id returns an integer that identifies this message within the channel. Other endpoints use this integer to cancel or acknowledge the message within the channel.
aborted? returns TRUE if abort occurred on this endpoint or the reader endpoints connected to the channel. If aborted? is TRUE, further calls to this endpoint will do nothing except returning aborted? TRUE again.

Write With Abort Details

Related Information

Read With Abort

Example

Refer to the Channel Message Handler.lvproj in the labview\examples\Channels\Channel Message Handler directory for an example of using the Write With Abort endpoint.

 Open example  Find related examples