Jelajahi Sumber

bugfixes and GUI improvements

just found a bug regarding sequences that use stepper index, so are not
exchangeable. Will fix that in next commit
Etienne Landon 7 tahun lalu
induk
melakukan
d8dffbc6a5
4 mengubah file dengan 296 tambahan dan 206 penghapusan
  1. 80 77
      OSCstepperCtl.pd
  2. 198 110
      kostepper.pd
  3. 9 10
      stepperCue.pd
  4. 9 9
      steps2camrot.pd

+ 80 - 77
OSCstepperCtl.pd

@@ -1,25 +1,19 @@
 #N canvas 537 200 1131 703 10;
-#N canvas 157 186 817 472 SerialOSC 0;
+#N canvas 112 146 817 472 SerialOSC 0;
 #X obj 99 6 inlet;
 #X obj 99 362 outlet;
 #X obj 99 200 comport;
-#X msg 590 173 devices;
+#X msg 124 159 devices;
 #X obj 112 329 s /fromOSC;
 #X obj 130 32 r /toOSC;
 #X obj 429 50 route 0 1;
 #X msg 429 132 close;
-#X obj 59 391 mrpeach/unpackOSC;
 #X obj 99 231 mrpeach/slipdec 65536;
 #X obj 99 291 mrpeach/unpackOSC;
 #X obj 99 57 mrpeach/packOSC;
 #X obj 99 122 mrpeach/slipenc 65536;
-#X msg 404 214 devicename /dev/ttyACM0 \, baud 115200 \, pollintervall
-1 \, verbose 1;
 #X obj 48 240 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
 1;
-#X obj 257 375 print;
-#X obj 238 290 route 13 10;
-#X obj 253 321 list fromsymbol;
 #X obj 429 31 r serialConnect;
 #X obj 540 28 r serialDevice;
 #X obj 462 80 symbol;
@@ -29,12 +23,10 @@
 #X obj 13 75 loadbang;
 #X obj 13 116 metro 200;
 #X msg 13 137 info;
-#X obj 329 264 route open;
-#X obj 382 292 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 1
-1;
+#X obj 291 213 route open;
 #X obj 13 96 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 1 1
 ;
-#X obj 426 312 s serialIsOpen;
+#X obj 290 243 s serialIsOpen;
 #N canvas 1 55 450 300 \$0-colors 0;
 #X obj 129 33 r serialIsOpen;
 #X obj 129 54 route 0 1;
@@ -55,7 +47,7 @@
 verbose 1 \, retries 0;
 #X obj 362 51 cnv 20 22 60 empty serialSend S 4 12 0 20 -233017 -233017
 0;
-#X obj 362 81 cnv 20 22 30 empty serialReceive R 4 12 0 20 -233017
+#X obj 362 70 cnv 20 22 30 empty serialReceive R 4 12 0 20 -233017
 -233017 0;
 #X obj 99 78 t a b;
 #N canvas 1 55 450 300 serialSendGUI 0;
@@ -91,48 +83,52 @@ verbose 1 \, retries 0;
 #X connect 4 0 6 0;
 #X connect 5 0 6 0;
 #X restore 142 268 pd serialReceiveGUI;
-#X connect 0 0 11 0;
-#X connect 0 0 15 0;
-#X connect 2 0 9 0;
-#X connect 2 1 26 0;
+#X obj 664 429 print OSCin;
+#X obj 662 295 r /fromOSC;
+#X obj 662 317 t a a;
+#X obj 662 408 spigot;
+#X msg 694 343 \$1;
+#X obj 694 365 == 3;
+#X obj 365 94 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
+-1;
+#X connect 0 0 10 0;
+#X connect 2 0 8 0;
+#X connect 2 1 21 0;
 #X connect 3 0 2 0;
-#X connect 5 0 11 0;
+#X connect 5 0 10 0;
 #X connect 6 0 7 0;
-#X connect 6 1 20 0;
+#X connect 6 1 15 0;
 #X connect 7 0 2 0;
-#X connect 9 0 36 0;
-#X connect 10 0 1 0;
-#X connect 10 0 4 0;
-#X connect 11 0 34 0;
-#X connect 12 0 2 0;
-#X connect 13 0 2 0;
-#X connect 17 0 15 0;
-#X connect 18 0 6 0;
-#X connect 19 0 21 0;
-#X connect 20 0 31 0;
-#X connect 21 0 20 1;
-#X connect 23 0 28 0;
-#X connect 24 0 25 0;
+#X connect 8 0 30 0;
+#X connect 9 0 1 0;
+#X connect 9 0 4 0;
+#X connect 10 0 28 0;
+#X connect 11 0 2 0;
+#X connect 13 0 6 0;
+#X connect 14 0 16 0;
+#X connect 15 0 25 0;
+#X connect 16 0 15 1;
+#X connect 18 0 22 0;
+#X connect 19 0 20 0;
+#X connect 20 0 2 0;
+#X connect 21 0 23 0;
+#X connect 22 0 19 0;
+#X connect 24 0 17 0;
 #X connect 25 0 2 0;
