Good morning, Tom! I was desided the some problem with the wpa_cli and with the next link: http://linux.die.net/man/8/wpa_supplicant
If You not had a IP-address, then make next steps:
1. sudo killall dhcpcd
2. sudo dhcpcd wlan0 start
P.S I used "sudo ifconfig -a" instead "ip a"