#N canvas 948 458 411 305 10;
#X obj 14 14 receive fromSystem;
#X obj 14 60 route /location /compass;
#X obj 14 37 list trim;
#X obj 14 113 unpack f f f f f f f f f;
#X obj 63 192 pack f f f f, f 19;
#X obj 84 83 s \$0-compass;
#X obj 83 225 s latlon;
#X obj 45 258 print locations:;
#N canvas 1 91 604 394 notes 0;
#X text 18 15 when location data is enabled \, it is sent via a message
"/location" with 9 numbers. Location coordinate data in iOS is a 64-bit
floating point number (double);
#X text 18 65 PureData is only 32-bit float \, so sending that number
into a patch loses resolution. However \, a tweaky workaround (via
64-bit math in the iOS layer) is provided by the last 4 numbers in
the message.;
#X text 18 125 arg #1: latitude coordinate (as 32-bit float);
#X text 18 145 arg #2: longitude coordinate (as 32-bit float);
#X text 18 165 arg #3: altitude (meters);
#X text 18 185 arg #4: horizontal accuracy (meters radius);
#X text 18 205 arg #5: vertical (altitude) accuracy (meters radius)
;
#X text 18 235 arg #6: latitude "rough";
#X text 18 275 arg #8: latitude "fine";
#X text 18 255 arg #7: longitude "rough";
#X text 18 295 arg #9: longitude "fine";
#X text 208 235 latitude/longitude "rough" = 64-bit value multiplied
by 1000 and truncated to an integer before being sent into Pd;
#X text 208 285 latitude/longitude "fine" = 64-bit value modded by
0.001 \, multiplied by 1e+06 \, and truncated to an integer \, before
being sent into Pd So the "rough" contains the significant digits up
to the thousandths place \, and the "fine" contains the next three
significant digits. An original coordinate value of 123.457 would be
turned into rough=123456 fine=789.;
#X restore 223 113 pd notes;
#X text 202 188 arg #6: latitude "rough";
#X text 202 228 arg #8: latitude "fine";
#X text 202 208 arg #7: longitude "rough";
#X text 202 248 arg #9: longitude "fine";
#X text 170 113 <======;
#N canvas 1 91 1064 672 gui 0;
#X obj 16 239 send toGUI;
#X obj 526 72 list trim;
#X obj 526 49 receive fromGUI;
#X msg 526 118 list /enableLocation \$1;
#X obj 526 141 send toSystem;
#X obj 356 49 loadbang;
#X obj 356 95 send toGUI;
#N canvas 590 91 614 581 draw_arrow 0;
#X obj 89 257 rot2d;
#X msg 89 149 0.5 0.6;
#X obj 70 327 list store;
#X msg 106 172 0.4 0.7;
#X msg 140 218 0.6 0.7;
#X obj 89 280 list prepend append;
#X obj 89 303 list trim;
#X obj 70 103 t b b b;
#X obj 89 126 t b b b b;
#X obj 70 81 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
-1;
#X obj 70 19 inlet;
#X obj 70 42 t b a;
#X obj 209 219 t a;
#X obj 242 199 t a;
#X msg 123 195 0.5 0;
#X obj 70 350 list prepend /lcd.Pointer paintpoly;
#X obj 70 373 t b a b;
#X msg 70 419 list /lcd.Pointer paintoval 0.45 0.45 0.55 0.55 1 1 1
1;
#X obj 89 442 send toGUI;
#X msg 244 311 list /lcd.Pointer paintoval 0 0 1 1 0.6 1 0.6 1;
#X msg 244 288 list /lcd.Pointer paintoval 0 0 1 1 0 0.8 0.6 1;
#X msg 109 396 list /lcd.Pointer paintoval 0 0 1 1 0.6 1 0.6 1;
#X connect 0 0 5 0;
#X connect 1 0 0 0;
#X connect 2 0 15 0;
#X connect 3 0 0 0;
#X connect 4 0 0 0;
#X connect 5 0 6 0;
#X connect 6 0 2 0;
#X connect 7 0 2 0;
#X connect 7 1 8 0;
#X connect 7 2 12 0;
#X connect 8 0 1 0;
#X connect 8 1 3 0;
#X connect 8 2 14 0;
#X connect 8 3 4 0;
#X connect 9 0 7 0;
#X connect 10 0 11 0;
#X connect 11 0 9 0;
#X connect 11 1 13 0;
#X connect 12 0 2 1;
#X connect 13 0 0 2;
#X connect 14 0 0 0;
#X connect 15 0 16 0;
#X connect 16 0 17 0;
#X connect 16 1 18 0;
#X connect 16 2 21 0;
#X connect 17 0 18 0;
#X connect 21 0 18 0;
#X restore 406 597 pd draw_arrow;
#X floatatom 406 403 5 0 0 1 angle_(deg) - -;
#X obj 100 580 send toGUI;
#X floatatom 406 335 5 0 0 1 angle_(deg) - -;
#X obj 406 380 +;
#X obj 406 357 * -1;
#X obj 406 312 r \$0-compass;
#X obj 586 417 r \$0-brng;
#X obj 100 534 r \$0-dist;
#X obj 154 372 loadbang;
#X obj 154 395 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
-1 -1;
#N canvas 592 91 458 517 draw_arrow 0;
#X obj 89 257 rot2d;
#X msg 89 149 0.5 0.6;
#X obj 70 327 list store;
#X msg 106 172 0.4 0.7;
#X msg 140 218 0.6 0.7;
#X obj 89 280 list prepend append;
#X obj 89 303 list trim;
#X obj 70 103 t b b b;
#X obj 89 126 t b b b b;
#X obj 70 81 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
-1;
#X obj 70 19 inlet;
#X obj 70 42 t b a;
#X obj 209 219 t a;
#X obj 242 199 t a;
#X obj 87 465 send toGUI;
#X obj 70 350 list prepend /lcd.Compass paintpoly;
#X msg 70 442 list /lcd.Compass paintoval 0.45 0.45 0.55 0.55 1 1 1
1;
#X obj 70 373 t b a b b;
#X msg 123 195 0.5 0.1;
#X msg 104 418 list /lcd.Compass frameoval 0.1 0.1 0.9 0.9 0 1 1 1
;
#X msg 121 395 list /lcd.Compass paintoval 0 0 1 1 1 1 0 1;
#X connect 0 0 5 0;
#X connect 1 0 0 0;
#X connect 2 0 15 0;
#X connect 3 0 0 0;
#X connect 4 0 0 0;
#X connect 5 0 6 0;
#X connect 6 0 2 0;
#X connect 7 0 2 0;
#X connect 7 1 8 0;
#X connect 7 2 12 0;
#X connect 8 0 1 0;
#X connect 8 1 3 0;
#X connect 8 2 18 0;
#X connect 8 3 4 0;
#X connect 9 0 7 0;
#X connect 10 0 11 0;
#X connect 11 0 9 0;
#X connect 11 1 13 0;
#X connect 12 0 2 1;
#X connect 13 0 0 2;
#X connect 15 0 17 0;
#X connect 16 0 14 0;
#X connect 17 0 16 0;
#X connect 17 1 14 0;
#X connect 17 3 20 0;
#X connect 18 0 0 0;
#X connect 19 0 14 0;
#X connect 20 0 14 0;
#X restore 16 425 pd draw_arrow;
#X floatatom 16 335 5 0 0 1 angle_(deg) - -;
#X obj 16 312 r \$0-compass;
#X text 11 16 disp. lat/long in text;
#X text 354 18 toggle gps reception + automatically enable at start-up
;
#X obj 16 46 r latlon;
#X floatatom 16 403 5 0 0 1 angle_(deg) - -;
#X obj 16 357 * -1;
#X obj 16 380 + 360;
#X text 97 499 disp. distance (km) in text;
#X obj 850 281 s toGUI;
#X obj 807 284 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
1;
#X obj 757 238 f;
#X obj 807 238 + 1;
#X obj 807 261 % 2;
#X obj 757 134 t a b;
#X msg 784 202 0;
#X obj 757 202 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
-1 -1;
#X obj 850 200 del 1000;
#X msg 850 223 0;
#X obj 757 62 r latlon;
#X obj 757 85 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
-1;
#X text 756 24 location info arrival indicator;
#X obj 757 163 scan 400;
#X msg 757 111 10;
#X obj 526 95 route /tgl.Location.En;
#X msg 356 72 list /tgl.Location.En 1;
#X msg 850 252 list /tgl.Location.Act set \$1;
#X msg 16 98 list /disp.Loc.Current.Lat.Coarse \$1;
#X msg 43 121 list /disp.Loc.Current.Lon.Coarse \$1;
#X msg 70 167 list /disp.Loc.Current.Lat.Fine \$1;
#X msg 97 213 list /disp.Loc.Current.Lon.Fine \$1;
#X obj 16 69 unpack f f f f;
#X obj 100 557 list prepend /disp.Distance;
#X text 14 281 draw north pointing compass;
#X obj 304 367 loadbang;
#X obj 304 390 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
-1 -1;
#X text 404 282 draw dest. pointing arrow = bearing arrow;
#X obj 586 332 expr fmod(($f1+360) \, 360);
#X obj 586 355 expr fmod(($f1+180) \, 360)-180;
#X obj 586 378 s \$0-brng-error;
#N canvas 24 163 465 242 tester 0;
#X obj 17 67 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 1
;
#X obj 17 87 metro 100;
#X obj 87 110 vline~;
#X obj 87 133 snapshot~;
#X floatatom 87 156 5 0 0 0 - - -;
#X msg 87 74 0 0 \, 50 2000 \, 0 2000 2000 \, 360 0 4000 \, 310 2000
4000 \, 360 2000 6000;
#X obj 87 19 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 1
;
#X obj 87 45 metro 8000;
#X obj 87 178 outlet;
#X connect 0 0 1 0;
#X connect 1 0 3 0;
#X connect 2 0 3 0;
#X connect 3 0 4 0;
#X connect 4 0 8 0;
#X connect 5 0 2 0;
#X connect 6 0 7 0;
#X connect 6 0 0 0;
#X connect 7 0 5 0;
#X restore 331 312 pd tester;
#X obj 489 487 tgl 15 0 empty \$0-veryclose r:0-veryclose 17 7 0 10
-262144 -1 -1 0 1;
#N canvas 719 91 614 663 draw_veryclose 0;
#X obj 89 257 rot2d;
#X msg 89 149 0.5 0.6;
#X obj 70 327 list store;
#X msg 106 172 0.4 0.7;
#X msg 140 218 0.6 0.7;
#X obj 89 280 list prepend append;
#X obj 89 303 list trim;
#X obj 70 103 t b b b;
#X obj 89 126 t b b b b;
#X obj 70 81 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
-1;
#X obj 70 19 inlet;
#X obj 70 42 t b a;
#X obj 209 219 t a;
#X obj 242 199 t a;
#X obj 70 350 list prepend /lcd.Pointer paintpoly;
#X obj 161 577 send toGUI;
#X msg 123 195 0.5 0.3;
#X msg 113 465 list /lcd.Pointer frameoval 0.12 0.12 0.88 0.88 1 1
0 0.7;
#X msg 142 419 list /lcd.Pointer frameoval 0 0 1 1 1 1 0 1;
#X obj 70 373 t b a b b b b b;
#X msg 70 511 list /lcd.Pointer paintoval 0.45 0.45 0.55 0.55 0 1 0
1;
#X msg 99 488 list /lcd.Pointer frameoval 0.25 0.25 0.75 0.75 1 1 0
0.5;
#X msg 128 442 list /lcd.Pointer frameoval 0.05 0.05 0.95 0.95 1 1
0 0.9;
#X msg 222 325 list /lcd.Pointer paintoval 0 0 1 1 1 0.4 0.6 1;
#X msg 157 396 list /lcd.Pointer paintoval 0 0 1 1 0 0.4 0.4 1;
#X connect 0 0 5 0;
#X connect 1 0 0 0;
#X connect 2 0 14 0;
#X connect 3 0 0 0;
#X connect 4 0 0 0;
#X connect 5 0 6 0;
#X connect 6 0 2 0;
#X connect 7 0 2 0;
#X connect 7 1 8 0;
#X connect 7 2 12 0;
#X connect 8 0 1 0;
#X connect 8 1 3 0;
#X connect 8 2 16 0;
#X connect 8 3 4 0;
#X connect 9 0 7 0;
#X connect 10 0 11 0;
#X connect 11 0 9 0;
#X connect 11 1 13 0;
#X connect 12 0 2 1;
#X connect 13 0 0 2;
#X connect 14 0 19 0;
#X connect 16 0 0 0;
#X connect 17 0 15 0;
#X connect 18 0 15 0;
#X connect 19 0 20 0;
#X connect 19 1 15 0;
#X connect 19 2 21 0;
#X connect 19 3 17 0;
#X connect 19 5 18 0;
#X connect 19 6 24 0;
#X connect 20 0 15 0;
#X connect 21 0 15 0;
#X connect 24 0 15 0;
#X restore 491 597 pd draw_veryclose;
#X obj 491 574 spigot;
#X obj 445 531 == 0;
#X obj 406 574 spigot;
#X obj 445 508 f;
#X obj 406 485 t a a b;
#X obj 524 534 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
1;
#X obj 445 554 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 1
1;
#X obj 489 440 loadbang;
#X msg 489 463 0;
#X obj 70 144 makefilename %03d;
#X obj 97 190 makefilename %03d;
#X obj 876 589 send toGUI;
#X msg 876 566 list /tgl.Location.En \$1;
#X obj 913 514 del 500;
#X obj 876 471 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
-1 -1;
#X obj 876 491 t b b;
#X msg 876 514 0;
#X msg 913 537 1;
#X obj 935 171 del;
#X text 681 423 if there is no GPS update for a long time \, let's
try to get one intentionally by performing a enable/disable cycle.
;
#X msg 935 148 20000;
#X text 947 123 20 seconds;
#X connect 1 0 43 0;
#X connect 2 0 1 0;
#X connect 3 0 4 0;
#X connect 5 0 44 0;
#X connect 8 0 56 0;
#X connect 8 0 66 0;
#X connect 10 0 12 0;
#X connect 11 0 8 0;
#X connect 12 0 11 0;
#X connect 13 0 10 0;
#X connect 14 0 11 1;
#X connect 15 0 51 0;
#X connect 16 0 17 0;
#X connect 17 0 19 0;
#X connect 19 0 25 0;
#X connect 20 0 19 0;
#X connect 23 0 50 0;
#X connect 24 0 18 0;
#X connect 25 0 26 0;
#X connect 26 0 24 0;
#X connect 29 0 45 0;
#X connect 30 0 31 0;
#X connect 31 0 32 0;
#X connect 32 0 30 1;
#X connect 32 0 29 0;
#X connect 33 0 41 0;
#X connect 33 1 34 0;
#X connect 34 0 30 1;
#X connect 35 0 30 0;
#X connect 36 0 37 0;
#X connect 37 0 45 0;
#X connect 38 0 39 0;
#X connect 39 0 42 0;
#X connect 39 0 82 0;
#X connect 41 0 35 0;
#X connect 41 1 36 0;
#X connect 42 0 33 0;
#X connect 43 0 3 0;
#X connect 44 0 6 0;
#X connect 45 0 28 0;
#X connect 46 0 0 0;
#X connect 47 0 0 0;
#X connect 48 0 0 0;
#X connect 49 0 0 0;
#X connect 50 0 46 0;
#X connect 50 1 47 0;
#X connect 50 2 71 0;
#X connect 50 3 72 0;
#X connect 51 0 9 0;
#X connect 53 0 54 0;
#X connect 54 0 8 0;
#X connect 56 0 57 0;
#X connect 57 0 58 0;
#X connect 59 0 8 0;
#X connect 60 0 65 1;
#X connect 62 0 61 0;
#X connect 63 0 68 0;
#X connect 64 0 7 0;
#X connect 65 0 67 0;
#X connect 65 0 63 0;
#X connect 66 0 64 0;
#X connect 66 1 62 0;
#X connect 66 2 65 0;
#X connect 67 0 62 1;
#X connect 68 0 64 1;
#X connect 69 0 70 0;
#X connect 70 0 65 1;
#X connect 71 0 48 0;
#X connect 72 0 49 0;
#X connect 74 0 73 0;
#X connect 75 0 79 0;
#X connect 76 0 77 0;
#X connect 77 0 78 0;
#X connect 77 1 75 0;
#X connect 78 0 74 0;
#X connect 79 0 74 0;
#X connect 80 0 76 0;
#X connect 82 0 80 0;
#X restore 287 25 pd gui guts;
#X obj 63 142 / 1000;
#X obj 100 165 / 1000;
#N canvas 541 159 818 604 location 0;
#X obj 183 351 geocoord_dist;
#X obj 273 351 geocoord_bearing;
#X obj 183 291 pack f f f f;
#N canvas 1 91 631 615 get_point 0;
#X obj 297 17 r fromGUI;
#X obj 297 86 sel 1;
#X obj 297 173 send toSystem;
#X obj 17 40 list trim;
#X obj 17 17 r fromSystem;
#X obj 17 63 route /textDialog;
#X obj 388 86 sel 1;
#X obj 297 40 list trim;
#X obj 17 236 tofloat;
#X obj 205 236 tofloat;
#X obj 297 63 route /btn.Set.Lat /btn.Set.Lon;
#X msg 297 110 list /textDialog /diagInputLat Set Latitude:;
#X msg 317 143 list /textDialog /diagInputLong Set Longitude:;
#X obj 17 576 send toGUI;
#X obj 17 86 route /diagInputLong /diagInputLat;
#X msg 17 494 list /disp.Loc.Pointing.Lon.Coarse \$1;
#X msg 44 547 list /disp.Loc.Pointing.Lon.Fine \$1;
#X obj 159 447 outlet;
#X obj 159 424 pack f f f f;
#X obj 343 400 send toGUI;
#X msg 370 371 list /disp.Loc.Pointing.Lat.Fine \$1;
#X msg 343 325 list /disp.Loc.Pointing.Lat.Coarse \$1;
#X text 156 469 (Lat.fine \, Lon.fine \, Lat.rough \, Lon.rough);
#X obj 159 401 f;
#X obj 159 372 t b a;
#X obj 205 272 expr $f1+int($f2*1000)/1000 \; rint(abs($f2*1000000))%1000
;
#X obj 17 272 expr $f1+int($f2*1000)/1000 \; rint(abs($f2*1000000))%1000
;
#X obj 44 524 makefilename %03d;
#X obj 370 348 makefilename %03d;
#X obj 101 152 unpack f f f f;
#X obj 201 49 r PRESET;
#X obj 111 208 f;
#X obj 101 175 t b a;
#X connect 0 0 7 0;
#X connect 1 0 11 0;
#X connect 3 0 5 0;
#X connect 4 0 3 0;
#X connect 5 0 14 0;
#X connect 6 0 12 0;
#X connect 7 0 10 0;
#X connect 8 0 26 0;
#X connect 8 1 26 1;
#X connect 9 0 25 0;
#X connect 9 1 25 1;
#X connect 10 0 1 0;
#X connect 10 1 6 0;
#X connect 11 0 2 0;
#X connect 12 0 2 0;
#X connect 14 0 8 0;
#X connect 14 1 9 0;
#X connect 15 0 13 0;
#X connect 16 0 13 0;
#X connect 18 0 17 0;
#X connect 20 0 19 0;
#X connect 21 0 19 0;
#X connect 23 0 18 0;
#X connect 24 0 23 0;
#X connect 24 1 18 3;
#X connect 25 0 18 2;
#X connect 25 0 21 0;
#X connect 25 1 23 1;
#X connect 25 1 28 0;
#X connect 26 0 15 0;
#X connect 26 0 24 0;
#X connect 26 1 18 1;
#X connect 26 1 27 0;
#X connect 27 0 16 0;
#X connect 28 0 20 0;
#X connect 29 0 32 0;
#X connect 29 1 25 1;
#X connect 29 2 31 1;
#X connect 29 3 26 1;
#X connect 30 0 29 0;
#X connect 31 0 26 0;
#X connect 32 0 31 0;
#X connect 32 1 25 0;
#X restore 494 19 pd get_point;
#X obj 183 42 unpack f f f f;
#X obj 183 19 r latlon;
#X obj 421 351 geocoord_dist;
#X obj 511 351 geocoord_bearing;
#X obj 421 314 t a a;
#X obj 421 291 pack f f f f;
#X obj 183 111 pack f f f f;
#X obj 183 88 f;
#X obj 183 65 t b a;
#X obj 413 134 unpack f f f f;
#X obj 183 134 unpack f f f f;
#X obj 440 183 expr copysign($f1 \, $f2)/1e+06;
#X obj 413 206 expr copysign($f1 \, $f2)/1e+06;
#X obj 210 183 expr copysign($f1 \, $f2)/1e+06;
#X obj 183 206 expr copysign($f1 \, $f2)/1e+06;
#X text 574 273 coarse;
#X text 307 280 fine;
#X obj 183 374 v distF\$0;
#X obj 273 374 v brngF\$0;
#X obj 511 374 v brngC\$0;
#X obj 421 374 v distC\$0;
#X obj 183 314 t b a a;
#X obj 55 372 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
-1;
#X obj 236 428 v x\$0;
#X obj 236 448 v y\$0;
#X obj 181 568 s \$0-dist;
#X obj 266 568 s \$0-brng;
#X text 325 72 (Lat.fine \, Lon.fine \, Lat.rough \, Lon.rough);
#X msg 18 64 36.123 127.789 456 12;
#X msg 18 113 456 12 36.123 127.789;
#X text 43 89 re-order to be;
#X obj 55 415 sel 1;
#X obj 55 392 v haveSetPoint;
#X obj 554 134 v haveSetPoint;
#X msg 554 111 1;
#X obj 653 224 send toGUI;
#X msg 653 201 list /tgl.Location.En \$1;
#X obj 690 149 del 500;
#X obj 653 106 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
-1 -1;
#X obj 653 126 t b b;
#X msg 653 149 0;
#X msg 690 172 1;
#X obj 494 42 t b b a;
#X obj 518 319 print input(C);
#X obj 278 319 print input(F);
#X obj 55 497 print dist(km);
#X obj 55 474 print brng(deg);
#X obj 181 474 expr sqrt(x\$0*x\$0+y\$0*y\$0) \; fmod(atan2(x\$0 \,
y\$0)*360/6.28319+360 \, 360) \; x\$0=distC\$0*sin(brngC\$0*6.28319/360)+
distF\$0*sin(brngF\$0*6.28319/360) \; y\$0=distC\$0*cos(brngC\$0*6.28319/360)+
distF\$0*cos(brngF\$0*6.28319/360);
#X obj 628 520 tgl 15 0 \$0-veryclose empty s:0-veryclose 17 7 0 10
-262144 -1 -1 0 1;
#X obj 628 497 < 0.03;
#X obj 628 474 r \$0-dist;
#X connect 0 0 21 0;
#X connect 1 0 22 0;
#X connect 2 0 25 0;
#X connect 2 0 48 0;
#X connect 3 0 46 0;
#X connect 4 0 12 0;
#X connect 4 1 10 3;
#X connect 4 2 11 1;
#X connect 4 3 10 1;
#X connect 5 0 4 0;
#X connect 6 0 24 0;
#X connect 7 0 23 0;
#X connect 8 0 6 0;
#X connect 8 1 7 0;
#X connect 9 0 8 0;
#X connect 9 0 47 0;
#X connect 10 0 14 0;
#X connect 11 0 10 0;
#X connect 12 0 11 0;
#X connect 12 1 10 2;
#X connect 13 0 16 0;
#X connect 13 1 15 0;
#X connect 13 2 9 2;
#X connect 13 2 16 1;
#X connect 13 3 9 3;
#X connect 13 3 15 1;
#X connect 14 0 18 0;
#X connect 14 1 17 0;
#X connect 14 2 9 0;
#X connect 14 2 18 1;
#X connect 14 3 9 1;
#X connect 14 3 17 1;
#X connect 15 0 2 3;
#X connect 16 0 2 2;
#X connect 17 0 2 1;
#X connect 18 0 2 0;
#X connect 25 0 26 0;
#X connect 25 1 0 0;
#X connect 25 2 1 0;
#X connect 26 0 36 0;
#X connect 32 0 4 0;
#X connect 33 0 13 0;
#X connect 35 0 51 0;
#X connect 36 0 35 0;
#X connect 38 0 37 0;
#X connect 40 0 39 0;
#X connect 41 0 45 0;
#X connect 42 0 43 0;
#X connect 43 0 44 0;
#X connect 43 1 41 0;
#X connect 44 0 40 0;
#X connect 45 0 40 0;
#X connect 46 0 42 0;
#X connect 46 1 38 0;
#X connect 46 2 13 0;
#X connect 51 0 29 0;
#X connect 51 0 49 0;
#X connect 51 1 30 0;
#X connect 51 1 50 0;
#X connect 53 0 52 0;
#X connect 54 0 53 0;
#X restore 287 48 pd location guts;
#N canvas 142 162 800 337 audio 0;
#X obj 18 146 wav2~;
#X msg 18 68 01.wav;
#X msg 31 117 1;
#X msg 667 227 \; pd dsp 1;
#X obj 31 16 loadbang;
#X obj 153 39 r \$0-dist;
#X obj 153 62 map 0.005 0.05 1 0.1;
#X obj 18 303 dac~;
#X floatatom 318 43 5 0 0 1 - - -;
#X floatatom 153 85 5 0 0 1 vol - -;
#X obj 153 146 line~;
#X msg 153 123 \$1 20;
#X obj 31 39 t b b;
#X obj 667 204 loadbang;
#X obj 18 169 expr~ $v1 * pow($v2 \, 4);
#X obj 318 20 r \$0-brng-error;
#X obj 318 248 line~;
#X obj 18 265 eqpan2~ 30;
#X obj 363 81 t a a;
#X obj 363 110 -;
#X obj 363 156 > 100;
#X obj 318 65 t a a;
#X obj 363 179 sel 1 0;
#X obj 318 225 pack f f;
#X msg 393 202 100;
#X msg 363 202 0;
#X obj 363 133 abs;
#X text 419 150 if abs of diff. greater than 100 \, disable fading.
(otherwise one will hear glitches.);
#X text 411 47 for a very big jumps \, like 180 <-> -180 .. this is
not regular change \, we should disable [line~] for such events.;
#X connect 0 0 14 0;
#X connect 1 0 0 0;
#X connect 2 0 0 1;
#X connect 4 0 12 0;
#X connect 5 0 6 0;
#X connect 6 0 9 0;
#X connect 8 0 21 0;
#X connect 9 0 11 0;
#X connect 10 0 14 1;
#X connect 11 0 10 0;
#X connect 12 0 2 0;
#X connect 12 1 1 0;
#X connect 13 0 3 0;
#X connect 14 0 17 0;
#X connect 15 0 8 0;
#X connect 16 0 17 1;
#X connect 17 0 7 0;
#X connect 17 1 7 1;
#X connect 18 0 19 1;
#X connect 18 1 19 0;
#X connect 19 0 26 0;
#X connect 20 0 22 0;
#X connect 21 0 23 0;
#X connect 21 1 18 0;
#X connect 22 0 25 0;
#X connect 22 1 24 0;
#X connect 23 0 16 0;
#X connect 24 0 23 1;
#X connect 25 0 23 1;
#X connect 26 0 20 0;
#X restore 287 71 pd audio guts;
#N canvas 1 420 450 324 PRESET 0;
#X obj 147 287 s PRESET;
#X obj 147 264 pack f f f f;
#X text 14 8 (Lat.integral \, Lat.fractional \, Lon.integral \, Lon.fractional)
;
#X obj 18 43 loadbang;
#X obj 18 162 t b b b b, f 46;
#X obj 18 112 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
-1;
#X obj 18 89 del;
#X msg 18 66 500;
#X msg 109 211 0.574749;
#X msg 291 211 0.92608;
#X msg 18 185 37;
#X msg 200 185 126;
#X connect 1 0 0 0;
#X connect 3 0 7 0;
#X connect 4 0 10 0;
#X connect 4 1 8 0;
#X connect 4 2 11 0;
#X connect 4 3 9 0;
#X connect 6 0 5 0;
#X connect 7 0 6 0;
#X connect 8 0 1 1;
#X connect 9 0 1 3;
#X connect 10 0 1 0;
#X connect 11 0 1 2;
#X restore 190 24 pd PRESET;
#X connect 0 0 2 0;
#X connect 1 0 3 0;
#X connect 1 1 5 0;
#X connect 2 0 1 0;
#X connect 3 5 15 0;
#X connect 3 6 16 0;
#X connect 3 7 4 2;
#X connect 3 8 4 3;
#X connect 4 0 6 0;
#X connect 4 0 7 0;
#X connect 15 0 4 0;
#X connect 16 0 4 1;
