Difference between revisions of "Change API legacy"

From ElphelWiki
Jump to: navigation, search
 
Line 1: Line 1:
Elphel cameras have two different APIs. The old [[ccam.cgi]] API and the [[Video API]] which is a superset of the [[AxisAPI]]. By default (after flashing), Elphel cameras (at least the 333 model) work in the [[ccam.cgi]] API mode, which means that all attempts to acces the images using the [[Video API]] will come  back with a 500 Server Error.
+
Elphel cameras have two different APIs. The old [[ccam.cgi]] API and the [[Video API]] which is a superset of the [[AxisAPI]]. By default (after flashing), Elphel cameras (at least the 333 model) work in the [[ccam.cgi]] API mode, which means that all attempts to acces the images using the [[Video API]] will come  back with a <tt>500 Server Error</tt>.
  
 
To check wich API is currently active for your camera, use the "chapi.cgi" CGI script:
 
To check wich API is currently active for your camera, use the "chapi.cgi" CGI script:
Line 15: Line 15:
 
</pre>
 
</pre>
  
0 - cigcam.api
+
meaning:
  
1 - Video API
+
* <tt><api>0</api></tt> - [[ccam.api]]
 +
* <tt><api>1</api></tt> - [[Video API]]
  
To change the API, use the action=setup&api=X parameters, e.g.:
+
To change the API, use the <tt>action=setup&api=X</tt> parameters, e.g.:
  
 
<pre>
 
<pre>
Line 32: Line 33:
 
</camera>
 
</camera>
 
</pre>
 
</pre>
 +
 +
== References ==
 +
 +
* [[ccam.cgi]] Attempt to describe the somewhat incomprehendible older API
 +
* [[Video API]] Description of the the new Axis-compatible API
 +
* [[AxisAPI]] Description of the Axis-camera API which is partially supported by the [[Video API]].

Revision as of 00:57, 1 December 2006

Elphel cameras have two different APIs. The old ccam.cgi API and the Video API which is a superset of the AxisAPI. By default (after flashing), Elphel cameras (at least the 333 model) work in the ccam.cgi API mode, which means that all attempts to acces the images using the Video API will come back with a 500 Server Error.

To check wich API is currently active for your camera, use the "chapi.cgi" CGI script:

http://192.168.0.9/cgi-bin/admin/chapi.cgi?action=status

This will return and XML document such as:

<camera>
<api>0</api>
</camera>

meaning:

To change the API, use the action=setup&api=X parameters, e.g.:

http://192.168.0.9/cgi-bin/admin/chapi.cgi?action=setup&api=1

which will change the API even over reboots and return the changed configuration:

<camera>
<api>1</api>
</camera>

References

  • ccam.cgi Attempt to describe the somewhat incomprehendible older API
  • Video API Description of the the new Axis-compatible API
  • AxisAPI Description of the Axis-camera API which is partially supported by the Video API.