-#X connect 26 0 27 0;
-#X connect 26 0 29 0;
-#X connect 28 0 24 0;
-#X connect 30 0 22 0;
-#X connect 31 0 2 0;
-#X connect 34 0 12 0;
-#X connect 34 1 35 0;
-#X connect 36 0 10 0;
-#X connect 36 1 37 0;
+#X connect 28 0 11 0;
+#X connect 28 1 29 0;
+#X connect 30 0 9 0;
+#X connect 30 1 31 0;
+#X connect 33 0 34 0;
+#X connect 34 0 35 0;
+#X connect 34 1 36 0;
+#X connect 35 0 32 0;
+#X connect 36 0 37 0;
+#X connect 37 0 35 1;
+#X connect 38 0 3 0;
 #X coords 0 -1 1 1 85 61 1 300 50;
-#X restore 723 46 pd SerialOSC;
-#X obj 756 540 print OSCin;
-#X obj 754 406 r /fromOSC;
-#X obj 754 428 t a a;
-#X obj 754 519 spigot;
-#X msg 786 454 \$1;
-#X obj 786 476 == 3;
-#X msg 725 21 /home;
-#N canvas 212 557 792 428 syncControl 0;
+#X restore 721 130 pd SerialOSC;
+#N canvas 194 541 792 428 syncControl 0;
 #X floatatom 42 268 5 0 0 0 - - -, f 5;
 #X floatatom 218 275 5 0 0 0 - - -, f 5;
 #X obj 23 49 unauthorized/grid grid1 200 -2 2 200 -2 2 1 0.01 0.01
@@ -155,26 +151,36 @@ verbose 1 \, retries 0;
 1;
 #X msg 23 -29 \; /stepper/0/manualDrive \$1 \; /stepper/1/manualDrive
 \$1;
-#X obj 236 26 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
+#X obj 447 34 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
 -1;
-#X msg 236 46 \; /stepper/0/move/go bang \; /stepper/1/move/go bang
+#X msg 436 74 \; /stepper/0/move/go bang \; /stepper/1/move/go bang
 ;
-#X text 256 26 moveInSync;
-#X obj 361 14 bng 40 250 50 0 empty empty empty 17 7 0 10 -258113 -1
--1;
-#X text 369 27 STOP;
-#X msg 422 14 \; /stepper/0/stop bang \; /stepper/1/stop bang;
-#X text 241 116 SEQUENCE;
-#X obj 252 158 bng 40 250 50 0 empty empty empty 17 7 0 10 -4034 -1
--1;
+#X text 467 34 moveInSync;
+#X obj 253 211 bng 40 250 50 0 empty empty empty 17 7 0 10 -258113
+-1 -1;
+#X msg 420 210 \; /stepper/0/stop bang \; /stepper/1/stop bang;
+#X obj 253 167 bng 40 250 50 0 empty empty empty 17 7 0 10 -204786
+-1 -1;
 #X msg 410 173 \; /stepper/0/sequencer/go bang \; /stepper/1/sequencer/go
 bang;
-#X text 258 171 PLAY;
-#X obj 255 138 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
--1 -1;
-#X text 274 136 goto_startPos;
+#X obj 253 79 bng 40 250 50 0 empty empty empty 17 7 0 10 -262144 -1
+-1;
+#X text 298 91 goto_startPos;
 #X msg 420 123 \; /stepper/0/move/gotoStart bang \; /stepper/1/move/gotoStart
 bang;
+#X obj 253 35 bng 40 250 50 0 empty empty empty 17 7 0 10 -203904 -1
+-1;
+#X text 258 47 HOME;
+#X obj 650 60 f;
+#X obj 665 37 r speedLimit;
+#X msg 650 81 \; /toOSC /home \$1;
+#X text 299 40 reset absolute;
+#X text 300 54 position;
+#X obj 253 123 bng 40 250 50 0 empty empty empty 17 7 0 10 -4034 -1
+-1;
+#X text 300 179 PLAY SEQUENCES;
+#X text 298 135 PLAY MOVE;
+#X text 299 224 STOP ALL;
 #X connect 2 0 0 0;
 #X connect 2 0 3 0;
 #X connect 2 1 1 0;
@@ -191,16 +197,19 @@ bang;
 #X connect 12 0 13 0;
 #X connect 15 0 16 0;
 #X connect 17 0 18 0;
-#X connect 20 0 22 0;
-#X connect 24 0 25 0;
+#X connect 20 0 21 0;
+#X connect 22 0 23 0;
+#X connect 24 0 26 0;
 #X connect 27 0 29 0;
