Wifi Set Up Static IP

I am unable to get wifi set up on a new Home Assistant. I can get a wired connection. Have followed the example from https://github.com/home-assistant/operating-system/blob/035e3884d847107ca1e954e1b56a98d618b26c0d/Documentation/network.md, but using the Wireless LAN code. My Google Wifi does not pick up the device when I boot. I wonder whether I should be using the Static IP example instead, but as a non-computer guy, I just don’t understand the explanation of the address - “subnet prefix bit length” … Have tried looking this up and I am more confused than ever
I know the IP address of my Pi4, and my router. Can anyone explain this to me - or suggest what else I can do to get my Pi / Home Assistant onto my wifi network?
Thank you

Not knowing your actual level of knowledge, sorry if the question seems dumb, but have you changed “MY_SSID” and “MY_WLAN_SECRET_KEY” to the actual values of your wifi setup?

My level of knowledge is minimal, but yes I changed those and put in a new UUID

Okay.

You mean when wired, I guess? Because if you don’t have wifi, you don’t have IP.
Unless you left the ethernet cable hooked up? If so, unhook it first.

So you don’t see your RPI registered and given an IP address, right?

and be very careful of caps and spelling. You probably have. In one case, I did not and was blessed by taking the longest troubleshooting path to the correction.

Hi guys
Really appreciate your help. Am trying to use the SSH and Terminal and following the instructions there. Managing to get set up with a wifi connection, but as soon as I either take out the ethernet cable or just reboot, I am losing the wifi connection again. Seems like something is making the system “forget” the wifi connection.

Either SSH to it while it’s wired or - if SSH is not enabled yet - connect a display and keyboard and use “sudo raspi-config” and configure the WLAN there.
I don’t know Google Wifi but make sure it accepts new devices on WLAN. For security reasons some routers can be configured to accept already known devices only.

@mike144, I did it this way. You say you get connected with a Ethernet connection.
Format a USB drive with FAT32 system, and name it CONFIG (capitals).
In this drive make a folder with name network
Create a file (I used Notepad++) with name my-network (no extension leave it out)



# Wireless WPA/PSK
[connection]
id=my-network
uuid=
type=802-11-wireless

[802-11-wireless]
mode=infrastructure
ssid=
# Uncomment below if your SSID is not broadcasted
#hidden=true

[802-11-wireless-security]
auth-alg=open
key-mgmt=wpa-psk
psk=

[ipv4]
method=auto

[ipv6]
addr-gen-mode=stable-privacy
method=auto

In this file make entries for your system
1 Change uuid Generate one for yourself there are online uuid generators on the net. I found a mention of it on this forum only.
2 Put in name of your SSID
and password.
All three are empty in the file, fill in your details
Now fix this usb drive in the RPi usb port. and reboot with the Ethernet still connected.
Once it is rebooted you can remove the ethernet drive and the usb drive. Now your wifi connect should work.

Hi guys
Thank you for your advice. In the end, I was not able to get HA to recognise the information from the USB drive. My guess is that I just had something wrong, even though I thought I copied accurately and correctly entered my details.
I did get the answer - at least in my case, from my very techie brother. Used the terminal, and followed the recommended commands, but then used nmtui to give me the popup GUI. Used that, removed the cable, and wifi connection worked
Thanks again for spending time on this
Mike