socket.onClose = function () { // remove the HTTP info from received data var imageStartIndex = receivedData.indexOf("\r\n\r\n"); var bitmapData = receivedData.substring(imageStartIndex+4);
// display the image var MyImage = new Image(bitmapData); GUI.widget("panel").setImage(MyImage); };
socket.connect("192.168.83.25", 80, 3000);
I want to use onWake to renew the connection to my camera when the Pronto awakes.