Hacker News new | ask | show | jobs
by lovelyviking 898 days ago
As I understand GPIO speed is limited and below usb 2.0 speed if I am not mistaken. So what is the maximum speed of this setup? How ‘gaming” gaming mouse can be?
2 comments

You are talking transfer rate but these are polling in most cases. The gpio can easily handle 1000hz. It can 66 thousand times that speed in fact. The amount of processing they do is negligible and probably amounts to a few microseconds delay at most.

Even with a non polling mouse there would be no point in reading the result more than a thousand times per second. If you move the mouse 3 inches per second (quite fast) and you only process 1000 reports a second you would still achieve a resolution of 0.003 inches.

From a quick google search (to make sure I'm not just stating my memories, but actual facts) the RP2040 can toggle a GPIO at about 66MHz (via its PIOs. Otherwise a bit slower, and using more CPU). USB 1 is 1.5 or 12Mbps, so you should have no issues even if you bit bang it.

Despite the USB protocol overhead, it is plenty even for a gaming mouse. Pretty sure there's no point polling it at above 1 kilohertz or so.