Shutdown the notebook computer within 60 seconds in case it was accidentally powered-on by a drop or shock.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
COPYING
README
iDidNotPressPower.cpp
iDidNotPressPower.h
iDidNotPressPower.pro
iDidNotPressPower.ui
main.cpp
ui_iDidNotPressPower.h

README

About
-----------
iDidNotPressPower is used to shutdown the notebook computer within 60 seconds in case it was accidentally powered-on by a drop or shock - it would cancel the countdown and exit if user moves the mouse cursor.

iDidNotPressPower is developed for both Ubuntu GNU/Linux and Windows.

The original version was developed and deployed at http://www.clearevo.com/
Source code is hosted at http://github.com/ykasidit/iDidNotPressPower/

The little program was made because the developer and his friends had sometimes experienced that their notebooks accidentally booted in their notebook-bag when it was hit or dropped, then the notebook became VERY dangerously hot as it powered and stayed on in a closed bag without air flow - so this little app was coded to make sure the user actually booted the notebook intentionally - and moves the mouse - otherwise it would shutdown the notebook in 60 Seconds.


THIS PROGRAM USES QT 4.5 (LGPL) DYNAMICALLY LINKED
--------------------------------------------------
You can get qt source code and its licenses from http://qt.nokia.com/downloads


Compiling
-----------
This project was developed and built via "Qt Eclipse Integration for C++" please see more info at:
http://qt.nokia.com/developer/eclipse-integration

To make a release build, right click project > properties > C/C++ make project > Make Builder tab > Build: release (default would be "debug")  

Installing
----------

- Your notebook must be set to auto-login.

GNU/Linux:
1. Get and install Qt 4.5, compile it. 
OR
1. Use the (Ubuntu) compiled binary, make sure you have libqtcore4 and libqtgui4 installed (run in terminal: sudo apt-get install libqtcore4 libqtgui4).
2. Allow it to execute: chmod +x iDidNotPressPower, test running it: ./iDidNotPressPower
3. Make a new file, rename it as autoshut.sh, chmod +x autoshut.sh. This app must be run as root (because "halt" needs 
root), edit your sh to contain something like:

echo "mypassword" | sudo -S /home/<your user>/<folder>/iDidNotPressPower

4.  Add to computer startup, for example, in ubuntu "session and startup" add a new one and copy the autoshut.sh file in the file browser, paste it into "command" so you'll get the file path (remove file:// if present), or enter something like:
/home/<your user>/<folder>/autoshut.sh

Windows:
1. Get and install Qt 4.5, compile it.
OR
1. Use the compiled binary windows release zip, the qt lib dlls should be included, try double-click the iDidNotPressPower.exe.
2. Create a shortcut to iDidNotPressPower.exe, put the shortcut in the "Startup" folder. (Go to Start > All Programs > right-click "Startup" then "Open" - if would be like "C:\Documents and Settings\<User>\Start Menu\Programs\Startup")

License
-----------
Copyright (C) 2009 Kasidit Yusuf.

This file is part of iDidNotPressPower.

iDidNotPressPower is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

iDidNotPressPower is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with iDidNotPressPower.  If not, see <http://www.gnu.org/licenses/>.