Skip to content

Enable ROS Code


Normal Method

import ros
ros.message_print('Hello World')

Don’t use the ros prefix

from ros import *
message_print('Hello World')

Enable only a specific command

from ros import message_print
message_print('Hello World')

Use a different command prefix other than ros

import ros as tools
tools.message_print('Hello World')

Enable only a specific command and rename it

from ros import message_print as message
message('Hello World')

Comments