So let's say you have configured the Raspberry Pi OS to connect to a Wi-Fi network here, WiFi network
one.
But then you go somewhere else and you need to use a different Wi-Fi network, and you don't have access
to the one already configured.
This can be a problem, because then your Raspberry Pi is kind of lost and you can't get access to it.
You would either need to find an external monitor or to flash the SD card again with a new Wi-Fi configuration,
which is not ideal because you would lose all the files here.
In this video, I will show you how you can solve this problem and note that if you just install the
Raspberry Pi OS and you can have access to the desktop, you don't need to do this.
You can just keep this video and directly go ahead and go to the next section of the course.
Okay.
This video is more of a help you would potentially need in the future, in case you have the problem
that I just described before.
So now let's see how to solve this problem.
And the first thing you can do, and I'm coming back to what I said before is just find an external
monitor, maybe plug a keyboard and a mouse.
That would be the easiest.
Then you just pick the new Wi-Fi network.
You could also try to use an Ethernet cable between your Raspberry Pi and your computer.
And another solution that I also like is simply because you have your phone with you all the time,
so you just use your phone as a hotspot for the Raspberry Pi.
So then if you go to a new place, you can still use your phone as a hotspot.
You can still connect your Raspberry Pi to your phone and then change the settings from there.
But if you can't do any of that, then there is another solution that I'm going to explain right now.
So the idea is quite simple.
We will configure a hotspot on the Raspberry Pi okay.
So that when we get to a new place and there is no Wi-Fi network that the Pi can connect to because
it doesn't have the password, then the Raspberry Pi is going to boot as a hotspot from this computer,
we will be able to connect to the Raspberry Pi, get access to the desktop, and then choose the new
Wi-Fi network to connect to.
Okay.
And for this to work, we actually need to do a bit of preparation, okay.
Because we need to configure the hotspot while we still have access to it.
So while we are still connected here, you can see I'm connected to your Wi-Fi network.
So it's the same network I have configured.
And I'm going to connect to the Raspberry Pi.
Okay I can keep it like this.
And you can see the Raspberry Pi is connected to your Wi-Fi network.
So that's the same thing we had before.
And now we are going to configure.
So I'm going to click here and go to Advanced Options.
And we're going to create a wireless hotspot.
So let's name it for example my RPI hotspot.
You can choose whatever name you want and let's choose here WPA two personal okay.
And let's put a password I choose a very simple password here.
Well raspberry doesn't really matter and you can create it.
You will notice that as soon as you create it, you lose the connection here because it's automatically
gonna create the hotspot.
So let's close Tigervnc here.
And then if we go under settings here on the Wi-Fi settings of our computer, we should find the my
my Raspberry Pi hotspot here.
So I'm going to connect to it.
And I will need to put the, uh pin.
Now I'm going to use a security key instead.
That's the password that I have set.
So that's the raspberry.
Same name I have set here.
You can choose a different name if you want.
Uh, next.
And we should be connected to the Raspberry Pi hotspot.
Okay.
So we are connected.
We don't have access to the internet.
Okay.
Because the Raspberry Pi has no internet access.
And then I'm going to go, uh, again, connect with Tigervnc, but this time the IP address is not
going to be the same because now the hotspot is the Raspberry Pi.
So I'm going to go back to my IP scanner.
Click here.
And now with the Wi-Fi here you can see the network is 10.42 .0. something.
And well you can start the scanner here.
But yeah, what you will find is that the Raspberry Pi as a hotspot will have the IP address ending
with one.
Okay, so I think it should always be like that.
I'm just going to stop once you find it and go back to Tigervnc and just use 10.42 .0.1.
Let's connect.
And we are back to the Raspberry Pi.
This time the Raspberry Pi is the hotspot and our computer is connecting to it.
Okay.
And we just need to do one more thing.
We're going to click here again.
Go to Advanced Options and Edit Connections.
We are going to click here on my API hotspot and click on the configuration.
Here on the settings okay.
And if you go to general so we don't change anything here.
But if you go to general you can see connect automatically with priority zero.
We keep zero here and you have to check that box.
Because if you don't check that box then when you reboot your Raspberry Pi it's not going to create
the hotspot okay.
So we need to make sure that the hotspot is going to be created when we boot the Raspberry Pi.
So I can click on save.
Okay.
And now I can shut down the Raspberry Pi.
So I'm going to shut it down like this.
And I can be sure that if so no close.
Okay.
I can be sure that if I go to any place where the Raspberry Pi cannot connect to a Wi-Fi, then it's
going to create its own hotspot, and from this computer I can connect to the Raspberry Pi hotspot.
All right, so what we did before was the configuration.
Now let's say that we have arrived to a new place, and the Raspberry Pi doesn't know any of the Wi-Fi
networks, so it cannot connect to any Wi-Fi network.
Or simply you have changed your Wi-Fi Ssid or password at home.
Okay, so the Raspberry Pi cannot connect to any network from this computer I have connected to.
So here I have named it another Wi-Fi network.
Okay, so that's my new network that I want to connect the Raspberry Pi to.
So what I will do here is I will boot my Raspberry Pi, and the Raspberry Pi is going to start its own
hotspot.
So I'm going to wait a few seconds, maybe a minute or two, and then I can go there and I should find
somewhere the Raspberry Pi.
Okay, RPI hotspot, let's connect to this one.
So connecting.
Okay.
And we are connected to my Raspberry Pi hotspot.
Note that well of course we don't have internet.
We just have a connection to the Raspberry Pi.
I'm going to open Tigervnc again, and, well, that should be the same IP address as before, but you
can use angry IP scanner if needed.
Let's connect.
Okay.
It works.
So let's connect and we have access to the Raspberry Pi.
You could just keep it like this if you don't need internet.
But here we're going to try to connect the Raspberry Pi to this new Wi-Fi network.
So we're going to click on the Wi-Fi here.
And what it doesn't see any thing okay.
Probably because it's configured as a hotspot.
So you can just click on Advanced options and connect to hidden wireless network.
So when I click here and we're going to set here The network name, so the network name was another
Wi-Fi network.
Make sure you don't make any mistake, any typo.
Okay, so another Wi-Fi network.
So that's the network we want to connect to.
And we're going to choose this one and put the password.
So the password here is going to be the password of the new Wi-Fi network that you should have.
Since you can connect your computer to this new Wi-Fi network.
Okay.
Let's connect.
And well, as soon as we connect, of course, we're going to lose the connection from Tigervnc because
the Raspberry Pi is connecting to another Wi-Fi network.
And we don't have anything else with the hotspot.
So you can see the error.
So let's click on no.
Then our computer, we're going to lose the connection to the Raspberry Pi hotspot because it doesn't
exist anymore.
And you see we are back to another Wi-Fi network.
So make sure that you are back on that one, and then the Raspberry Pi and your computer should be connected
to this new Wi-Fi network.
So we are going to run an IP scan again.
Okay.
So make sure you have the correct Wi-Fi here.
We scan again.
Okay.
Scanning completed.
Let's sort by ping.
You can see we even find it here.
So 192 168 zero and 222.
You can see that it's the same IP address as I had before.
The network mask is the same simply because I'm using the same phone.
I used different names for the Wi-Fi, but it's the same phone, so it's going to create the same IP
address.
But if you go to a different place, the IP address is probably going to look different.
So tigervnc.
And now we can do this.
So we put the IP address.
We connect.
And we are back to the Raspberry Pi.
This time we are connected to another Wi-Fi network.
And what you can do?
Well, if you want to be sure you are connected to this Wi-Fi network and that the Raspberry Pi doesn't
start as a hotspot, you could go back to advanced options, edit connections, and then the hotspot.
You edit the connection again here in the settings, you go to general and you remove this automatically
connect and you save okay.
This way the Raspberry Pi is going to connect automatically to this network.
You are sure it's not going to start as a hotspot.
And then you can repeat this process again.
So if you're going again to a place where you don't know any Wi-Fi network in advance, so it's not
saved on the Raspberry Pi, you just make sure first to start the hotspot, okay?
By default on boot.
So that's the configuration you need to do.
And after this you can go to any place and do this process again.