I want to use a PIC 16F877A to control a Direct Digital Synthesis RF signal source. I need to serially load a 40 bit word into the DDS board.
First I have to calculate the value of the frequency control word (32 bits). The equation for it is:
fout = (control word x system clock)/ 2e32
fout - desired frequency in MHz control word - decimal value of the 32 bit word needed for the DDS system clock = clock speed in MHz
For testing, I will set the DDS to 10MHz so:
control word =(fout x 2e32)/180
None of the variable types appear to handle a number the size of 2e32 so how would I calculate the control word?
Log in to post a comment.
I want to use a PIC 16F877A to control a Direct Digital Synthesis RF signal source. I need to serially load a 40 bit word into the DDS board.
First I have to calculate the value of the frequency control word (32 bits). The equation for it is:
fout = (control word x system clock)/ 2e32
fout - desired frequency in MHz
control word - decimal value of the 32 bit word needed for the DDS
system clock = clock speed in MHz
For testing, I will set the DDS to 10MHz so:
control word =(fout x 2e32)/180
None of the variable types appear to handle a number the size of 2e32 so how would I calculate the control word?