Welcome! Log In Create A New Profile

Advanced

Control through internet

Posted by RoSt 
Control through internet
March 03, 2015 06:48PM
I think its great to just access the printer via my laptop/Ipad/Android phone at home now. After the release of 0,78za-dc42 it works even better, great to be able to drop g-codes to print through the web-interface without need of picking the sd in and out.

I have port-forward my webcam through the router and have access to it anywhere through internet, but, when i connect the printer to the same port i get error mess.

Anyone that have been able to reach the printer through internet and not only home network?
Re: Control through internet
March 04, 2015 03:32AM
you have to put one of the devices on another port than 80. I dont know how easy it is to put the printer on another port [github.com] suggests that it is fixed to port 80. so have a look if you could put your webcam on another port. 8000 is a good one to use.
Re: Control through internet
March 04, 2015 04:44AM
It would be quite easy to add a gcode to set the printer port to something other than 80. I'll probably add this in my next release.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Control through internet
March 04, 2015 06:37AM
The problem isn't that the printer and webcam are both on port 80, since they have their own IP's.

In your DSL router, you need to port forward port 80 to :80, and then port 81 (for example) to :80.
Then from outside you can access your printer on :80 and your webcam on :81.
Re: Control through internet
March 04, 2015 07:31AM
Quote
pandionx
In your DSL router, you need to port forward port 80 to :80, and then port 81 (for example) to :80.
Then from outside you can access your printer on :80 and your webcam on :81.
this will also work.
Re: Control through internet
March 04, 2015 03:45PM
Thanks for all the answers, i still have problem thou. When i forward my webcam i can reach it but not the printer, even when i take the port that works on the webcam and put it on the printer it stops work.

I can connect to **.**.**.***:5201 if i have the webcam on the port, wen i connect the printer to the same port it stops working. If i enter the local adress 192.168.1.114 i connect directly.

Network config isn't my strong side sadly.
Re: Control through internet
March 04, 2015 06:43PM
I've put a pre-release copy of firmware 1.00n-dc42 at [dl.dropboxusercontent.com]. With this version, you can change the http port number that the Duet response to, by adding a R parameter to your M552 command in config.g. For example, add R81 to that command, then you can connect the browser via port 81 (i.e. append ":81" to the IP address you type in the browswr address bar).

See separate thread here [forums.reprap.org] on additional considerations if you are not already runnig my 1.00 series firmware.

Hope this helps - dc

Edited 1 time(s). Last edit at 03/04/2015 06:43PM by dc42.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Control through internet
March 05, 2015 08:09AM
Quote
RoSt
Thanks for all the answers, i still have problem thou. When i forward my webcam i can reach it but not the printer, even when i take the port that works on the webcam and put it on the printer it stops work.

I can connect to **.**.**.***:5201 if i have the webcam on the port, wen i connect the printer to the same port it stops working. If i enter the local adress 192.168.1.114 i connect directly.

Network config isn't my strong side sadly.

Each device (or application) will "listen" on a particular port number. Unless the incoming connection is for that port number, it will be ignored. The Ormerod is only listening on port 80, so if you forward any other port number to it, the connection will be ignored. You cannot forward the same port number to two different devices (IP addresses), because the router will not know which device to route the incoming connection to. If you can set the webcam application to listen on a different port to the Ormerod (which you suggest you can), then set the webcam to (say) port 5201 and port forward 5201 to the local webcam IP address, and port forward port 80 to the Ormerod IP address, and it should work. I see David has provided a version of firmware that allows you to change the port number that the Ormerod listens on, so you could now change the Ormerod port number instead of the webcam's port number - just make sure that the port numbers of the webcam and the Ormerod are different and you forward each port number to the IP address of the device that is listening to that port.

DasBasti describes another solution, in that some (but not all) routers are able to change the incoming port number when they route it, so you could set the router to route incoming connections to (say) port 81 to the Ormerod, but change the port number so that the Ormerod "thinks" it is a connection to port 80 and will thus respond. You will then set the external web browser's address bar to send to port 81 (put ":81" at the end of the address). You must still ensure that the incoming port number for the webcam is different to the incoming port number for the Ormerod.

Dave
Re: Control through internet
March 05, 2015 08:55AM
Great, i didn't know that the printer was bound to a certain port like that in the firmware, my router web interface is locked to 80, thats why i had trouble to use port 80 for my printer then, i thought the port was for/in the router only.

Thank god i have you guys, i have experience with building, repairing and config pc's but i think all network terms and hierarchy is confusing.....

I update the firmware to start with and change to a free port.

Thanks
//Robert
Re: Control through internet
March 05, 2015 09:19AM
Quote
RoSt
Great, i didn't know that the printer was bound to a certain port like that in the firmware, my router web interface is locked to 80, thats why i had trouble to use port 80 for my printer then, i thought the port was for/in the router only.

Thank god i have you guys, i have experience with building, repairing and config pc's but i think all network terms and hierarchy is confusing.....

I update the firmware to start with and change to a free port.

Thanks
//Robert

When you port forward port 80, it results in most routers disabling their internal web server from the WAN side (it still works from the LAN side) so you should be able to use port 80. Note that with most routers you will still need to connect to the Ormerod using its local (private) IP address when on a local PC, but use the public IP address of your Internet connection when connecting via the Internet from outside your LAN. To test port forwarding therefore, unless you have a second Internet connection you will need to go through an external web proxy (e.g. webproxy.net). If your Internet address is not fixed, you may want to use a dynamic DNS service to give it a domain name instead of using an IP address which could change from time to time.

Dave
Re: Control through internet
March 05, 2015 09:25AM
After more testing, I discovered that my latest firmware build has a problem with fetching the SD card file list over the web interface. So I've just fixed that and updated the binary. Use the same link as before to download it.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Control through internet
March 07, 2015 04:44PM
Thanks for the help guys!
I loaded the 1.00n-dc42 firmware and set the port in there and now i can connect from my laptop/Ipad or Samsung Galaxy S5 anywhere smiling smiley
Nice to be able to abort and lower the temp if i see the print go bananas on the webcam when i am not home.


I also attached the Aluminium X-Arm kit that i bought of Davek0974 while i was working with the machine, looking really great and after i touched up the surface of the aluminium it looks good with a brushed surface.


Again, thanks alot!

//Robert
Sorry, only registered users may post in this forum.

Click here to login