Magellan Linux

Contents of /trunk/hwinfo/emulate-ddcxinfo-knoppix.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1750 - (show annotations) (download) (as text)
Tue Apr 24 14:11:07 2012 UTC (12 years ago) by niro
File MIME type: application/x-sh
File size: 400 byte(s)
-be compat with old fallback behavoir
1 #!/bin/bash
2
3 case $1 in
4 -vsync)
5 vsync=$(hwinfo --monitor | grep "Vert. Sync" | sed 's:.*Vert.*Sync\ Range\:\ \(.*\)\ Hz:\1:')
6 if [[ -z ${vsync} ]]
7 then
8 echo "0-0"
9 else
10 echo "${vsync}"
11 fi
12 ;;
13
14 -hsync)
15 hsync=$(hwinfo --monitor | grep "Hor. Sync" | sed 's:.*Hor.*Sync\ Range\:\ \(.*\)\ kHz:\1:')
16 if [[ -z ${hsync} ]]
17 then
18 echo "0-0"
19 else
20 echo "${hsync}"
21 fi
22 ;;
23 esac