2
$\begingroup$

My problem:

I need to connect to my 3D printer via the internet from an Android app (using IP address and API key).

My 3D printer is based on Marlin firmware latest and connected to a Raspberry Pi running OctoPi. I don't want to use a router and port forward it, because the Raspberry will be connected to internet via a Wi-Fi hotspot.

My question:

Is it possible to control the printer using a cloud platform or a server (another Raspberry Pi) if my OctoPi Raspberry Pi can access the internet? If it is possible, how can one do it?

Any suggestions or solutions are welcome.

$\endgroup$
2
  • $\begingroup$ I take it you don't have control over the wifi hotspot? Because a wifi hotspot is able to port forward just as well as a wired router is. $\endgroup$ Mar 16, 2018 at 8:38
  • $\begingroup$ yes i dont have control over the wifi hotspot and it can come from android or even a laptop too $\endgroup$
    – Amrith
    Mar 16, 2018 at 9:02

1 Answer 1

1
$\begingroup$

There are a few solutions, but each one needs to match same criteria: an open network socket visible outside the local network.

So from TCP/IP protocol theory, we don't even need to have an IP address to send a packet to another computer as we can use layer One which is just the MAC address to identify the receiver. But things become more complicated when we have to provide a link to two separate endpoints.

Basic requirements:

  1. We need to know public accessible IP address and port that server is exposed (listening) on
  2. We can have a DNS entry that will be translated to public IP, but that assume that public IP is same all the time (or we have a dynDNS service)

Solutions:

  1. Have the RPi exposed with public IP address and routed properly;
  2. Create a VPN bridge from RPi to your home/cloud network and connect Android to the same VPN;
  3. Do a port forwarding to RPi from public IP and expose that in the firewall.

So at this point, if you don't have admin access to network devices then only solution '2' is viable, IMHO.

$\endgroup$
3
  • $\begingroup$ The controlling organization of the network to which the printer is connected has not been defined. If it is a home network, you can usually open a port and have it forwarded to your internal device. One is unlikely to be able to install a VPN on the printer, but one could expose the network port to the external internet by this method of opening the (or the few) ports required. $\endgroup$
    – cmm
    Mar 23, 2018 at 21:19
  • $\begingroup$ As OP says there is no access to router (I had assumption that it could be university printer). That is the reason I'm suggesting 2nd proposal. $\endgroup$
    – profesor79
    Mar 23, 2018 at 21:23
  • $\begingroup$ I understand. The OP would need then to have another RaspPi (or something similar) implementing the VPN, and routing traffic to the printer. OpenVPN can do that, but I found the setup to be difficult. $\endgroup$
    – cmm
    Mar 23, 2018 at 21:26

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .