Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OSC /buttonBank example sending incorrect OSC message names #36

Open
mrbombmusic opened this issue Dec 23, 2022 · 0 comments
Open

OSC /buttonBank example sending incorrect OSC message names #36

mrbombmusic opened this issue Dec 23, 2022 · 0 comments

Comments

@mrbombmusic
Copy link

Hello @L05 ,

I got the OSC /buttonBank example working to send OSC messages to Sonic Pi.

However, the OSC message names only go from "button0" to "button3" in each respective column no matter which row you are clicking (4-8, 9-12, 13-16)

I did find the problem which is in the sendOsc( ) function on line 45

sendOsc('/button' + i, b[i][j].val);

It was an easy fix. I just replaced 'i' with the .label method for each button in the 2D array

sendOsc('/button' + b[i][j].label, b[i][j].val);

Works fine now!
(I apologize that Im not super savvy with Github or I would tried to make the change myself)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant