YouTube/zsteinkamp/Your First Max for Live Device Build a WavScope
Properties
- tags
- Tutorial, c74/M4L, GitHub/zsteinkamp/m4l-WavScope
- created-date
- 2024/11
- 00:00 hey there thanks for joining me again today I'm Zach and I make things for Ableton Live I'm doing a little detour today my previous videos have been about some devices that I've created giving tours or example usage but um I've learned a lot from people on YouTube about making things in mac and thought I could maybe do something too um and so I had a I I made a device uh the other week and uh it's useful and it's pretty easy to make um what it is is it's uh this wave scope and all it does is show you a picture of the wave as it goes by in a track and one cool use case that I found is to put it before and after in effect and then you can see visually the effect of the effect on the sound and so
- 00:45 like for example we can throw it before and after this saturator and see that what goes in is different than what comes out and we can see that visually um we can adjust the duration of The View that we have here from like two bars in this case to you know a 64th note and that just kind of gives us like an oscilloscope sort of view so let's get into making it let's check it out so I'm going to just delete these devices and go to the max for live section here and drag a Max audio effect uh into my channel and from here I can hit this edit button and that takes us into max I'm going to do this kind of as a new user tutorial so I'm going to explain some basic stuff here about Max and Max for live okay the first thing
- 01:36 that we want to do is get this ready for presentation mode and you'll see what that means in a second and so let's get started by hitting command I that turns on this info pane um
- and this is a weird thing about Max I really don't like the ux on this but to get to the properties of this whole device you have to click this P icon here the Patcher inspector
- and once you click it basically that'll come that view will come back when you click on the background
- in my opinion that should just be the default okay so uh what do we need to change here uh we need to change this uh first of all I like to turn on Snap to pixel and open and presentation um and if we pick that some stuff goes away from here uh if I save
- 02:22 this device now and let's save this as a scoper the device in life goes to nothing and if I switch into presentation mode in Max we see that it's empty uh and so we will put some things in here to uh show up in our device and so let's get started and we can in two seconds make a useful device here and so we're going to create a couple of objects called live. scope and uh what this does is it visualizes the waveform of anything any signal coming in and in this in our case it's the audio signal coming through our device and the way that we can make it work is by connecting one of the outputs from the plugin object which comes in by default to the left Inlet of the live. scope um and now if I just play some
- 03:16 stuff Hey look it's already useful um if I switch into presentation mode we're still empty and so the way to add something to presentation mode is to select it in the info panel check the includ in presentation Che check box uh and now when we switch to presentation mode there it is and now we can drag it around let's just put it like up here in the corner and save it and here we've got it showing up in live and let's do one other thing uh let's connect the other uh we connected the left let's connect the right to a second one so we can see both left and right waveforms separately so I'm just holding down alt and dragging on this object that makes a copy uh so I'll just connect the signal from the right Outlet
- 04:01 of plug in to the left Inlet of live. scope um switch to presentation mode I'm going to arrange these kind of top and bottom here and have them you know roughly the same size I'll save this and now we've got two Scopes in the view in live and let's check it out so we've got that's cool um and we can see the left and right let's put uh low con um turn on the mixer put the low Conga to the right put the mid Conga to the left and [Music] um okay that works we'll go back to Max and we'll go cool so I'll just close this window in Max you can have one of these let's put another one after and now we've got our cool kind of before and after Vis visualization um you could be done at this point
- 05:00 you could have your first max device at this point um but uh the original device that we were looking at um lets us control the the time view of this uh of these displays and so let's add that that's not too hard um and we'll learn more about Max this way so the first thing I want to do before I get into that is I want to clean up this junk there's always this junk that comes in when you make a new device in live so I'm going to just um select the plug out shift select the plugin move them over here and then I can just draw a rectangle around the junk and hit delete and now they're gone okay so now we've got a clean slate okay so what we need is a a knob to control the zoom level of these scope
- 05:49 devices and so that's called a live. dial and one thing I do all the time in Max and I think everybody does does is you want to kind of learn how things work by using them and one really great way to see like what's coming out of something is to use a message object you can create a message object by double clicking the background and typing message and hitting enter and now you can uh have your message object but once you do this a whole bunch uh you'll learn the shortcut which is to click somewhere where you want the message to be and then hit the letter M and now you've got a message and if you collect something to the right right Inlet of a message that just sets the value of the
- 06:33 message the other so if I try to move this dial oh this thing is moving around well what you need to do is hold down the command key and probably control on Windows while you're trying to move the dial and now you can move the dial and now we can see the value of that dial coming out the Dial's left Outlet going into the right Inlet of the message and setting the value of this message object here from the value of the dial so what we need to do is customize this dial for its purpose so I'm with it selected hit command I again to bring up the info panel the first thing I like to do when I create a new object is to give it a sensible name so let's call this one like uh time and link to scripting name I don't
- 07:13 know why I do that but I do that and time uh its type this is very important instead of being a float which is indicated with a decimal point after a number um is to change it to an enum because what we want is uh we want to have like note value values coming through here um as selections and so by default the enims are zero and one and so if I move this dial enough we get to zero and see there's no in between it's just either zero or one uh but you can put anything you want in this list and so let's let's just add some note values um and we're making note values that um double in length every time so we've got from a 64th notee 32nd 16th 8th fourth half whole note uh two notes and four
- 08:11 notes and we'll hit enter and now if I'm holding on command and moving this dial now I can see all those values that I put in and we can see what's coming out of the left Outlet now is an integer you can tell it's an integer because it doesn't have a decimal point uh and it's basically the position of that dial uh starting at zero uh okay so how do we get from an integer to something these Scopes understand um in Max uh you can hold down option or alt and click on an object to see help on that object what we want to pay attention to here is uh this attribute called samples and this says sets the numbers of samples to capture let's play around with that a little bit so uh I can create a new
- 08:58 message here and say samples and then give it a number like a thousand so that's a fairly low number for samples and so if I attach this to this Scope Play some stuff they're moving both moving slowly but if I command click this the other way can do uh is uh command click the background now the whole Patcher is locked you can see the lock icon in the in the corner here uh and now you can click on things without holding down command but I don't like to switch between modes more than I need to so I just command click I've always got my fingers on the keyboard uh so if I command click this samples 1000 message which is connected to the left Inlet of this scope uh and then play some notes look
- 09:41 this top one is like an oscilloscope while the bottom one is still slow if I connect this to the bottom one and hit it again now they're both the same okay so what I need to do is translate from our note value here to a number of samples and we're going to take a a little slightly windy road to get there so there's an object called translate that's going to help us with this but we still have a little windy road um so we can say translate and I'm just going to look at the help for it so uh I'm just going to make the object and then alt click on it we've got translate here and it says it converts from any of the fixed or relative Max time values to any of the other fixed or relative time view values
- 10:25 that's super cool so uh let's see what we mean by time values so now we have this Max reference thing that opens up um time value syntax is what we're interested in here what we want to do is focus on ticks here and a tick is a 480th of a quarter note so that's kind of cool now we're starting to get into some math um and here we have a a handy little table of like oh a 64th note is 30 ticks a 30 second note is 60 ticks oh okay so uh we're doubling the time from a 64th to a 30 second note and we're doubling the number of ticks so we go 30 60 uh 120 for a 16th note and so on so we can use a little bit of math here to get from this integer to uh the right number of ticks to go here and uh you
- 11:18 can use a an object called exper and what we're going to do I it took me a while to figure this out but I'm just going to show you I won't show you the toil of figuring it out um there's a uh power function here so we we want to take two to the power of the first integer that you receive in this Inlet work with me here on this so we'll take it step by step so I'm going to connect the dial to this exper and then I'm going to connect uh this message box because we don't oh no I'll copy it um so we've got zero coming out of the dial that goes through this function and saying 2 to the power of 0 which is one that's handy we've got one coming out and 2 to the power of 1 is 2 4 8 16 blah blah blah 2 the Power of
- 12:13 5 is 32 so we're getting closer uh we've got 1 2 4 um and we actually want this one to be 30 the two to be 60 the four to be 120 well what are we doing for all those numbers we're just multiplying this number by 30 so we can add that time 30 here and so now when I move this dial hey look we're getting the correct tick numbers now so if I go to like a quarter note we're getting 480 coming out of here and that's perfect and so what we need to do is change this translate object from ticks ticks to samples and so I'm going to alt drag another this message box down here connect this Outlet connect this one to this guy put it over here change this and look we're getting something that looks like a reasonable number of
- 13:09 samples coming out of this translate object we're getting closer what we need to do is say samples and then that number uh and so one way we can do that I'm just going to alt drag this to copy it is instead of 1000 we can say dollar one and let's just bring this down connect this and connect this like this so we're getting some number of samples coming out of translate it goes into this message using this syntax we're saying the first element of anything coming in here uh add it to this word samples and then if we move the dial now we're getting samples and then the number so here we are this is exactly where we want to be so I'm going to delete this let's make some space uh now I'm going to take the output of
- 14:02 the samples and send it to both of these scope devices so if I uh oh there's one thing we need to do before we go use it is in presentation mode our time dial goes away so we need to rightclick here's the other way to add it to presentation it's probably faster than hunting in the in the in the inspector over here is just right click add to presentation switch to presentation View and put put it where you want it to be let's put it here uh we can save this and close it go back to live now we've got oh we need to move it well that ain't working why doesn't it work let's see we've got this coming through here we're saying samples what the heck oh okay I see the problem the problem is is we're sending
- 15:06 this into the right Inlet which only sets the value it doesn't actually Echo the value out the left Outlet so what we need to do is instead of sending this to the right Inlet of this message we send it here and in fact we don't need this in the middle anymore and here's one cool trick if you hold down with something selected if you hold down shift and drag on it it'll just kind of pull it out of the the wires so let's try this again close my device here go back to live and there we [Music] go so now you've got something where uh even if I change the tempo I'm moving changing the tempo I'm using my push for that and if I decrease the tempo it'll go slower so it's already Tempo aware so again at this point you could
- 15:55 be done uh you have a very functional device you can still um put a second copy here and uh we're defaulting to a 64th that's something to bookmark to look at um but you know here you are and now you can see uh the before and after and you have a a time zoom control here but you know maybe maybe the next level of usefulness is well maybe I want these things to be linked together uh maybe when I change this to a half note I want this other one to change to a half note just so that they're both operating the same for me as the tool that I want them to be um so let's add that and we'll learn some more about Max that way so I'll delete the second one I'll click the edit button of this one
- 16:44 again and uh we're going to exit Pat Uh presentation mode go back to patching mode and okay we're going to add a button a toggle that's going to link this device to other instances of the device and so there's uh there's some stuff to put in here so uh we're going to double click here and add a live. text which is a strange name for something that's a user interface button or toggle but cool um that's what it is and so I'm going to get rid of these things um Okay so we've got this uh live. text and at the very bottom of the inspe we've got text off Lael and text on Lael and we want both of those to be Link Link well let's set the name just for good hygiene um so link to scripting name
- 17:43 call it link call it link now it's link um and let's see how this works so I'm going to make a new message I'm going to click here and hit M and then connect the left Outlet to the right Inlet of the message and then holding down command I'll click on this link and we see when it's on and yellow it's emitting a one and when it's off it's emitting a zero so uh we can use that to uh control whether or not we're synchronizing this with uh other instances so let's just get into making how this works and and we'll learn along the way so I'm going to use something called a gate uh which uh it says pass input to an outlet and U if I hover over this we we see if we send a zero to this Inlet it'll close the gate non zero
- 18:33 opens the outlet opens the outlet and if we hover over the outlet it says it's currently closed and what's this one incoming gated messages okay this is cool so what we can do is uh use the output of this link going to the left Inlet of the gate so that uh if I turn on link if I hover over here we say currently open and if I turn that off it says currently closed so that's cool and what we can do is take the output of this dial uh and I'm going to just slide this message over here and so with link off if I change the dial nothing's coming through the gate with link on if I change the dial now the dial value is coming through so we can use this to our advantage here um so let's get rid of these things now so
- 19:26 what what we need to do is we need to send this value to other instances of this device in the live set if link is enabled there's a natural way to do this in Max for live um called send and what you do is you you send to a named Channel and so we're going to name this uh link scoper uh this will make more sense in in a couple minutes here so one thing I like to do with my sends is set a border color so they stand out um and if I alt drag here I'll make a [Music] receive and let me create a message here and add that and so if uh with the link enabled if I change this time without having a direct wired connection to this message box we're having that value teleport between the send and receive
- 20:23 end points here uh and it works just as if there was a a cable in between um just as an illustration what I'm going to do is uh right click add this message to the presentation view just so we can see this working um so I'm going to put this here and go back to patching View and save it and now I'll close the device so we've got um that working uh if I add another one to the set and change this we see this dial is not moving but this message is updating and that's because let me delete this one open editing when we send this value all instances of the device receive what's sent to that uh that channel that named Channel and so this will no matter where it is in no matter what device it's in
- 21:21 it'll update um now this isn't always what you want uh and then this is one of these like sneaky little things in Max that you just have to learn if you prepend the name with three dashes and then I'll put three dashes here I'll save this close the device put a new instance here uh we've got um so if I move this dial uh the one on the left here is changing the one on the right's not because the three dashes are behind the scenes translated to a unique number for this device instance and uh and that that number replaces the dashes in the channel name and so that's a way to the three dashes are a way to keep a send receive pair private to an instance of a device uh but in this case which is probably not
- 22:22 the normal case in Max for live we don't want the three dashes be because we want this message broadcast pass out to all devices okay we've got our send and receive pair and what do we want to do when we receive this we want to uh update the dial value and let's think let's think this through if we just connect the receive to the left Inlet of our time dial what's going to happen is I'm going to change the dial the number comes out this wire goes into the gate goes out the gate goes to the send comes back up here to the receive goes into the dial changing this value will emit the value again and we're going to have an infinite Loop and so uh what we need to do at this point is to uh figure out well how can we how
- 23:14 can we change what this dial is pointing out without actually having it emit its value again out this Outlet if we look at the uh the help for this we can see we can send a message to the dial set set a value without causing output that sounds perfect for what we're trying so let's do that so just like we did with the dollar one on the message here we can say or I'll just alt drag this um and change samples to set and then if I'm dragging and hold down and then hold down shift that can jam this in the middle of a chord and so here we've got our receive uh going to the set who uh will just change the uh position of the knob without causing output and an infinite Loop and that's what we want
- 24:06 um however uh just setting the dial position doesn't actually change the the samples that are set to the scope um and so we still need to um essentially send that new number into this expression object uh so we're going to set the dial and then we're going to send the number here and so there's another common Max object that you'll see all the time called trigger which I use to just sort of fan out a message to be to be processed in a specific order you'll see what that means here so I'm triggering uh two integers here and so if I receive this um let's just see what what we've got here um so I'll just connect uh I'll make a copy connect it to both Outlets of the trigger link is
- 25:05 enabled I'll change the dial and we see uh both of those uh messages are uh receiving that new integer and so uh what we need to do is send the first one so I'm going to move this stuff down I'm G to sh click this shift drag it out delete this patching wire or this cord uh we want set to happen first and here's another another thing that you're just going to have to learn about Max is uh the out the data comes out uh right to left and so this right one will happen before this left one happens and so we that's very important in many cases to uh do things in a specific order and so in this case what we want to do it's not so critical but we want to set the value the position of that knob
- 26:02 first and then we want to send that number into this expression box I keep moving these around one thing about making Max patches is you can just have like crazy unmanageable spaghetti very easily um I've learned to just take my time when creating these patches and organize them visually sensibly and simply using Color I I like to keep keep wires straight where I can I like to have a consistent vertical uh Rhythm uh I like to have space around things and use comments and things like that to label them um and so uh let's do a little bit of that so uh just like with a message you can hit M uh you can also click on the background and hit C for a comment and let's say calculate the number of ticks for the
- 26:55 given knob index by raising the index or raising 2 to the power of the index uh something like that um and personally I like to use uh this uh freeze color for uh for comments that for me that just visually stands out better than if it's white uh makes it easier for me to see where the comments are okay so what we can do is change this value we see everything working properly we're not getting any errors if there was an infinite Loop we would get an error here in Max okay so we are receiving this but if the let's let's imagine we've got two of these devices one has link enabled one does not if we change the time zoom in the one that has link enabled it's going to send out this channel the one who doesn't have it
- 27:57 enabled is going to still receive it and all this stuff is going to happen uh and so we what we need is another one of these Gates uh in between the receive and like kind of the action of the receive so let's give it some space move it up uh select this holding down shift now we're jammed in the middle here but we want this to go to the messages Inlet and then link is going to also be connected to this gate so we've got uh link up here connected to the two Gates this gate is controlling whether or not changes to this dial are sent and broadcast this gate is controlling whether or not okay now a a number has been broadcast are we going to pay attention to it and so the answer is yes
- 28:44 in both cases according to the only if this link is enabled okay so let's try this now so I think we're close to having something that works really well uh oh the link disappeared so we need to add that to the presentation so I'm going to right click choose add to presentation go to presentation mode and move this let's put it here and give this a little bit of more space and we're going to save it and uh close this device back in Live still works we're on an eighth quarter half let's put another one here um okay that one's unlined if we link it and move this look now both are moving in lock step um and both Scopes are responding uh as they should so we're in good shape here so again you could be
- 29:41 done you have a very functional device at this point good to go um but you know there's always something else to do let's do some cool stuff with it here let's put some let's put some uh let's put some peanut butter on it so um uh let's edit it again and maybe one cool thing to do would be to have a control of maybe a just a visual vertical Zoom uh for these waveform displays uh and that's a real easy thing to do and so we would want a dial to control that and what that dial is going to do is the value that comes out of the dial we will multiply with the signal value or let's let's look at what is a signal anyway so I'm going to create a number Tilda anything with a Tilda in Max is signals
- 30:31 so signals are like audio rate data uh they're these special uh fancy chords regular old chords passing messages and numbers and stuff like that operate at a lower data rate and they're represented more plainly so if we connect this plug in to the signal what are we seeing we're seeing numbers uh when it's silent at zero when we see uh when we get audio through there where and louder audio it's going closer to one or closer to negative 1 depending on where that wave is deviating from zero so that's all it is it's just a data stream of floating Point numbers between -1 and one and if we look at the properties for one of these Scopes we can see that its range is 1 to 1 so these things are kind of made by default
- 31:21 to work together um and so what we could do is we could multiply this number by some Factor that you decide you the user decide uh through a knob uh to scale what we're sending to these Scopes we're not changing the audio that's coming through here uh the plugin is connected directly to the plug out let's start with a live. dial as usual we go down here link to scripting name give it a long name let's call it scale short name which is actually the one that's displayed scale and then it's a FL that's cool cuz we want it we want this to be like a multiplier um and maybe we want it to go from like 0.1 to 10 um that feels exponential um so let's move this or oh that's still acting like
- 32:13 an integer that's because the unit style here is set to int so let's change it to float and so now we're at the minimum 0.1 and if we move it up uh we've got floating Point numbers being displayed now so good uh but I'm not too happy with the range like I I really want this like from 0.1 to one should have a lot more distance on this dial and so uh thankfully this is a common problem in music stuff some things have an exponential relationship some things have a linear relationship we have control over that stuff here uh we can control that through this exponent so if we look at what range we're trying to capture it's 0.1 to one to 10 uh that's three power of 10 involved this my
- 33:02 little shortcut so if I give an exponent of three uh now we can see how this dial responds so now with this uh you know almost the full uh half of the range is now consumed from 0.1 to one and then the second half is from 1 to 10 in an exponential fashion and in using this knob in this case this feels right but you can also come back always come back and tune this exponent depending on how you want to use it uh so uh let's again uh connect this to a message and just see what's coming out all right it's just the number that's being displayed that's cool um and so we can create an object called which is a signal multiplier so we want to multiply but in a signal context and the Tilda again is
- 33:49 signal stuff multiply two signals uh you can also you don't have to give it two signals you can give it a signal and a float um so we've got uh we need to connect this to here let's by default we'll multiply by one uh connecting to the right Inlet of this um changes the number that we're multiplying uh the signal with so now we just need to put the signal connection put it in the path of the signal connection to the scope so I'm going to just go like this maybe make it a little prettier let's take this out um I can option or alt drag this to copy it and shift to jam it in the middle there and now I'll connect the dial to this one also uh we'll rightclick this add to presentation go
- 34:45 to presentation mode let's put our scale dial right here save it uh let's try it so oops I'm going to just lock this [Music] so we hear the volume's not changing but what we're doing is scaling scaling the display and so we could save this uh close this window again here we are we've got a very useful device usable device works great um we can have multiple instances their time zooms are linked oh I had to click that well that's something to fix isn't it and it also defaulted to a 64th note so let's let's fix some defaults here um so we're we start in presentation mode uh command I to show the inspector uh this link button if we scroll to the bottom uh every every parameter sort of object has these
- 35:50 options of initial enable and initial value so we want to enable an initial value and the initial value should be one one in this case meaning the button is on um if we save this and close this device now when we add a new one a second instance to our track here that link button is now turned on so that's what we wanted but we're still at a 64th which is not what we wanted um so let's go back and edit um command option e it's a gives you carpel tunnel syndrome but you'll uh maybe soon enough learn to use it all the time to switch so you don't have to hunt for this little button for presentation mode command option e toggles between patching and presentation mode um so uh what we want
- 36:38 to do is set a default for this time dial and so I'm going to make a new message here connect it to the right Inlet um and we I'm doing this so that I can get the value the default value that we want so maybe by default we want it to be like a whole note and so that's index number six uh so command I again for the inspector go all the way down initial enable oh and because we're on six it picked it already so we didn't need to do that inspection but okay so we can get rid of that now we're defaulting to a whole note how about a default scale initial enable let's set that default to one that seems pretty reasonable save that close this window we're back in live um I'll just add a second one here
- 37:28 and here we are all our defaults are just as we want them so scale is one uh and also double clicking a parameter will return it to its default value okay uh so again here we are you've got something that uh said it's defaults are good you can use it um but maybe we can get a little bit cooler with the display this is just one last thing that we could do uh with it um both of our channels are the same color here that's maybe less interesting than it could be let's talk about colors in Max for live um you'll notice that these color swatches have a name on them uh if I click this uh waveform active line color if I click this we are in a Dynamic Color if I do this drop down we've got
- 38:16 all the colors from the current live theme here and so this is in my opinion the way to make Max for live devices is to use these colors appropriately and then whatever theme the user has are going to carry through into your device and the usability is going to be good the legibility is going to be good now but you may be of the of the sort who's like no I want a specific visual language to my plugins if you maybe see what you're doing more like building little vsts for live maybe you want to use your own color palette here great you know just make sure that it's legible in different live themes light and dark uh because sometimes you know if you're using one of these Dynamic
- 38:57 Color and it's a text color and it's a if it's a light gray in your current theme but in a user's theme that may be a different color so you got to make sure that if you got to go all the way one way or the other either all in on the live colors or all in on your own custom colors and there's really no in between there um so for this case uh we are with LCD text icon um so let's there's a similar one so we've got LCD text icon here and we've got LCD text icon variant that sounds like the perfect name for what we're trying to do here um so we'll make the bottom one blue um and we can save that oh that's the top one let's just swap these so that visually they're more correct but we want to make
- 39:44 something kind of kind of nifty here visually and maybe give a toggle for it I'll show you what I mean um so we've got two waveforms and we're seeing the positive and negative of each U maybe it's a cool sort of view to have them be sort of two Hales of one seeming waveform uh and so what we can do is we can play with this range and so for the one on the top maybe I only want to visualize from like 0 to one and now see our our line is at the bottom and for the one on the bottom maybe I want it its range to be uh -1 to zero and now the line's at the top and so if I save this uh close this go back to live we can see here's our two lines and so they're kind of like one way form
- 40:35 going by and there's a little Gap let's fix that um so uh I'm just on my trackpad I'm just uh like open pinching to zoom in um and let's move this up a couple or one pixel we'll move this down one pixel now they're right next to each other I'll shift click both of them command I for the inspector let's make them not round round see these boxes are round have rounded Corners uh let's just drag this nine down to zero now they have sharp Corners so I'm looking at this box here presentation rectangle 0 0 18482 so that's x y withd height and this one uh X Y width height X is one so we want to move that over 0 84 82 so this one's 82 tall this one's 84 tall let's make them both 80 uh
- 41:28 84 tall well I think that's good I just uh pinch to zoom back out and let's close our window here after saving it and that's cool so now there's no Gap it takes the full height uh that works pretty well um but maybe you know maybe in some cases you want this View and maybe in some cases you want that separate view so we'll go back to the editor We'll add another little toggle button to toggle between this View and the original view that we were working working with um so exiting presentation mode command option e and then I'm just going to alt drag this link button command I for the inspector uh we need to change its name uh so we're going to call it uh uh split and join split
- 42:22 join and so its two states uh are going to be let's see when it's off we're going to be in Split mode and in on we're going to be in join mode uh and so now if I click this split join split join split join and again if I visualize what the output is here uh join is one split is zero okay so how can we make wire this button up to to change how these Scopes look and one way you can do that if we if we click the scope we have this range uh option and many Max devices if you just send a message with the name of the the parameter or the attribute you want to change um then uh you can just send that message to the device and it will uh or to the object and it'll change so like we could do
- 43:16 range minus one to one and let's use decimal points to tell Max that we're doing floats so if I connect this to both of these and then command and click it now they're both back to normal how they were before uh so I'm going to make two copies here and so this one is going to be range 0 to one and this one's going to be range netive 1 to 0 and I can attach these to their appropriate Scopes so if I click command click this here we are back there here we are back there here we are back there so now we just need to make it so that um when split goes from 0er to one and so that would be join mode uh we want both of these messages to fire when we go back to split mode we want just this
- 44:06 one to Fire and the way we can do that is with this uh object called cell which is Select and we just want to say cell zero so check this out so if I connect the split to the left inl of cell zero and then I'm going to make two messages one for that or sorry put it on the right put it on the right we've got a one that shows up here because what's this Outlet if it's the input if the input doesn't match zero in this case this one sends a bang if the input matches zero so if we go back to split we got a bang here so we're going to get a bang here or a one here uh depending on the state of that button so if I send this bang to here uh that bang will Trigg trigger this range -11 to go out and to be sent
- 44:59 to both Scopes that's cool uh this one uh we can just connect directly to both of these message objects even though a one is coming out we're not using a dollar one in these messages and we're going into the left Inlet so just that one happening is a lot like a bang just a little poke um and it's going to cause that message object to emit its current message out its left Outlet um so now we can see um if we I'm holding down command and clicking this join now these are right here split now they're back in the middle uh I'm going to rightclick this it should already be in presentation because I copied this one and I'll go to presentation mode and place it where we want to in our UI let's just do it like
- 45:48 here and let's give that a little bit more space on top and we'll save that uh let's close the device here and check check it out so we've got we're in Split mode we're in join mode split join uh let's make another instance we can be doing this we can scale each one independently uh we can split and join them [Music] independently and let's delete that and I think the last step here once what I do is when I get to a place of functionality that I like I look for opportunity unities to kind of clean this up comment it make it make sense because I guarantee the next time I open this I'm not going to remember all the context that I have right now uh having just made it um and so you know here we
- 46:41 can say like uh toggle whether the Scopes are um in Split mode or join mode visually um um and yeah you could probably clean this up a little better uh maybe I won't take all the time to do that okay so there were some uh fundamentals of Max and Max for live in this uh little tutorial and you've got a very usable useful device out of it uh let me know what you think what other ideas do you have for a device like this you can go Hog Wild um maybe a spectrum view maybe a true oscilloscope view uh the scope object support something like that you know you name it you make it uh share what you've done let's see it uh anyhow hope you have a great one and uh until next time take care bye