The card's files outside the run log: the ESC profiles read at start-up, the log viewer's list, open and delete, and the servo programmer's record and file requests, which the logger task serves (panel_log.c).
More...
|
|
static void | esc_card_take (const storage_entry_t *entry, void *ctx) |
|
static void | esc_profiles_read (void) |
|
void | esc_profiles_load (void) |
| static size_t | card_read (void *ctx, char *buf, size_t max) |
| | One read of the open log for the viewer, counted as the render task's progress (render_progress()).
|
|
static void | card_tick (void) |
| | The walks' tick (storage_walk()): one directory entry read on the render task, counted as its progress, for the reason card_read() gives.
|
|
static bool | card_busy (const char *name) |
|
static void | card_folder (const char *dir, void *ctx) |
|
static unsigned | card_written (log_viewer_tab_t *tab, void *ctx) |
| static void | card_take (const storage_entry_t *entry, void *ctx) |
| | Offer one directory entry of the walk to the page.
|
| static int | card_list (log_viewer_file_t *out, int max_entries, log_viewer_page_t *page, void *ctx) |
| | The viewer's list(): the page page names of the folder the viewer points at.
|
|
static bool | card_open (const char *name, log_source_t *src, void *ctx) |
|
static void | card_close (void *ctx) |
|
static const char * | card_volume (void *ctx) |
|
static card_state_t | card_state (void *ctx) |
|
static unsigned | card_mounts (void *ctx) |
|
static bool | card_remove (const char *name, void *ctx) |
|
void | kst_record_write (void) |
|
static bool | kst_record_read (const char *path, size_t *len) |
|
static bool | kst_record_use (bool late, size_t len) |
|
static void | kst_record_load_held (bool late) |
|
void | kst_record_load (bool late) |
|
void | kst_card_serve (void) |
The card's files outside the run log: the ESC profiles read at start-up, the log viewer's list, open and delete, and the servo programmer's record and file requests, which the logger task serves (panel_log.c).
SPDX-License-Identifier: MIT
| size_t card_read |
( |
void * | ctx, |
|
|
char * | buf, |
|
|
size_t | max ) |
|
static |
One read of the open log for the viewer, counted as the render task's progress (render_progress()).
The viewer reads a log whole inside one pass of the render loop, up to LOG_DEFAULT_MAX_ROWS (60,000) rows in two passes over the file, and that pass can last longer than the watchdog's FRAME_WATCH_MS (1000ms): a live supply output held by a programming port stays on while LOGS is open. Counted per read, the watchdog sees one read's length at a time, which a card that stops answering still exceeds.
- Parameters
-
| ctx | The FILE * of the open log. |
| buf | Where the bytes go. |
| max | Room in buf, bytes. |
- Returns
- The bytes read; 0 at the end or on a failure.