bjoluc / cubase-mcu-midiremote

Cubase MIDI Remote Scripts for DAW Controllers using the MCU Protocol
MIT License
38 stars 10 forks source link

Script is sending the wrong Velocity Value (which is being covered by C12, but may not be by future versions). #15

Closed djaychela closed 1 year ago

djaychela commented 1 year ago

I don't want to break an NDA, but let's just say I know that this will not work in a future version of Cubase (I think that C12 is masking this error, and a later version will not).

I understand Python well, but don't have any typescript skills, so couldn't do a PR, however, I think in this file:

src/midi/PortPair.ts

There is an issue which is a simple fix:

output.sendMidi(context, [0x90, pitch, +Boolean(velocity) * 0xff]);

Should read

output.sendMidi(context, [0x90, pitch, +Boolean(velocity) * 0x7f]);

So that the script tries to send 127 as the maximum value, not 255. Then it will work.

djaychela commented 1 year ago

I've made a manual change to the compiled JS file (line 4146 for me) and it works fine, BTW.

bjoluc commented 1 year ago

A message from the future, exciting! Thanks for the heads-up @djaychela, and what a silly mistake :facepalm: Fixed by c7d5597 which will be included in 1.7.0 soon. By the way, any words on the 2024 US election yet?

github-actions[bot] commented 1 year ago

:tada: This issue has been resolved in version 1.7.0 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: