Engine Performance problem
2000 Nissan Sentra 4 cyl Front Wheel Drive 48160 miles
Vehicle came in with code PO171-engine lean on bank 1. Tested fuel pressure, checked for vacuum leaks. Found EGR valve not sealing. Replaced EGR and retested. Light has not reset but after 15-20 seconds of cold start vehicle still runs badly and will even shut off. Rechecked and found spark plugs incorrectly gapped so I regapped to spec. Also minumum air rate was inncorrect.I have also cleaned the throttle body and did a top engine clean. Did O2 sensor test and enriched with propane and created vacuum leak to test range of sensors. Was graphing sensors during all of this and the y seemed to respond properly with plenty of switching with no glitching. Also when vehicle does this timing retards on scan tool at the same time. All sensors seem to read normal. Cooliant and air charge sensors read correct ambient temperature on start. Mass air flow seems correct but I am not that familiar with this vehicle. We usually work on high end European. Its almost like it needs a reprogram of the computor. There is a reprogram but it is for a standard shift. This vehicle is a automatic. Any ideas?
Thanks for your help.