annotate TVout/matroxtv @ 2487:ac3c0836aaa1

hope it's not too buggy, and overall useful
author gabucino
date Fri, 26 Oct 2001 17:20:33 +0000
parents
children 383a4f3870e0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2487
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
1 #!/bin/sh
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
2 # Gabucino - no warranty
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
3 # you need fbset, and matroxfb modules loaded
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
4
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
5 # mode to use on the monitor in "1-Monitor only" and "4-Dualhead" mode
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
6 # (from /etc/fb.modes)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
7 DEFAULTMODE="768x576-60"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
8
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
9 #echo "You didn't check this file for possible mis-configurations ! :)"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
10 #exit 1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
11
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
12 while [ 1 ]; do
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
13
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
14 clear
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
15
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
16 echo " [ 1 ] Monitor only"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
17 echo " [ 2 ] Cloning - CRTC1 to Monitor and TV"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
18 echo " [ 3 ] Dualhead - CRTC1 to Monitor, CRTC2 to TV"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
19
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
20 #echo " [ 4 ] Cloning - CRTC2 to Monitor and TV"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
21 #echo " [ 5 ] Dualhead - CRTC2 to Monitor, CRTC1 to TV"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
22
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
23 echo
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
24
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
25 #echo " [ Q ] All consoles to fb0"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
26 #echo " [ W ] tty3 to fb1"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
27 #echo
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
28
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
29 echo " [ A ] 640x512"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
30 echo " [ S ] 640x528"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
31 echo " [ D ] 720x576"
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
32
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
33 read ABC
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
34
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
35 case "$ABC" in
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
36 1)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
37 matroxset -f /dev/fb1 -m 0
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
38 matroxset -f /dev/fb0 -m 1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
39 fbset -a -fb /dev/fb0 $DEFAULTMODE
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
40 echo
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
41 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
42
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
43 2)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
44 matroxset -f /dev/fb1 -m 0
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
45 matroxset -f /dev/fb0 -m 3
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
46 matroxset 1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
47 # 640x512
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
48 fbset -fb /dev/fb1 -left 60 -right 0 -upper 70 -lower 39 -hslen 76 -vslen 4 -xres 640 -yres 512 -bcast true
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
49 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
50
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
51
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
52 3)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
53 fbset -a -fb /dev/fb0 $DEFAULTMODE
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
54 echo
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
55 matroxset -f /dev/fb0 -m 0
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
56 matroxset -f /dev/fb1 -m 2
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
57 matroxset -f /dev/fb0 -m 1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
58 matroxset 1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
59 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
60
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
61 4)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
62 matroxset -f /dev/fb0 -m 0
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
63 matroxset -f /dev/fb1 -m 3
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
64 matroxset 1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
65 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
66
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
67 5)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
68 matroxset -f /dev/fb1 -m 0
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
69 matroxset -f /dev/fb0 -m 2
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
70 matroxset -f /dev/fb1 -m 1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
71 matroxset 1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
72 # 640x512
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
73 fbset -fb /dev/fb1 -left 60 -right 0 -upper 70 -lower 39 -hslen 76 -vslen 4 -xres 640 -yres 512 -bcast true
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
74 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
75
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
76 q)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
77 con2fb /dev/fb0 /dev/tty1
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
78 con2fb /dev/fb0 /dev/tty2
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
79 con2fb /dev/fb0 /dev/tty3
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
80 con2fb /dev/fb0 /dev/tty4
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
81 con2fb /dev/fb0 /dev/tty5
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
82 con2fb /dev/fb0 /dev/tty6
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
83 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
84
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
85 w)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
86 con2fb /dev/fb1 /dev/tty3
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
87 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
88
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
89 a)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
90 # 640x512
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
91 fbset -fb /dev/fb1 -left 60 -right 0 -upper 70 -lower 39 -hslen 76 -vslen 4 -xres 640 -yres 512 -bcast true
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
92 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
93
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
94 s)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
95 # 640x528
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
96 fbset -fb /dev/fb1 -left 40 -right 0 -upper 63 -lower 29 -hslen 56 -vslen 4 -xres 640 -yres 528 -vxres 640 -vyres 528 -depth 32 -laced false -bcast true
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
97 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
98
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
99 d)
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
100 # 720x576
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
101 fbset -fb /dev/fb1 -left 54 -right -36 -upper 55 -lower -6 -hslen 46 -vslen 4 -xres 720 -yres 576 -vxres 720 -vyres 576 -depth 32 -laced false -bcast true
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
102 ;;
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
103
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
104 esac
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
105
ac3c0836aaa1 hope it's not too buggy, and overall useful
gabucino
parents:
diff changeset
106 done