If I paste any of my urls into a browser, I can use the old (less secure) method, by prefixing the url with my credentials. I.e. this will work in a browser:
Code: Select all
http://username:[email protected]/Streaming/Channels/102/picture
I believe this because it is basic authentication over http, which is a no-no, especially when not called directly by you.
However, the following method does work (for me) via Dashticz (and most other locally hosted systems):
Code: Select all
http://192.168.1.99/Streaming/Channels/102/picture?user=username&pwd=password
- MJPEG is only enabled on models with firmware above v4 (which is most nowadays).
- I have only managed to display the substream (aka channel 2 or 102), not the main stream (channel 1 or 101). Even if I put 101 in the url, it will still display the substream (which is lower resolution).
- You need to change the substream video encoding to MJPEG on the camera. Image > Video & Audio > Stream Type = "Sub Stream", Video Encoding Type = "M_JPEG" > Save.
Code: Select all
blocks['camera_1'] = {
type: 'camera',
imageUrl: 'http://192.168.1.99/Streaming/Channels/102/picture?user=username&pwd=password',
videoUrl: 'http://192.168.1.99/Streaming/Channels/102/httppreview?user=username&pwd=password',
refresh: 3000,
width: 6,
height: 300
}
I hope this helps.