Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need help to run the code #84

Open
thalesmaoa opened this issue Jun 26, 2023 · 8 comments
Open

Need help to run the code #84

thalesmaoa opened this issue Jun 26, 2023 · 8 comments

Comments

@thalesmaoa
Copy link

Hello, just arrived by a suggestion of @thatdevsherry, but I'm a completely dumb in rust. Never used and I'm having difficulties to understand its work flow.
After some reading, I tried to run the example, but I get an error:

$ cargo run --package client mp4 --url rtsp://192.168.11.125:8800/ 
error: Found argument '--url' which wasn't expected, or isn't valid in this context

	If you tried to supply `--url` as a value rather than a flag, use `-- --url`

USAGE:
    cargo run --package [<SPEC>...]

For more information try --help

I have a cheap chinese brand that open using V380. I need to open it in the computer. I can find the reason for that.

@thatdevsherry
Copy link

Hey, can you also try running my forked repo of retina? I had tried messing around with it to support my v380 camera. If it doesn't work on upstream retina but works on my fork, then both of our cameras have the same problem.

I'm able to use my forked version to get an RTSP stream, using the following command

cargo run --package client mp4 --url rtsp://192.168.10.10 out.mp4

Relevant V380 PR

@scottlamb
Copy link
Owner

$ cargo run --package client mp4 --url rtsp://192.168.11.125:8800/

Sorry, typo in the README. Instead of mp4 --url, it should read mp4 -- --url. The extra -- ends the arguments to cargo itself (Rust's build tool) and starts the arguments that should be passed through to the program being run.

@thalesmaoa
Copy link
Author

Sorry, but I've being trying to understand my problem, but I think this is a really simple and noob problem.

$ cargo run --package client mp4 -- --url rtsp://10.254.1.223:8800 --username admin --password password out.mp4
error: package(s) `mp4` not found in workspace `/home/thales/chinese_camera/retina`

Really need help.

@thalesmaoa
Copy link
Author

Hello, not sure why I had this problem before. I've made a new clone and everything works great.

$ cargo run --package client mp4 --url rtsp://10.254.1.223:8800 --username admin --password password out.mp4
    Finished dev [unoptimized + debuginfo] target(s) in 0.23s
     Running `target/debug/client mp4 --url 'rtsp://10.254.1.223:8800' --username admin --password password out.mp4`
E20230713 11:03:10.417 main client] Fatal: Error reading from RTSP peer: EOF while expecting response to DESCRIBE CSeq 1

conn: 10.0.2.15:50776(me)->10.254.1.223:8800@2023-07-13T11:03:10
msg: 0@2023-07-13T11:03:10

@thatdevsherry , I've tried your repo, but I get the following error.

Here is the capture of wireshark. wireshark.pcapng.zip

@thatdevsherry
Copy link

@thalesmaoa I see that you're using rtsp://10.254.1.223:8800. Can you try using just rtsp://10.254.1.223 or rtsp://10.254.1.223:554, since RTSP usually has port 554 assigned. I have seen 8800 open on my v380 cam as well, but I'm pretty sure it's used for something else.

@thalesmaoa
Copy link
Author

The only opened port is the 8800.

$ sudo nmap 10.254.1.223
[sudo] senha para thales:        
Starting Nmap 7.80 ( https://nmap.org ) at 2023-07-13 12:00 -03
Nmap scan report for 10.254.1.223
Host is up (0.0031s latency).
Not shown: 999 closed ports
PORT     STATE SERVICE
8800/tcp open  sunwebadmin

Nmap done: 1 IP address (1 host up) scanned in 1.90 seconds

If I try without it:

$ cargo run --package client mp4 --url rtsp://10.254.1.223 --username admin --password password out.mp4
    Finished dev [unoptimized + debuginfo] target(s) in 1.06s
     Running `target/debug/client mp4 --url 'rtsp://10.254.1.223' --username admin --password Cameraadmin123 out.mp4`
E20230713 11:59:33.262 main client] Fatal: Unable to connect to RTSP server: Connection refused (os error 111)

@thatdevsherry
Copy link

I have a feeling that your v380 firmware doesn't support ONVIF. Mine didn't either. I had to contact the v380 team with my cam details and they sent me a new firmware to flash to the cam. After that, I could see onvif setting in my cam settings on v380 app under Advanced settings > Onvif setting.

Could you verify that you have Onvif setting in your cam settings under v380 app?

@thalesmaoa
Copy link
Author

I will try as you suggested and let you know. Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants