Announcement

Collapse
No announcement yet.

API2 with Python

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • API2 with Python

    Hi, i'm working on a simulation using ROS, Python and Gazebo. But now for tests on the real Robotino i have seen that the common way to make the connection is through the Robortino API2, but i don't know how to set up my program to make it works using the API. Any ideas? Or it's not possible to use the API for non C++ based programs?

  • #2
    Why don't you use the robotino_rest_node?



    This is pure Python integrating seemlessly with ROS and you do not need to compile anything.

    Comment


    • #3
      Ok, i'm goig to try that. But, how do i Install the REST-API ? i haven't seen information about that.


      And do i need robotino-damons? When i try sudo apt install robotino-daemons appears:


      robotino-daemons : Depends on: librealsense2 (= 2.28.0-0~realsense0.1512) but it's not installable

      Comment


      • #4
        I just realized that this topic is in "Robotino2". If you have a Robotino2 then you can not upgrade. The only way would be this

        Comment


        • #5
          Hi again, thank you. Do you know if it's posible to do tests in the Simulated Robotino of Robotino SIM Demo?, i have been trying it as is shown in https://wiki.openrobotino.org/index.php?title=API2 changing the ip to 127.0.0.1:8080 but always get -> "Connection refused"

          And this appears in Robotino SIM, like if something were blocking the connection
          Attached Files

          Comment


          • #6
            Please check in Robotino SIM the port you have to connect to. Select Robotino and then look at the dialog shown at the right side of the simulation window. It might be 8081 or something else if 8080 is already used.

            Comment


            • #7
              It seems to be right, I only changed this in the main.cpp of the circle example:

              int main( int argc, char **argv )
              {
              std::string hostname = "127.0.0.1:8081";
              if( argc > 1 )
              {
              hostname = argv[1];
              }

              The next image shows the output from Visual Studio:
              :
              Attached Files

              Comment

              Working...
              X