Is some one killing the messenger? If the blue line and the red line are of the old and the new sensor than you have proven one thing only: both sensors work perfectly.
The P1170 is most likely caused by a vacuum leak. First place to look is the Air Intake Duct, the rippled section. Bend it to see if there are cracks. If you have any doubt, take it out, clean it well on the outside with soap and water, then wrap some good quality duct tape around it.
Look also at all vacuum lines and connections. Dont forget the PCV hoses and the brake booster hose. The lower intake manifold gasket could be at fault as well.
Listening for the hiss can help too.