/
unit-joystick.pd
51 lines (51 loc) · 1.6 KB
/
unit-joystick.pd
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
#N canvas 394 396 467 288 10;
#X obj 17 98 inlet;
#X text 139 30 parses incoming OSC data for OSC from unit_joysticks
;
#X text 113 98 incoming OSC messages;
#X text 111 144 creation arg : address for the device;
#X text 219 202 events are sent out in lists;
#X text 248 247 button # 0 is down aka '1';
#X text 221 224 ex: /button "0 1";
#X text 215 164 ex: /joy1;
#X obj 17 232 outlet axis;
#X obj 116 232 outlet button;
#N canvas 8 69 407 221 button 0;
#X obj 63 43 inlet;
#X text 27 13 unpack button messages and send to gui / named sends
;
#X obj 96 145 s \$0-button;
#X obj 153 99 s \$0-button-value;
#X obj 96 70 unpack f f;
#X connect 0 0 4 0;
#X connect 4 0 2 0;
#X connect 4 1 3 0;
#X restore 126 199 pd button;
#N canvas 12 90 407 221 axis 0;
#X obj 63 43 inlet;
#X text 27 13 unpack button messages and send to gui / named sends
;
#X obj 96 70 unpack f f;
#X obj 153 99 s \$0-axis-value;
#X obj 96 145 s \$0-axis;
#X connect 0 0 2 0;
#X connect 2 0 4 0;
#X connect 2 1 3 0;
#X restore 30 201 pd axis;
#X obj 17 170 unit-joystick_ \$1;
#X obj 1 16 cnv 15 128 43 empty empty empty 20 12 0 14 -233017 -66577
0;
#X obj 29 41 nbx 2 14 -1e+37 1e+37 0 0 empty \$0-button btn -20 6 0
10 -261234 -1 -1 0 256;
#X obj 64 41 nbx 5 14 -1e+37 1e+37 0 0 empty \$0-button-value empty
0 -6 0 10 -228856 -1 -1 0 256;
#X obj 29 21 nbx 2 14 -1e+37 1e+37 0 0 empty \$0-axis axis -25 6 0
10 -204786 -1 -1 0 256;
#X obj 64 22 nbx 6 14 -1e+37 1e+37 0 0 empty \$0-axis-value empty 0
-6 0 10 -228856 -1 -1 0 256;
#X connect 0 0 12 0;
#X connect 12 0 8 0;
#X connect 12 0 11 0;
#X connect 12 1 9 0;
#X connect 12 1 10 0;
#X coords 0 -1 1 1 130 62 1 0 0;