If you are getting a P0335 it means the PTCM is seeing oddball, nonsense data from the Crank sensor. This is either an issue with the connector or the sensor itself.
I would try another new CPS, you are describing almost exactly how they act when they fail. Are you SURE this is a BOSCH part? It sounds like it is one of those Chinese knockoffs from Autozone or Advanced.
I got mine here:
https://www.germanautosupply.com/sto...sensor-95.html