I don't have issues with staying awake at work...my issues come about on my days off. I try to switch to a normal sleeping schedule on my days off but I still end up being wide awake in the middle of the night.
As for trying to get to sleep once you get home, different things work for different people. Some people like to work out immediately after getting off the clock. I never have the energy (or desire) to do that lol and working out actually energizes me, so I avoid. Some, though, swear that it helps them sleep afterwards.
Invest in some black out curtains or if you don't want to do that, invest in an sleep mask to mimic night time when you sleep. Turn off all electronics, including your cell phone
. Tell your friends and family about your work schedule and your designated sleep times. Remember, their 1pm is your 1am! Keep your sleep environment cool, too. Turn on the AC or have a fan going - it's nice to have a little bit of "white noise" to help you doze off.
I use either Benadryl or melatonin to help me sleep when I'm switching back to my night shift schedule. I typically do 3 in a row (though now I'm doing 2 in a row with 3-4 days off, 2 in a row, 1 off, 2 in a row) so once I'm back on my night shift sleep schedule, I don't use sleep aids to help me sleep when I'm off the clock.
If you like coffee, drink it. I need this liquid elixir to function, lol. I do, however, cut off my caffeine consumption around 0100 to prevent sleeping problems when I'm finally off the clock. If I feel like I'm dragging at work, then I'll drink a couple of sips of coffee if it's past my 0100 cut off time, but that's it. No problems.
I also agree with wearing sunglasses. And wear them if you have to get up and pee. Any light exposure will start waking you up and you'll find it hard to go back to sleep.