WARNING! Access to this system is limited to authorised users only.
Unauthorised users may be subject to prosecution.
Unauthorised access to this system is a criminal offence under Australian law (Federal Crimes Act 1914 Part VIA)
It is a criminal offence to:
(1) Obtain access to data without authority. -Penalty 2 years imprisonment.
(2) Damage, delete, alter or insert data without authority. -Penalty 10 years imprisonment.
User activity is monitored and recorded. Anyone using this system expressly consents to such monitoring and recording.

To protect your data, the CISO officer has suggested users to enable 2FA as soon as possible.
Currently 2.7% of users enabled 2FA.

Commit 9aa3e405 authored by Jack Henderson's avatar Jack Henderson
Browse files

update ptp mon

parent c31ec198
#!/usr/bin/env python3
#!/usr/bin/env python
import os
import rospy
......@@ -11,6 +11,7 @@ class PtpMonitor:
def __init__(self):
self.diagnostics = diagnostic_updater.Updater()
task = diagnostic_updater.CompositeDiagnosticTask("PTP")
task.addTask(diagnostic_updater.FunctionDiagnosticTask("PTP Stats", self.update_stats))
task.addTask(diagnostic_updater.FunctionDiagnosticTask("Clock sync check", self.check_sync_bounds))
......@@ -61,6 +62,7 @@ class PtpMonitor:
self.port_state = data['Port state']
self.offset = float(data.get('Offset from Master', '0').split(' ')[0])
self.clock_correction = float(data.get('Clock correction', '0').split(' ')[0])
stat.summary(diagnostic_msgs.msg.DiagnosticStatus.OK, "PTP is connected")
stat.summary(diagnostic_msgs.msg.DiagnosticStatus.ERROR, "PTPD is not connected to master")
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment