gmassolo
Posts: 3
Joined: Thu Jun 30, 2016 8:32 pm

Remote control via WI-FI

Mon Jul 11, 2016 7:01 pm

Hello everybody!

I've installed Raspian on my RPi3 through a USB keyboard and a HDMI monitor.
After that I installed tightvncserver and I can easily access to my RPi connecting to my local network via Wi-Fi using a router and the ip address.
Now I would like to access to my RPi using the WI-FI but without using the router, I mean directly from my Mac to my Raspberry using the WI-FI.

Is that possible?

Thanks in advance:)

epoch1970
Posts: 5131
Joined: Thu May 05, 2016 9:33 am
Location: Paris, France

Re: Remote control via WI-FI

Tue Jul 12, 2016 8:42 am

If you want to keep the Pi on the router's wifi network and in addition, offer another wifi link for the Mac to connect to, it might be tricky or impossible. You're looking at creating an additional virtual wireless interface, I predict a bumpy road.

If connecting the Pi to the Internet does not matter, or if you have an additional USB wifi adapter, then you have 2 solutions (AFAIK):
- Add Access Point functionality to the Pi, or
- Setup a wifi interface in adhoc mode.

I've almost never used adhoc mode, I'm not sure it works as well as AP mode.
"S'il n'y a pas de solution, c'est qu'il n'y a pas de problème." Les Shadoks, J. Rouxel

User avatar
faramon
Posts: 123
Joined: Sat Jun 11, 2016 8:36 am
Location: Croatia

Re: Remote control via WI-FI

Tue Jul 12, 2016 10:23 am

If i understaind, you want to connect to pi over the internet out from home network...
Ok, i have done this with noip dyndns to get static ip for raspberry and router port forward to ftp port 21 (maybe 22?! but first 21).
Then in thightvnc client must set VNC server to your ddns host (...like youddns.net:1) and hit password in next step and you may be in. This is what i done.

Faramon

Heater
Posts: 15949
Joined: Tue Jul 17, 2012 3:02 pm

Re: Remote control via WI-FI

Tue Jul 12, 2016 10:40 am

A quick google search for "Raspberry pi WIFI access point" Will return a bunch of instructions on how to do what you want. Like this: http://elinux.org/RPI-Wireless-Hotspot

Now I have no idea if you can use a wifi adapter as both an access point and a regular WIFI client. Perhaps you have to add a second WIFI adapter as suggested above.
Memory in C++ is a leaky abstraction .

gmassolo
Posts: 3
Joined: Thu Jun 30, 2016 8:32 pm

Re: Remote control via WI-FI

Wed Jul 13, 2016 11:28 am

Thanks everybody for replies!

I think I need something like this
http://www.howtogeek.com/214053/how-to- ... i-hotspot/

I want to access to RPi with my PC via WI-FI (or other?) and see the desktop even if I am not in a wireless LAN. That's what I need.
More or less like you do with Arduino, you can access it via USB and control almost everything from the PC.

I am a beginner, sorry for silly questions.

User avatar
procount
Posts: 2211
Joined: Thu Jun 27, 2013 12:32 pm
Location: UK

Re: Remote control via WI-FI

Wed Jul 13, 2016 1:06 pm

In the presence of your wireless LAN, you have connected to your Pi from your MAC and can do remote desktop sharing. Great!
Now you want to do the same when your wireless LAN is not present, but still over wifi?

In this case I assume it is a one-one direct link with no other internet access required by either the Pi or the Mac.
So you basically need to create your own wireless LAN.

You can do it like in the article your posted, where the MAC becomes the Access Point (HotSpot) and the Pi connects to the wireless LAN created by the Mac.
Or you can turn your RPi into an Access Point (HotSpot) and get your MAC to connect to the wireless Lan created by the Pi. (Your wifi dongle needs to support AP mode)
(3rd option is to create an Ad-Hoc network as posted above, but I have no experience with that either)

In either case, switching between the 2 configurations when you either have or haven't got a separate wireless router network to provide the Wireless LAN can be a pain.
So another neat solution is to have your Pi boot up as a client and try to connect to your Wireless Router. If that fails (e.g. when your router is missing), then it creates its own Access Point hotspot automatically. Then your Mac just has to connect to this wireless network. One such tutorial can be found here -> http://simplesi.net/class-hotspot/
gmassolo wrote: I want to access to RPi with my PC via WI-FI (or other?)
For 'other' - you could just use an ethernet network cable between the Pi and the Mac. Just set both IPs to be on the same network and you're all set.
PINN - NOOBS with the extras... https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=142574

gmassolo
Posts: 3
Joined: Thu Jun 30, 2016 8:32 pm

Re: Remote control via WI-FI

Wed Jul 13, 2016 1:13 pm

Great! You got my problem.
I'll try tonight and I'll let you know.
(I do not have a ethernet wired connection, for now, from my Mac. That makes everything more tricky)

P.S. For the PRi hotspot you mean something like this? http://elinux.org/RPI-Wireless-Hotspot
Last edited by gmassolo on Wed Jul 13, 2016 1:19 pm, edited 1 time in total.

epoch1970
Posts: 5131
Joined: Thu May 05, 2016 9:33 am
Location: Paris, France

Re: Remote control via WI-FI

Wed Jul 13, 2016 1:16 pm

faramon wrote:Ok, i have done ...
For the record, you do what you want, but nobody should do the same unless they understand the potential consequences i. to the Pi in question, ii. to all other machines in the same network.
Do not expose ssh or ftp to the Internet as a matter of routine. On any machine.
"S'il n'y a pas de solution, c'est qu'il n'y a pas de problème." Les Shadoks, J. Rouxel

Return to “General discussion”