Add a V plate model so the detector has something to find in simulation
The chain was testable but not runnable: simulation fakes the dock entirely (use_simulated_goal writes an invented pose 1.6 m ahead of base_link), so no physical object exists for a laser to see. Nothing in the worlds under Test/simulators is a dock either. This is the missing half - an SDF plate whose geometry matches the v_std profile exactly: 90 degree interior angle, 0.30 m wings. 0.02 m thick so min_split_dist does not read the two faces of one wing as two segments, and 0.6 m tall from the floor so a planar laser at any plausible mounting height cuts through it. The plate and the profile have to agree. Change the model and the wing_length gate rejects the very object that was just spawned, which is the kind of failure that looks like a broken detector.
This commit is contained in:
14
sim/models/dock_plate_v/model.config
Normal file
14
sim/models/dock_plate_v/model.config
Normal file
@@ -0,0 +1,14 @@
|
||||
<?xml version="1.0"?>
|
||||
<model>
|
||||
<name>dock_plate_v</name>
|
||||
<version>1.0</version>
|
||||
<sdf version="1.6">model.sdf</sdf>
|
||||
<author>
|
||||
<name>T800 Robotics</name>
|
||||
<email>tdd@gmail.com</email>
|
||||
</author>
|
||||
<description>
|
||||
Tấm dẫn hướng chữ V của trạm dock, dùng để kiểm bộ dò biên dạng bằng LiDAR trong Gazebo.
|
||||
Góc trong tại đỉnh 90 độ, mỗi cánh 0.30 m — khớp profile `v_std`.
|
||||
</description>
|
||||
</model>
|
||||
58
sim/models/dock_plate_v/model.sdf
Normal file
58
sim/models/dock_plate_v/model.sdf
Normal file
@@ -0,0 +1,58 @@
|
||||
<?xml version="1.0"?>
|
||||
<!--
|
||||
Tấm dẫn hướng chữ V.
|
||||
|
||||
Hình học phải KHỚP profile `v_std` trong action_handlers_params.yaml:
|
||||
vertex_angle = 90 độ (góc TRONG tại đỉnh, giữa hai cánh)
|
||||
wing_length = 0.30 m (từ đỉnh ra đầu mút)
|
||||
|
||||
Đỉnh nằm tại gốc model, hai cánh mở về phía +X. Robot tiếp cận từ +X nên nó nhìn thấy MẶT TRONG
|
||||
của chữ V — đúng thứ bộ dò khớp.
|
||||
|
||||
Mỗi cánh nghiêng 45 độ so với trục Y, nên góc giữa hai cánh = 180 - 2*45 = 90 độ.
|
||||
|
||||
Cao 0.6 m và đáy sát sàn: LiDAR phẳng gắn ở độ cao nào trong khoảng đó cũng cắt qua tấm. Dày
|
||||
0.02 m để `min_split_dist` (0.02 m) không nhầm hai mặt của cùng một cánh thành hai đoạn.
|
||||
-->
|
||||
<sdf version="1.6">
|
||||
<model name="dock_plate_v">
|
||||
<static>true</static>
|
||||
|
||||
<link name="wing_left">
|
||||
<!-- Tâm cánh nằm giữa đỉnh và đầu mút: 0.15 m dọc theo cánh. -->
|
||||
<pose>0.10607 0.10607 0.3 0 0 0.7854</pose>
|
||||
<collision name="collision">
|
||||
<geometry>
|
||||
<box><size>0.02 0.30 0.6</size></box>
|
||||
</geometry>
|
||||
</collision>
|
||||
<visual name="visual">
|
||||
<geometry>
|
||||
<box><size>0.02 0.30 0.6</size></box>
|
||||
</geometry>
|
||||
<material>
|
||||
<ambient>0.9 0.6 0.1 1</ambient>
|
||||
<diffuse>0.9 0.6 0.1 1</diffuse>
|
||||
</material>
|
||||
</visual>
|
||||
</link>
|
||||
|
||||
<link name="wing_right">
|
||||
<pose>0.10607 -0.10607 0.3 0 0 -0.7854</pose>
|
||||
<collision name="collision">
|
||||
<geometry>
|
||||
<box><size>0.02 0.30 0.6</size></box>
|
||||
</geometry>
|
||||
</collision>
|
||||
<visual name="visual">
|
||||
<geometry>
|
||||
<box><size>0.02 0.30 0.6</size></box>
|
||||
</geometry>
|
||||
<material>
|
||||
<ambient>0.9 0.6 0.1 1</ambient>
|
||||
<diffuse>0.9 0.6 0.1 1</diffuse>
|
||||
</material>
|
||||
</visual>
|
||||
</link>
|
||||
</model>
|
||||
</sdf>
|
||||
Reference in New Issue
Block a user