Generate Noise Using LFSR (Linear Feedback Shift Register)
Hello,
I am trying to generate white noise using the DAC, much like was mentioned in this forum post:
How to generate a white noise with the DAC on STM32L1
However, I don't know if putting values into memory table and using cyclic mode is the only answer. From my research using Audio and waveform generation using the DAC in STM32 microcontrollers - Application note, it looks like you should be able to use the LFSR (Linear Feedback Shift Register) / Random Number Generator in Figure 5 to make white noise as is shown in Figure 6 on page 9:
Here is how I have my STMCubeMX set:
And here is my "Software Trigger":
HAL_DAC_Start(&hdac, DAC1_CHANNEL_1);
HAL_DAC_Start(&hdac, DAC1_CHANNEL_2);
Yet, when I look at the oscilloscope, all I get is a DC offset just like my friend in the other forum post observed:
Any thoughts on this? Many thanks in advance!
