dima schreef:
Hi. Batch for easy reboot, sleep mode, power off. ;-)
echo off
cls
SET fdapm=D:\FDOS\BIN\fdapm.com
SET flag=C:\TEMP\flag0000.000
for FDAPM, you could also search the path if the file exists.
for %%x in ( %path% ) do if exist %%x\fdapm.com set fdapm=%%x\fdapm.com
FDAPM's location determined by a variable, but CHOICE's location not?
echo Чего изволишь?
echo [40;31;1m [R] Перезагрузка
echo [40;36;1m [S] Спать
echo [40;33;1m [P] Выключить питание
echo [40;35;1m [V] Монитор в режим низкого энергопотребления
echo [0m [x] Передумал, выйти.
D:\FDOS\BIN\CHOICE.EXE /c:rspvx Выбирай:
my Russian (?) isn't very good, and you're using ANSI Escape-sequences
which require NANSI.SYS installed?
:Power
if exist %flag% del %flag%
%fdapm% PowerOff
goto exit
what file uses temporary file %flag%?
it doesn't seem to get deleted after ending the batchfile.
Nonetheless a nice batchfile for powersaving on real systems.
FDAPM will probably have a nice command for a CPU IDLE as well, which I
can use in VMware.
Bernd
-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user