From b0356477bb99ce627e21091445fe0cd3fb8025d5 Mon Sep 17 00:00:00 2001 From: Leonard Kugis Date: Wed, 22 May 2024 02:32:12 +0200 Subject: FT245_read_buffered now returning actual number of bytes read. --- doc/FT245.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'doc/FT245.md') diff --git a/doc/FT245.md b/doc/FT245.md index 7f677ba..7ffea0e 100644 --- a/doc/FT245.md +++ b/doc/FT245.md @@ -1240,9 +1240,9 @@ Returns: - `true`: Data successfully transferred to output buffer. - `false`: Data could not be transferred to output buffer. -### `bool FT245_read_buffered(ft245_t *ft245, uint8_t *data, size_t size)` +### `size_t FT245_read_buffered(ft245_t *ft245, uint8_t *data, size_t size)` -Reads the given amount of data from the input buffer, specified with `size`, to the pointer `data`, if available. +Reads up to the given amount of data from the input buffer, specified with `size`, to the pointer `data`. Parameters: @@ -1252,8 +1252,7 @@ Parameters: Returns: -- `true`: Data successfully transferred to `data` buffer. -- `false`: Data could not be transferred to `data` buffer, i.e. no data available at input buffer. +- Number of bytes actually read. ### `bool FT245_write_word_buffered(ft245_t *ft245, uint32_t word)` -- cgit v1.2.1