mirror of
https://github.com/CopterExpress/clover.git
synced 2026-05-26 11:43:25 +00:00
Implement dynamic reconfiguration for aruco_map (#448)
This commit is contained in:
@@ -390,6 +390,26 @@ rospy.sleep(5)
|
||||
flow_client.update_configuration({'enabled': True})
|
||||
```
|
||||
|
||||
<!-- markdownlint-disable MD044 -->
|
||||
|
||||
### # {#aruco-map-dynamic}
|
||||
|
||||
> **Info** For [RPi image](image.md) version > 0.23.
|
||||
|
||||
Change the used [ArUco markers map file](aruco_map.md) dynamically:
|
||||
|
||||
<!-- markdownlint-enable MD044 -->
|
||||
|
||||
```python
|
||||
import rospy
|
||||
import dynamic_reconfigure.client
|
||||
|
||||
rospy.init_node('flight')
|
||||
map_client = dynamic_reconfigure.client.Client('aruco_map')
|
||||
|
||||
map_client.update_configuration({'map': '/home/pi/catkin_ws/src/clover/aruco_pose/map/office.txt'})
|
||||
```
|
||||
|
||||
### # {#wait-global-position}
|
||||
|
||||
Wait for global position to appear (finishing [GPS receiver](gps.md) initialization):
|
||||
|
||||
@@ -401,6 +401,26 @@ rospy.sleep(5)
|
||||
flow_client.update_configuration({'enabled': True})
|
||||
```
|
||||
|
||||
<!-- markdownlint-disable MD044 -->
|
||||
|
||||
### # {#aruco-map-dynamic}
|
||||
|
||||
> **Info** Для [образа](image.md) версии > 0.23.
|
||||
|
||||
Динамически изменить используемый файл с [картой ArUco-маркеров](aruco_map.md):
|
||||
|
||||
<!-- markdownlint-enable MD044 -->
|
||||
|
||||
```python
|
||||
import rospy
|
||||
import dynamic_reconfigure.client
|
||||
|
||||
rospy.init_node('flight')
|
||||
map_client = dynamic_reconfigure.client.Client('aruco_map')
|
||||
|
||||
map_client.update_configuration({'map': '/home/pi/catkin_ws/src/clover/aruco_pose/map/office.txt'})
|
||||
```
|
||||
|
||||
### # {#wait-global-position}
|
||||
|
||||
Ожидать появления глобальной позиции (окончания инициализации [GPS-приемника](gps.md)):
|
||||
|
||||
Reference in New Issue
Block a user