Easy Setup
Go to the Settings section of the XMB menu and select Network Settings and enable the Internet Connection option if it's disabled. Then select Internet Connection Settings, then Easy, then Wireless, then Scan. All the wireless networks in range will display in a moment; select the one you want to connect to and then confirm the network name, or SSID, by pressing the right directional button. Select the type of security the network uses; if it's not None, or open access, then it probably uses WPA-PSK/WPA2-PSK; next enter the password. You should now see the Settings List page. Press the "X" button to continue and then select Test Connection to test the console's current network status.
Custom
Select the Network Settings option from the Settings section of the XMB menu and make sure that the Internet Connection option is enabled. After that select Internet Connection Settings, then Custom, then Wireless, then Scan. A list of all available Wi-Fi networks will display; select the one you want to connect to and press the right directional button to confirm its name. If the network is secure, select the security type. -- most networks use WPA-PSK/WPA2-PSK -- and then enter the password. The next few screens contain technical settings for your network connection, and you should select the default options for these unless you specifically know you need a different setup. Press the "X" button when you reach the Settings List page; if you don't see any mistakes in the configuration, press the "X" button again and select Test Connection to ensure that your PS3 is online. If you do see mistakes, press the "Circle" button to go back and fix whatever you need to.
Test Connection
Although you have the opportunity to test the network immediately after setting it up, you can also test it any time if you're experiencing difficulty with the connection. Just select Internet Connection Test from the Network Settings option. When the test begins, the PS3 will entirely disconnect from any Internet connection it has and then attempt to re-establish that connection. If the console has any problems, you'll see the issue displayed on the screen during the test.
Resetting the Connection
The simplest option to reset a connection on the PS3 is to go to the Settings section of the XMB menu and select Network Settings and then change the Internet Connection setting to disable. After that wait a few moments and change it back to Enable to allow the PS3 to reconnect. You could also go through the easy or custom setup again to reset all configurations, or you may want to reset your wireless router using whatever method its manual recommends.