You do not "get" the passcode. You either know it or you do not.
If you do not, then you must restore the ipod.
If you are unable to restore, then type "unable to restore" into the search bar at the top if this page by Support and read the resulting help article. It will tell you how to put it into recovery mode.