What is the meaning behind words "I am but mad north-north-west

What is the meaning behind words “I am but mad north-north-west. When the wind is southerly, I know a hawk from a handsaw” in Hamlet?