开发者

Detecting a spike in an input signal using Java

I'm working on a project where, I need to control the mouse cursor by some accelerometer input. I'm using Java and have already completed the data collection part and I can开发者_如何学Python move the mouse according to accelerometer input successfully.

I also need to support mouse click events which are triggered by a sudden movement. So; this sudden movement creates a spike in the input signal (a wide one, not just single point). How can I detect such a spike using Java?


A properly tuned high-pass filter could do it, depending on your application. Really simple, 1 line of code.

High-pass filter

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