There is a whole section on criminal procedure. The gist is, the police are expected to cross the line, infringing on rights on a fairly regular basis. It's up to the courts to throw out the excessive or egregious uses of power. Which, when you think about it, makes a lot of sense. They shouldn't step way over the line, ever. but you want police to push hard to find the "bad guys". sometimes they go excessively far and the bad guys go free. The thinking is, sometimes pushing to hard, and letting people go (innocent or not!) is preferable to timid officers that don't approach the line at all. We all want the "bad guys" to get caught.
It's whole different sections of government that decide where the line is. The police should push using every tool they have until the courts or the legislature say it's to much. You won't find a police officer, DA, defense attorney or judge that says the system is perfect. I think it's a pretty good heuristic though, the innocent pay a (hopefully) small price from time to time, in exchange more "bad guys" get caught.