What codes are you getting?are they po171 po174? if so it sounds like you have a vacuum leak.Have found that the upper intake seals on this engine get hard and leak when engine is cold.engine runs o.k.as the pcm adjusts the fuel trims to compensate for the vacuum leak until it reaches a max amount and then puts the check engine light on.check to see if you have any vacuum hoses leaking or poss faulty pcv valve.hope this helps.