I just had the same numbers as you when I got smogged 2 weeks ago, my NOX was gross polluter levels. In my case my EGR wasn't opening. Get a vacuum tester and see if your EGR opens, it should kill the engine at around 5 psi. If it's working, try bypassing the EGR BPT valve.
Bypass the EGR BPT valve by either using a vacuum line connector or replacing the two short hoses with one long one, as shown by the red line.
This is the ONLY thing I did to get it to pass and it brought both my NOx and my CO down considerably, and the car passed with flying colors. The car WILL run a tad rough at low throttle during acceleration, but it's hardly noticable, just a slight miss now and then. WOT and Idle are unaffected, because the EGR solenoid valve is not open. Cruise is also not affected.