Labview FRC Dashboard Camera code not HTTP 1.1 compliant

In attempts to discover why the default FRC Dashboard doesn’t successfully connect to an embedded web server on a Raspberry Pi (when it works just fine from IE on the classmate PC itself), I discovered that it’s because the Dashboard is sending out invalid HTTP requests, which the Axis camera’s embedded server seems to accept.

Here is a raw data capture of what the current default Dashboard sends out to receive video from the axis camera.

GET /axis-cgi/mjpg/video.cgi?fps=30&compression=30&resolution=320x240 HTTP/1.1
User-Agent: HTTPStreamClient
Connection: Keep-Alive
Cache-Control: no-cache
Authorization: Basic RlJDOkZSQw==

This is not compliant, as the 1.1 spec requires the Host: field which is clearly missing, even though it is stating it is an HTTP/1.1 request.

This probably is a very simple fix to the Labview code, as it just needs to provide the IP address it is trying to send to:

Host: 10.xx.yy.11:80

where xx.yy is the normal team designation when running camera on the 10 network.

Still trying to work around this bug, as even the proxy servers I’m attempting to pass it through are kicking back a 400 Bad Request response before attempting anything adjustments to the headers. Even an incorrect Host entry would be easy to work around.

-Spencer

It is indeed a very simple fix. The http header is a string constant in WPI_CameraIssue HTTP Request with Authentication.vi. It’s trivial to put a specific team number’s address into the string. The code would take a little modification in order to use the cRIO’s address automatically, but not much.