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

output.puts doesnt product sound consistently #26

Open
udit99 opened this issue Nov 28, 2013 · 1 comment
Open

output.puts doesnt product sound consistently #26

udit99 opened this issue Nov 28, 2013 · 1 comment

Comments

@udit99
Copy link

udit99 commented Nov 28, 2013

I'm using the tutorial here: http://tx81z.blogspot.com/2011/06/unimidi-platform-independent-realtime.html

I've found that if I try running the following loop immediately after running it once, it doesnt produce any sound:

output.open do |output|

notes.each do |note|
output.puts(0x90, note, 100) # note on message
sleep(duration) # wait
output.puts(0x80, note, 100) # note off message
end

end

But if I give it a few seconds (20-30) to "catch up"...I can make sounds again...Doing individual output.puts also seems to result in similar "silent lags".

@arirusso
Copy link
Owner

arirusso commented Sep 2, 2014

Sorry for the late response. If you're still interested, what platform/ruby are you on? What MIDI interface are you using?

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

2 participants