I’ve managed to get my wanscam W2 to work by using ffmpeg to re-encapsulate the media stream and re-publishing there via rtsp-simple-server and monocle-gateway:
Install rtsp-simple-server from
https://github.com/aler9/rtsp-simple-server/releases/latest
Make sure, ffmpeg is available on your system (https://ffmpeg.org)
Configure rtsp-simple-server to serve the reencoded stream
Here the relevant part of my rtsp-simple-server.yml
[...]
# port of the TCP/RTSP listener. This is used only if encryption is "no" or "optional".
rtspPort: 8654
# port of the TCP/TLS/RTSPS listener. This is used only if encryption is "yes" or "optional".
rtspsPort: 8655
# port of the UDP/RTP listener. This is used only if "udp" is in protocols.
rtpPort: 8100
# port of the UDP/RTCP listener. This is used only if "udp" is in protocols.
rtcpPort: 8101
[...]
paths:
cam:
source: record
publishIps: ["127.0.0.1"]
runOnInit: "ffmpeg -i 'rtsp://user:pass@IP_OF_CAMERA/live/ch0' -vcodec copy -acodec aac -f rtsp rtsp://localhost:${RTSP_PORT}/${RTSP_PATH} -loglevel 8"
runOnInitRestart: yes
readUser: user
readPass: pass
readIps: ["YOURLOCALSUBNET"] #or let empty
The runOnInit might be also replaced by a runOnDemand
Now configure monocle to connect to the local rtsp server, e.g.:
rtmp://IP_OF_HELPER_SERVER:8654/cam
and use as tags @proxy
Hope that helps!