rvi / ONVIFCameraAndroid

Example on how to connect to an ONVIF camera on Android
MIT License
142 stars 68 forks source link

Error, make sure your endpoint is correct #13

Open ankitvaluepitch opened 4 years ago

ankitvaluepitch commented 4 years ago

hi, the all code works fine, but there is one problem - it works for 5 to 10 seconds well and I get the video stream, but after this duration, it gives me the error - Error, make sure your endpoint is correct. and after that, it never gives me the video stream.

this is the log I get when trying to connect the second time after disconnecting in 5second.

EGLint new_window_surface(egl_winsys_display , void , EGLSurface, EGLConfig, egl_winsys_surface **, EGLBoolean) returns 0x3000 W/libEGL: EGLNativeWindowType 0x7ea5df1010 disconnect failed W/VLC: [0000007ebceda410/48eb] libvlc demux: no data received in 10s. Switching to TCP D/VLC: [0000007ebcfa0590/48eb] libvlc decoder: killing decoder fourcc h264' [0000007ebcfa0590/48eb] libvlc decoder: removing module "avcodec" D/VLC: [0000007ebcfa0910/48eb] libvlc packetizer: removing module "h264" D/VLC: [0000007ebcfa0c90/48eb] libvlc decoder: killing decoder fourccmp4a' [0000007ebcfa0c90/48eb] libvlc decoder: removing module "avcodec" D/VLC: [0000007ea81ec090/48eb] libvlc input: Program doesn't contain anymore ES W/VLC: [0000007ebceda410/48eb] libvlc demux: Password in a URI is DEPRECATED D/VLC: [0000007ebceda410/48eb] libvlc demux: connection error -115

E/VLC: [0000007ebceda410/48eb] libvlc demux: Failed to connect with rtsp://deviceipaddress:554/live/deviceusername_p0_TVFMETBYEDCJ [0000007ebceda410/48eb] libvlc demux: TCP rollover failed, aborting

D/VLC: [0000007ea81ec090/48eb] libvlc input: EOF reached D/VLC: [0000007ebceda410/48eb] libvlc demux: removing module "live555"

rvi commented 4 years ago

Weird, I guess it's probably from your camera, I never saw this issue before. Do you have a second camera to try to reproduce it?

ankitvaluepitch commented 4 years ago

@rvi, I don't have now, will check on another camera in some time. @rvi it would be easy for me if you suggest any camera to me.thanx

ankitvaluepitch commented 4 years ago

hi @rvi , Currently due to lockdown period I can not get another camera, but I have tried with this site app link -> http://happytimesoft.com/products/onvif-client-for-android/index.html they have built the app with the onvif source code, and their app working fine for the same camera.but their source code is not available. can you please debug with me for your source code that what the exact issue is. thank you.

rvi commented 4 years ago

Hey Ankit, when I wrote this code I tested it with 9 cameras and it worked for all of them.

I can't really help you without any camera. I think you can try to change the pod for libVLC, I know they change it and it might be not up to date.