Open patmaddox opened 3 years ago
I have seen the exact same behaviour on all counts: empty events at time, and "stuck" process then coming back to life.
I have seen a few commits in forks mentioning a "sleep", will try that out and investigate.
It is fixed by #15 for me (which I'll incorporate in my fork at https://github.com/thbar/ex-portmidi).
I am a bit confused about the event API, and hope @lucidstack can clear it up for me. I am admittedly very new to elixir and so am not sure if it's normal or not.
First, the documentation says that a received event looks like
{144, 112, 127}
. I am seeing events that look like this though:[{{146, 46, 127}, 36124}]
.Okay, I'm guessing that the events are now a list of events with a timestamp. Cool. But I'm seeing LOTS of empty events. Sometimes when I press and release a button on my controller, there are several hundred empty events between the on and off. Example:
What's the purpose of those empty events?
Also, other times I can press the buttons on my controller hundreds of times without seeing an empty event. Why is that?
Also sometimes only the first few button presses register and it seems to get stuck. It's pretty inconsistent and I'm not sure what's going on.
I'm just a bit confused and could use some help clearing it up :)