 In this video, I'm going to show you how to automate the ending of an extra long live stream using keyboard maestro. Hello, welcome to Take One Tech, my name's Alec. And today I'm answering a question that was asked by Rich, who wanted to know how can we end a live stream after specifically 10 hours, but this will work for any particular length. Now, why would you want to do that? And why would you want it to be automated? Well, the length of the stream may give it away, that he's not actually going to be sitting there for 10 hours behind his computer doing this live stream. It is something that's just going to be running in the background. And specifically, it is, at least I'm assuming, this is the use case, because I know that he does do some with this. It would be where you have these continuous streams that are playing background music and things like that. So there's lots of these sorts of channels around doing that. And in fact, I'll leave a link to his channel just up in the top corner as well, where this is happening, where it's basically a continuous stream of music. And then there are, and in fact, in his case, it's from Epidemic. And then there is also a playlist that is shown as well. So it will actually show you the track that is put up, I believe. But in any case, in the background, as well as the music, there is also a cycling series of sort of animated overlays as well, going on in ECAM. Now, with animated overlays and with scenes, obviously in ECAM, you can just have a timer that is set to advance to the next scene, or you could have a timer that is set to end the broadcast when the timer runs out. So in theory, what you could do is just chain together all of these scenes and then have the final scene be the one that ends the stream. Okay, in principle, but the only issue is that these video clips or these animations are only about 30 seconds to a minute long. So even at a minute long, if you were wanting to run this for 10 hours, then that would essentially be a chain of 600 scenes. And they're also going to be duplicating. So that would mean that if you, because there's not 600 individual scenes, unique scenes, it is going to be basically a case of creating the initial loop and then just duplicating it. So it's going to be quite bloated from ECAM's point of view, so not really the ideal solution. Also, if you did want to go and sort of change up the animations and things like that, then it would involve going in and sort of replacing multiple copies of the same one and so on. So not exactly the most elegant, as I say. So what we want to do is basically have all of the looping scenes that we want in ECAM, but then we want to automate the ending of the stream. Now we can actually automate the starting and the ending as well. And so we're going to do that in Keyboard Maestro. So first, let's just have a very quick look at what I have done in ECAM. So if I come over to my demo mode, basically what we've got is timed stream demo. I've not actually put anything in here because it's irrelevant really for the demo, but if you've got a folder where you have multiple scenes in the folder, then basically if you start one scene and you've got a timer to go to the next scene, once you get to the very last scene, it will come all the way back round to the beginning. So you could still have this within a profile that had got other scenes in. So this is the one that I'm in at the moment. But if you activated the scene one and had a timer to go to the next, the next, the next, the next, then when it got to scene five, it would just loop back round to the beginning. So let's just assume that we've got five scenes that we just want to loop for 10 hours basically. So this is the way that that would be set up. I did do another video actually all about this. So I'll leave a link to that in the top corner. But for now, let's head over to Keyboard Maestro and have a look at the next step. So what we wanna do in Keyboard Maestro, now that we've assuming we've got scenes set up, is I'm going to, and I'll leave a link to my very first introduction video to Keyboard Maestro up in the top corner, just for those that are unaware of how to use it. But we're gonna go through something really basic today. So basically in Keyboard Maestro, just a quick recap in the interface, you've got groups here, this column, which is basically just groups of macros. So this is how you sort of organize all of your automations. And then within each folder or group, we have then got all of the macros that are contained within that. So I've got different ones grouped related to Keynote, related to different businesses, related to different applications and things like that. And so in each of these folders, there is a group of macros, which is listed here. And then when you click on any one of these macros, it will then tell you what the trigger is for that macro and the action that is going to take place. So I'm not gonna go in, as I say, to a full overview of Keyboard Maestro, but that in a nutshell is what we're looking at here with this interface. So I'm gonna create a new group for this, which I'm going to call timed stream demo. And then now that I've created this folder, we can leave all these settings just exactly as they are. I explained them in the first video that I've linked to, so I won't go through all of those. But basically, we're just setting up a folder with the default settings here. Now, what I'm gonna do is I'm gonna add in ultimately two macros, but I'll start with the first one. And I'm gonna just name this, when you add in a macro, it automatically highlights the macro name. So I'm gonna call this one start stream like that. And then what we're gonna do is add a trigger. Now, you can have lots of different types of trigger, actually, so we can have it the common one that I guess people use is a hotkey. So you want it that when you press a hotkey, like command S for command start or something like that, although that would be command save, wouldn't it, that would be save rather. So yeah, just you can use a hotkey, but you can also have all these other different types of triggers. Again, I talked about this in the first video, but what we're gonna have a look at today is specifically somewhere down here is further down the list. There is quite a lot of them. So this one, time of day trigger. So here we can set the time. And these are usually used, this type of macro or this type of trigger rather, is usually used for routine tasks. So for example, you might want to have something starting at two o'clock in the morning in the middle of the night to start a routine. Obviously probably not good for me because I tend to wake up at three. So I would do it at a slightly different time. But what I mean is you can use this to schedule routine tasks that are gonna happen maybe in the background, or you might have it that before you get in to start work, if you start work at a particular time, you might want it to start up a load of applications ready for when you get there at a particular time. So that's the use case for these timed starts. I'm just gonna leave this actually at 8.30 just for the time being. And let's say that the day that this is for is a Monday. So we can just block out, as you can see, just select the days. So basically at 8.30 on a Monday is when this is gonna trigger. Now this will trigger every Monday. So what you would want to do if you just wanted to use it like on an ad hoc basis, if I just quickly come back to the actual folder, here you can see whether you can enable it or disable it. And you'll notice that when I disable it, then we've got this sort of light blue folder rather than the dark blue folder. Don't know if you can make that out, but it is a, and the actual name of it is grayed out as well. Much like these ones here are grayed out because they're not active. But if you click enable, then it will be enabled. So once we've set this all up, you'll basically enable it when you want to use it to initiate your stream and then toggle it off when you want to end it. So anyway, I digress slightly. We've now set our start time, but now we want to tell it actually what we're going to do. So in keyboard maestro, this is the triggers and you can add multiple triggers, but we'll just stick with this one. And then down here is where you're gonna add in the action. So this is what you're actually going to be triggering when it triggers, what action's gonna happen. So we're gonna click on this new action and it'll bring up all of the list of potential actions. And they are sort of categorized here. So you'll notice that what's happened here is it's covered up these two columns with a new set of two columns so that you don't get confused. Click on new action, you'll see how it just slides up from the bottom. So this now is the categories of all of the different actions. And if you go into all actions, you can see all of the different types of actions that you could actually trigger. And there is a lot of them, which is why some people find keyboard maestro a little bit daunting, because they think, oh, there's loads of different actions. I'll never be able to learn all of those. Well, the fact is you only need to learn the one that you need for that particular task. And I don't use the majority of these. It's just when I want to use something, I'll be able to go in and find the particular thing that I want to do. So don't be put off by the fact that there is a very large number of potential actions. All it means is if you can think of something you want to do with keyboard maestro, you can probably do it. So in any case, let us have a search because you might think, well, how are we gonna find it? Well, there is a cunning little search box up here. So what we want to do is when the start time is triggered, then we want to basically activate something in Ecamm Live. We want it to start recording and or in fact, start live streaming, isn't it? But that is just a menu item. So the start recording and recording, start live streaming and live streaming is just a command in the menu of Ecamm Live. So there is an action that you can have in keyboard maestro. If I just type menu, there's only two related to menu. So we've already got rid of that daunting list. And it's either one of these two. Show status menu, that's not what we want, or select or show a menu item. Well, we want to select the menu item to start live streaming or end live streaming. So let's click on start that, start a menu item, select a menu item. Again, all my S is mixed up. Now you can either drag it into this little area here, which is quite useful when you end up with a big stack of actions because you can chain actions together. So there are instances where you might want to drag this and just drop it into a particular place in the chain. But for our purposes, you can also just double click it and it'll just add it to the bottom. And since there's nothing else in the list, it's just exactly where we want it. So now what we're gonna do is we've got some settings that we can change with this. So this is the same with any keyboard maestro macro. Once you've added it in, there are lots of different ways that you can adjust it. So here we're gonna go to select front application. Well, we actually want a specific application because we want to trigger Ecamm Live. So I'm gonna come down here and it'll have all of the apps that you've got open listed. So if you are wanting to trigger something in another application, make sure you do have the app open. But we're gonna select Ecamm Live, or the beta as it is, because that's the one that I use. Now, if you know the particular menu item that you want, you can actually add that in here. So the menu title, that would be the actual name that appears in the menu bar on the Mac. And the menu item is the sub item. And as you can see, there's a little plus. So we can actually add a whole chain. So if you've got something where it was, you know, in a nested folder within the menu stack, then you can add those in as well. There is another way that you can get to it if you don't wanna actually type it out. Cause if you get the name wrong, obviously, then it won't be able to trigger because it will be trying to trigger something that doesn't exist. So cunningly, they have added this little menu button here. And from here, you can basically go down to any app. So I'm gonna go down to Ecamm Live. And you can see now it's listing all of the different menus that come along the top of the menu bar. So we've got the Apple menu, which is obviously in every app. Then you've got the main application menu, and then we've got edit, profile, scene, source, and so on. So these are all just the Ecamm Live menus. Now we want to start and stop the recording or the live stream rather. Now, because I am in record mode at the moment in Ecamm Live, then it actually changes the menu slightly of Ecamm Live. So what you'll see is I've either got begin recording or end recording. I'm gonna select that one for now. But in actual fact, to start a live stream, if we've got live stream selected as the output of Ecamm Live, what that would say, rather than begin recording, it would actually say begin live session. So I'm just gonna go and edit that now because obviously I'm recording at the moment. If you were setting this up yourself, then just make sure you've got it into Ecamm Live, the destination to be streaming, and then you'd just be able to pick the correct item out of the menu. It's only because I'm currently recording to make this video that it doesn't show up, if that makes sense. So there we go. We've got the, basically it's gonna start recording at 8.30. And what we could actually do though, if you remember I created those scenes one, two, three and four and five, just to be sure that you do start at the beginning, perhaps what I could also do is have it so that at the beginning it goes to scene one first. So at 8.30 it does actually change to scene one and then it starts the recording. That might be just an extra little failsafe just in case you weren't in the correct scene or weren't in the correct scene in the folder or maybe you were in a scene outside of the folder. So let's just do that, shall we? And we can actually do that just by duplicating this. So if I duplicate action, like that, and I'm gonna adjust the top one because we want it to change scene first. So what I can do here is if I come to my menu and then I'll go to Ecamm Live and then I'll go down to scene and then let's have a little look where is it. It is the timed stream demo and scene one. So can you see that's the folder that I've got with all of my, those scenes that I created. And so if I go to scene one, there we go. It's just one extra little step. So now when the timer hits 8.30 it's going to basically go to scene one and then it'll start the stream. So now what we need to do is let's just close that down. It can sometimes catch you out by the way that this window sort of looks like the window that's underneath it. So these are all the actions. So just click this little cross button here to get rid of the actions and then you'll see we're back to our group of macros and the macros within that group. So now what we want to do is actually do want to end the stream. And now what we could do here is actually just duplicate this one. So I'm gonna duplicate and I'm gonna change that to end stream. And then I'm gonna change the time on this. So if it's 10 hours, then basically we want that finishing at 18.30 on the same day. We can get rid of this one because we don't want any scenes to be changed. So you just click in it and then delete any ones that any actions that you don't want. And then here what we need to do is instead of begin live stream we can actually just go and change that to end live stream. And that essentially is it. So if you wanted to do this on an ad hoc basis you would just go in and change the particular time and the date. So all the day rather that you're on and it would just start and it would stop it at that time. And that in a nutshell is how you would do that with keyboard maestro. One thing just to remind you once again is do come into the folder and after the stream's finished if you don't want this to happen every Monday or every day or whatever it is you would just toggle that one off and then it would be inactive. And you would know that it's inactive because it would be grayed out. So I hope that has helped. Whoops, Daisy, come back to the wrong scene there. If you've found this useful obviously I don't need to tell you what to do. Although I probably will do. Go down, leave a comment, leave a like and subscribe to the channel if you haven't already subscribed. And don't forget to turn on notifications as well because you wouldn't want to miss one of my videos or live streams. And so that is all for this video. But what I'll do is I'll leave a link to some other Ecam Live and Keyboard Maestro. In fact, Keyboard Maestro videos over on the right hand side. Until the next video, have a great day.