raw1394_start_async_send

Name

raw1394_start_async_send --  send an asynchronous packet

Synopsis

int raw1394_start_async_send (raw1394handle_t handle, size_t length, size_t header_length, unsigned int expect_response, quadlet_t * data, unsigned long rawtag);

Arguments

handle

libraw1394 handle

length

the amount of bytes of data to send

header_length

the number of bytes in the header

expect_response

indicate with a 0 or 1 whether to receive a completion event

data

pointer to data to send

rawtag

data to identify the request to completion handler

Description

This starts sending an arbitrary async packet. It gets an array of quadlets consisting of header and data (without CRC in between). Header information is always in machine byte order, data (data block as well as quadlet data in a read response for data quadlet) shall be in big endian byte order. expect_response indicates, if we expect a response (i.e. if we will get the tag back after the packet was sent or after a response arrived). length is the length of the complete packet (header_length + length of the data block). The main purpose of this function is to send responses for incoming transactions, that are handled by the application. Do not use that function, unless you really know, what you do! Sending corrupt packet may lead to weird results.

Returns

0 on success or -1 on failure (sets errno)