Hello g3n,
I hope this works for you.
First, I got my card to find the access point. So, the light on the card was not blinking. I have not tried this when it cannot find the access point. My access point allows "ANY".
Now, from the terminal as root, I run iwconfig and it shows what currently is setup. Mine shows info about the access point (SSID, MAC address, etc.)
I originally did a google on iwconfig and got the parameters.
Now, on to what I do.
At the command line:
iwconfig wlan0 key <my key> mode managed enc on
ifconfig wlan0 down (mine was up)
ifconfig wlan0 up
route add default gw <my gateway>
Doing ifconfig wlan0 should show that you have an IP address assign, assuming you use DHCP.
At some point, I will put that into a script.
Hope that helps,
C-