IP camera EDIMAX


#1

Hi, I know it is not officially supported, but I have IP camera (EDIMAX) and I would like to use it with octopi. For the live stream it works like a charm. I just add to stream URL http://webcam_ip_address/mjpg/video.mjpg and it works. For Timelapse unfortunatelly, it is not that easy. Edimax provides users with snapshot http://webcam_ip_address/jpg/image.jpg. But Octopi shows an error "Got this as a content type header: text/html. Please double check that the URL is returning static images, not multipart data or videos." Thing is that my url DOES return static image! Any ideas how to resolve this?

Thanks

Newbie


#2

Use curl in a Terminal prompt to see what the IP camera is really sending back.

curl -v http://webcam_ip_address/jpg/image.jpg

It should provide details about pulling that URL. It may very well be just a snippet of HTML code which is perhaps a 301 redirect or it's got HTML with a <head> section which includes a redirect. You're interested in that new URL that's given to you. It's probably an uglier URL, has a deep path to it or something like that. But try that path directly and see if it returns a JPG. If so, then give that path to OctoPrint's settings.


#3

thx for a quick reply. it shows this:

  • Trying webcam_ip_address...
  • TCP_NODELAY set
  • Connected to webcam_ip_address (webcam_ip_address) port 80 (#0)
    GET /jpg/image.jpg HTTP/1.1
    Host: webcam_ip_address
    User-Agent: curl/7.52.1
    Accept: /

HTTP/1.1 401 Unauthorized
Server: GoAhead-Webs
Date: Mon Sep 10 20:56:08 2018
WWW-Authenticate: Basic realm="Network Camera"
Pragma: no-cache
Cache-Control: no-cache
Content-Type: text/html

  • no chunk, no close, no size. Assume close to signal end
Document Error: Unauthorized

Access Error: Unauthorized

Access to this document requires a User ID

  • Curl_http_done: called premature == 0
  • Closing connection 0

It is strange tough because it does not requiere anything in a web browser - anonymous login. Even when I try to add user name and password into the links the result remains the same.


#4

Oh I see now! I have to use this syntax:

http://username:password@webcam_ip_address/jpg/image.jpg

this way it works! It seems, that octopi does not like annonymouse access :slight_smile:
Thank you for pushing me the right way!