running rough engine code P0325 on 2000 Nissan Xterra

2000 xterra replaced distributor cap, rotor, spark plug wires and fuel filter, runs fine when first started from being cold - once warm starts running rough knocking and loses power - stalls out , wont start back up

1 answer
Not sure if you solved this issue yet, but that code is for a knock sensor and could be either a bad sensor or sensor wiring.