4
\$\begingroup\$

I'm working on an audio electronics project that uses frequency modulation. A potentiometer will control the tempo/modulation speed, and I'd like to convert the voltage value to a triple-digit value in beats per minute so that it can be displayed to the user on a segmented display. With some time, I could program this in software, but I want this project to be condensed onto a single PCB without something like an Arduino board involved.

What is the best way to do this in a robust way that can be easily replicated?

\$\endgroup\$

2 Answers 2

9
\$\begingroup\$

The simple way is with a microcontroller. You could integrate just the microcontroller on your PCB rather than plugging in a whole Arduino.

The complicated way would be to use op-amps to do your math, then use an ADC with BCD outputs and some seven segment LED drivers with BCD input. Maybe you could use a multimeter ADC with seven segment LED driver instead.

\$\endgroup\$
1
\$\begingroup\$

A microcontroller is indeed the best way to do this.

I want to comment that it is probably not the best strategy to try converting the voltage and/or the potentiometer into the beats per minute (BPM) value in cases where an analog circuit is used to generate the tempo / modulation.

A much better approach is to setup the MCU to be able to use counter / timer / interrupts to directly monitor the tempo waveforms so that you are measuring the beats per minute directly. This is in contrast to having to calibrate a voltage to BPM conversion formula that may never get to desired accuracy and repeatability.

A probably even better approach is to have the MCU read the potentiometer setting directly and the have the MCU generate the timing for the tempo / modulation using onboard timers. This way the software in the MCU knows exactly what to put on the display. Do note that the MCU with some software is the very easiest way to support a display with minimal hardware.

\$\endgroup\$
2
  • \$\begingroup\$ Or use the MCU to generate tne beat. \$\endgroup\$
    – Oskar Skog
    Feb 16 at 23:15
  • \$\begingroup\$ @OskarSkog - Your comment came just as I was typing that very idea into my answer! \$\endgroup\$ Feb 16 at 23:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.