RTE RBC 2oo2 Reference Application 0.1.0 build 0006685
SIL 4 2oo2 Dual-Site Fault-Tolerant ERTMS Radio Block Centre Reference Architecture
Loading...
Searching...
No Matches
main_c_train.c
Go to the documentation of this file.
1
9#include "gateway_c_common.h"
11
12int main(int argc, char **argv)
13{
14 static const gateway_c_service_def_t svc = {
15 .app_name = "safeAPIRBC2oo2-Gateway-Train",
16 .log_tag = "TRAIN",
17 .handler_init = gateway_c_train_handler_init,
18 .handler_execute = gateway_c_train_handler_execute,
19 .handler_shutdown = gateway_c_train_handler_shutdown,
20 .handler_check_link_down = gateway_c_train_handler_check_link_down,
21 .pre_execute_hook = NULL,
22 /* ADR-038: publish own status to the C broker every 5 s. */
23 .broker_channel = "c-broker-train",
24 .status_src_id = (uint8_t)RBC_UTIL_SRC_GW_TRAIN
25 };
26
27 return gateway_c_main(argc, argv, &svc);
28}
int gateway_c_main(int argc, char **argv, const gateway_c_service_def_t *svc)
Full process entry for a Role C gateway service: prints the version banner, parses argv[1] as {WEST|E...
Shared skeleton for the three Role C gateway service binaries (rte_gateway_c_train / _il / _ctc - ADR...
void gateway_c_train_handler_shutdown(void)
bool gateway_c_train_handler_check_link_down(rte_timestamp_ms_t threshold_ms, rte_timestamp_ms_t now_ms, char *out_which, size_t which_size)
rte_status_t gateway_c_train_handler_init(gateway_c_context_t *ctx)
void gateway_c_train_handler_execute(gateway_c_context_t *ctx, uint32_t cycle)
TrainHandler - Role C Gateway's TCP/IP server for the ONE multiplexed Train sim connection and the ON...
int main(int argc, char **argv)
ADR-038: the wire frame for the A/B<->C util side channel (RTE_EXAMPLE_RELAY_KIND_UTIL) and the C-sid...
@ RBC_UTIL_SRC_GW_TRAIN
One gateway service's identity and its single handler's entry points - a pure-literal table each main...