+#X connect 29 0 31 0;
+#X connect 30 0 29 1;
 #X coords 0 -1 1 1 400 250 1 10 10;
-#X restore 721 117 pd syncControl;
+#X restore 721 217 pd syncControl;
 #N canvas 417 245 901 633 settings 0;
 #X obj 100 100 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
 -1 -1;
 #X obj 100 178 text define -k settings;
-#A set accLimit 3 \; speedLimit 10 \; microstepping 4 \; serialDevice
+#A set accLimit 10 \; speedLimit 10 \; microstepping 16 \; serialDevice
 /dev/ttyACM0 \;;
 #X msg 100 150 click;
 #X obj 417 249 r accLimit;
@@ -250,13 +259,7 @@ bang;
 #X connect 19 0 18 0;
 #X connect 21 0 1 0;
 #X coords 0 -1 1 1 85 30 1 100 100;
-#X restore 812 47 pd settings;
-#X obj 12 362 kostepper 1;
+#X restore 721 96 pd settings;
 #X obj 12 13 kostepper 0;
-#X connect 2 0 3 0;
-#X connect 3 0 4 0;
-#X connect 3 1 5 0;
-#X connect 4 0 1 0;
-#X connect 5 0 6 0;
-#X connect 6 0 4 1;
-#X connect 7 0 0 0;
+#X text 808 174 list;
+#X obj 12 362 kostepper 1;

+ 198 - 110
kostepper.pd

@@ -1,4 +1,4 @@
-#N canvas 224 55 871 626 10;
+#N canvas 197 55 871 626 10;
 #X obj 85 172 cnv 15 130 200 empty empty Status 2 8 0 14 -233017 -128992
 0;
 #X obj 85 377 cnv 15 130 100 empty empty MANUEL 2 8 0 14 -233017 -128992
@@ -54,7 +54,7 @@
 #X restore 65 96 pd conversion;
 #X obj 65 74 route /status /onTarget;
 #X obj 177 382 vsl 12 60 0 2 0 0 /stepper/\$1/manualSpeed /stepper/\$1/manualSpeed
-speed -10 70 0 10 -262144 -1 -1 0 1;
+speed -10 70 0 10 -262144 -1 -1 5900 1;
 #X obj 105 444 hradio 15 1 0 2 /stepper/\$1/manualDirection /stepper/\$1/manualDirection
 direction -10 22 0 10 -262144 -1 -1 0;
 #X obj 329 295 bng 25 250 50 0 /stepper/\$1/move/go /stepper/\$1/move/go
@@ -96,17 +96,17 @@ empty 17 7 0 10 -204800 -33289 -1 0 1;
 #X obj 345 350 tgl 15 0 /stepper/\$1/accMode empty 0/1 17 7 0 10 -262144
 -1 -1 0 1;
 #X obj 233 292 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/move /stepper/\$1/move
-tours 48 8 0 10 -262144 -1 -1 0.0555556 256;
+tours 48 8 0 10 -262144 -1 -1 0 256;
 #X obj 165 459 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/manualSpeed /stepper/\$1/manualSpeed
-empty 0 -8 0 10 -262144 -1 -1 0 256;
+empty 0 -8 0 10 -262144 -1 -1 2 256;
 #X obj 253 371 vsl 25 60 0 2 0 0 /stepper/\$1/setMaxSpeed /stepper/\$1/setMaxSpeed
-speed -4 70 0 10 -262144 -1 -1 600 1;
+speed -4 70 0 10 -262144 -1 -1 2950 1;
 #X obj 243 449 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/setMaxSpeed /stepper/\$1/setMaxSpeed
-empty 0 -8 0 10 -262144 -1 -1 0.20339 256;
+empty 0 -8 0 10 -262144 -1 -1 1 256;
 #X obj 342 372 vsl 25 60 0 2 0 0 /stepper/\$1/acceleration /stepper/\$1/acceleration
-acc 4 70 0 10 -233017 -233017 -195568 400 1;
+acc 4 70 0 10 -233017 -233017 -195568 2950 1;
 #X obj 333 449 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/acceleration
-/stepper/\$1/acceleration empty 0 -8 0 10 -233017 -233017 -195568 0.135593
+/stepper/\$1/acceleration empty 0 -8 0 10 -233017 -233017 -195568 1
 256;
 #X obj 434 838 cnv 15 180 100 empty empty presets 2 8 0 14 -233017
 -128992 0;
@@ -126,12 +126,12 @@ goto 17 7 0 10 -204800 -1 -1;
 #X obj 296 229 bng 15 250 50 0 /stepper/\$1/move/setStart /stepper/\$1/move/setStart
 set 17 7 0 10 -262144 -1 -1;
 #X obj 148 241 nbx 3 14 -1e+37 1e+37 0 0 /stepper/\$1/pos/current/deg
