2002 grand am rpm problem

I have a 2002 grand am gt. When static the engin rpm will climb to 3900 and drop back to approx. 3700 and climb again. It has error codes
po404 and po302. Has anybody else seen this problem.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
Add image file

Motorsforum.com is a website by car enthusiasts for car enthusiasts. It is not affiliated with any of the car or spare part manufacturers or car dealers discussed here. All logos and trade names are the property of their respective owners.