8 Replies Latest reply on Sep 9, 2016 12:57 PM by Intel Corporation

    How could  I use webcam on public network?

    Feng.L

      Hello,

      I can see the picture using mjpeg-streamer on Edison ,but it only can be used in the same WiFi connection.

      I have got an cloud webserver and a public network ip,

      Is there any possible to use it in public network?

      Thanks.

        • 1. Re: How could  I use webcam on public network?
          Intel Corporation
          This message was posted on behalf of Intel Corporation

          Hi Feng.L,

          This is an interesting question. I’ve never tried to connect the Edison and the computer on different networks. Most guides that require the Edison to be connected to the network require it to be on the same network as the computer so I’m not sure if this is going to work. However, one thing to try is using NAT (Network Address Translation). NAT is a method used to translate one public IP address to a private address or addresses. There are lots of possible NAT configurations so it can be customizable for your needs. I’d suggest you to look into your router’s documentation to see which NAT features you can configure.

          You can also take a look how NAT works in Linux. I found a guide you might find useful https://www.howtoforge.com/nat_iptables . There’s not a guide to do this on the Edison so it’s possible you’d have to make additional configuration and installation of features to be able to follow the guide completely.

          Let us know your results and if you’re able to succeed in configuring NAT to use the webcam. In case you are, we encourage you to share your results with the community.

          -Sergio
           

          • 2. Re: How could  I use webcam on public network?
            if

            Did you set a port forwarding in you wifi router what the edison is connected to?

            • 3. Re: How could  I use webcam on public network?
              Feng.L

              Thanks for your answer,

              I think the NAT guide seems to make linux be a router and connect to external network.I don't know how to run it but I tried Port Mapping and DMZ(Demilitarized Zone) on my router configuration.I can't load edison's homepage using public IP , maybe because of the dynamic IP. Maybe the network operator set the limits. I use Remote Manage Networked Devices Anywhere to visit my edison's homepage but I can't visit specific port (like 8080) to see the picture of my cam.(mjpeg-streamer WebCam: Using mjpeg streamer to stream video over HTTP ).I'like to know if I could use the cloud server to receive data from edison and visit the cloud server to read.

              • 4. Re: How could  I use webcam on public network?
                Feng.L

                I tried but it didn't work.I still can't visit edison using router's public IP..

                • 5. Re: How could  I use webcam on public network?
                  if

                  Not entirelly sure about your actual network setup. Is the edison in a subnetwork (home?), connecting to a wifi router. Is the WAN side of the router is a broadband connection, and you try to connect to it from an outside sub-net (office, web server?) that tries to connect to the edison.

                  Have you tried to forward port 22 the same way, then connect to the edison with ssh?

                  Have you checked if the public port what you forwarded to the edison open when you look at it from the outside network? (e.g. nmap) If so, you could also double-check if the protocol of the port is set properly (TCP/UDP).

                  • 6. Re: How could  I use webcam on public network?
                    Feng.L

                    Yes ,the edison connected with a wifi router. But the cloud webserver is in public network with a static IP.I haven't use nmap. I tried to forward many ports to edison on the router  but I can't visit edison's homepage from each port of them.  I won't know my router's public IP in few minutes or hours even though it works once ,and I still can't visit edison . So I wonder if I could use cloud server to connect to edison then I can visit my edison by the public static IP anywhere.

                    • 7. Re: How could  I use webcam on public network?
                      if

                      Just to summarize it, if your Edison is behind your home wifi router, what you should do is:

                       

                      Check the local IP address of your Edison. (192.168.x.y).

                      Check the port number of the mjpg-streamer on your Edison board.

                      Choose a port number what you want to use from the outside word, to access the Edison stream. (It can be the same as the mjpg-streamer port number.)

                      Then define the port forwarding in you router: WAN Port number   ->    Edison local IP address / mjpg-port number.

                       

                      Check WAN side IP address of your home router (not the local network address, but the one what is given to you by your service provider).

                      You can do it with visiting the url: http://whatismyip.com from your home network, with a browser.

                      To access your Edison you will need this IP and the WAN Port number.

                       

                      Important, that your router can only find your Edison as long as its local address remains the same (most likely some 192.168.x.y). Unfortunately, if the Edison has got a dynamic IP address, it may change after every reboot.

                      To achieve a constant local IP address, you need to give the Edison a static IP address, or you need to reserve an IP address in your router for it.

                       

                      An easy way to test the port forwarding is: following the above process create a port forwarding from port 22 on the WAN side to port 22 of the Edison. Then you should be able to access it from the outside world with ssh.

                       

                      Istvan

                      1 of 1 people found this helpful
                      • 8. Re: How could  I use webcam on public network?
                        Intel Corporation
                        This message was posted on behalf of Intel Corporation

                        Hi Feng.L,

                        Do you still need assistance with this thread? Were you able to use your webcam on a public network as @if suggested? We’ll be waiting for your response.

                        -Sergio