How to disable “turn off display after” when using Apple TV

appletvbatterydisplaysleep-wake

I have my Energy Saver->Battery->'Turn display off after:" set to 2 minutes. This setting is exactly how I want power settings to behave when I'm using the computer on my lap. However, when I hook up to Apple TV for a presentation it still shuts off after 2 minutes which disconnects apple TV and disrupts the presentation.

Is there a way to have a different Energy Saver setting when using Apple TV (or other external monitor)? I frequently switch between using Apple TV and not to the point that changing Energy Saver every time is a burden.

Using a 2015 Macbook Pro on El Capitan.

Best Answer

You can keep your Mac on forever when you need to (including while AirPlaying) without digging into settings if you download the Mac app Amphetamine. With Amphetamine, a button will appear on your Mac's menu bar. Just click it to prevent your Mac from sleeping indefinitely, and click it again to allow it to sleep. This is a very simple method of keeping your Mac on forever, especially useful while downloading a large file or—like you're doing—AirPlaying.

Alternatively, you can use macOS's built-in command line tool caffeinate to keep your Mac awake for longer periods.