A new function generator?

Post Reply
mwm
Posts: 44
Joined: Fri Jun 24, 2016 2:35 pm

A new function generator?

Post by mwm »

The FG085 was so impressive I bought it instead of rolling my own. Well, I couldn't have done as good a job with the hardware, but think I could have done a lot better job on the software by choosing a more recent µcu.

I built a simple one (demo at https://youtu.be/FXWTkszKLiU) based on an STM32F4, though you could use an STM32F3 as well. I notice a lot of response of "We're out of memory" to request for features on the FG085. The STM32F series has gobs compared to the ATmega chips. The F3 line starts at 32K, and goes up to 512K.

The other interesting feature is that the STM32F4 has a hardware DAC and DMA support that work together. While I didn't do it in that demo, I've since figured it out, and it's possible to set things up so that you can output an analog wave form from memory without the CPU needing to do anything - a timer drives the DAC to trigger DMA hardware to fetch through the buffer, starting over when done. So you shouldn't need a second CPU, which might help compensate for extra cost of the STM32F chips. Better yet, some of them have two complete sets of such hardware, making a dual generator possible with that CPU.

I may explore this at some point, as I really want the ability to store presets on one, and the STM32F will work fine for the things I want to do. But it's a tool, so I'd much rather buy one than build it if I can find one that'll do what I want.
jye1
Posts: 1221
Joined: Wed Feb 20, 2013 4:58 pm

Re: A new function generator?

Post by jye1 »

Thank you for the suggestion. We have a DDS project that use STM32F1. The DDS core uses hardware (SRAM + CPLD). DMA won't be suitable here because you need to do phase accumulation. The frequency range can go up to 2M at 20MHz clock. For some reason the project was delayed.
Post Reply