To generate a desired output frequency from a given waveform:
- Count the number of samples per period of your waveform
- Calculate the necessary update rate of your device based on this formula:
Update Rate =
Output Frequency *
# of Samples per PeriodNote: If the required update rate is above your device's specification, we will need to modify the waveform, use a faster device, or choose a lower frequency signal to generate.
To generate a desired output frequency with a given update rate:
- Calculate the number of samples for each period based on this formula:
# of Samples per Period = Update Rate / Output Frequency
- Create a waveform of the desired signal with the correct number of samples per period
Note: You need to have more than 2 samples per period based on Nyquist Theorem.
Additional Information
In general, this is the formula for calculating the frequency of the analog signal being output:
Output Frequency =
Update Rate /
# of Samples per PeriodNote: Based on
Nyquist Theorem , the quality of the signal is significantly improved by having at least 10 samples per period