EasyManua.ls Logo

Jinan USR IOT Technology USR-TCP232-410S

Jinan USR IOT Technology USR-TCP232-410S
46 pages
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...
USR-TCP232-410S User Manual
24 / 46
Web to serial test
Web to serial needs users webpage programming ability. Design webpage, request own device’s data
and process data then reveal the results on webpage. According to chapter4.1.17 Customized Webpage, can
download revised webpage into 410S.
1. Build a connection and connect to 410S.
function connectx(){
try{
socket=new WebSocket('ws://'+window.location.host+':6432');
socket.binaryType = "arraybuffer";
}catch(e){
alert('error');
return;
}
socket.onopen = sOpen;
socket.onerror=sError;
socket.onmessage=sMessage;
socket.onclose=sClose
}
2. Receive Data Function
function sMessage(msg)
3. Send data function
function send()