예제 #1
0
 protected override void StartRos()
 {
     InitializeGameObject();
     chatterPublisher  = node.CreatePublisher <std_msgs.msg.String>(Topic);
     chatterPublisher2 = node.CreatePublisher <sensor_msgs.msg.CompressedImage>("chatter_image/compressed");
     msg  = new std_msgs.msg.String();
     msg2 = new sensor_msgs.msg.CompressedImage();
     StartCoroutine("PublishMessage");
 }
예제 #2
0
    // Update is called once per frame
    void Update()
    {
        if (RCLdotnet.Ok())
        {
            std_msgs.msg.String msg = new std_msgs.msg.String();
            msg.Data = "Hello World: ";
            chatter_pub.Publish(msg);

            //RCLdotnet.PrintTopicNamesAndTypes(node.Handle);
        }
    }
예제 #3
0
 protected override void StartRos()
 {
     chatterPublisher = node.CreatePublisher <std_msgs.msg.String>(Topic);
     msg = new std_msgs.msg.String();
     StartCoroutine("PublishMessage");
 }