Wednesday, June 15, 2016 alfa-0.2 release - documentation : part2

  This post is the second extension to the previous documentation post part1. Previously has been shown how to instruct the robot by commands over HTTP connection by using POST, GET  request types.  
$curl  -X GET  http://brick_ip:8022?left=10\&right=10
$curl -H "Content-Type: application/json" -X 
POST -d '{"command" : "right=10;left=10"}' http://brick_ip:8022
  The following post will explain and introduce another services which are available in current robo4j alfa-0.2 release. Those services are provided by the robo4j-brick-client light-weight socket server. 
  The socket server is responsible for handling HTTP requests. It is open on the port 8022. The running services also provide access to the robo4j AGENT. This agentis running on the brick. This specific AGENT implementation is currently responsible for cashing processed command requests. You can access it by using cURL or simply your favorite web browser.
  The robo4j-brick-client returns its current state with information which commands have been received. 
  The next service provided by GET request is, already mentioned, command request. After the command has been send the robot will generate following response

Such response provides information about command process state. 
   The last service which is touch in this post is the EXIT service .
By sending exit request to the robot the exit response is generated.
The response is generated after all Executors are stopped and application process is ready to finish.
Have a great day! 
Stay tuned and enjoy all news.

No comments:

Post a Comment