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
ab_gp_proc_train_data.c File Reference

Implementation of ERTMS Subset-026 §5.4 Validated Train Data & Start of Mission. More...

Include dependency graph for ab_gp_proc_train_data.c:

Go to the source code of this file.

Macros

#define RBC_MAX_ALLOWED_TRAIN_LENGTH_M   5000U
#define RBC_MAX_ALLOWED_TRAIN_SPEED_KMH   350U

Functions

bool ab_gp_proc_train_data_validate (ab_gp_ertms_train_context_t *ctx, uint32_t l_train_m, uint32_t v_maxtrain_kmh, uint8_t m_axleload, uint8_t m_loadinggauge, bool m_airtight, uint32_t timestamp_ms)
 Validates inbound Train Data (Msg 129 + Packet 11) against site topology limits.
bool ab_gp_proc_train_data_is_valid (const ab_gp_ertms_train_context_t *ctx)
 Checks if train data has been successfully validated.
bool ab_gp_proc_train_data_get_ack_timestamp (const ab_gp_ertms_train_context_t *ctx, uint32_t *out_t_train_ack)
 Retrieves the timestamp for Msg 8 (Ack of Train Data) generation.

Detailed Description

Implementation of ERTMS Subset-026 §5.4 Validated Train Data & Start of Mission.

Definition in file ab_gp_proc_train_data.c.

Macro Definition Documentation

◆ RBC_MAX_ALLOWED_TRAIN_LENGTH_M

#define RBC_MAX_ALLOWED_TRAIN_LENGTH_M   5000U

Definition at line 9 of file ab_gp_proc_train_data.c.

◆ RBC_MAX_ALLOWED_TRAIN_SPEED_KMH

#define RBC_MAX_ALLOWED_TRAIN_SPEED_KMH   350U

Definition at line 10 of file ab_gp_proc_train_data.c.

Function Documentation

◆ ab_gp_proc_train_data_validate()

bool ab_gp_proc_train_data_validate ( ab_gp_ertms_train_context_t * ctx,
uint32_t l_train_m,
uint32_t v_maxtrain_kmh,
uint8_t m_axleload,
uint8_t m_loadinggauge,
bool m_airtight,
uint32_t timestamp_ms )

Validates inbound Train Data (Msg 129 + Packet 11) against site topology limits.

Parameters
[in,out]ctxTrain ERTMS context.
[in]l_train_mTrain length in meters.
[in]v_maxtrain_kmhMaximum train speed in km/h.
[in]m_axleloadAxle load category.
[in]m_loadinggaugeLoading gauge category.
[in]m_airtightAirtight capability flag.
[in]timestamp_msTimestamp from train message.
Returns
true if parameters are compatible and validated, false otherwise.

Definition at line 12 of file ab_gp_proc_train_data.c.

◆ ab_gp_proc_train_data_is_valid()

bool ab_gp_proc_train_data_is_valid ( const ab_gp_ertms_train_context_t * ctx)

Checks if train data has been successfully validated.

Parameters
[in]ctxTrain ERTMS context.
Returns
true if valid train data is stored, false otherwise.

Definition at line 65 of file ab_gp_proc_train_data.c.

◆ ab_gp_proc_train_data_get_ack_timestamp()

bool ab_gp_proc_train_data_get_ack_timestamp ( const ab_gp_ertms_train_context_t * ctx,
uint32_t * out_t_train_ack )

Retrieves the timestamp for Msg 8 (Ack of Train Data) generation.

Parameters
[in]ctxTrain ERTMS context.
[out]out_t_train_ackEchoed timestamp to place in Msg 8.
Returns
true if train data was validated and timestamp populated.

Definition at line 74 of file ab_gp_proc_train_data.c.