Author Topic: FM 3 how to change OP shape over MIDI?  (Read 4833 times)

ericd

  • Team Member
  • **
  • Posts: 84
    • View Profile
FM 3 how to change OP shape over MIDI?
« on: April 07, 2021, 11:57:14 AM »
This is probably more a 'MIDI' noob question than a FM3 question as such.

How could I change the shape of an OP (let's say OP2) via MIDI with an Octatrack as MIDI controller? There is not a CC assigned to this.

The MSB number is 0 and the LSB number is 45, I want to switch between shape OFF (0) and Sin (1).

Is it possible directly with CC messages from the Octatrack?

If not, I could use a MIDI Event Processor by mapping a CC to a sysex command. How do I work out the sysex message to control the OP shape?

Thanks

ericd

  • Team Member
  • **
  • Posts: 84
    • View Profile
Re: FM 3 how to change OP shape over MIDI?
« Reply #1 on: April 11, 2021, 05:37:45 AM »
hmm, perhaps I can ask this question another way.

Currently OP shape cannot be changed by MIDI CC, correct?

Is it possible to change OP shape with a sysex message, if I can work out what the sysex command should be?

solipsvs

  • Team Member
  • ***
  • Posts: 222
    • View Profile
Re: FM 3 how to change OP shape over MIDI?
« Reply #2 on: April 11, 2021, 05:52:06 AM »
i dont think so.

Xavier

  • Administrator
  • Hero Member
  • *
  • Posts: 2256
    • View Profile
Re: FM 3 how to change OP shape over MIDI?
« Reply #3 on: April 11, 2021, 08:37:51 AM »
hmm, perhaps I can ask this question another way.
Currently OP shape cannot be changed by MIDI CC, correct?

Is it possible to change OP shape with a sysex message, if I can work out what the sysex command should be?

No CC for OP Shape. No Sysex.
NRPN only (NRPN are 4 CC BTW, but i don't think the Octotrack can do that.

Adding CC is easy, add yours here :
https://github.com/Ixox/preenfm2/blob/master/src/midi/MidiDecoder.h?ts=4#L47
Then something very close to this (for the OP shape)
https://github.com/Ixox/preenfm2/blob/master/src/midi/MidiDecoder.cpp#L357


ericd

  • Team Member
  • **
  • Posts: 84
    • View Profile
Re: FM 3 how to change OP shape over MIDI?
« Reply #4 on: April 22, 2021, 04:43:33 AM »
Thanks for the info. Unfortunately for me the information about adding CC is beyond my level (it may be 'easy' for some but I don't even understand what the information in those github links is!!).

You are right that the OT doesn't send NRPN but the Midi Events Processor can convert CC to NRPN so I might be able to get someone to help me work that out.

Thanks again.

lokki

  • Sr. Member
  • ****
  • Posts: 383
    • View Profile
Re: FM 3 how to change OP shape over MIDI?
« Reply #5 on: April 22, 2021, 05:17:54 PM »
i think xavier misunderstood a little, because he shared code from the preenfm2 and you asked about the preenfm3, right?

the files he linked to are the source files of the firmware, so you can change things there, compile your own version of the firmware and upload it to your device. i did this many times for the preenfm2 but i yet have to setup the build environment for preenfm3.

hope this clarifies things a little.

ericd

  • Team Member
  • **
  • Posts: 84
    • View Profile
Re: FM 3 how to change OP shape over MIDI?
« Reply #6 on: April 22, 2021, 11:42:03 PM »
Thanks for the clarification.

I am talking about the FM3 yes, but the bigger problem for me is my lack of knowledge about firmware. I wouldn't know where to start and probably not something I have the time to learn at this point in my life!

But at least now I know what those links are ;D

Xavier

  • Administrator
  • Hero Member
  • *
  • Posts: 2256
    • View Profile
Re: FM 3 how to change OP shape over MIDI?
« Reply #7 on: April 23, 2021, 08:46:16 AM »
i think xavier misunderstood a little, because he shared code from the preenfm2 and you asked about the preenfm3, right?

Oh yes :)
Here are the files from the preenfm3, the midi part is mainly the same :

Add CC here :
https://github.com/Ixox/preenfm3/blob/master/firmware/Src/midi/MidiDecoder.h?ts=4#L42
Then use the new value here :
https://github.com/Ixox/preenfm3/blob/master/firmware/Src/midi/MidiDecoder.cpp?ts=4#L497

The pfm3 dev env is only STM32CubeIDE from STMicroelectronics (Same company that makes the MCU STM32H7 used by the preenfm3)