Skip to content

Commit 1ac4333

Browse files
committed
Merge remote-tracking branch 'origin/main'
2 parents 6098926 + d4ffde6 commit 1ac4333

9 files changed

Lines changed: 70 additions & 19 deletions

File tree

assets/doc/connection_config.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
# 相机类传感器连接配置
2-
## 工业相机类
3-
## 带有触发器的相机
1+
# 相机类
2+
## 带有触发的USB相机
43
<p align="center">
54
<img style="width:50%;" alt="usb_camera" src="../picture/link/USB.jpg">
65
</p>
76

7+
## 工业相机
8+
89
<p align="center">
910
<img style="width:50%;" alt="gige_camera" src="../picture/link/CAM.png">
1011
</p>
@@ -14,19 +15,19 @@
1415
</p>
1516

1617

17-
# 雷达类传感器连接配置
18-
# Mid360配置
18+
# 雷达类
19+
# Mid360
1920

2021
<p align="center">
2122
<img style="width:50%;" alt="mid360" src="../picture/link/MID360.png">
2223
</p>
2324

24-
# GPS类传感器连接配置
25+
# GPS类
2526

2627
<p align="center">
2728
<img style="width:50%;" alt="gps" src="../picture/link/GPS.jpg">
2829
</p>
2930

30-
# IMU类传感器连接配置
31+
# IMU类
3132

32-
# 其他传感器连接配置
33+
# 其他传感器连接配置

assets/doc/firmware.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# 同步板软件介绍
2+
3+
本固件系统采用模块化设计,兼顾时间同步精度、低延迟控制与易用性,为多传感器融合系统提供稳定、灵活的软件支撑。整体的功能如下图所示
4+
5+
![alt text](../picture/sync.png)
6+
7+
其中,时间戳的输入来自于上位机或者GPS,然后在本地系统板中进行计时。然后根据不同的需要将系统时间转换为PWM上升沿、PPS时间戳等格式,用于给不同传感器授时。本质上同步板是一个支持不同设备、不同格式的时间分发装置。
8+
9+
10+
## 时间管理功能
11+
12+
同步板内部的系统时间来自于稳定的上位机发送的UTC(协调世界时)时间。为了获取更高的时间同步精度,一个类似PTP的软件同步机制被用于上位机和同步板进行时间戳对齐。
13+
14+
$$
15+
t_{pc} == t_{sys}
16+
$$
17+
18+
另一个时间源来自于GPS,它是不稳定的(室内)并且并不是所有场景下都搭载了GPS设备。因此,GPS的时间戳数据只会被采集并不会被用于整体系统时间,而是实时估计GPS和系统之间的时间差。用户可以自行选择采用所提供的系统时间还是GPS时间,他们的转换关系如下
19+
20+
$$
21+
t_{sys} = t_{gps} + \Delta t
22+
$$
23+
24+
25+
## 同源PWM生成
26+
27+
同源PWM是指具有不同频率但是相同相位的PWM信号,它能够保证外部传感器的触发时间成倍数关系。
28+
29+
![alt text](../picture/align.png)
30+
31+
例如,相机以10Hz采集,而外部IMU以100Hz采集,同源PWM则可以保证相机采集的时刻刚好对应一帧IMU数据。
32+
33+
同步板将采集PWM的上升沿时刻,并记录反馈给上位机,这样上位机即可精准的获得每一个触发时刻的时间。
34+
35+
## PPS时间戳输出功能
36+
37+
38+
39+
40+
## 通信协议
41+
42+
## 固件烧写流程
43+
44+
## 固件更新日志
45+
46+

assets/doc/hardware_intro.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ USB-TypeC 型号的USB2.0 接口被用于下载程序以及虚拟串口用于和
151151
在PWM触发接口中,提供了标称12V的接口给工业相机供电,但是这一功能在默认情况下是关闭的。部分网口工业相机需要供12V的电源,为了接线方便,我们的板卡上做了一次转发。将输入的12V电源**直接**转发到PWM触发的接口中,方便多路相机接线。为了开启转发功能,需要在同步板的背面找到一个没有焊接的电阻位置,如下图所示
152152

153153
<p align="center">
154-
<img style="width:50%;" alt="nc" src="../picture/12.png">
154+
<img style="width:50%;" alt="nc" src="../picture/power_select.png">
155155
</p>
156156

157157
在默认发货的板子中,这个电阻没有被焊接,这是为了电源的安全。如果需要启用这一功能,请自行焊接或者直接短路,然后输入的电源将会被转发到PWM触发的接口,实现对工业相机的供电。

assets/picture/sync.png

20.1 KB
Loading

example/GigeCam/CMakeLists.txt

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
cmake_minimum_required(VERSION 3.16)
22

