ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
Loading...
Searching...
No Matches
console_ring_t Struct Reference

One channel's scrollback ring. More...

Data Fields

char lines [k_board_console_ring_depth][k_board_console_line_cap]
 Row storage.
uint32_t head
 Next write slot (one past newest).
uint32_t count
 Rows held (saturates at ring depth).
uint32_t total
 Rows ever pushed (monotonic).

Detailed Description

One channel's scrollback ring.

lines is a circular buffer of NUL-terminated rows; head is the next write slot (one past the newest); count saturates at the ring depth and total climbs without bound. A back-index b maps to ring slot (head + depth - 1 - b) mod depth.

Invariant
count <= k_board_console_ring_depth at all times.
head < k_board_console_ring_depth at all times.

Definition at line 35 of file board_console.c.

Field Documentation

◆ count

uint32_t console_ring_t::count

Rows held (saturates at ring depth).

Definition at line 39 of file board_console.c.

Referenced by board_console_line(), and internal_ring_push().

◆ head

uint32_t console_ring_t::head

Next write slot (one past newest).

Definition at line 38 of file board_console.c.

Referenced by board_console_line(), and internal_ring_push().

◆ lines

Row storage.

Definition at line 37 of file board_console.c.

Referenced by board_console_line(), and internal_ring_push().

◆ total

uint32_t console_ring_t::total

Rows ever pushed (monotonic).

Definition at line 40 of file board_console.c.

Referenced by internal_ring_push().


The documentation for this struct was generated from the following file: