Realtime pitch recognition

Hi everybody, I want to create a realtime pitch recogniser with Processing. How can I do this?
Thanks.