It sounds like what you want is a PS2 Gameshark, I had one but I never really got to put it to use, but I remember it worked really well, like a PS1 or 64 Gameshark.
ps2 gameshark - Google Search
GameShark 2 | Springledge Entertainment, Inc.
It looks like they still sell em too, there's one on this page and I'm sure you can find plenty more online, you could also consider Action Replay but it's not really the same type of device. If you get the Gameshark they come with thousands of codes already built in for a library of games and there's plenty of sites all over the internet with pages and pages of codes you can add in yourself.