Code: Select all
F1::PostMessage, 0x0112, 0xF170, % (i:=!i)?2:-1,, A ; << Press F1 to toggle On/Off
Code: Select all
F1::PostMessage, 0x0112, 0xF170, % (i:=!i)?2:-1,, A ; << Press F1 to toggle On/Off
Code: Select all
F1::PostMessage, 0x0112, 0xF170, % (i:=!i)?2:-1,, A ; << Press F1 to toggle On/Off
F2 Up:: ; << Press F2 to toggle On/Off
IF !F2 := !F2
Return
BlockInput, On
While, !GetKeyState("F2","P")
Sleep, 100
BlockInput, Off
Return
This script disables all monitors, mouse, and mouse pad. Unfortunately, the keyboard is still on. I'm sure it doesn't matter what kind of keyboard it is, but for what it's worth, it's a Corsair Vengeance K70 Blue.Rohwedder wrote: ↑13 Jun 2019, 04:06Code: Select all
F1::PostMessage, 0x0112, 0xF170, % (i:=!i)?2:-1,, A ; << Press F1 to toggle On/Off F2 Up:: ; << Press F2 to toggle On/Off IF !F2 := !F2 Return BlockInput, On While, !GetKeyState("F2","P") Sleep, 100 BlockInput, Off Return
I'm confused, so have some questions:Hitaku wrote: ↑13 Jun 2019, 12:12Very close! This script disables all monitors, mouse, and mouse pad. Unfortunately, the keyboard is still on. I'm sure it doesn't matter what kind of keyboard it is, but for what it's worth, it's a Corsair Vengeance K70 Blue.Rohwedder wrote: ↑13 Jun 2019, 04:06Code: Select all
F1::PostMessage, 0x0112, 0xF170, % (i:=!i)?2:-1,, A ; << Press F1 to toggle On/Off F2 Up:: ; << Press F2 to toggle On/Off IF !F2 := !F2 Return BlockInput, On While, !GetKeyState("F2","P") Sleep, 100 BlockInput, Off Return
I typically move my mouse to wake my devices. When I run the script it disables the lights, but I can still use the mouse to turn everything back on.1) If you disable the keyboard, how do you intend to wake your computer back up from sleep mode?
Usually people touch a key, then the computer wakes up from sleep because of that. Do you want to put everything to sleep, then wake it back up at a set time instead?
My computer has a lot of RGB lights, but when I go to sleep it's very distracting. Sometimes I want to keep my computer running over night to do something, so I wanted to make a keybind that turns off the lights / monitors.2) What difference does it make to include the keyboard, based on power consumption?
That's assuming that the purpose of the script is to put everything to sleep to save power, or do you have some other reason?
Users browsing this forum: No registered users and 336 guests