stream_send_ubyte stream_send_ubyte_array navigation bar

Table of Contents

stream_send_ubytes

Writes an array of unsigned bytes to the stream buffer.

Description

This function writes an array of unsigned bytes to the stream buffer. It is has the same semantics as the stream_send function.

Unlike the stream_send_ubyte_array function, this function does not require that the stream send buffer be at least num_elements bytes in length. Hence, it allows smaller stream buffers to be used.

Prototype

        
t_int
stream_send_ubytes(t_stream stream, const t_ubyte * elements, t_uint num_elements);

    

Parameters

t_stream stream

A client stream established using stream_connect or stream_accept.

const t_ubyte * elements

The array to be sent.

t_uint num_elements

The number of elements in the array to send.

Return value

The number of bytes sent, which may be less than the request number of bytes for non-blocking streams. If an error occurs then a negative error code is returned.

Error codes

This function does not return any error code.

Requirements

Include Files

Libraries

quanser_stream.h

quanser_communications.lib;quanser_runtime.lib;quanser_common.lib

See Also

 

navigation bar