Error Code Definitions for ra8-firmware.
ra8_err_codes_t ra8_err_t
Canonical error-return type used by every ra8-firmware API.
ra8_err_t ra8_io_stream_write(ra8_io_stream_t *s, const uint8_t *buf, uint32_t len, uint32_t *out_written)
Write len bytes to the bound sink.
ra8_err_t ra8_io_stream_puts(ra8_io_stream_t *s, const char *str)
Write a NUL-terminated string (without the NUL) to the bound sink.
ra8_err_t ra8_io_stream_put_u32(ra8_io_stream_t *s, uint32_t value)
Write value as unsigned decimal ASCII (no leading zeros).
ra8_err_t ra8_io_stream_flush(ra8_io_stream_t *s)
Flush any sink-side buffering to its destination.
struct ra8_io_stream_iface ra8_io_stream_iface_t
ra8_err_t ra8_io_stream_put_u64(ra8_io_stream_t *s, uint64_t value)
Write value as unsigned 64-bit decimal ASCII without leading zeros.
ra8_err_t ra8_io_stream_putc(ra8_io_stream_t *s, char c)
Write a single byte to the bound sink.
ra8_err_t ra8_io_stream_put_hex(ra8_io_stream_t *s, uint32_t value, uint8_t min_digits)
Write value as lowercase hex ASCII, zero-padded to min_digits.
Opaque to stream users; backend implementers use the public backend contract in ra8_io_stream_backend...
Caller-allocated byte-stream handle binding a sink to its context.
const ra8_io_stream_iface_t * iface
Bound sink vtable (private).
void * ctx
Sink-private context (private).