Forums > MaxMSP

Boolean invert (Not gate)

Sep 25 2012 | 1:06 am

I’ve got a patch that’s set up so that if I press a button on my launchpad it will assign a cell on an 8×8 matrixctrl. I want to be able to toggle ther cells using the launchpad buttons, so I’ve set up a checking system that uses getrow to create a list of what is on and what is off, and then use if statements to create binary switches that’ll turn a cell on or off depending on its current state

The problem is that if I press one button and then press the one next to it the if statements don’t update straight away, so I have to press the button twice.

Could anyone see where I’m going wrong?

Many thanks

  1. Untitled2.maxpat
Sep 25 2012 | 8:43 am

try this:

-- Pasted Max Patch, click to expand. --

you had a catch 22 situation where you need access the info before you know what it is. study the trigger object to carefully assign the correct message ordering that is needed: I made a different approach where you use == and zl mth instead of trying to switch according to not-yet-known status…

Sep 25 2012 | 11:35 am

Thanks so much! I’ve only been using Max about a week so I’m not familiar with most of the elements yet. This helps a lot, I can begin tidying up the other parts of this project now =]

Viewing 3 posts - 1 through 3 (of 3 total)

Forums > MaxMSP