|
ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
|
esp-hosted port header: optional host features, RPC bounds, counters. More...
Go to the source code of this file.
Macros | |
| #define | H_HOST_PS_ALLOWED (0) |
| Whether the host may sleep and be woken by the co-processor. | |
| #define | H_HOST_WAKEUP_GPIO (-1) |
| Pin index of the host wake input, or -1 when none is wired. | |
| #define | H_HOST_WAKEUP_GPIO_PORT RA8_ESP_HOSTED_GPIO_PORT(k_ra8_pin_none) |
| Opaque port handle of the host wake input. | |
| #define | H_HOST_WAKEUP_GPIO_LEVEL (0) |
| Level the co-processor would drive to wake the host. | |
| #define | H_HOST_USES_STATIC_NETIF (0) |
| Whether the transport attaches a statically created esp_netif. | |
| #define | H_NETWORK_SPLIT_ENABLED (0) |
| Whether the TCP/IP stack is split between host and co-processor. | |
| #define | H_HOST_TCP_LOCAL_PORT_RANGE_START (49152) |
| First ephemeral TCP port the host would own under network split. | |
| #define | H_HOST_TCP_LOCAL_PORT_RANGE_END (61439) |
| Last ephemeral TCP port the host would own under network split. | |
| #define | H_HOST_UDP_LOCAL_PORT_RANGE_START (49152) |
| First ephemeral UDP port the host would own under network split. | |
| #define | H_HOST_UDP_LOCAL_PORT_RANGE_END (61439) |
| Last ephemeral UDP port the host would own under network split. | |
| #define | H_SLAVE_TCP_REMOTE_PORT_RANGE_START (61440) /* LEGACY-OK: upstream macro name */ |
| First TCP port the co-processor would own under network split. | |
| #define | H_SLAVE_TCP_REMOTE_PORT_RANGE_END (65535) /* LEGACY-OK: upstream macro name */ |
| Last TCP port the co-processor would own under network split. | |
| #define | H_SLAVE_UDP_REMOTE_PORT_RANGE_START (61440) /* LEGACY-OK: upstream macro name */ |
| First UDP port the co-processor would own under network split. | |
| #define | H_SLAVE_UDP_REMOTE_PORT_RANGE_END (65535) /* LEGACY-OK: upstream macro name */ |
| Last UDP port the co-processor would own under network split. | |
| #define | H_WIFI_TX_DATA_THROTTLE_HIGH_THRESHOLD (80) |
| Queue occupancy, in percent, at which the co-processor throttles. | |
| #define | H_WIFI_TX_DATA_THROTTLE_LOW_THRESHOLD (60) |
| Queue occupancy, in percent, at which throttling is released. | |
| #define | H_HOST_RESTART_NO_COMMUNICATION_WITH_SLAVE (0) /* LEGACY-OK: upstream macro name */ |
| Whether a silent co-processor restarts the host. | |
| #define | H_HOST_RESTART_NO_COMMUNICATION_WITH_SLAVE_TIMEOUT_MS (-1) /* LEGACY-OK: upstream esp-hosted macro name */ |
| Milliseconds of silence before that restart would fire. | |
| #define | H_MAX_SYNC_RPC_REQUESTS (1) |
| Synchronous RPC transactions that may be outstanding at once. | |
| #define | H_MAX_ASYNC_RPC_REQUESTS (1) |
| Asynchronous RPC transactions that may be outstanding at once. | |
| #define | H_MAX_CUSTOM_MSG_HANDLERS (4) |
| Callback slots for co-processor custom messages, if ever enabled. | |
| #define | H_TEST_RAW_TP (0) |
| Whether the raw-throughput test harness is compiled in. | |
| #define | H_TEST_RAW_TP_DIR (0) |
| Direction bitmap advertised for the raw-throughput test. | |
| #define | H_RAW_TP_PKT_LEN (1448) |
| Payload bytes per raw-throughput test frame. | |
| #define | H_RAW_TP_REPORT_INTERVAL (10) |
| Seconds between raw-throughput reports. | |
| #define | H_MEM_STATS (0) |
| Whether the transport keeps allocation counters. | |
| #define | H_MEM_MONITOR (0) |
| Whether the RPC layer logs free-heap movement around each call. | |
| #define | ESP_PKT_STATS (0) |
| Whether per-interface packet counters are compiled in. | |
| #define | ESP_PKT_STATS_REPORT_INTERVAL (10) |
| Seconds between packet-counter reports. | |
esp-hosted port header: optional host features, RPC bounds, counters.
Included from the bottom of port_esp_hosted_host_config.h, which is the file name the vendored core knows. It carries the switches for host features that need code this port does not have, the two RPC concurrency bounds, and the debug counters – separated from the wiring facts because the repository caps a source file at 1000 lines and because these answer a different question: not "how is the link built" but "what does this image choose not to do".
Definition in file port_esp_hosted_host_config_features.h.
| #define ESP_PKT_STATS (0) |
Whether per-interface packet counters are compiled in.
Zero. The counters are incremented on every transmit and receive and reported from a periodic thread; neither is free, and the link's health is already visible through the transport event callbacks.
Definition at line 543 of file port_esp_hosted_host_config_features.h.
| #define ESP_PKT_STATS_REPORT_INTERVAL (10) |
Seconds between packet-counter reports.
Ten, matching H_RAW_TP_REPORT_INTERVAL so the two debug harnesses print on the same cadence and their logs interleave predictably.
Definition at line 560 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_PS_ALLOWED (0) |
Whether the host may sleep and be woken by the co-processor.
Zero. The vendored power-save driver drives an ESP-IDF sleep entry point and a dedicated wake input; this board wires neither, and the RA8's own low-power modes are managed by the firmware's LPM layer rather than by a radio co-processor.
Definition at line 70 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_RESTART_NO_COMMUNICATION_WITH_SLAVE (0) /* LEGACY-OK: upstream macro name */ |
Whether a silent co-processor restarts the host.
Zero, for the same reason as H_TRANSPORT_RESTART_ON_FAILURE: the RA8 owns the display, the storage and the reader state, and a radio that never answers must not cost the user their place in a book. The transport reports the failure; the application decides.
Definition at line 323 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_RESTART_NO_COMMUNICATION_WITH_SLAVE_TIMEOUT_MS (-1) /* LEGACY-OK: upstream esp-hosted macro name */ |
Milliseconds of silence before that restart would fire.
Minus one, the vendored "disabled" spelling. The guard is #if <flag> && <timeout> != -1, so both halves have to agree that the policy is off; leaving the timeout at a real number while the flag is 0 would be a trap for whoever flips the flag next.
Definition at line 342 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_TCP_LOCAL_PORT_RANGE_END (61439) |
Last ephemeral TCP port the host would own under network split.
61439, leaving the top 4096 ports of the dynamic range to the co-processor so the two halves cannot pick the same tuple.
Definition at line 196 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_TCP_LOCAL_PORT_RANGE_START (49152) |
First ephemeral TCP port the host would own under network split.
49152, the bottom of the IANA dynamic range, so a split deployment never collides with a registered service port.
Definition at line 181 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_UDP_LOCAL_PORT_RANGE_END (61439) |
Last ephemeral UDP port the host would own under network split.
61439; mirrors H_HOST_TCP_LOCAL_PORT_RANGE_END.
Definition at line 225 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_UDP_LOCAL_PORT_RANGE_START (49152) |
First ephemeral UDP port the host would own under network split.
49152; the UDP partition mirrors the TCP one so one rule explains both.
Definition at line 211 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_USES_STATIC_NETIF (0) |
Whether the transport attaches a statically created esp_netif.
Zero. That path calls esp_netif_attach_wifi_station() and esp_netif_dhcpc_stop(); this tree has no esp_netif, it has NetX Duo behind ra8_net_pal, so the glue lives on the application side of the transport rather than inside it.
Definition at line 146 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_WAKEUP_GPIO (-1) |
Pin index of the host wake input, or -1 when none is wired.
Minus one. The co-processor has no line back to the RA8 other than HANDSHAKE and DATA_READY, and neither is routed to a low-power wake source on this package.
Definition at line 89 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_WAKEUP_GPIO_LEVEL (0) |
Level the co-processor would drive to wake the host.
Zero. An active-low wake is the conventional choice because a sleeping host can hold a pull-up and the co-processor only has to sink current for the pulse.
Definition at line 122 of file port_esp_hosted_host_config_features.h.
| #define H_HOST_WAKEUP_GPIO_PORT RA8_ESP_HOSTED_GPIO_PORT(k_ra8_pin_none) |
Opaque port handle of the host wake input.
Encodes k_ra8_pin_none through the same adapter the side-band pins use, so an unwired signal has one representation across this port rather than a special case per call site.
Definition at line 106 of file port_esp_hosted_host_config_features.h.
| #define H_MAX_ASYNC_RPC_REQUESTS (1) |
Asynchronous RPC transactions that may be outstanding at once.
One. The application issues asynchronous requests one at a time – a scan, then a connect, then a status read – and a deeper table would be reserved memory that no call path can reach.
Definition at line 384 of file port_esp_hosted_host_config_features.h.
| #define H_MAX_CUSTOM_MSG_HANDLERS (4) |
Callback slots for co-processor custom messages, if ever enabled.
Four. Unreachable while H_PEER_DATA_TRANSFER stays undefined (see this file's header block), but stated so the table bound is a decision rather than something discovered later.
Definition at line 401 of file port_esp_hosted_host_config_features.h.
| #define H_MAX_SYNC_RPC_REQUESTS (1) |
Synchronous RPC transactions that may be outstanding at once.
One. The RPC layer is driven from a single thread in this port and every synchronous call blocks it until the response arrives, so a second slot could never be occupied. Keeping it at one also keeps the transaction table a single entry, which is what makes the RPC path allocation-free after init.
Definition at line 367 of file port_esp_hosted_host_config_features.h.
| #define H_MEM_MONITOR (0) |
Whether the RPC layer logs free-heap movement around each call.
Zero. It is a heap-leak hunt for a build with a general heap; this port allocates from a fixed pool that cannot grow, so a leak shows up as pool exhaustion, which MEM_DUMP reports directly.
Definition at line 523 of file port_esp_hosted_host_config_features.h.
| #define H_MEM_STATS (0) |
Whether the transport keeps allocation counters.
Zero. The counters live on the per-frame allocate and free paths, and the port already reports pool occupancy through MEM_DUMP when it is asked, which answers the same question without a hot-path cost.
Definition at line 504 of file port_esp_hosted_host_config_features.h.
| #define H_NETWORK_SPLIT_ENABLED (0) |
Whether the TCP/IP stack is split between host and co-processor.
Zero. Network split runs part of the socket layer on the C6 and partitions the local port space between the two ends; it needs a co-processor image built for it and a host stack that honours the partition. This image terminates every socket on the RA8.
Definition at line 166 of file port_esp_hosted_host_config_features.h.
| #define H_RAW_TP_PKT_LEN (1448) |
Payload bytes per raw-throughput test frame.
1448 – a 1460-byte TCP maximum segment less the twelve-byte esp-hosted payload header, which is the comparison the vendored header spells out. It makes the reported number directly comparable with a network throughput measurement instead of a transport-only best case.
Definition at line 469 of file port_esp_hosted_host_config_features.h.
| #define H_RAW_TP_REPORT_INTERVAL (10) |
Seconds between raw-throughput reports.
Ten: long enough to average out a scheduling hiccup, short enough that a bench operator does not think the test has hung.
Definition at line 485 of file port_esp_hosted_host_config_features.h.
| #define H_SLAVE_TCP_REMOTE_PORT_RANGE_END (65535) /* LEGACY-OK: upstream macro name */ |
Last TCP port the co-processor would own under network split.
65535, the top of the port space.
Definition at line 244 of file port_esp_hosted_host_config_features.h.
| #define H_SLAVE_TCP_REMOTE_PORT_RANGE_START (61440) /* LEGACY-OK: upstream macro name */ |
First TCP port the co-processor would own under network split.
61440, one past the host's range, so the partition is a single boundary rather than an interleaving.
Definition at line 235 of file port_esp_hosted_host_config_features.h.
| #define H_SLAVE_UDP_REMOTE_PORT_RANGE_END (65535) /* LEGACY-OK: upstream macro name */ |
Last UDP port the co-processor would own under network split.
65535, the top of the port space.
Definition at line 262 of file port_esp_hosted_host_config_features.h.
| #define H_SLAVE_UDP_REMOTE_PORT_RANGE_START (61440) /* LEGACY-OK: upstream macro name */ |
First UDP port the co-processor would own under network split.
61440; mirrors the TCP partition.
Definition at line 253 of file port_esp_hosted_host_config_features.h.
| #define H_TEST_RAW_TP (0) |
Whether the raw-throughput test harness is compiled in.
Zero. The harness spawns a thread that pushes dummy frames as fast as the transport accepts them; it measures the wire, and it starves everything else while it does so.
Definition at line 431 of file port_esp_hosted_host_config_features.h.
| #define H_TEST_RAW_TP_DIR (0) |
Direction bitmap advertised for the raw-throughput test.
Zero, which is ESP_TEST_RAW_TP_NONE in the vendored esp_hosted_transport_init.h. It is read unconditionally – the host puts it in the configuration message it sends after the boot event – so it must be defined even with H_TEST_RAW_TP off, and zero is what tells the co-processor not to start a test.
Definition at line 451 of file port_esp_hosted_host_config_features.h.
Referenced by c6_fwver_priv_host_caps().
| #define H_WIFI_TX_DATA_THROTTLE_HIGH_THRESHOLD (80) |
Queue occupancy, in percent, at which the co-processor throttles.
Eighty. Sent to the co-processor in the host's configuration message: once four fifths of the host's receive capacity is committed, the co-processor stops handing Wi-Fi frames to the transport rather than letting them pile up and be dropped at the far end of the link.
Definition at line 283 of file port_esp_hosted_host_config_features.h.
Referenced by c6_fwver_priv_host_caps().
| #define H_WIFI_TX_DATA_THROTTLE_LOW_THRESHOLD (60) |
Queue occupancy, in percent, at which throttling is released.
Sixty. The twenty-point gap is the hysteresis band; with the twenty-frame queues this port uses that is four frames of slack, enough that one burst cannot cross both thresholds.
Definition at line 300 of file port_esp_hosted_host_config_features.h.
Referenced by c6_fwver_priv_host_caps().