Ah yes, this is an annoyance with many USB HIDs that output relative
data. The data they output is in effect speed, but they don't output
zero. What those devices are actually outputting is the amount of
change in pixels since the last measurement of location. If there is
no change, they output nothing. So you don't get a zero.
Personally, I think this is a bad design, and makes them hard to work
with if you are doing something other than moving a cursor around on
a screen. (I suppose it makes things a bit more efficient for moving
a mouse cursor around on a screen).
I dealt with this problem by using a delay to output a 0 when the
stream of data has stopped for a 10 ms or so. Check the attached patch:
 .hc
On Jul 24, 2007, at 8:17 PM, Diego Azar wrote:
Absolute value. So if the last value was -3 and the mouse stop
moving, it stays there. What I meant was that if the number was
greater than absolute value of 1, and the mouse stops, it stays
there. I put abs(1) because the sign is logical. If I move from
right to left it stays in a negative number, what seems correct. If
it is in the oposite direccion it stays in a positive number, so
the sign thing seems to work fine. What number is it supposed to
give if there´s no movement? one? When moving fast it always have this problem Could it be some delay between the on of the mouse´s led and the
"data transfer" from the os to pd? I tried it with two mouses ,one with a led-cam-dsp system and the
other with a ball-system, and they had the same behavior. Sorry if I wasn´t clear enough.Diego.
Hans-Christoph Steiner hans@eds.org wrote:
I read your question again, and I don't quite get it. What's abs(1)?
.hc
On Jul 24, 2007, at 4:37 AM, Diego Azar wrote:
Hans, thanks for your reply. I'm working with hidio because it
works better, with my configuration, than the hid.thanks again, Diego.
Hans-Christoph Steiner hans@eds.org wrote:
First off, I must say [hidio] can be quite rough since it's very
alpha. But I am glad to have people testing it, with that in
mind. But if you are using [hidio] and not [hid], and you are
getting "rel_x" as a message, then that is a bug. "rel_x" is the
old [hid] style messages. [hidio]'s messages look like [relative
x 0 1(.hc
On Jul 22, 2007, at 9:49 PM, Diego Azar wrote:
Hi. I'm using the hidio object with a mouse and it seems there's
something I'm not getting. The problem is when routing the list
from the rel_x to obtain the x relative axes; the value,
sometimes, is greater than abs(1) when the mouse is not moving.
Is this behavior correct? Is this a bug? Has it anythig to do
with the numbers hidio gets from the /dev/event$ or something
within the OS? I'm using a Debian based distro.Thanks, Diego.
Boardwalk for $500? In 2007? Ha! Play Monopoly Here and Now (it's updated for today's economy) at
Yahoo! Games. _______________________________________________ PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/ listinfo/pd-list
I have the audacity to believe that peoples everywhere can have
three meals a day for their bodies, education and culture for
their minds, and dignity, equality and freedom for their
spirits. - Martin Luther King, Jr.Pinpoint customers who are looking for what you sell.
Mistrust authority - promote decentralization. - the hacker ethic
Pinpoint customers who are looking for what you sell.
"[W]e have invented the technology to eliminate scarcity, but we are
deliberately throwing it away to benefit those who profit from
scarcity." -John Gilmore