Failed to add flash plugin in xacro file
hello, I have seen tutorial given by johnconn similar problem, but it is SDF format, I try libFlashLightPlugin in sdf, it works! however, I fail to run this plugin in xacro file. here is my code:
<joint name="${robot_namespace}/led_joint" type="fixed">
<origin xyz="0 0 0" rpy="0 0 0" />
<parent link="${robot_namespace}/base_link" />
<child link="led_link" />
</joint>
<link name="led_link">
<visual name="led">
<origin xyz="0 0 -0.2" rpy="0 0 0" />
<geometry>
...
</geometry>
</visual>
<light name="led" type="point">
...
</light>
</link>
<gazebo>
<light> name ='led_link/led' type = 'point'</light>
<plugin name='light_control' filename='libFlashLightPlugin.so'>
<enable>true</enable>
<light>
<id>led_link/led</id>
<duration>0.3</duration>
<interval>0.4</interval>
<color>0.5 1 0.8</color>
</light>
</plugin>
</gazebo>
here is my successful demo in SDF format
<joint name="quad01/led_joint" type="fixed">
<parent>quad01/base_link</parent>
<child>led_link</child>
</joint>
<link name="led_link">
<pose>0 0 0.1 0 0 0</pose>
<visual name="led">
<geometry>
<sphere>
<radius>0.01</radius>
</sphere>
</geometry>
</visual>
<light name="led" type="point">
<attenuation>
<range>0.5</range>
<linear>0.5</linear>
</attenuation>
<diffuse>1 0.2 0.2 1</diffuse>
<specular>1 1 1 1</specular>
</light>
</link>
<plugin name='light_control' filename='libFlashLightPlugin.so'>
<enable>true</enable>
<light>
<id>led_link/led</id>
<duration>0.3</duration>
<interval>0.4</interval>
<color>0.5 1 0.8</color>
</light>
</plugin>