Skip to content

Commit

Permalink
Adapt documentation and CMakeList to new hd_monitor.py
Browse files Browse the repository at this point in the history
  • Loading branch information
limaanto committed Mar 15, 2024
1 parent e15fe27 commit 5c0891a
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
1 change: 1 addition & 0 deletions diagnostic_common_diagnostics/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ ament_python_install_package(${PROJECT_NAME})

install(PROGRAMS
${PROJECT_NAME}/ntp_monitor.py
${PROJECT_NAME}/hd_monitor.py
DESTINATION lib/${PROJECT_NAME}
)

Expand Down
15 changes: 14 additions & 1 deletion diagnostic_common_diagnostics/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,20 @@ Computer name in diagnostics output (ex: 'c1')
Disable self test.

## hd_monitor.py
**To be ported**
Runs 'shutil.disk_usage' to check if there is enough space left on a given device.
* Above 5% of free space left, an `OK` status will be published.
* Between 5% and 1%, a `WARN` status will be published,
* Below 1%, an `ERROR` status will be published.

### Published Topics
#### /diagnostics
diagnostic_msgs/DiagnosticArray
The diagnostics information.

### Parameters
#### path
(default: home directory "~")
Path in which to check remaining space.

## cpu_monitor.py
**To be ported**
Expand Down
1 change: 1 addition & 0 deletions diagnostic_common_diagnostics/mainpage.dox
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

\b diagnostic_common_diagnostics contains a few common diagnostic nodes

- hd_monitor publishes diagnostic messages related to the available space on a given storage device.
- ntp_monitor publishes diagnostic messages for how well the NTP time sync is working.
- tf_monitor used to publish diagnostic messages reporting on the health of
the TF tree. It is based on tfwtf. It is not ported to ROS2.
Expand Down

0 comments on commit 5c0891a

Please sign in to comment.