<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>DaviTools &#187; Utilities</title>
	<atom:link href="http://www.davitools.com/category/utilities/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.davitools.com</link>
	<description></description>
	<lastBuildDate>Sun, 13 Sep 2020 07:33:12 +0000</lastBuildDate>
	<language>en-US</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=4.0</generator>
	<item>
		<title>Sleep button for the SteelSeries APEX M500 keyboard</title>
		<link>http://www.davitools.com/qsleep-with-the-steelseries-apex-m500-keyboard/</link>
		<comments>http://www.davitools.com/qsleep-with-the-steelseries-apex-m500-keyboard/#comments</comments>
		<pubDate>Thu, 09 Mar 2017 13:00:27 +0000</pubDate>
		<dc:creator><![CDATA[david]]></dc:creator>
				<category><![CDATA[Utilities]]></category>

		<guid isPermaLink="false">http://www.davitools.com/?p=171</guid>
		<description><![CDATA[After nearly 15 years I retired my old Cherry keyboard and bought a new SteelSeries APEX MX500 keyboard with Cherry MX Red switches. My old Cherry keyboard had a nice sleep button, wich I used all the time. The SteelSeries keyboard has a very minimalistic design and has no sleep button. I decided to resort [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>After nearly 15 years I retired my old Cherry keyboard and bought a new SteelSeries APEX MX500 keyboard with Cherry MX Red switches.</p>
<figure id="attachment_174" style="width: 600px;" class="wp-caption alignnone"><a href="http://www.davitools.com/wp-content/uploads/apex-mx500.jpg"><img class="size-full wp-image-174" src="http://www.davitools.com/wp-content/uploads/apex-mx500.jpg" alt="APEX MX500" width="600" height="281" /></a><figcaption class="wp-caption-text">APEX MX500</figcaption></figure>
<p>My old Cherry keyboard had a nice sleep button, wich I used all the time. The SteelSeries keyboard has a very minimalistic design and has no sleep button.</p>
<p>I decided to resort to an autohotkey hotkey to suspend the machine. I did not want to see the console executing the script so I made a VB executable that runs invisible. It is a Windows Forms application that hides the form on Load and executes Application.SetSuspendState. Just very simple.</p>
<pre>Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
   Me.Visible = False
   Application.SetSuspendState(PowerState.Hibernate, False, True)
   Me.Close()
End Sub</pre>
<p>I compiled a version for hibernate and another for sleep.</p>
<p>The autohotkey script is reacting to the Pause button for sleep and Alt+Pause for hibernate</p>
<pre>; Run qsleep.exe on Pause key
Pause::
   Run, c:\util\davitools\qsleep.exe
Return

; Run qhibernate.exe on Alt+Pause key
!Pause::
   Run, c:\util\davitools\qhibernate.exe
Return</pre>
<p>So now I can hit the Pause button to send the computer to sleep just like in the old days with my Cherry keyboard.</p>
<p>I made a zip with both QSleep.exe and QHibernate.exe, and the source code so you can inspect and build the tools yourself. I also included the autohotkey script.</p>
<p><a title="Download qsleep.7z" href="http://www.davitools.com/download/qsleep/qsleep.7z">Download QSleep.7z</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.davitools.com/qsleep-with-the-steelseries-apex-m500-keyboard/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
