io_write

I/O write interface.

int32_t io_write(
    struct io_descriptor *const io_descr,
    const uint8_t *const buf,
    const uint16_t length
)

This function writes up to length of bytes to a given I/O descriptor. It returns the number of bytes actually write.

Parameters

descr

An I/O descriptor to write

buf

Type: const uint8_t *const

The buffer pointer to story the write data

length

Type: const uint16_t

The number of bytes to write

Returns

Type: int32_t

The number of bytes written