connection to pi from a different network

April 22, 2024, 08:18

suzzit911

how to connect rpi to laptop wirelessly, the rpi is connected to wifi via ethernet cable and my laptop is connected to some other network not the ethernet netwrok that raspberry pi is connected to. how do i now connect my laptop to raaspberry pi using vnc

oops.se

I think you need to read your question and make corrections.

thunder07337

Either they must be in the same network or you must have access from the network in which your laptop is located to the network in which the Pi is located. Or you have to open the port for VNC to the Internet in the network where the Pi is located.

suzzit911

<@796000224690307072> No they weren't in the same network laptop was connected to my wifi and rpi to my college's internet via ethernet cable can i connect rpi to laptop without being on the same network?

thunder07337

If by connect you mean access (SSH or VNC), yes, I already explained above what you have to do for that!

k9t33n

To add, the best way to do this in my opinion is to set up wireguard/pivpn on that pi so you can access it anywhere.

suzzit911

Do.u have any docs or yt videos thag explains the steps in detail ?

k9t33n

Which one do you want wireguard or pivpn?

k9t33n

Pivpn is slightly easier ig

suzzit911

Pivpn

k9t33n

You would need access to the pis terminal before hand maybe with a display and keyboard

k9t33n

I'll brb.

suzzit911

Also getting a bit offtopic , i will explain my full project which is music player using voice command . I have a rpi 3 in which i have installed nodejs as i have coded in nodejs.link to my code (https://github.com/Suzzit6/MusicPlayerMPL) . What problems am i to face now like will fmpeg work as my speaker output will be in fmpeg also i will be connecting my bluetooth earphones to input the voice commands for which i will be using some packages which i saw in youtube. Will there be any need of gpio pins to output songs or input voice commands ?

k9t33n

Depends on how you use it. You would just use the audio jack and usbs for output/input

oops.se

Yes and No. It depends on if there is a routed network, public IPs or firewalls and private IPs. You need to provide more information!

suzzit911

<@1071178789939331253> thanks for all the help , Also do yall have any idea abt when i connect the wifi (not via ethernet cable) and after some time when i reconnect the same connection is not established I had to make ssh and applicant files again and even after that theres a lot of grinding on connecting the rpi with wifi

k9t33n

maybe its just instability