-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMriTimeSync.h
51 lines (25 loc) · 1.03 KB
/
MriTimeSync.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#pragma once
#include <string>
#include "DataReader_Aux2Strings.h"
void TimestampThread();
long GenerateAPP_ID();
bool TimeSynchronizationGetVEH_ID(DDS::DomainParticipant_var m_participant, DDS::Subscriber_var m_subscriber, DDS::Publisher_var m_publisher);
void SetTimestamp(long perfectTimestamp);
long GetTimestamp();
long GetElapsedMicroseconds();
bool ParseAux2Strings(Mri::Aux2Strings aux_message);
long MedianPackageDelay();
long MedianOffsetServerApp();
bool SendSyncMessage();
bool SendRegisterVehIdMessage();
bool SendUnregisterAppMessage();
long long startTimer(void);
long endTimer(long long const & begin);
const std::string TAG_TIME_SYNC = "timesync";
const std::string TAG_DNPW = "dnpw";
const std::string TAG_REGISTER_VEH_ID = "register_veh_id";
const std::string TAG_UNREGISTER_APP = "unregister_app";
const long SERVER_ID = 0;
extern Mri::Aux2StringsDataWriter_var writer_global_aux2strings;
extern Mri::V2XMessageDataWriter_var writer_global_v2xmessage;
extern Mri::VehDataDataWriter_var writer_global_vehdata;