Download and install iFunBox (free). I strongly recommend you do not enter your Apple ID and password if it should ask you. Apparently it can also manage apps but that isn't what you want it for.
Make sure iTunes itself isn't running, Use the File Browser to get access to Raw File System\iTunes_Control\Music. Inside are a number of folders with obscured 4 character filenames as shown below. Right-click on the Music folder and click Copy to PC. Save to <Media Folder>'Automatically Add to iTunes.
When all the files have been extracted start iTunes. The tracks will be added to the library and moved to their correct artist and album folders. Any .wav files will end up in Unknown Artist\Unknown Album and you will need to edit the metadata for those by hand.
You can also use my free scripts ImportDevice Playlists and SyncStats to recover playlists, ratings and playcounts.
Refer to the user tip for advice on backing up the device and restoring it once all the media has been extracted, and on backing up your library so you don't need to do this again.
tt2