Changes between Version 4 and Version 5 of en/ProgrammingRobotsCourse/GettingWwwInfo2


Ignore:
Timestamp:
Mar 16, 2020, 4:37:56 PM (4 years ago)
Author:
Ales Horak
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • en/ProgrammingRobotsCourse/GettingWwwInfo2

    v4 v5  
    33A service can be tested in the virtual robot settings.
    44
     5* prepare an app with the service to test - you may start with the examples below or use the ''templater'' tool [https://github.com/pepperhacking/robot-jumpstarter#template-python-service robot-jumpstarter] (use a ''new name'' for your service):
     6  {{{
     7cd /nlp/projekty/pepper/web/robot-jumpstarter
     8python jumpstart.py python-service tweety-service TweetyService
     9cp -a output/tweety-service ~/pepper/
     10}}}
     11  Here `tweety-service` is the directory name of the application (and the app name), `TweetyService` is the API name of your service as it will be called from Python.
    512* start Choregraphe and [../Introduction#virtualrobot run the virtual robot]
    613* find out the ''port number'' of your virtual robot: click [[Image(pepper_connect.png, valign=top)]] [[br]]
     
    815  [[Image(pepper_virtual_port.png)]][[br]]
    916  Here the virtual robot's address is `localhost:34121`
     17* run your service in the virtual robot (Choregraphe must still be running, of course):
     18  {{{
     19cd ~/pepper/tweety-service/app
     20python scripts/tweetyservice.py --qi-url localhost:34121
     21}}}
     22  The output should look like:
     23  {{{
     24[I] 1584373059.579170 4749 qimessaging.session: Session listener created on tcp://0.0.0.0:0
     25[I] 1584373059.579385 4749 qimessaging.transportserver: TransportServer will listen on: tcp://192.168.1.2:36873
     26[I] 1584373059.579394 4749 qimessaging.transportserver: TransportServer will listen on: tcp://127.0.0.1:36873
     27}}}