No passcode if at home? Is there a way to set up the iPhone so that when I'm away from home it requires a lock code, but when I'm at home I don't need a passcode?
Actually, the basic functionality does not provide this feature.

You can do this by Jaibreaking your device (getting write priviligies to system partition) and installing tweaks like :


AutoProtect
CleverPin