33
project(gige_cam VERSION 1.0)
4-
4+
message(STATUS "System Processor: ${CMAKE_SYSTEM_PROCESSOR}")
55
if (CMAKE_SYSTEM_PROCESSOR MATCHES "arm" OR CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64")
66
set(PLATFORM_DIR "arm")
77
set(MVCAM_LIB_DIR ${CMAKE_CURRENT_SOURCE_DIR}/mvcam/lib/aarch64)
@@ -31,9 +31,9 @@ set_target_properties(${PROJECT_NAME} PROPERTIES INSTALL_RPATH "$ORIGIN")
3131
# **************************编译ROS2节点*****************************
3232
find_package(rclcpp QUIET)
3333
if (NOT rclcpp_FOUND)
34-
message(STATUS "rclcpp not found. ros2 demo will not be built")
34+
message(STATUS "rclcpp not found. ROS2 demo will not be built")
3535
else ()
36-
message(STATUS "rclcpp found. ros2 demo will be built")
36+
message(STATUS "rclcpp found. ROS2 demo will be built")
3737
find_package(ament_cmake REQUIRED)
3838
find_package(std_msgs REQUIRED)
3939
find_package(sensor_msgs REQUIRED)
@@ -67,11 +67,13 @@ else ()
6767
)
6868
ament_package()
6969
endif ()
70+
7071
# **************************编译ROS1节点*****************************
7172
find_package(catkin QUIET)
7273
if (NOT catkin_FOUND)
73-
message(STATUS "catkin found, ros1 demo will be built")
74+
message(STATUS "catkin not found, ROS1 demo will not be built")
7475
else ()
76+
message(STATUS "catkin found. ROS1 demo will be built")
7577
find_package(catkin REQUIRED COMPONENTS
7678
roscpp
7779
sensor_msgs

example/GigeCam/mv_cam.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ bool MvCam::Initialization() {
9292
PrintDeviceInfo(p_device_info);
9393
}
9494
} else {
95-
LOG(ERROR) << "Find No Devices!";
95+
LOG(ERROR) << "Find No GIGE or USB Cam Devices!";
9696
return false;
9797
}
9898
LOG(INFO) << "Number of cameras detected : " << st_device_list.nDeviceNum;

infinite_sense_core/src/infinite_sense.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ Synchronizer::Synchronizer() {
1313
<< " █ ▐▛▚▖▐▌▐▌ █ ▐▛▚▖▐▌ █ █ ▐▌ ▐▌ ▐▌ ▐▛▚▖▐▌▐▌ ▐▌ " << "\n"
1414
<< " █ ▐▌ ▝▜▌▐▛▀▀▘ █ ▐▌ ▝▜▌ █ █ ▐▛▀▀▘ ▝▀▚▖▐▛▀▀▘▐▌ ▝▜▌ ▝▀▚▖▐▛▀▀▘" << "\n"
1515
<< " ▗▄█▄▖▐▌ ▐▌▐▌ ▗▄█▄▖▐▌ ▐▌▗▄█▄▖ █ ▐▙▄▄▖▗▄▄▞▘▐▙▄▄▖▐▌ ▐▌▗▄▄▞▘▐▙▄▄▖";
16+
int major, minor, patch;
17+
zmq_version(&major, &minor, &patch);
18+
LOG(INFO) << "ZeroMQ version: " << major << "." << minor << "." << patch;
1619
};
1720
void Synchronizer::SetLogPath(const std::string& path) { SetLogDestination(FATAL, path.c_str()); }
1821
void Synchronizer::SetNetLink(std::string net_dev, const unsigned int port) {
@@ -40,7 +43,7 @@ void Synchronizer::Start() const {
4043
sensor_manager_->Initialization();
4144
sensor_manager_->Start();
4245
}
43-
LOG(INFO) << "Synchronizer started";
46+
LOG(INFO) << "Synchronizer Started";
4447
}
4548
void Synchronizer::Stop() const {
4649
if (net_manager_) {
@@ -52,7 +55,7 @@ void Synchronizer::Stop() const {
5255
if (sensor_manager_) {
5356
sensor_manager_->Stop();
5457
}
55-
LOG(INFO) << "Synchronizer stopped";
58+
LOG(INFO) << "Synchronizer Stopped";
5659
}
5760

5861
} // namespace infinite_sense

infinite_sense_core/src/usb.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@
55

66
namespace infinite_sense {
77

8-
UsbManager::UsbManager(std::string port, int baud_rate)
9-
: port_(std::move(port)), started_(false) {
8+
UsbManager::UsbManager(std::string port, int baud_rate) : port_(std::move(port)), started_(false) {
109
serial_ptr_ = std::make_unique<serial::Serial>();
1110
try {
1211
serial_ptr_->setPort(port_);
@@ -37,7 +36,7 @@ UsbManager::~UsbManager() {
3736

3837
void UsbManager::Start() {
3938
if (!serial_ptr_ || !serial_ptr_->isOpen()) {
40-
LOG(ERROR) << "Cannot start USB manager: serial port not open.";
39+
LOG(ERROR) << "Cannot start USB manager: Serial port not open.";
4140
return;
4241
}
4342
started_ = true;

0 commit comments

Comments
 (0)