The three minute boot cycle is a tell-tale sign of the iPhone phenomenon known as a kernel panic. What's happening is that every three minutes the phone goes to scan it's internal sensors. If, during that scan, a sensor cannot be read the phone performs a kernel panic. That involves logging the error then rebooting the phone in an attempt to recover from that error. Unfortunately, since it's a hardware problem, the next time the phone scans its sensors, the issue is still present, so it goes ahead and does another kernel panic, which it will continue to do to infinity and beyond since the phone is incapable of realizing that rebooting the phone isn't helping.
The key takeaway here is that the phone writes a file with an exact description of why the phone is being rebooted. We can use that to determine what part has failed and in most cases replacing that part will fix the issue. So your next step is to locate the panic log, as it's called, then cut and paste or screenshot the first page of it. Come back here and add that information to your question and chances are good we'll be able to figure out what's going on with your phone. This guide has all the information you need, but interpretation of the panic log can be tricky, which is why I recommend adding your log to your question so we can give you a definitive diagnosis.
iPhone Kernel Panics - iFixit
So scroll down to the part titled How to Find a Panic Log and use that to locate the newest panic log on your phone. Get the first page information then add it to your question. If you cut'n'paste it, then all you have to do is edit your question and paste the text in at the end; otherwise this guide will show you how to add a screenshot to your question.
Adding images to an existing question - iFixit Repair Guide