RTE RBC 2oo2 Generic Application
0.1.0 build 308eda7
IL/CTC route and train logic for the RBC_GP reference RBC
Toggle main menu visibility
Loading...
Searching...
No Matches
gateway_c_il_handler.h
Go to the documentation of this file.
1
#ifndef RTE_EXAMPLE_GATEWAY_C_IL_HANDLER_H
2
#define RTE_EXAMPLE_GATEWAY_C_IL_HANDLER_H
3
13
14
#include "gateway_c_types.h"
15
16
typedef
struct
17
{
18
/* --- ILSim-facing (one multiplexed channel) --- */
19
rte_channel_service_t sim_channel;
20
21
/* --- A/B-facing (one dedicated relay channel per peer) --- */
22
rte_channel_service_t relay_channel[GATEWAY_C_PEER_COUNT];
23
uint8_t relay_consecutive_timeout;
24
rte_timestamp_ms_t relay_down_since_ms[GATEWAY_C_PEER_COUNT];
25
rte_timestamp_ms_t
send_down_since_ms
[GATEWAY_C_PEER_COUNT];
26
uint32_t a_seen_this_cycle;
27
unsigned
int
a_stale_cycles;
28
const
char
*last_known_tag;
29
gateway_c_dedup_t dedup;
30
}
gateway_c_il_handler_state_t
;
31
32
rte_status_t gateway_c_il_handler_init(gateway_c_context_t *ctx);
33
void
gateway_c_il_handler_execute(gateway_c_context_t *ctx, uint32_t cycle);
34
void
gateway_c_il_handler_shutdown(
void
);
35
bool
gateway_c_il_handler_check_link_down(rte_timestamp_ms_t threshold_ms, rte_timestamp_ms_t now_ms,
36
char
*out_which,
size_t
which_size);
37
46
void
gateway_c_il_handler_broadcast_to_ab
(
const
uint8_t bytes[RBC_ENVELOPE_WIRE_SIZE]);
47
48
#endif
/* RTE_EXAMPLE_GATEWAY_C_IL_HANDLER_H */
gateway_c_il_handler_broadcast_to_ab
void gateway_c_il_handler_broadcast_to_ab(const uint8_t bytes[RBC_ENVELOPE_WIRE_SIZE])
Sends one RBC_ENVELOPE_WIRE_SIZE frame to BOTH A and B on the IL relay link. Used by gateway_c_logctl...
Definition
gateway_c_il_handler.c:36
gateway_c_il_handler_state_t
Definition
gateway_c_il_handler.h:17
gateway_c_il_handler_state_t::send_down_since_ms
rte_timestamp_ms_t send_down_since_ms[GATEWAY_C_PEER_COUNT]
Definition
gateway_c_il_handler.h:25
src
C
il
gateway_c_il_handler.h
Generated by
1.18.0