EasyManua.ls Logo

Cognex DataMan - Customer Protocol Integration

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...
onUnexpectedData: function (inputString) {
return false;
},
onTimer: function () {
}
};
}
// data formatting script
function onResult (decodeResults, readerProperties, output)
{
var d = new Date();
var real = new Date(time_offset+d.getTime());
output.content = real.toString() + " " + decodeResults[0].content + "\r\n";
}
Customer Protocols implemented in various CR releases
Communication with cmf400 Profibus gateway
var CMF400_PROTOCOL_STATUS =
{
RUNNING: {value: 0, name: "Running"},
SYNCRONIZING: {value: 1, name: "Sync"},
CONFIGURING: {value: 2, name: "Config"},
STOPPED: {value: 3, name: "Stop"}
};
// make the enum non-modifyable
Object.freeze(CMF400_PROTOCOL_STATUS);
var cmf400_protocol_stx = '\x02'; // header
var cmf400_protocol_etx = '\x03'; // termination
// VT Parameter to be converted into script configuration constant values:
// "/Communication/Interfaces/COM1/Protocol")
var vt_param_comif_com1_protocol = 1;
// "/Communication/Protocols/CMF400/Profibus node number"), 3);
var vt_param_profibus_node_number = 1;
// "/Communication/Protocols/CMF400/Profibus mode"), 3);*/
var vt_param_profibus_mode = 1;
// TODO: how to configure parameter, where to store them with a out of stock firmware?
var cmf400_protocol_profibus_node_number = 1;
var cmf400_protocol_profibus_mode = 1;
var cmf400_protocol_test_diagnostic_enabled = 0;
var cmf400_protocol_test_diagnostic = 'TEST';
// Protocol strings
var cmf400_gateway_init = '+Gateway-Init+';
var cmf400_gateway_ident_ok = '+GW SOK TSICDPS';
var cmf400_gateway_ident_no = '+GW SNO TSICDPS';
var cmf400_gateway_run = '+GW-RUN+';
var cmf400_gateway_error = '+GW-ERR';
60
DataMan Application Development

Table of Contents

Other manuals for Cognex DataMan

Related product manuals