Study of the production of charged pions, kaons, and protons in pPb collisions at sqrt{s_NN}=5.02 TeV