The AD9851 uses a 30MHz crystal, and multiplies that by 6 to get the 180MHz clock. It might be worth checking that the crystal is the correct frequency. Given the frequencies that you measured, it looks like the clock might running at 2/3 of the correct value - 20MHz crystal ? I'm using an AD9851 and it works perfectly with the same Hex files you have been using.DaveR wrote:My AD9850 and AD9851 modules arrived a couple of days ago, so I tried out the four hex files Steve posted. All four files worked first time when uploaded to my Mega2560 and UNO boards, and the AD9850 works very well indeed. However, there is a problem with the AD9851 in that, although it functions ok under both Arduinos, the output from it is 2/3 that of the frequency set in RSP-SAS, eg setting a spot frequency of 24MHz only produces output at 16MHz, and doing a sweep around 30MHz produces nothing on the screen because the actual sweep is carried out at 20MHz!
DaveR wrote:Doing a search for info on this glitch, I quickly came across this thread on the Arduino.cc forum from someone who had found exactly the same behaviour with the AD9851: https://forum.arduino.cc/index.php?topic=530929.0
i had a look at the link. Somebody posted that by playing around with one of the constants used in the frequency calculation he could get close to the correct frequency. Unfortunately he didn't post any figures, so it's not possible to work out his actual crystal frequency.
What is puzzling is that you have no problems with the AD9850. I know Don-K9AQ could not get his AD9850 to work with any of the Hex files, yet source code he had found did work. I've waiting for an AD9850 module to arrive. When it does, I'll be able to get a better idea of what may be happening.
You say you got two modules, are they the same as the module I post a photo of a few messages back in this thread? If not, would you be able to post a picture of them ?