1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
|
==============================================================================
= output one value per poll
- for relative axes, sum up all events and output one
http://lists.apple.com/archives/mac-games-dev/2005/Oct/msg00060.html
- for absolute axes, just output latest value. if they are not in the queue,
I can check them manually
- buttons, output everything
- is this at all necessary? How often do multiple events happen in one poll period?
==============================================================================
= iterate through elements and do a proper queue of the ones we want:
- also, label multiple instances of the same usage
http://mud.5341.com/msg/8455.html
==============================================================================
= make second inlet for poll # (for [human->pd])
==============================================================================
= output device data on open
- Logical Min/Max i.e. [range -127 127(
- device string [name Trackpad(
==============================================================================
= open devices by name
i.e "Trackpad" a la Max's [hi]
==============================================================================
=
= autoscaling based on Logical min/max
- this is probably essential for input, the question is how to find out what
the data range is easily.
- output would be handy, rather than autoscale, to save on CPU
==============================================================================
= test verbose names
- matju says symbols are compared by pointer, so they are fast
- try verbose names like:
syn = sync
snd = sound
msc = misc
rep = repeat
pwr = power
- maybe these too
abs = absolute
rel = relative
btn = button
- maybe make the type the full name, with the code using the abbreviation
- change generic ev_9 to type_9
- change word "code" to "element"
==============================================================================
= event name changes
- make key/button Type "button" rather than "key" (undecided on this one)
==============================================================================
= hid/serial
- open/close status outlet
- [send ( to send data
- [tgl] 1/0 for open/close
==============================================================================
= linux input synch events (EV_SYN)
- these seem to be generated by the Linux kernel, so they probably don't fit
in with the [hid] scheme. Probably the best thing is to ditch them, or
figure out whether they should be used in controlling the flow of event
data, as they are intended.
==============================================================================
= profile [hid] object and usage
- find out if [autoscale] takes a lot of CPU power, or where in [hid] is using
CPU where it doesn't have to be
==============================================================================
= Report available FF effects
- check against HID Utilities Source/PID.h
==============================================================================
= pollfn for mouse-like devices
- determine whether using a pollfn is actually better than using a t_clock
- any device that acts like a system mouse can be used with a pollfn, since
the mouse data will go thru Pd's network port, triggering the pollfn.
- this is probably unnecessary since the t_clock seems to run well at 1ms delay
- at standard block size (64 samples), one block = ~1.5ms
==============================================================================
= function return values
- most functions probably do not need return values
==============================================================================
= check out using USB timestamp
- use the USB timestamp to correctly space the output data (meh, probably
unnecessary)
/++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++\
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
BUGS BUGS BUGS BUGS BUGS BUGS BUGS BUGS BUGS BUGS BUGS BUGS BUGS BUGS BUGS
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
\++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++/
______________________________________________________________________________
- BUG: figure out how to prevent segfaults on mismapped devices/elements
- it should gracefully ignore things where it currently segfaults
- looks like its in build_device_list
______________________________________________________________________________
- BUG: multiple instances pointing to the same device don't have seperate close/free
- closing the device on one instance closing that same device on all other
instances of [hid]
- deleting that instance also closes the device for all other instances
pointing to that same device
______________________________________________________________________________
- BUG: getting events from the queue doesn't output a 0 value event when the
motion stops, so when the mouse stops, the sound keeps playing.
This is probably only a problem on relative axes.
This will probably have to be implemented on a platform-specific level:
- On Darwin/MacOSX, I think that the HIDGetEvent() loop will have to be
followed by one call to HIDGetElementValue()
______________________________________________________________________________
- BUG: hatswitches on MacOS X output an event without a change in value
Because of the currnently implementation of the conversion of the MacOS X
style event to the Linux style event, an event with a value of zero is output
on the unchanged axis when the hatswitch is moved in along the X or Y axis (as
opposed to diagonally).
______________________________________________________________________________
- BUG: on MacOS X, two keyboard key codes are reported as hatswitches
abs abs_hat0x Button Input, Keyboard Usage 0x39
abs abs_hat0y Button Input, Keyboard Usage 0x39
I am pretty sure this is just a hid_print_element_list() display problem.
|