Controlling frequency with slider in MSP

    Oct 06 2009 | 9:42 pm
    I'm working on a modular-synth build in MAX/MSP. I want to control frequency with a knob or slider and am trying to find a way to constrain the values similar to the relative amplitude calculation used in Tutorial Four that changes integers from the slider into decibals. The slider only gives values from 1 to 127 and I want to convert to Hertz. Any ideas on this would be great.
    If anyone else is working on any sort of synth builds in MSP, I would be interested in messaging with them.

    • Oct 06 2009 | 9:47 pm
      I think that [mtof] will be your friend. It will turn midi values into the related frequencies in hertz.
    • Oct 06 2009 | 9:52 pm
    • Oct 07 2009 | 12:31 am
      0. - 1. to frequency:
      [* 127] [mtof]
      [expr (440.*exp(0.057762265*(($f1*127)-69.)))]
      0. - 1. to db/A:
      [expr max((log10($f1)*20),-90.)]
      numberfully yours