Processing a list easier?

ygreq's icon

Hi,

Do you maybe know how I can process this list with fewer objects? I chose [unpack] which is not the nicest option, I'd say.
It is for calculating a XOR checksum of the list.

Max Patch
Copy patch and select New From Clipboard in Max.

Thank you,
ygr

Emmanuel Jourdan's icon
Max Patch
Copy patch and select New From Clipboard in Max.

You can do something like that:

Emmanuel Jourdan's icon

well I was too late… but that's the spirit ;-)

ygreq's icon

Hi Nicolas,

Thank you again for your help. I used your patch to figure out how XOR works. It helped a hell of a lot to understand how a checksum is created.

Unfortunately, because of the way it is built, I can not get it to work. I need to add the XOR checksum to the list. And I tried a few tricks but I just can not get the final XOR checksum to be in the same list as the original list. It only gets the XOR before the last number is processed.

Mainly the problem is like this:

"Start patch and then stop. Once it settles, the number in the message (A) should be the same as the last numer in the list (B). But they aren't. The last numer in the list is actually the penultimate XOR that was calculated, and not the last one as it should be. Check the Max window for details."

Max Patch
Copy patch and select New From Clipboard in Max.

Check the patch to see what I mean:

ygreq's icon

Hi, Emmanuel

Thank you for helping out. I will look at your patch in a bit. :)

PS: Thank you for the [join] object. :) Didn't know it existed.

ygreq's icon

But mainly this is what I am trying to achieve.

It's good. It works. But it's too big (using the unpack object).

Max Patch
Copy patch and select New From Clipboard in Max.

Like I said, with the other examples the final XOR and
the list don't sync. :(

ygreq's icon

Hi, Nicolas

I am still trying to figure out how you did it but it definitely works!

The [trigger] object is actually my favorite object. Got me out of a lot of problems. And I actually used it trying to get the first patch you sent me to work. :)

Thank you so much!

And thank you once again, Emmanuel.

ygreq's icon

Now I realised something. Does using encapsulating switch the priority of the messages going to append object? Kinda like saying "wait for the encapsulation [p] to finish processing and then send another list from [trigger l l] to [append]? Otherwise if it wasn't encapsulated I would have had the same problems with the resulted XOR being out of place (the penultimate instead of the last one)?

ygreq's icon

Thank you, Nicolas!