mirror of
https://github.com/orbbec/OrbbecSDK_ROS2.git
synced 2026-10-10 14:39:49 +08:00
Add examples of log output
This commit is contained in:
@@ -29,7 +29,7 @@ If the camera node crashes unexpectedly, it will generate a crash log in the cur
|
|||||||
|
|
||||||
**1. SDK debug logs**
|
**1. SDK debug logs**
|
||||||
|
|
||||||
Set the launch parameter `log_level` to `debug`. After running, the SDK will generate log files in the `Log/` folder under the current project directory. If you want a more recognizable file name for this test, you can set the parameter `log_file_name`.
|
Set the launch parameter `log_level` to `debug`. After running, the SDK will generate log files in the `Log/` folder under the current working directory. If you want a more recognizable file name for this test, you can set the parameter `log_file_name`.
|
||||||
|
|
||||||
- SDK logs are appended to the same file: multiple launches will continue writing into the same log file.
|
- SDK logs are appended to the same file: multiple launches will continue writing into the same log file.
|
||||||
- Recommendation: before packaging logs to send to technical support, delete old log files, then reproduce the issue and collect new logs. This keeps the logs cleaner and makes troubleshooting more accurate.
|
- Recommendation: before packaging logs to send to technical support, delete old log files, then reproduce the issue and collect new logs. This keeps the logs cleaner and makes troubleshooting more accurate.
|
||||||
@@ -41,6 +41,20 @@ In the launch file, set the node (or composable node container) parameter `outpu
|
|||||||
- After setting `output="log"`, ROS 2 logs will be stored in the `~/.ros/log/` directory.
|
- After setting `output="log"`, ROS 2 logs will be stored in the `~/.ros/log/` directory.
|
||||||
- When submitting an issue, please package both the SDK logs under the `Log/` directory and the corresponding ROS 2 logs under `~/.ros/log/` for the same time period.
|
- When submitting an issue, please package both the SDK logs under the `Log/` directory and the corresponding ROS 2 logs under `~/.ros/log/` for the same time period.
|
||||||
|
|
||||||
|
**3. Example Tutorial**
|
||||||
|
|
||||||
|
Run in the terminal
|
||||||
|
```
|
||||||
|
ros2 launch orbbec_camera gemini_330_series.launch.py log_level:=debug
|
||||||
|
```
|
||||||
|

|
||||||
|
|
||||||
|
You can find the SDK logs in the Log folder within the current working directory.
|
||||||
|

|
||||||
|
|
||||||
|
ros2 log is enabled by default and can be viewed under `~/.ros/log/`
|
||||||
|

|
||||||
|
|
||||||
### Why Are There So Many Launch Files?
|
### Why Are There So Many Launch Files?
|
||||||
|
|
||||||
- Different cameras have varying default resolutions and image formats.
|
- Different cameras have varying default resolutions and image formats.
|
||||||
|
|||||||
@@ -29,7 +29,7 @@
|
|||||||
|
|
||||||
**1. SDK debug 日志**
|
**1. SDK debug 日志**
|
||||||
|
|
||||||
将 launch 参数 `log_level` 设为 `debug` 运行后,会在当前工程目录下的 `Log/` 文件夹中生成 SDK 日志文件。如果需要为本次测试指定一个更易识别的日志文件名,可以修改参数 `log_file_name`。
|
将 launch 参数 `log_level` 设为 `debug` 运行后,会在当前工作目录下的 `Log/` 文件夹中生成 SDK 日志文件。如果需要为本次测试指定一个更易识别的日志文件名,可以修改参数 `log_file_name`。
|
||||||
|
|
||||||
- SDK 日志是追加写入的:多次启动会在同一个文件里不断累积日志。
|
- SDK 日志是追加写入的:多次启动会在同一个文件里不断累积日志。
|
||||||
- 建议:在准备打包日志发给技术支持前,先删除旧的日志文件,然后重新复现问题并采集新的日志,这样日志更干净、定位更准确。
|
- 建议:在准备打包日志发给技术支持前,先删除旧的日志文件,然后重新复现问题并采集新的日志,这样日志更干净、定位更准确。
|
||||||
@@ -41,6 +41,20 @@
|
|||||||
- 设置为 `output="log"` 后,ROS2 日志将保存在 `~/.ros/log/` 目录下。
|
- 设置为 `output="log"` 后,ROS2 日志将保存在 `~/.ros/log/` 目录下。
|
||||||
- 如需提交问题,请同时打包 `Log/` 目录下的 SDK 日志和 `~/.ros/log/` 下对应时间的 ROS2 日志,一并提供。
|
- 如需提交问题,请同时打包 `Log/` 目录下的 SDK 日志和 `~/.ros/log/` 下对应时间的 ROS2 日志,一并提供。
|
||||||
|
|
||||||
|
**3. 示例**
|
||||||
|
|
||||||
|
在终端运行
|
||||||
|
```
|
||||||
|
ros2 launch orbbec_camera gemini_330_series.launch.py log_level:=debug
|
||||||
|
```
|
||||||
|

|
||||||
|
|
||||||
|
即可在当前工作目录下的 Log 文件夹下查看 SDK 日志
|
||||||
|

|
||||||
|
|
||||||
|
ros2 log 默认开启,可在 `~/.ros/log/` 下查看
|
||||||
|

|
||||||
|
|
||||||
### 为什么有这么多启动文件?
|
### 为什么有这么多启动文件?
|
||||||
|
|
||||||
- 不同的相机具有不同的默认分辨率和图像格式。
|
- 不同的相机具有不同的默认分辨率和图像格式。
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 17 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 18 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 30 KiB |
Reference in New Issue
Block a user