Skip to content

TEL - Create Latency Node - #127

Open
davidbeechey wants to merge 1 commit into
masterfrom
tel-latency_node
Open

TEL - Create Latency Node#127
davidbeechey wants to merge 1 commit into
masterfrom
tel-latency_node

Conversation

@davidbeechey

Copy link
Copy Markdown
Contributor

No description provided.

@davidbeechey davidbeechey self-assigned this Jul 2, 2024
Comment thread lib/telemetry/latency.cpp

const auto payload = nextMessage->payload;
const auto topic = core::MqttTopic::kLatencyResponse;
const core::MqttMessage::Header header{.timestamp = 0,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you need a WallClock as a data member, then:
.timestamp = time_.now().time_since_epoch().count()

Comment thread lib/telemetry/latency.cpp
}

void Latency::run()
{

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

while (true) otherwise this runs once lol

'latency/request',
JSON.stringify({
latency: new Date().getTime().toString(),
timestamp: new Date().getTime().toString(),

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here and elsewhere, are you remembering that all mqtt messages are of the format:

{
  header : {
    timestamp: int,
    priority: int
  },
  payload: { rest of data }
}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahhh I see. Will need to change this throughout the telemetry code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants