Quote
if I do a pwmWrite(10, 2000), I get a Duty cycle of 81.6% in this logic analyzer
That's because the acceptable range for pwmWrite() is 0 - 255, or one unsigned 8 bit integer. You are truncating that int many times over with that second parameter and getting a junk duty cycle as a result.
pwmWrite() parameters are meant to mimic analogWrite() parameters. If you need more resolution, use pwmWriteHR(). It is described earlier in this thread.
This fix should solve your frequency issues, I still have no answer for the test program resolution issue. My Mega, my Uno, and Atmel studio simulators have no problem with it.
The latest version of the library as of this post is v .05. You can download it here:
https://code.google.com/p/arduino-pwm-frequency-library/downloads/list
Ahh, yeah I was thinking about that while I was at work. Forgot to use the HR version. Didn't realize it was 0-255 for lower resolution frequencies as well. I'll try it out and add some results here in a bit.
Thanks again for your efforts.
Update:
Still have the 0 resolution problem on Timer2, and after looking at your code I assume there has to be some offset mismatch specific to this nano for some reason. No big deal though since I am getting the output I need: http://i.imgur.com/iwFcl.png . Both signals behaving as expected.