web services subscriptions
GMORRIS59
✭✭
I am trying to better understand the web services and in particular subscriptions. Using C# I can register as a subscription but there are two main questions with the event data I received
a) When subscribing to a value change the data received does not contain the value of the variable. Just an event that it changed eg.
a) When subscribing to a value change the data received does not contain the value of the variable. Just an event that it changed eg.
This is the type of subscription but actually done in C# <br>curl --digest -u "Default User":robotics -X POST -d "resources=1&1=/rw/rapid/symbol/data/RAPID/T_ROB1/Module1/count;value&1-p=1" "http://127.0.0.1/subscription"<br><br>The reply is<br>"<?xml version=\"1.0\" encoding=\"utf-8\"?><br><html xmlns=\"http://www.w3.org/1999/xhtml\"> <br> <head> <br><title>Event</title><base href=\"http://127.0.0.1:80/\"/> <br></head> <br><body> <br> <div class=\"state\"><a href=\"subscription/52\" rel=\"group\"></a> <br> <ul> <li class=\"rap-value-ev\" title=\"value\"> <br> <a href=\"/rw/rapid/symbol/data/RAPID/T_ROB1/Module1/count;value\" rel=\"self\"/></li> <br> </ul> </div> <br> </body><br> </html>"<br><br><br>b) How can I subscribe to an I/O change in value - I only seem to be able to change in state
This fails:<br><br>curl --digest -u "Default User":robotics -d "resources=1&1=/rw/iosystem/signals/testDI;value&1-p=0" -X POST "http://localhost/subscription"<br><br>This works<br><br>curl --digest -u "Default User":robotics -d "resources=1&1=/rw/iosystem/signals/testDI;state&1-p=0" -X POST "http://localhost/subscription"<br><br>but I want the value change.<br>
0
Comments
-
I'm having the identical problem: no <span class="lvalue"> or <span class="lstate"> items in the subscription POST reply or WebSocket response.
What is wrong?0 -
Hello all,
I think this post is relevant to your questions:
https://forums.robotstudio.com/discussion/12655/robotwebservices-subscriptions
—Maxim RiabichevPC Software Support Engineer0
Categories
- All Categories
- 5.5K RobotStudio
- 392 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 249 ScreenMaker
- 2.7K Robot Controller
- 307 IRC5
- 59 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 3 RobotStudio AR Viewer
- 779 RAPID Programming
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 4 Job listings