EasyManua.ls Logo

Cognex DataMan - Page 68

Cognex DataMan
76 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
var msg = 'D' + packageID + ',S,W,V';
if (my_decode_results.length == 0)
{
msg += ',?';
output.content = "no result";
}
else
{
for(var i = 0; i < my_decode_results.length; i++)
{
msg += ',' + getFixedPsocId(decodeResults
[i].symbology.id);
switch (my_decode_results[i].symbology.name)
{
case 'Data Matrix':
case 'PDF417':
msg += encode_base64(my_decode_results
[i].content);
break;
case 'POSTNET':
case 'PLANET':
case 'XYZ OneCode':
case 'Interleaved 2 of 5':
default:
msg += my_decode_results
[i].content;
}
}
}
packageID = "000000000"; // reset the package id
output.Telnet = output.Serial = msg + '\r\n';
}
Input match string, output from script (30x)
function CommHandler()
{
return {
onConnect: function (peerName)
{
this.expectFramed('\x02', '\x03', 256);
return true;
},
onDisconnect: function ()
{
},
onExpectedData: function (inputString) {
68
DataMan Application Development

Table of Contents

Other manuals for Cognex DataMan

Related product manuals