Prepare Dfterm3<=>WebSocket connection for JSON messages.

We prepend one byte to each message sent to the web browser. 1 indicates screen
data and 2 indicates a JSON message.

It is intended that, apart from the screen data, all other communication is
done using JSON.