-/stepper/\$1/pos/current/deg degrees -50 8 0 10 -262144 -1 -1 330.808
-256;
+/stepper/\$1/pos/current/deg degrees -50 8 0 10 -262144 -1 -1 0 256
+;
 #X obj 148 225 nbx 5 14 -1e+37 1e+37 0 0 /stepper/\$1/pos/current /stepper/\$1/pos/current
-turns -45 7 0 10 -262144 -1 -1 0.918911 256;
+turns -45 7 0 10 -262144 -1 -1 0 256;
 #X obj 233 308 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/move/deg /stepper/\$1/move/deg
-deg 48 8 0 10 -262144 -1 -1 20 256;
+deg 48 8 0 10 -262144 -1 -1 0 256;
 #X obj 153 97 s /stepper/\$1/pos/onTarget;
 #X obj 301 174 cnv 25 70 25 /stepper/\$1/runningGui /stepper/\$1/runningGui
 idle 17 12 0 14 -233017 -195568 0;
@@ -151,7 +151,7 @@ grey95 black 0 \, none \, test (autre copie).move \, test.move \, test (3e copie
 #X obj 798 255 nbx 5 14 -1e+37 1e+37 0 0 /stepper/\$1/cue/current /stepper/\$1/cue/current
 empty 0 -8 0 10 -262144 -1 -1 0 256;
 #X obj 481 229 bng 30 250 50 0 /stepper/\$1/sequencer/go /stepper/\$1/sequencer/go
-GO 9 16 0 10 -4034 -1 -1;
+GO 9 16 0 10 -204786 -1 -1;
 #X msg 494 538 1;
 #X obj 534 229 tgl 30 0 /stepper/\$1/sequencer/loop /stepper/\$1/sequencer/loop
 loop 32 15 0 13 -162280 -1 -1 0 1;
@@ -336,18 +336,18 @@ CUE 3 \; /stepper/0/cue/3/move 0.0277778 \; /stepper/0/cue/3/setMaxSpeed
 #X text 286 58 START POSITION MANAGEMENT;
 #X obj 140 455 list;
 #X obj 140 396 pack 0 0 4000 0;
-#X obj 351 333 steps2camrot;
 #X text 242 396 stepper ID \, move \, speed \, acc;
 #X msg 140 421 driveMode 0 \$1 \, acceleration \$4 \$1 \, maxSpeed
 \$3 \$1 \, move \$2 \$1 \, getStatus \$1 \$1;
 #X msg 416 461 driveMode 1 \$1 \, maxSpeed \$3 \$1 \, acceleration
 move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X obj 611 332 / 60;
-#X obj 542 350 steps2camrot;
 #X obj 648 356 / 60;
-#X obj 579 374 steps2camrot;
 #X obj 648 338 r /stepper/\$1/accLimit;
 #X obj 611 314 r /stepper/\$1/speedLimit;
+#X obj 351 333 steps2camrot;
+#X obj 542 350 steps2camrot;
+#X obj 579 374 steps2camrot;
 #X connect 0 0 1 0;
 #X connect 1 0 26 0;
 #X connect 3 0 6 0;
@@ -363,7 +363,7 @@ move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X connect 12 0 18 0;
 #X connect 16 0 15 0;
 #X connect 17 0 32 0;
-#X connect 18 0 33 1;
+#X connect 18 0 40 1;
 #X connect 20 0 8 0;
 #X connect 21 0 11 0;
 #X connect 22 0 21 0;
@@ -380,17 +380,17 @@ move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X connect 29 0 19 0;
 #X connect 29 0 3 1;
 #X connect 31 0 16 0;
-#X connect 32 0 35 0;
-#X connect 33 0 32 1;
-#X connect 35 0 31 0;
-#X connect 37 0 38 1;
-#X connect 38 0 32 2;
-#X connect 39 0 40 1;
-#X connect 40 0 32 3;
-#X connect 41 0 39 0;
-#X connect 42 0 37 0;
+#X connect 32 0 34 0;
+#X connect 34 0 31 0;
+#X connect 36 0 41 1;
+#X connect 37 0 42 1;
+#X connect 38 0 37 0;
+#X connect 39 0 36 0;
+#X connect 40 0 32 1;
+#X connect 41 0 32 2;
+#X connect 42 0 32 3;
 #X restore 661 97 pd \$0-startposition;
-#N canvas 561 76 1211 848 \$0-modes&moves 0;
+#N canvas 698 92 1211 848 \$0-modes&moves 0;
 #X obj 40 108 route 0 1;
 #X obj 40 44 r /stepper/\$1/manualDrive;
 #X obj 51 131 r /stepper/\$1/accMode;
@@ -401,28 +401,28 @@ move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X obj 40 193 spigot;
 #X obj 73 173 == 0;
 #X text 73 11 SET DRIVE MODE;
-#X obj 740 263 r /stepper/\$1/driveMode;
-#X obj 740 351 pack s f f;
-#X obj 797 326 f \$1;
-#X obj 797 304 loadbang;
-#X obj 740 405 s /toOSC;
-#X msg 740 383 /\$1 \$3 \$2;
-#X text 760 247 SEND DRIVE MODE;
-#X obj 711 177 / 60;
-#X obj 642 236 spigot;
-#X obj 725 199 r /stepper/\$1/driveMode;
-#X obj 725 220 == 2;
-#X msg 642 255 setSpeed \$1;
+#X obj 909 276 r /stepper/\$1/driveMode;
+#X obj 909 364 pack s f f;
+#X obj 966 339 f \$1;
+#X obj 966 317 loadbang;
+#X obj 909 418 s /toOSC;
+#X msg 909 396 /\$1 \$3 \$2;
+#X text 929 260 SEND DRIVE MODE;
+#X obj 880 190 / 60;
+#X obj 811 249 spigot;
+#X obj 894 212 r /stepper/\$1/driveMode;
+#X obj 894 233 == 2;
+#X msg 811 268 setSpeed \$1;
 #X obj 51 152 == 0;
-#X msg 740 284 driveMode \$1 \, setSpeed 0;
-#X text 696 14 MANUAL SPEED;
-#X obj 711 153 * 1;
-#X obj 726 133 t b f;
-#X obj 726 93 route 0 1;
-#X msg 726 113 -1;
-#X msg 755 113 1;
-#X obj 726 67 r /stepper/\$1/manualDirection;
-#X obj 711 42 r /stepper/\$1/manualSpeed;
+#X msg 909 297 driveMode \$1 \, setSpeed 0;
+#X text 865 13 MANUAL SPEED;
+#X obj 880 166 * 1;
+#X obj 895 146 t b f;
+#X obj 895 106 route 0 1;
+#X msg 895 126 -1;
+#X msg 924 126 1;
+#X obj 895 88 r /stepper/\$1/manualDirection;
+#X obj 880 41 r /stepper/\$1/manualSpeed;
 #X obj 215 149 r /stepper/\$1/updateStatus;
 #X obj 215 170 f \$1;
 #X msg 215 191 /getStatus \$1;
@@ -448,24 +448,21 @@ move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X obj 215 43 r /stepper/\$1/stop;
 #X obj 396 65 spigot 1;
 #X obj 396 184 spigot 1;
-#X obj 642 199 steps2camrot;
-#X obj 663 492 / 60;
-#X obj 663 474 r /stepper/\$1/setMaxSpeed;
-#X obj 519 646 list prepend;
-#X obj 626 454 r /stepper/\$1/move;
-#X obj 519 450 f \$1;
-#X obj 701 512 / 60;
-#X obj 701 494 r /stepper/\$1/acceleration;
-#X obj 519 754 list;
-#X obj 519 792 s /toOSC;
-#X msg 519 773 /\$1 \$3 \$2;
-#X obj 519 429 r /stepper/\$1/move/go;
-#X msg 519 685 acceleration \$4 \$1 \, maxSpeed \$3 \$1 \, move \$2
+#X obj 453 474 / 60;
+#X obj 453 436 r /stepper/\$1/setMaxSpeed;
+#X obj 309 618 list prepend;
+#X obj 416 416 r /stepper/\$1/move;
+#X obj 309 412 f \$1;
+#X obj 491 514 / 60;
+#X obj 491 476 r /stepper/\$1/acceleration;
+#X obj 309 787 list;
+#X obj 309 825 s /toOSC;
+#X msg 309 806 /\$1 \$3 \$2;
+#X obj 309 391 r /stepper/\$1/move/go;
+#X msg 309 718 acceleration \$4 \$1 \, maxSpeed \$3 \$1 \, move \$2
 \$1 \, getStatus \$1 \$1;
-#X obj 632 530 steps2camrot;
-#X text 543 407 MOVE MANAGEMENT;
-#X obj 594 510 steps2camrot;
-#X obj 557 472 steps2camrot;
+#X text 333 369 MOVE MANAGEMENT;
+#X obj 384 492 steps2camrot;
 #X obj 44 319 r /stepper/\$1/manualDrive;
 #X obj 44 342 route 0 1;
 #X obj 117 361 r /stepper/\$1/accMode;
@@ -474,22 +471,101 @@ move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X text 66 280 SET DRIVE MODE V2;
 #X text 43 293 Vconst -> accelerate AQAP;
 #X text 95 22 not used;
-#X msg 582 748 move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1
+#X msg 372 781 move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1
 ;
-#X msg 544 715 acceleration \$5 \$1 \, maxSpeed \$3 \$1 \, move \$2
+#X msg 334 748 acceleration \$5 \$1 \, maxSpeed \$3 \$1 \, move \$2
 \$1 \, getStatus \$1 \$1;
-#X obj 739 532 / 60;
-#X obj 670 550 steps2camrot;
-#X text 894 512 used if driveMode = 2;
-#X obj 739 514 r /stepper/\$1/accLimit;
-#X obj 519 594 pack 10 5000 1000 1000 1000;
-#X obj 970 43 r /stepper/\$1/manualDrive;
-#X msg 970 64 0;
-#X text 970 20 Force speed to 0 when manual;
-#X obj 970 83 s /stepper/\$1/manualSpeed;
+#X obj 569 534 / 60;
+#X text 704 494 used if driveMode = 2;
+#X obj 569 496 r /stepper/\$1/accLimit;
+#X obj 309 576 pack 10 5000 1000 1000 1000;
+#X obj 641 41 r /stepper/\$1/manualDrive;
+#X msg 641 62 0;
+#X text 641 18 Force speed to 0 when manual;
+#X obj 641 81 s /stepper/\$1/manualSpeed;
 #X msg 44 363 0;
-#X obj 599 624 r /stepper/\$1/accMode;
-#X obj 519 665 route 1 0;
+#X obj 378 596 r /stepper/\$1/accMode;
+#X obj 309 698 route 1 0;
+#X obj 811 212 steps2camrot;
+#X obj 422 532 steps2camrot;
+#X obj 347 434 steps2camrot;
+#X obj 500 552 steps2camrot;
+#N canvas 78 190 450 300 clipValue 0;
+#X obj 87 36 inlet;
+#X obj 87 117 moses;
+#X obj 181 46 inlet;
+#X obj 181 67 t f f;
+#X obj 114 158 f;
+#X obj 96 217 outlet;
+#X obj 117 138 bang;
+#X connect 0 0 1 0;
+#X connect 1 0 5 0;
+#X connect 1 1 6 0;
+#X connect 2 0 3 0;
+#X connect 3 0 1 1;
+#X connect 3 1 4 1;
+#X connect 4 0 5 0;
+#X connect 6 0 4 0;
+#X restore 705 587 pd clipValue;
+#X obj 342 640 r /stepper/\$1/manualDrive;
+#X obj 309 680 spigot;
+#X obj 342 661 == 0;
+#X floatatom 706 546 5 0 0 0 - - -, f 5;
+#X floatatom 716 601 5 0 0 0 - - -, f 5;
+#X floatatom 786 551 5 0 0 0 - - -, f 5;
+#N canvas 78 190 450 300 clipValue 0;
+#X obj 87 36 inlet;
+#X obj 87 117 moses;
+#X obj 181 46 inlet;
+#X obj 181 67 t f f;
+#X obj 114 158 f;
+#X obj 96 217 outlet;
+#X obj 117 138 bang;
+#X connect 0 0 1 0;
+#X connect 1 0 5 0;
+#X connect 1 1 6 0;
+#X connect 2 0 3 0;
+#X connect 3 0 1 1;
+#X connect 3 1 4 1;
+#X connect 4 0 5 0;
+#X connect 6 0 4 0;
+#X restore 453 455 pd clipValue;
+#X obj 613 436 r /stepper/\$1/speedLimit;
+#N canvas 78 190 450 300 clipValue 0;
+#X obj 87 36 inlet;
+#X obj 87 117 moses;
+#X obj 181 46 inlet;
+#X obj 181 67 t f f;
+#X obj 114 158 f;
+#X obj 96 217 outlet;
+#X obj 117 138 bang;
+#X connect 0 0 1 0;
+#X connect 1 0 5 0;
+#X connect 1 1 6 0;
+#X connect 2 0 3 0;
+#X connect 3 0 1 1;
+#X connect 3 1 4 1;
+#X connect 4 0 5 0;
+#X connect 6 0 4 0;
+#X restore 491 495 pd clipValue;
+#N canvas 78 190 450 300 clipValue 0;
+#X obj 87 36 inlet;
+#X obj 87 117 moses;
+#X obj 181 46 inlet;
+#X obj 181 67 t f f;
+#X obj 114 158 f;
+#X obj 96 217 outlet;
+#X obj 117 138 bang;
+#X connect 0 0 1 0;
+#X connect 1 0 5 0;
+#X connect 1 1 6 0;
+#X connect 2 0 3 0;
+#X connect 3 0 1 1;
+#X connect 3 1 4 1;
+#X connect 4 0 5 0;
+#X connect 6 0 4 0;
+#X restore 880 63 pd clipValue;
+#X obj 1040 40 r /stepper/\$1/speedLimit;
 #X connect 0 0 4 0;
 #X connect 0 1 5 0;
 #X connect 2 0 22 0;
@@ -504,7 +580,7 @@ move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X connect 12 0 11 2;
 #X connect 13 0 12 0;
 #X connect 15 0 14 0;
-#X connect 17 0 57 1;
+#X connect 17 0 92 1;
 #X connect 18 0 21 0;
 #X connect 19 0 20 0;
 #X connect 20 0 18 1;
@@ -519,7 +595,7 @@ move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X connect 28 0 26 0;
 #X connect 29 0 26 0;
 #X connect 30 0 27 0;
-#X connect 31 0 25 0;
+#X connect 31 0 106 0;
 #X connect 32 0 33 0;
 #X connect 33 0 34 0;
 #X connect 34 0 35 0;
@@ -542,36 +618,48 @@ move \$2 \$1 \, setSpeed \$3 \$1 \, getStatus \$1 \$1;
 #X connect 54 0 36 0;
 #X connect 55 0 51 0;
 #X connect 56 0 47 0;
-#X connect 57 0 18 0;
-#X connect 58 0 72 1;
-#X connect 59 0 58 0;
-#X connect 60 0 95 0;
-#X connect 61 0 73 1;
-#X connect 62 0 88 0;
-#X connect 63 0 70 1;
-#X connect 64 0 63 0;
-#X connect 65 0 67 0;
-#X connect 67 0 66 0;
-#X connect 68 0 62 0;
-#X connect 69 0 65 0;
-#X connect 70 0 88 3;
-#X connect 72 0 88 2;
-#X connect 73 0 88 1;
-#X connect 74 0 75 0;
-#X connect 75 0 93 0;
-#X connect 75 1 78 0;
-#X connect 78 0 77 0;
-#X connect 83 0 65 0;
-#X connect 84 0 85 1;
-#X connect 85 0 88 4;
-#X connect 87 0 84 0;
-#X connect 88 0 60 0;
-#X connect 89 0 90 0;
-#X connect 90 0 92 0;
-#X connect 93 0 77 0;
-#X connect 94 0 60 1;
-#X connect 95 0 69 0;
-#X connect 95 1 83 0;
+#X connect 57 0 70 1;
+#X connect 58 0 103 0;
+#X connect 59 0 98 0;
+#X connect 60 0 94 1;
+#X connect 61 0 84 0;
+#X connect 62 0 93 1;
+#X connect 63 0 105 0;
+#X connect 64 0 66 0;
+#X connect 66 0 65 0;
+#X connect 67 0 61 0;
+#X connect 68 0 64 0;
+#X connect 70 0 84 2;
+#X connect 71 0 72 0;
+#X connect 72 0 89 0;
+#X connect 72 1 75 0;
+#X connect 75 0 74 0;
+#X connect 80 0 64 0;
+#X connect 81 0 95 1;
+#X connect 83 0 81 0;
+#X connect 83 0 105 1;
+#X connect 84 0 59 0;
+#X connect 85 0 86 0;
+#X connect 86 0 88 0;
+#X connect 89 0 74 0;
+#X connect 90 0 59 1;
+#X connect 91 0 68 0;
+#X connect 91 1 80 0;
+#X connect 92 0 18 0;
+#X connect 93 0 84 3;
+#X connect 94 0 84 1;
+#X connect 95 0 84 4;
+#X connect 96 0 101 0;
+#X connect 97 0 99 0;
+#X connect 98 0 91 0;
+#X connect 99 0 98 1;
+#X connect 100 0 96 0;
+#X connect 102 0 96 1;
+#X connect 103 0 57 0;
+#X connect 104 0 103 1;
+#X connect 105 0 62 0;
+#X connect 106 0 25 0;
+#X connect 107 0 106 1;
 #X restore 661 117 pd \$0-modes&moves;
 #X obj 514 190 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/move/startPos
 /stepper/\$1/move/startPos Position_depart 0 -8 0 12 -204800 -1 -1

+ 9 - 10
stepperCue.pd

@@ -1,4 +1,4 @@
-#N canvas 1929 61 1278 947 10;
+#N canvas 1921 55 1401 947 10;
 #X obj 102 252 cnv 15 356 41 /stepper/\$1/cue/\$2/canvas /stepper/\$1/cue/\$2/canvas
 empty 48 8 0 14 -225280 -225280 0;
 #X obj 104 160 tof/menubutton 100 25 \$0-mbS \$0-mbR 1 grey90 black
@@ -8,16 +8,15 @@ grey95 black 0 \, none \, test (autre copie).move \, test.move \, test (3e copie
 #X obj 174 260 bng 25 250 50 0 /stepper/\$1/cue/\$2/move/go /stepper/\$1/cue/\$2/move/go
 GO 6 13 0 10 -4034 -1 -1;
 #X obj 427 258 tgl 10 0 /stepper/\$1/cue/\$2/accMode empty 0/1 15 5
-0 8 -262144 -1 -1 0 1;
+0 8 -262144 -1 -1 1 1;
 #X obj 205 271 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/cue/\$2/move
-/stepper/\$1/cue/\$2/move tours 0 -8 0 10 -262144 -1 -1 0.138889 256
-;
+/stepper/\$1/cue/\$2/move tours 0 -8 0 10 -262144 -1 -1 0 256;
 #X obj 340 271 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/cue/\$2/setMaxSpeed
-/stepper/\$1/cue/\$2/setMaxSpeed speed 0 -8 0 10 -262144 -1 -1 2 256
+/stepper/\$1/cue/\$2/setMaxSpeed speed 0 -8 0 10 -262144 -1 -1 0 256
 ;
 #X obj 392 271 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/cue/\$2/acceleration
-/stepper/\$1/cue/\$2/acceleration acc 0 -8 0 10 -233017 -233017 -195568
-0.17 256;
+/stepper/\$1/cue/\$2/acceleration acc 0 -8 0 10 -262144 -1 -1 0 256
+;
 #X obj 320 55 r /stepper/\$1/accMode;
 #X obj 320 76 route 0 1;
 #X msg 320 95 color 10 10 20;
@@ -67,7 +66,7 @@ GO 6 13 0 10 -4034 -1 -1;
 #X obj 66 381 + 2;
 #X text 468 405 MOVE DEGRES CONVERSION;
 #X obj 255 271 nbx 4 14 -1e+37 1e+37 0 0 /stepper/\$1/cue/\$2/move/deg
-/stepper/\$1/cue/\$2/move/deg deg 48 8 0 10 -262144 -1 -1 50 256;
+/stepper/\$1/cue/\$2/move/deg deg 48 8 0 10 -262144 -1 -1 0 256;
 #X obj 251 166 route 0 1;
 #X msg 251 185 color 10 10 20;
 #X msg 276 206 color 0 22 22;
@@ -85,11 +84,11 @@ GO 6 13 0 10 -4034 -1 -1;
 #X obj 557 736 f \$2;
 #X obj 66 450 f \$2;
 #X obj 557 757 s /stepper/\$1/cue/current;
-#X obj 105 255 tgl 15 0 /stepper/\$1/cue/\$2/active /stepper/\$1/cue/\$2/active
+#X obj 105 266 tgl 15 0 /stepper/\$1/cue/\$2/active /stepper/\$1/cue/\$2/active
 active 18 8 0 10 -262144 -1 -1 1 1;
 #X obj 733 455 r /stepper/\$1/cue/\$2/active;
 #X obj 557 715 r /stepper/\$1/cue/\$2/select;
-#X obj 105 275 bng 15 250 50 0 /stepper/\$1/cue/\$2/select /stepper/\$1/cue/\$2/select
+#X obj 45 275 bng 15 250 50 0 /stepper/\$1/cue/\$2/select /stepper/\$1/cue/\$2/select
 select 17 7 0 10 -262144 -1 -1;
 #X obj 713 437 + 1;
 #X obj 917 125 f \$1;

+ 9 - 9
steps2camrot.pd

@@ -1,11 +1,11 @@
-#N canvas 584 73 450 300 10;
+#N canvas 938 739 450 300 10;
 #X obj 96 72 inlet;
-#X obj 179 42 loadbang;
-#X msg 179 64 200;
+#X obj 179 22 loadbang;
+#X msg 179 44 200;
 #X obj 96 256 outlet;
 #X obj 286 71 inlet;
 #X text 82 39 step2rot;
-#X text 283 43 rot2step;
+#X text 330 67 rot2step;
 #X floatatom 179 160 10 0 0 0 - - -, f 10;
 #X obj 96 146 /;
 #X obj 179 107 * 70;
@@ -17,11 +17,11 @@
 #X obj 286 192 i;
 #X text 149 255 single output \, conversion direction is choosen via
 input;
-#X obj 208 63 r /microsteps;
-#X obj 179 86 * 4;
+#X obj 179 66 * 4;
+#X obj 208 43 r microstepping;
 #X connect 0 0 8 0;
 #X connect 1 0 2 0;
-#X connect 2 0 18 0;
+#X connect 2 0 17 0;
 #X connect 4 0 14 0;
 #X connect 8 0 3 0;
 #X connect 9 0 8 1;
@@ -33,5 +33,5 @@ input;
 #X connect 13 1 12 1;
 #X connect 14 0 15 0;
 #X connect 15 0 3 0;
-#X connect 17 0 18 1;
-#X connect 18 0 9 0;
+#X connect 17 0 9 0;
+#X connect 18 0 17 1;