5 La reconnaissance d'un symbole ArUco


Nous avons utilisé le paquet aruco_ros, ce paquet possède 3 nœud permettant la détection des symboles ArrUco. Voici un exemple de symbole ArrUco :

pour l’installer sous ROS, on envoie la commande suivante :

git clone https://github.com/pal-robotics/aruco_ros.git 
  • aruco_marker_publisher

le type de ce nœud est marker_publisher. Il permet de connaître les Identifiants des markers détectés.

Voici ses topics :

/aruco_marker_publisher/debug
/aruco_marker_publisher/debug/compressed
/aruco_marker_publisher/debug/compressed/parameter_descriptions
/aruco_marker_publisher/debug/compressed/parameter_updates
/aruco_marker_publisher/debug/compressedDepth
/aruco_marker_publisher/debug/compressedDepth/parameter_descriptions
/aruco_marker_publisher/debug/compressedDepth/parameter_updates
/aruco_marker_publisher/debug/theora
/aruco_marker_publisher/debug/theora/parameter_descriptions
/aruco_marker_publisher/debug/theora/parameter_updates
/aruco_marker_publisher/markers
/aruco_marker_publisher/markers_list
/aruco_marker_publisher/result
/aruco_marker_publisher/result/compressed
/aruco_marker_publisher/result/compressed/parameter_descriptions
/aruco_marker_publisher/result/compressed/parameter_updates
/aruco_marker_publisher/result/compressedDepth
/aruco_marker_publisher/result/compressedDepth/parameter_descriptions
/aruco_marker_publisher/result/compressedDepth/parameter_updates
/aruco_marker_publisher/result/theora
/aruco_marker_publisher/result/theora/parameter_descriptions
/aruco_marker_publisher/result/theora/parameter_updates 

Le topic aruco_marker_publisher/resultl permet de voir les images de la détection des markers. Pour cela on envoie la commande suivante :

rosrun image_view image_view image:=/aruco_marker_publisher/result 

le topic /aruco_marker_publisher/markers_list permet de connaitre les markers détectés. Pour voir cette liste, on envoie la commande suivante :

rostopic echo /aruco_marker_publisher/markers_list 

cette information est enregistré dans le tableau data qui est de type std_msgs/UInt32MultiArray, ce type de message est structuré de la façon suivante :

std_msgs/MultiArrayLayout layout
  std_msgs/MultiArrayDimension[] dim
    string label
    uint32 size
    uint32 stride
  uint32 data_offset
uint32[] data 
  • aruco_single

Ce nœud permet de détecter un marker prédéfini et donner sa position, son type est single.

Voici ses topics :

/aruco_single/camera_info
/aruco_single/debug
/aruco_single/debug/compressed
/aruco_single/debug/compressed/parameter_descriptions
/aruco_single/debug/compressed/parameter_updates
/aruco_single/debug/compressedDepth
/aruco_single/debug/compressedDepth/parameter_descriptions
/aruco_single/debug/compressedDepth/parameter_updates
/aruco_single/debug/theora
/aruco_single/debug/theora/parameter_descriptions
/aruco_single/debug/theora/parameter_updates
/aruco_single/marker
/aruco_single/parameter_descriptions
/aruco_single/parameter_updates
/aruco_single/pixel
/aruco_single/pose
/aruco_single/position
/aruco_single/result
/aruco_single/result/compressed
/aruco_single/result/compressed/parameter_descriptions
/aruco_single/result/compressed/parameter_updates
/aruco_single/result/compressedDepth
/aruco_single/result/compressedDepth/parameter_descriptions
/aruco_single/result/compressedDepth/parameter_updates
/aruco_single/result/theora
/aruco_single/result/theora/parameter_descriptions
/aruco_single/result/theora/parameter_updates
/aruco_single/transform 

Le topic /aruco_sile/pose permet de détecter la position d'un marker, pour cela on envoie la commande suivante :

rostopic echo /aruco_sile/pose

Voici la forme du message "Pose" :

header: 
     seq: 265
     stamp: 
     secs: 1544798521
     nsecs: 100394228
     frame_id: "base_link" 
vector: 
     x: -0.0383155898585
     y: 0.0596644374384
     z: 0.667706902504 

le topic /aruco_single/result permet de voir la détection des markers, on envoie la commande suivante :

rosrun image_view image_view image:=/aruco_single/result 
  • aruco_double

Ce nœud permet d’avoir la position de deux markers différents, son type est doule.

Voici ses topics :

/aruco_double/debug
/aruco_double/debug/compressed
/aruco_double/debug/compressed/parameter_descriptions
/aruco_double/debug/compressed/parameter_updates
/aruco_double/debug/compressedDepth
/aruco_double/debug/compressedDepth/parameter_descriptions
/aruco_double/debug/compressedDepth/parameter_updates
/aruco_double/debug/theora
/aruco_double/debug/theora/parameter_descriptions
/aruco_double/debug/theora/parameter_updates
/aruco_double/parameter_descriptions
/aruco_double/parameter_updates
/aruco_double/pose
/aruco_double/pose2
/aruco_double/result
/aruco_double/result/compressed
/aruco_double/result/compressed/parameter_descriptions
/aruco_double/result/compressed/parameter_updates
/aruco_double/result/compressedDepth
/aruco_double/result/compressedDepth/parameter_descriptions
/aruco_double/result/compressedDepth/parameter_updates
/aruco_double/result/theora
/aruco_double/result/theora/parameter_descriptions
/aruco_double/result/theora/parameter_updates  

Pour détecter les Positions du deux markers, on envoie les commandes suivantes en fonction du marker qu’on veut détecter:

- Premier marker :

rostopic echo /aruco_double/pose

- Deuxième marker :

rostopic echo /aruco_double/pose2

image_symbole_arruco.jpg