Table 3.1
Methods in inspector.js
Response attributes
Corresponding com-
mand
Method
protocolVersion
gVER
getVersion(callback)
mode
gMOD
getMode(callback)
values[0]
sMOD
setMode(mode, callback)
identifier
values[0 ... n]
gINT
getInt(identifier, arg1, ..., argn, callback)
identifier
values[0 ... n]
sINT
setInt(identifier, arg1, ..., argn, callback)
identifier
value
gSTR
getString(identifier, arg1, ..., argn, callback)
identifier
aACT
performAction(identifier, args, callback)
-
TRIG
trig(callback)
resultString
gRES
getResult(callback)
-
/LockLog
lockLog(callback)
-
/LockLog?Unlock
unlockLog(callback)
The result string returned by the
getResult()
method is the same string that is output over
Ethernet, and which is defined in the
Ethernet Results Output
dialog.
Note
Do not make another call to the Inspector before the current call has returned a response.
If you do, the current command will be interrupted and will not return any response at all,
making it difficult to figure out whether or not the command was performed on the Inspector.
Normally, this is not a problem, but if you are using timed triggers, you should make sure
that the triggered functions don't interrupt any commands that may currently be performed
on the Inspector.
3.4.1
Example: Display live image
To display the current live image, simply include the image from
/LiveImage.jpg
on your
web page:
...
<image src="/LiveImage.jpg"/>
..
This image will not update automatically, so you could add some JavaScript that makes the
live image refresh with a certain interval.
...
<script type="text/javascript">
//<!--
function refreshLiveImage() {
var image = document.getElementById("liveImage");
image.src = "/LiveImage.jpg?ShowOverlay" + (new Date()).getTime() );
// The (new Date()...) is a trick to make the browser
// retrieve the image from the Inspector and not from cache
setTimeout(refreshLiveImage, 500);
};
19
©SICK AG • Identification & Measuring • www.sick.com • All rights reserved
Subject to change without notice
8015726/ZPP7/2018-
09
Interfaces
Web interface
Reference Manual
Inspector PIM
Содержание Inspector PIM60
Страница 1: ...Inspector PIM60 ver 2 0 Vision sensor REFERENCE MANUAL...
Страница 5: ...Introduction...
Страница 7: ...Interfaces...
Страница 38: ...Appendix...
Страница 83: ......