Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
en:mervis-ide:65-webpanel:webpanel-api [2017/06/21 14:36]
m.chlupac [Request]
en:mervis-ide:65-webpanel:webpanel-api [2019/05/21 09:45]
m.chlupac [Request]
Line 26: Line 26:
  
 ==== Request ==== ==== Request ====
 +
 +**URL:** ''http://[ip-address-of-the-plc]/values.cgi''
  
 <code js>{ <code js>{
Line 39: Line 41:
   * variable ID is unique string - in future, may be different for different platforms/protocol versions (uPLC - int?, SharkRT - string)   * variable ID is unique string - in future, may be different for different platforms/protocol versions (uPLC - int?, SharkRT - string)
  
-=== Variable specification for RT2 ===+=== Variable specification for Mervis RT ===
  
   * svc - protocol   * svc - protocol
Line 50: Line 52:
  
   - JSON string (AngularJS default behaviour): <code js>{"ver":1,"c":{"u":"karel","p":"x"},"v":["svc://defaultConnection/myVarId1","svc://otherConnection/xxxYYYYDDD"]}</code>   - JSON string (AngularJS default behaviour): <code js>{"ver":1,"c":{"u":"karel","p":"x"},"v":["svc://defaultConnection/myVarId1","svc://otherConnection/xxxYYYYDDD"]}</code>
-  - converted into POST parameters (jQuery default behaviour): +  - converted into POST parameters (jQuery default behaviour):<code>ver=1&c%5Bu%5D=karel&c%5Bp%5D=x&v%5B%5D=svc%3A%2F%2FdefaultConnection%2FmyVarId1&v%5B%5D=svc%3A%2F%2FotherConnection%2FxxxYYYYDDD</code>
- <code>ver=1&c%5Bu%5D=karel&c%5Bp%5D=x&v%5B%5D=svc%3A%2F%2FdefaultConnection%2FmyVarId1&v%5B%5D=svc%3A%2F%2FotherConnection%2FxxxYYYYDDD</code>+
  
-The best solution would be to support both versions. Easier is now the JSON string. 
  
 ==== Response ==== ==== Response ====
Line 72: Line 72:
 === Encoding of values - version 1 === === Encoding of values - version 1 ===
  
-Ea  Unordered List Itemch value is transmitted as a big endian binary representation of the specified variable (and its offset and length).+  Each value is transmitted as a big endian binary representation of the specified variable (and its offset and length).
  
 ===== Command Request ===== ===== Command Request =====
  • © Energocentrum Plus, s.r.o. 2017 - 2024