LogicControl and Max/MSP initialization

Feb 27, 2007 at 2:37pm

LogicControl and Max/MSP initialization

Greetings to all…..

Firstly – to save people’s time…
If you don’t have a Logic Control (or Mackie Control) I don’t think you will be able to help me here as the patch relies on such a unit to be connected to really do anything – but read on if it intrigues you..

OK, to those who haven’t now moved on to the next new forum post……….

I wonder if someone can gelp me here, I have scoured the forum, and internet for information/solutions but drawn a complete blank.
What am I trying to do?
Connect to a Lofic Control/XT from within Max/MSP using the Logic Control Midi Implementation Guide from the Logic7.2.1 CS Support Manual (Appendix B, pp 239-242). I haven’t included an excerpt from it as that quite probably infringes the copyright of the pdf, so here is the link to download it if you think you can possibly help. http://www.apple.com/support/logic/ on the right hand side ‘control surfaces info’.

Below is a patch which;
A – Sends a ‘Device Query’ sysex string to Logic Control.
B – Receives a ‘Host Connection Query’ in reply from Logic Control.
C – Deconstructs the Host Connection Query sysex string, works out the response code from the challenge code contained in the last 4 bytes of the string.
D – Recompiles a ‘Host Conection Response’ sysex string which is then sent out to Logic Control (within 300ms of Logic Control sending the ‘Host Connection Query ‘ string.
From this Response, I would expect to receive back from the Logic Control either a ‘Host Connection Confirmation’ or ‘Host Connection Error’ sysex string in reply, but although the Response is definitely sending to the Logic Control I receive no response at all.
It is possible that my expression are incorrectly implemented, but I would still expect a ‘Host Connection Error’ reply even if no Response was sent.
If anyone has any idea whatsever as to what I might be doing wrong here, I would be so grateful to hear from you. a workaround I have for now is to leave LogicPro running in the bacjground with the Logic Control connected, but all the controller assignments deleted…..a bit messy, although Logic seems to use virtually no cpu when audio is disabled, so not the end of the world, but it would be nice not to have to rely upon LogicPro running as well as Max/MSP.
Thanks for your time in reading this – I do tend to prefer working things out for myself rather than firing questions here all the time but this one really has me stumped!
regards
leigh

.and the patch

max v2;
#N vpatcher 96 44 1252 1031;
#P origin -193 -16;
#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P comment 482 141 376 196617 EXPECTED HOST CONNECTION CONFIRMATION/ERROR MSG HERE NOT APPEARING.;
#P comment 481 186 312 196617 HOST CONNECTION QUERY MSG AS RECEIVED FROM LOGIC CONTROL;
#P comment 148 815 343 196617 HOST CONNECTION REPLY MSG COMPILED AND SENT TO LOGIC COMTROL;
#P newex -321 566 60 196617 s clrmsgs1;
#P message 160 103 22 196617 set;
#P window linecount 2;
#P comment 642 369 252 196617 THE DELAYBANG1 SEND OBJECT BANGS THE COMPLETED HOST CONECTION REPLY MSG;
#P window linecount 1;
#P newex 622 733 58 196617 s hcreply2;
#P newex 540 563 54 196617 r chbyte4;
#P newex 473 563 54 196617 r chbyte3;
#P newex 403 563 54 196617 r chbyte2;
#P newex 333 563 54 196617 r chbyte1;
#P newex 512 374 54 196617 s chbyte4;
#P newex 456 374 54 196617 s chbyte3;
#P newex 400 374 54 196617 s chbyte2;
#P newex 344 374 54 196617 s chbyte1;
#P window linecount 10;
#P comment 672 234 252 196617 THIS RATHER ‘MESSY BIT TAKES THE RETURNED HOST CONNECTION QUERY TO CONSTRUCT A HOST CONNECTION REPLY , AS SPECIFIED IN THE LC MIDI IMPLEMENTATION. GATE OUTPUT 6 CONVERTS TO A HOST CONNECTION REPLY. ALL OTHER BYTES ARE THE SAME AS THE QUERY , SAVE FOR THE LAST 4 BYTES WHICH ARE FED TO 4 EXPRESSION OBJECTS BELOW TO CREATE THE RESPONSE CODE. I’M PRETTY SURE THE ORDER IS CORRECT , THOUGH I’M SURE THERE MUST BE A LESS CONVOLUTED WAY OF ACHIEVING IT!;
#P window linecount 1;
#P newex 175 744 60 196617 r clrmsgs1;
#P newex 356 117 60 196617 r clrmsgs1;
#P newex 149 132 60 196617 s clrmsgs1;
#P newex 247 80 73 196617 r gateswitch1;
#P newex 594 398 73 196617 s gateswitch1;
#P newex 239 744 68 196617 r delaybang1;
#P newex 555 307 58 196617 s hcreply2;
#P newex 555 280 27 196617 t i b;
#P newex 112 744 58 196617 r hcreply2;
#P newex 156 403 58 196617 s hcreply2;
#P newex 50 744 58 196617 r hcreply1;
#P newex 97 403 58 196617 s hcreply1;
#P newex 30 79 68 196617 r delaybang1;
#P newex 573 374 68 196617 s delaybang1;
#P newex 247 149 40 196617 t b i i;
#P message 404 79 118 196617 240 0 0 102 16 99 247;
#P newex 404 98 51 196617 midiout d;
#P newex 107 79 66 196617 t b b b set 1;
#P newex 121 863 51 196617 midiout d;
#P number 5 133 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 5 113 35 196617 timer;
#P message 26 166 112 196617 240 0 0 102 16 0 247;
#P newex 573 351 31 196617 t b 2;
#P button 404 56 15 0;
#P message 425 139 55 196617 append $1;
#P window linecount 0;
#P message 425 160 38 196617;
#P window linecount 1;
#P newex 247 125 38 196617 gate 2;
#P newex 198 304 28 196617 + 1;
#P newex 572 329 55 196617 delay 150;
#P window linecount 0;
#P message 120 827 16 196617;
#P window linecount 1;
#P message 50 765 39 196617 set $1;
#P message 112 765 55 196617 append $1;
#P number 622 701 101 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 622 669 169 196617 expr 127 & ($i3 +($i2 ^ 10) – $i1);
#P number 50 701 101 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 50 669 202 196617 expr 127 & ($i3 – $i2 +(240 ^($i1 < < 4)));
#P number 256 701 101 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 256 669 190 196617 expr 127 & ($i1 -($i2 < < 2) ^ $i4 | $i3);
#P number 449 701 101 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 449 669 171 196617 expr 127 & ($i3 >> 4) ^ ($i2 + $i1);
#P newex 87 279 455 196617 gate 18;
#N counter 0 1 18;
#X flags 0 0;
#P newobj 87 230 77 196617 counter 0 1 18;
#P message 424 183 55 196617 append $1;
#P window linecount 0;
#P message 425 205 16 196617;
#P window linecount 1;
#P newex 275 99 53 196617 sysexin c;
#P button 108 56 15 0;
#P newex 26 184 51 196617 midiout d;
#P window linecount 4;
#P comment 123 23 252 196617 BANG TO SET INPUT ROUTING GATE TO 1 , CLEAR MSG BOXES , RESET COUNTER , SEND DEVICE QUERY , AND SET TIMER RUNNING TO CHECK 300ms FOR HOST CONNECTION REPLY IS NOT EXCEEDED;
#P window linecount 3;
#P comment 418 35 215 196617 RESET MSG TO TAKE LOGIC CONTROL OFFLINE (SINCE I HAVENT GOT IT ONLINE YET I HAVE NOT TESTED!);
#P user panel 84 229 845 327;
#X brgb 191 191 191;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P window setfont “Sans Serif” 12.;
#P window linecount 5;
#P comment 654 21 217 196620 NB – THIS PATCH USES MIDIINPORT C AND MIDIOUTPORT D. SIMPLY CHANGE THE 3 MIDIOUT OBJECTS AND 1 SYSEXIN OBJECT T OSUIT YOUR SETUP;
#P connect 33 0 30 0;
#P connect 30 0 31 0;
#P connect 33 1 29 0;
#P connect 29 0 4 0;
#P connect 38 0 30 1;
#P connect 59 0 15 0;
#P connect 15 0 16 0;
#P connect 40 0 20 0;
#P connect 36 0 9 0;
#P connect 9 0 10 0;
#P connect 10 0 39 0;
#P connect 5 0 33 0;
#P connect 42 0 19 0;
#P connect 20 0 21 0;
#P connect 19 0 21 0;
#P connect 45 0 21 0;
#P connect 50 0 21 0;
#P connect 21 0 32 0;
#P connect 33 2 9 3;
#P connect 58 0 15 1;
#P connect 33 3 48 0;
#P connect 62 0 48 0;
#P connect 10 1 41 0;
#P connect 10 2 41 0;
#P connect 10 3 41 0;
#P connect 10 4 41 0;
#P connect 10 6 41 0;
#P connect 10 7 41 0;
#P connect 10 8 41 0;
#P connect 10 9 41 0;
#P connect 10 10 41 0;
#P connect 10 11 41 0;
#P connect 10 12 41 0;
#P connect 23 0 41 0;
#P connect 10 5 23 0;
#P connect 57 0 15 2;
#P connect 47 0 24 0;
#P connect 33 4 24 0;
#P connect 24 0 36 0;
#P connect 59 0 13 0;
#P connect 13 0 14 0;
#P connect 6 0 24 1;
#P connect 58 0 13 1;
#P connect 10 13 52 0;
#P connect 57 0 13 2;
#P connect 10 14 53 0;
#P connect 27 0 35 0;
#P connect 35 0 34 0;
#P connect 36 2 8 0;
#P connect 24 1 26 0;
#P connect 26 0 25 0;
#P connect 49 0 25 0;
#P connect 8 0 7 0;
#P connect 49 0 7 0;
#P connect 56 0 13 3;
#P connect 59 0 11 0;
#P connect 11 0 12 0;
#P connect 10 15 54 0;
#P connect 10 16 55 0;
#P connect 56 0 11 1;
#P connect 36 1 10 1;
#P connect 10 17 43 0;
#P connect 43 0 44 0;
#P connect 43 1 22 0;
#P connect 22 0 28 0;
#P connect 28 0 37 0;
#P connect 28 1 46 0;
#P connect 58 0 11 2;
#P connect 59 0 17 0;
#P connect 17 0 18 0;
#P connect 18 0 60 0;
#P connect 12 0 60 0;
#P connect 14 0 60 0;
#P connect 16 0 60 0;
#P connect 57 0 17 1;
#P connect 56 0 17 2;
#P pop;

#30486
Feb 27, 2007 at 4:11pm

Hello Leigh,

I made some MXJ code (which you are welcome to) for talking to my MCU
some time ago, based on the logic spec, so I can confirm that it’s at
least possible. Unfortunately my unit’s been in storage for the last
year due to being spatially condensed, so finishing it off hasn’t
happened, and testing your patch isn’t possible.

However, looking at your patch, I noticed that the bracketing in the
[expr]s wasn’t exactly as in the spec, in that you’d missed some out. I
never remember about operator precedence, but there’s every chance that
it will mess with things. Corrected version pasted below.

The patch as it stands seems a bit arcane to me (although you may find
the Java approach equally so!) – it relies very heavily on ordering,
having the same byte going to different inlets of different exprs makes
debugging them difficult, and so forth. Not that I’ve tried it, but
wouldn’t it be easier to use zl.group to make a list out of the message,
and then some triggers to guarantee well ordered computation and
dispatch of the result? Worth a try perhaps.

My MCU is currently next to me in its box. If I discover a clear
horizontal surface ever again, I’ll have it set up and hopefully be able
to offer you more informed help.

OTOH, I think, spec-wise, my MXJ implementation was pretty much complete
(this could be rose-tinted memory though – I know it definitely worked,
at least), and what was left was making a sensible max interface for it,
a la the motormix objects. If you’re interested, not knowing how much
time you’ve sunk into it so far, we could finish it off together.

Oh, and thanks also for posting the link to the spec – I’d lost my copy,
somehow, and someone was asking about it just the other day.

Anyway, see if the added brackets help:

#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P comment 542 32 404 9109513 EXPECTED HOST CONNECTION
CONFIRMATION/ERROR MSG HERE NOT APPEARING.;
#P comment 541 77 340 9109513 HOST CONNECTION QUERY MSG AS RECEIVED FROM
LOGIC CONTROL;
#P comment 208 706 356 9109513 HOST CONNECTION REPLY MSG COMPILED AND
SENT TO LOGIC COMTROL;
#P newex -261 457 60 9109513 s clrmsgs1;
#P message 220 -6 22 9109513 set;
#P window linecount 2;
#P comment 702 260 252 9109513 THE DELAYBANG1 SEND OBJECT BANGS THE
COMPLETED HOST CONECTION REPLY MSG;
#P window linecount 1;
#P newex 682 624 58 9109513 s hcreply2;
#P newex 604 455 54 9109513 r chbyte4;
#P newex 530 455 54 9109513 r chbyte3;
#P newex 463 454 54 9109513 r chbyte2;
#P newex 770 451 54 9109513 r chbyte1;
#P newex 572 265 54 9109513 s chbyte4;
#P newex 516 265 54 9109513 s chbyte3;
#P newex 460 265 54 9109513 s chbyte2;
#P newex 404 265 54 9109513 s chbyte1;
#P window linecount 10;
#P comment 732 125 270 9109513 THIS RATHER ‘MESSY BIT TAKES THE RETURNED
HOST CONNECTION QUERY TO CONSTRUCT A HOST CONNECTION REPLY , AS
SPECIFIED IN THE LC MIDI IMPLEMENTATION. GATE OUTPUT 6 CONVERTS TO A
HOST CONNECTION REPLY. ALL OTHER BYTES ARE THE SAME AS THE QUERY , SAVE
FOR THE LAST 4 BYTES WHICH ARE FED TO 4 EXPRESSION OBJECTS BELOW TO
CREATE THE RESPONSE CODE. I’M PRETTY SURE THE ORDER IS CORRECT , THOUGH
I’M SURE THERE MUST BE A LESS CONVOLUTED WAY OF ACHIEVING IT!;
#P window linecount 1;
#P newex 235 635 60 9109513 r clrmsgs1;
#P newex 416 8 60 9109513 r clrmsgs1;
#P newex 209 23 60 9109513 s clrmsgs1;
#P newex 307 -29 73 9109513 r gateswitch1;
#P newex 654 289 73 9109513 s gateswitch1;
#P newex 299 635 68 9109513 r delaybang1;
#P newex 615 198 58 9109513 s hcreply2;
#P newex 615 171 27 9109513 t i b;
#P newex 172 635 58 9109513 r hcreply2;
#P newex 216 294 58 9109513 s hcreply2;
#P newex 110 635 58 9109513 r hcreply1;
#P newex 157 294 58 9109513 s hcreply1;
#P newex 90 -30 68 9109513 r delaybang1;
#P newex 633 265 68 9109513 s delaybang1;
#P newex 307 40 40 9109513 t b i i;
#P message 464 -30 118 9109513 240 0 0 102 16 99 247;
#P newex 464 -11 51 9109513 midiout d;
#P newex 167 -30 66 9109513 t b b b set 1;
#P newex 181 754 51 9109513 midiout d;
#P number 65 24 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 65 4 35 9109513 timer;
#P message 86 57 112 9109513 240 0 0 102 16 0 247;
#P newex 633 242 31 9109513 t b 2;
#P button 464 -53 15 0;
#P message 485 30 55 9109513 append $1;
#P window linecount 0;
#P message 485 51 38 9109513;
#P window linecount 1;
#P newex 307 16 38 9109513 gate 2;
#P newex 258 195 28 9109513 + 1;
#P newex 632 220 55 9109513 delay 150;
#P window linecount 0;
#P message 180 718 16 9109513;
#P window linecount 1;
#P message 110 656 39 9109513 set $1;
#P message 172 656 55 9109513 append $1;
#P number 682 592 101 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 682 557 169 9109513 expr 127 & ($i3 +($i2 ^ 10) – $i1);
#P number 110 592 101 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 110 560 202 9109513 expr 127 & ($i3 – $i2 +(240 ^($i1 < < 4)));
#P number 316 592 101 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 316 560 167 9109513 expr 127 & ($i1 -($i2 < < 2) ^ ($i4 | $i3));
#P number 509 592 101 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 516 560 151 9109513 expr 127 & (($i3 >> 4) ^ ($i2 + $i1));
#P newex 147 170 455 9109513 gate 18;
#N counter 0 1 18;
#X flags 0 0;
#P newobj 147 121 77 9109513 counter 0 1 18;
#P message 484 74 55 9109513 append $1;
#P window linecount 0;
#P message 485 96 16 9109513;
#P window linecount 1;
#P newex 335 -10 53 9109513 sysexin c;
#P button 168 -53 15 0;
#P newex 86 92 51 9109513 midiout d;
#P window linecount 4;
#P comment 183 -86 252 9109513 BANG TO SET INPUT ROUTING GATE TO 1 ,
CLEAR MSG BOXES , RESET COUNTER , SEND DEVICE QUERY , AND SET TIMER
RUNNING TO CHECK 300ms FOR HOST CONNECTION REPLY IS NOT EXCEEDED;
#P window linecount 3;
#P comment 478 -74 215 9109513 RESET MSG TO TAKE LOGIC CONTROL OFFLINE
(SINCE I HAVENT GOT IT ONLINE YET I HAVE NOT TESTED!);
#P user panel 144 120 845 327;
#X brgb 191 191 191;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P window setfont “Sans Serif” 12.;
#P window linecount 5;
#P comment 714 -88 217 9109516 NB – THIS PATCH USES MIDIINPORT C AND
MIDIOUTPORT D. SIMPLY CHANGE THE 3 MIDIOUT OBJECTS AND 1 SYSEXIN OBJECT
T OSUIT YOUR SETUP;
#P connect 59 0 15 0;
#P connect 59 0 13 0;
#P connect 59 0 11 0;
#P connect 59 0 17 0;
#P connect 57 0 15 2;
#P connect 57 0 13 2;
#P connect 57 0 17 1;
#P connect 56 0 13 3;
#P connect 56 0 11 1;
#P connect 56 0 17 2;
#P connect 58 0 15 1;
#P connect 58 0 13 1;
#P connect 58 0 11 2;
#P connect 13 0 14 0;
#P connect 11 0 12 0;
#P connect 16 0 60 0;
#P connect 14 0 60 0;
#P connect 12 0 60 0;
#P connect 18 0 60 0;
#P connect 17 0 18 0;
#P connect 28 1 46 0;
#P connect 28 0 37 0;
#P connect 22 0 28 0;
#P connect 43 1 22 0;
#P connect 43 0 44 0;
#P connect 10 17 43 0;
#P connect 36 1 10 1;
#P connect 10 16 55 0;
#P connect 10 15 54 0;
#P connect 49 0 25 0;
#P connect 49 0 7 0;
#P connect 8 0 7 0;
#P connect 26 0 25 0;
#P connect 24 1 26 0;
#P connect 36 2 8 0;
#P connect 35 0 34 0;
#P connect 27 0 35 0;
#P connect 10 14 53 0;
#P connect 10 13 52 0;
#P connect 6 0 24 1;
#P connect 24 0 36 0;
#P connect 33 4 24 0;
#P connect 47 0 24 0;
#P connect 10 5 23 0;
#P connect 23 0 41 0;
#P connect 10 12 41 0;
#P connect 10 11 41 0;
#P connect 10 10 41 0;
#P connect 10 9 41 0;
#P connect 10 8 41 0;
#P connect 10 7 41 0;
#P connect 10 6 41 0;
#P connect 10 4 41 0;
#P connect 10 3 41 0;
#P connect 10 2 41 0;
#P connect 10 1 41 0;
#P connect 62 0 48 0;
#P connect 33 3 48 0;
#P connect 33 2 9 3;
#P connect 21 0 32 0;
#P connect 50 0 21 0;
#P connect 45 0 21 0;
#P connect 19 0 21 0;
#P connect 20 0 21 0;
#P connect 42 0 19 0;
#P connect 5 0 33 0;
#P connect 10 0 39 0;
#P connect 9 0 10 0;
#P connect 36 0 9 0;
#P connect 40 0 20 0;
#P connect 15 0 16 0;
#P connect 38 0 30 1;
#P connect 29 0 4 0;
#P connect 33 1 29 0;
#P connect 30 0 31 0;
#P connect 33 0 30 0;
#P window clipboard copycount 67;

Leigh Hunt wrote:
> Greetings to all…..
>
> Firstly – to save people’s time… If you don’t have a Logic Control
> (or Mackie Control) I don’t think you will be able to help me here
> as the patch relies on such a unit to be connected to really do
> anything – but read on if it intrigues you..
>
> OK, to those who haven’t now moved on to the next new forum
> post……….
>
> I wonder if someone can gelp me here, I have scoured the forum, and
> internet for information/solutions but drawn a complete blank. What
> am I trying to do? Connect to a Lofic Control/XT from within Max/MSP
> using the Logic Control Midi Implementation Guide from the Logic7.2.1
> CS Support Manual (Appendix B, pp 239-242). I haven’t included an
> excerpt from it as that quite probably infringes the copyright of the
> pdf, so here is the link to download it if you think you can possibly
> help. http://www.apple.com/support/logic/ on the right hand side
> ‘control surfaces info’.
>
> Below is a patch which; A – Sends a ‘Device Query’ sysex string to
> Logic Control. B – Receives a ‘Host Connection Query’ in reply from
> Logic Control. C – Deconstructs the Host Connection Query sysex
> string, works out the response code from the challenge code contained
> in the last 4 bytes of the string. D – Recompiles a ‘Host Conection
> Response’ sysex string which is then sent out to Logic Control
> (within 300ms of Logic Control sending the ‘Host Connection Query ‘
> string.
>> From this Response, I would expect to receive back from the Logic
>> Control either a ‘Host Connection Confirmation’ or ‘Host
>> Connection Error’ sysex string in reply, but although the Response
>> is definitely sending to the Logic Control I receive no response at
>> all.
> It is possible that my expression are incorrectly implemented, but I
> would still expect a ‘Host Connection Error’ reply even if no
> Response was sent. If anyone has any idea whatsever as to what I
> might be doing wrong here, I would be so grateful to hear from you. a
> workaround I have for now is to leave LogicPro running in the
> bacjground with the Logic Control connected, but all the controller
> assignments deleted…..a bit messy, although Logic seems to use
> virtually no cpu when audio is disabled, so not the end of the world,
> but it would be nice not to have to rely upon LogicPro running as
> well as Max/MSP. Thanks for your time in reading this – I do tend to
> prefer working things out for myself rather than firing questions
> here all the time but this one really has me stumped! regards leigh
>
> .and the patch
>

#97624
Feb 27, 2007 at 5:30pm

At 2:37 PM +0000 2/27/07, Leigh Hunt wrote:
>What am I trying to do?
>Connect to a Lofic Control/XT from within Max/MSP using the Logic Control Midi Implementation Guide from the Logic7.2.1 CS Support Manual (Appendix B, pp 239-242).

I created a patch called MaxieControl that allows the use of a Mackie Control from within Max.

You might be able to look at it and either cobble bits from it, or at least figure out where you went wrong. I remember the “Secret Handshake” part of the protocol to be problematic. Look at my RouteSysex patcher to see how I did this.

It’s available at http://www.xfade.com/max

-C


Chris Muir | “There are many futures and only one status quo.
cbm@well.com | This is why conservatives mostly agree,
http://www.xfade.com | and radicals always argue.” – Brian Eno

#97625
Feb 27, 2007 at 5:39pm

Quote: owen wrote on Tue, 27 February 2007 16:11
Hi Owen

> However, looking at your patch, I noticed that the bracketing in the
> [expr]s wasn’t exactly as in the spec, in that you’d missed some out. I
> never remember about operator precedence, but there’s every chance that
> it will mess with things. Corrected version pasted below.

You little star Sir – the patch, and Host Connection with LC and XT are now working wonderfully!!!!!!!! You really have made my day/week/month!
If you are ever in Nottingham, do let me buy you a coffee/beer!

>
> The patch as it stands seems a bit arcane to me (although you may find
> the Java approach equally so!) – it relies very heavily on ordering,
> having the same byte going to different inlets of different exprs makes
> debugging them difficult, and so forth. Not that I’ve tried it, but
> wouldn’t it be easier to use zl.group to make a list out of the message,
> and then some triggers to guarantee well ordered computation and
> dispatch of the result? Worth a try perhaps.

It is a tad messy isn’t it?
Java approach for me is another learning curve I think (I hope) I can live without for my needs, but now I have the patch working I shall clean it up a bit. Thanks for the heads up on zl.group….I shall check it out shortly.

> OTOH, I think, spec-wise, my MXJ implementation was pretty much complete
> (this could be rose-tinted memory though – I know it definitely worked,
> at least), and what was left was making a sensible max interface for it,
> a la the motormix objects. If you’re interested, not knowing how much
> time you’ve sunk into it so far, we could finish it off together.

Do you think your MXJ implementation would be so advantageous for others as opposed to a cleaned up patch version? I really haven’t read anything about Java. Does the implementation you envisage include binding to objects/parameters and driving the control surface, or just the connecting procedure?
I already have a patch driven setup reading colls to bind to objects/pass data to LCDs and encoders etc (Admittedly, the patch is rather spaghettied, and to a point still relying on position of objects for order, but it is very stable so far – something else I’m now going to clean up ? I think so!- hey – it was only today I got round to adding triggers to the orignal patch I posted!). Let me know what you think..you can email at ‘myuseridhere’ at mac dot com if you like.

> Oh, and thanks also for posting the link to the spec – I’d lost my copy,
> somehow, and someone was asking about it just the other day.

No worries

Thanks again dude
Regards
Leigh

#97626
Feb 27, 2007 at 6:55pm

Leigh Hunt wrote:
> You little star Sir – the patch, and Host Connection with LC and XT
> are now working wonderfully!!!!!!!! You really have made my
> day/week/month! If you are ever in Nottingham, do let me buy you a
> coffee/beer!

Happy to be helpful matey! I’ll take you up on the beer though ;-)

> Do you think your MXJ implementation would be so advantageous for
> others as opposed to a cleaned up patch version?

Not especially, it was done that way because it was, for me, easier :)
It only has completeness (of protocol) and elegance going for it at the
moment. What it doesn’t have is any state management or persistence.


O

#97627
Feb 27, 2007 at 8:35pm

Hi Chris,

Nice interface, I’ll certainly take a look at your implementation. As you see from my crossing post, Owen spotted my expression errors, and now all works great.
You certainly have done a comprehensive job on the initialization and preference options. I hadn’t thought of using lbuild, though I have used a few lobjects in other areas of my (big) patch. I am beginning to think that I do rather alot more ‘order by placement’ programming than ‘order by trigger order’ than your average maxer, but it kind of works for my goals….for now!
Thanks for sharing and taking the time to respond.

Regards
Leigh

#97628

You must be logged in to reply to this topic.