Acer 3400LMI User Manual

Size:
756.04 Kb
Download

F8­x86_64 on the Acer Ferrari 3400LMi

me was:

 

 

Button

X key-codeDefault X key symbols

Mail

236

-

WWW

178

-

Fn-F4

223

none, but triggers KPowersave suspend->RAM

Fn-F5

214

none, but generate a Capability changed event

 

 

that is received by the X-server.

Fn-F8

160

-

Fn-NumLk

77

Num_Lock

Fn-ScrLk

78

Scroll_Lock

Fn-Home

97

Home

Fn-End

103

End

Fn-up

176

-

Fn-down

174

-

These are the buttons that are the simplest to get working. Save these X key­ codes for future use. First we need to get the other keys to show up under X as well. In order for them to do so they need properly configured Linux key­codes that they lack for the moment.

8.1.2 Scan-codes

This step is different and considerable easier under F8 than FC4 or FC5. There is no need to shutdown X now as before.

2.Just press the desired key, ex. P1. Then take look at thedmesg output:

#dmesg | tail

atkbd.c: Unknown key pressed (translated set 2, code 0xf4 on isa0060/serio0).

atkbd.c: Use 'setkeycodes e074 <keycode>' to make it known. atkbd.c: Unknown key released (translated set 2, code 0xf4 on isa0060/serio0).

atkbd.c: Use 'setkeycodes e074 <keycode>' to make it known.

I got the following result:

11

F8­x86_64 on the Acer Ferrari 3400LMi

Button

scan-code

P1

e074

P2

e073

Fn-F1

e025

Fn-F2

e026

Fn-F3

e027

8.1.3 Linux key-codes

3.Next, figure out what Linux key­codes that are available by looking at the Linux scan­code – key­code mapping.

# getkeycodes

 

 

 

 

 

 

 

Plain scancodes

xx (hex) versus

keycodes (dec)

for 1­83

(0x01­0x53)

scancode

equals

keycode

0x50:

80

81

82

83

99

 

0

86

87

0x58:

88

117

0

0

95

183

184

185

0x60:

0

0

0

0

0

 

0

0

0

0x68:

0

0

0

0

0

 

0

0

0

0x70:

93

0

0

89

0

 

0

85

91

0x78:

90

92

0

94

0

124

121

0

Escaped scancodes e0 xx

(hex)

 

 

 

e0

00:

0

0

0

0

0

 

0

0

0

e0

08:

0

0

0

0

0

 

0

0

0

e0

10:

165

0

0

0

0

 

0

0

0

e0

18:

0

163

0

0

96

 

97

0

0

e0

20:

113

140

164

0

166

 

0

0

0

e0

28:

0

0

255

0

0

 

0

114

0

e0

30:

115

0

172

0

0

 

98

255

99

e0

38:

100

0

0

0

0

 

0

0

0

e0

40:

0

0

0

0

0

119

119

102

e0

48:

103

104

0

105

112

106

118

107

e0

50:

108

109

110

111

0

 

0

0

0

e0

58:

0

0

0

125

126

127

116

142

e0

60:

0

0

0

143

0

217

156

173

e0

68:

128

159

158

157

155

226

0

112

e0

70:

0

0

0

0

0

 

0

0

0

e0

78:

0

0

0

0

0

 

0

0

0

4.First we need to set a Linux key­code for the keys that lack one. Add the following lines to /etc/rc.d/rc.local to set the key­codes after all services are started.

# Set Linux key­codes for special keys & buttons:

#

12

F8­x86_64 on the Acer Ferrari 3400LMi

 

 

 

 

 

# Buttons:

P1

 

P2

 

 

 

setkeycodes

e074

151

e073

152

 

 

#

 

 

 

 

 

 

# Buttons:

Fn­F1

Fn­F2

Fn­F3

setkeycodes

e025

131

e026

132

e027

133

5.In order to avoid a restart to load these setting, issues the very same commands.

#setkeycodes e074 151 e073 152

#setkeycodes e025 131 e026 132 e027 133

8.1.4 X key-codesrevisited

6.Repeat step 1 and use xev to figure out what X key­codes these buttons got. I got the following:

Button

X key-code

P1

201

P2

146

Fn-F1

135

Fn-F2

140

Fn-F3

248

7.Ok, now we have X key­codes for all special keys & buttons and need to map them to proper key­symbols. In order to do that put the following in the file /etc/X11/Xmodmap:

! Acer Ferrari 3400Lmi special keys & buttons

!

 

! Button

X key­code

! ­­­­­­

­­­­­­­­­­

! Mail

236

! WWW

178

! P1

201

! P2

146

! Fn­F1

135

! Fn­F2

140

! Fn­F3

248

! Fn­F5

214

! Fn­F8

160

! Fn­up

176

! Fn­down

174

!

 

keycode 236

= XF86Mail

keycode 178

= XF86WWW

keycode 201

= XF86Launch1

keycode 146

= XF86Launch2

13

F8­x86_64 on the Acer Ferrari 3400LMi

keycode 135 = XF86Launch3 keycode 140 = XF86Launch4 keycode 248 = XF86Launch5 keycode 214 = XF86Display keycode 160 = XF86AudioMute

keycode 176 = XF86AudioRaiseVolume keycode 174 = XF86AudioLowerVolume

8.The setting above are loaded the next time X is started, but to load them without a restart of X do:

# xmodmap ­verbose /etc/X11/Xmodmap

...

!

! executing work queue

!

keycode 0xec = XF86Mail keycode 0xb2 = XF86WWW keycode 0xc9 = XF86Launch1 keycode 0x92 = XF86Launch2 keycode 0x87 = XF86Launch3 keycode 0x8c = XF86Launch4 keycode 0xf8 = XF86Launch5 keycode 0xd6 = XF86Display keycode 0xa0 = XF86AudioMute

keycode 0xb0 = XF86AudioRaiseVolume keycode 0xae = XF86AudioLowerVolume

8.1.5 Configure actions

9.Finally it is time to configure the button actions. Actions for all but the audio control keys are easily configured in the KDE Control Center ­> Regional & Accessibility ­> Keyboard Shortcuts under the tab Command Shortcuts.

10.However, you probably also want to configure the audio control buttons. This is done in the same manner inside KMix. Fire up KMix and go to the menu Settings/Configure Global Shortcuts...

11.If you want to use the Fn­F5 key to manipulate the graphical output, refer to the section 10 Graphics below.

9 CPU & ACPI support

A pleasant news is the advancements in ACPI support. Now all the desirable features are working right out of the box, without any configuration.

14

F8­x86_64 on the Acer Ferrari 3400LMi

9.1 Suspend

I am glad to see that both Suspend to Disk and Suspend to RAM works like a charm. Previous there has been a lot of struggle, if at all possible, to get a stable and reliable ACPI support. OK, I know that suspend has been around for a while by now, but hand on the heart ­ has it been user friendly and reliable? I have not had that experience. So a reliable ACPI support right out of the box feels really luxurious.

Even the special sleep key, Fn­F4, is configured during the installation and works as expected (Suspend to RAM). The power button works of course as well, as it always has done.

9.2 CPU frequency scaling

The CPU frequency scaling has been working for quite some time now. So it is no big surprise that it works out of the box in F8 on this puppy. However, it is always nice to see things evolve and improve. The improvements of the suspend functionality mentioned above together with solid CPU frequency management really shows off in power management.

KPowersave now feels really mature and has three pre­configured CPU policies: Performance, Dynamic and Powersave. Dynamic is the default and there is no real reason to change it.

10 Graphics

The advancement of Xorg and its related drivers and modules has been enormous the last two years. Fedora 8 includes Xorg 7.2 which is a welcome improvement in X­server configuration. Furthermore, there is absolutely no need to use the ATI proprietary driver any more. This is a true liberation, for sure I will not miss all the violations the proprietary ATI driver did to my Xorg configuration.

The graphical hardware is properly identified and setup during the installation, so you will enjoy X11 right from the start.

Another nice thing is that the dim display button, Fn­F6, works without any configurations.

10.1 Basics

The Ferrari 3400 is equipped with a ATI Mobility Radeon 9700 chip. This chip has 128MB of memory and provides two external outputs, VGA­0 and S­video. The built­in display is called LVDS. These names refer to the definitions used by the radeon X driver.

The graphical chip has 2 CRTCs, eg pipeline for rendering graphics. This means that only two outputs may be active simultaneously, either LVDS + VGA­0, LVDS

15

F8­x86_64 on the Acer Ferrari 3400LMi

+ S­video or VGA­0 + S­video. This is a common limitation for most graphics hardware.

Note: The output names differ depending on the driver used. The names used in this document relate to theradeon driver. If you use some other driver usexrandr ­q to find out the proper names (provided that it supports RandR).

10.1.1 The radeon driver

Support for the ATI Mobility Radeon 9700 chip in the Ferrari is provided by the radeon driver. This driver supports all the features we want: the RandR extension (v 1.2), 3D acceleration (DRI) and TV­out.

There is also the ati driver, not to be confused with the proprietaryfglrx driver. However, theati driver is only a wrapper that auto­detects ATI cards and load the appropriate driver. In our case that will result in theradeon driver being loaded.

The main improvement in Xorg 7.2 is the arrival of version 1.2 of the X RandR (Resize and Rotate) extension. It provides automatic discovery of modes together with the ability to configure outputs dynamically. As of today only a few drivers support RandR 1.2. Fortunately, the radeon driver is one of them.

10.1.2 Simple configuration

If you are familiar with X configuration and take a look at the default /etc/X11/xorg.conf file, generated during the installation you will notice a significant change. Many of the traditional settings, sync and refresh rates, modes and modelines, are gone. All these settings are now auto­detected by RandR 1.2 and should only be present if you want to override the detected values. In some rare situations this might be needed, e.g. when an external monitor reports incorrect values.

In order to get full dual­head support you only need to add one line to the default X configuration. If you want to optimize 3D acceleration you need another line. That is a total oftwo lines for a full fledge X configuration supporting all features. Quite an improvement. Thank you all nice X guys!

The X server log file /var/log/Xorg.0.log will be your valuable companion when it comes to troubleshooting or just checking what configuration that is auto­detected.

For reference my xorg.conf is presented inAppendix A.

10.2 Dual-Head

The X Resize and Rotate (RandR) extension introduces a significant shift in dual­ head configuration with its version 1.2. All your setting may now be altered on

16

F8­x86_64 on the Acer Ferrari 3400LMi

the fly by the command line tool xrandr, and there is no need to restart the X server.

10.2.1 Virtual screen size

RandR works its magic by means of a virtual screen that is larger than the a single monitor.

The size of the virtual screen is reported as the maximum value by the command:

# xrandr ­q

Screen 0: minimum 320 x 200, current 1400 x 1050, maximum 1400 x 1200

...

In this case the size is 1400x1200, which is the default virtual screen size for this setup. The default screen size is too small for serious dual­head configurations. This value needs to be increased by setting the Virtual option in the Display sub­ section in /etc/X11/xorg.conf:

SubSection "Display"

Viewport

0 0

Depth

24

Virtual

3000 2000

EndSubSection

This is the most (only) important setting needed in xorg.conf. However, in order to enjoy hardware support for 3D acceleration the virtual screen may not be larger than 3000x2000. This limitation differs for the various driver, but for theradeon driver the limitation is 3000x2000. This is sufficient for having an external monitor running at 1600x1200 side­by­side with your internal display as 1400x1050.

After modifying xorg.conf you need to restart your X server, ie. logout and logon again. Now, check your settings once again:

# xrandr ­q

 

 

 

 

 

Screen 0: minimum

320 x 200, current 1400 x 1050, maximum 3000 x 2000

VGA­0 connected (normal left inverted right x axis y axis)

1280x1024

59.9

 

 

 

 

1152x864

75.0

74.8

 

 

 

1024x768

84.9

75.1

70.1

60.0

43.5

832x624

74.6

 

 

 

 

800x600

84.9

72.2

75.0

60.3

56.2

640x480

84.6

75.0

72.8

66.7

60.0

720x400

87.8

70.1

 

 

 

LVDS connected 1400x1050+0+0 (normal left inverted right x axis y axis)

0mm x 0mm

 

 

1400x1050

60.0*+

 

1360x768

59.8

60.0

1280x800

60.0

 

1152x864

60.0

 

1280x768

60.0

 

17

F8­x86_64 on the Acer Ferrari 3400LMi

1280x720

60.0

1024x768

60.0

800x600

60.3

640x480

59.9

S­video disconnected (normal left inverted right x axis y axis)

In the xrandr ­q output above we see that the new virtual screen size is recognized in the maximum value. Furthermore, we see our three supported outputs, VGA­0 (external display), LVDS (internal display), S­video (TV­out). For the report above an external monitor is connected but not activated. Stillxrandr ­q reports its supported modes. Neat!

10.2.2 The xrandr tool

It is highly recommended that you read through the man page for xrandr and play with it a bit to get to know it. A good place to start is at the debian wikihttp://wiki.debian.org/XStrikeForce/HowToRandR12. It is a great tool that you most likely will find useful. Connect an external monitor and try the following commands.

Get a full report of the current status by:

# xrandr ­­verbose

Activate the external monitor with its default mode and mirror the internal display:

# xrandr ­­output VGA­0 ­­auto

Put the external monitor to the left of the internal panel with:

# xrandr ­­output VGA­0 ­­left­of LVDS

Change resolution and refresh rate of the external monitor:

# xrandr ­­output VGA­0 ­­mode 1024x768 ­­rate 60

Turn off the external monitor:

# xrandr ­­output VGA­0 ­­off

Set the TV­output in PAL mode instead of the default NTSC:

# xranrd ­­output S­video ­­set tv_standard pal

10.2.3 Fn-F5button

Once the virtual screen is configured and we feel confident in xrandr, it is time to focus on the Fn­F5 special button. By default it does nothing, but now we have the tools to configure it the way we want it to work.

First the Fn­F5 button needs to be recognized, so please refer to the section

8 Special keys & buttons above for the basic setup of the Fn­F5 button. After that

18

F8­x86_64 on the Acer Ferrari 3400LMi

we design a script to run once Fn­F5 is pressed.

The Fn­F5 button should provide a simple, basic and robust functionality that works for any external monitor. I prefer to toggle through the available connected external outputs, while keeping the internal monitor alive. Furthermore, each connected external output is present in two operating modes. First the external output mirrors the internal display, then it extends the desktop by operating side­by­side with the internal display. When both VGA­0 and S­video are connected the following operation modes are toggled each time Fn­F5 is pressed.

LVDS (single head)

LVDS + VGA­0 (mirror)

LVDS + VGA­0 (side­by­side)

LVDS + S­video (mirror)

LVDS + S­video (side­by­side)

If a certain external device is not connected those modes are skipped. Consequently, the sequence above will only appear when both VGA­0 and S­video are connected. With only VGA­0 connected the sequence will only include the first three modes from above.

Notice that the internal monitor may be dimmed at any time by pressing the Fn­F6 button. Thus, turning off the internal monitor is not included in the script. The script is outlined in Appendix B and may be downloaded athttp://ferrari.database.se/3400/f8/dual­head.sh.

The script also includes some other common operation to manipulate the graphical outputs. To see all supported operations, try:

dual­head.sh help

Binding this script to the Fn­F5 button is then configured in the KDE Control Center ­> Regional & Accessibility ­> Input Actions.

If you run a more permanent dual­head setup you may want to configure the preferred default settings in xorg.conf. This is done by the Monitor sections and the lines

Option ”Monitor­<output>” “...”

in the Device section of the xorg.conf file.

10.3 3D acceleration

3D hardware acceleration is provided by the dri module. This module is loaded by default by theradeon driver, so no additional configuration is needed inxorg.conf to get hardware support for 3D. However, any possible optimizations that might improve performance are desirable.

19

F8­x86_64 on the Acer Ferrari 3400LMi

10.3.1 Simple benchmark

In order to compare different settings we need some kind of benchmark tool. A simple tool that comes with the glx­utils package found in most distributions isglxgears. It may be rough, rudimentary and lacking a lot of hype features, but it is present and sufficient for our needs.

An interesting exercise is to explicitly disable hardware acceleration and comparing the result with the default xorg.conf. Without hardware accelerationglxgears clocks in around a modest frame rate of 150 FPS, compared with approximately 2050 FPS for the default configuration. This is quite a difference, and it verifies that theradeon driver really does its job.

10.3.2 Optimization

The default values for most settings work well and there is no needed to modify xorg.conf. Furthermore, most of the other settings are correctly auto­detected, such as AGP 8x and memory. All this is reported by the X server in its log file

/var/log/Xorg.0.log during startup.

The options of most interest for performance are AccelMethod (default XAA),AGPMode (auto­detected),ColorTiling (default on) andEnablePageFlip (default off). The first three are correct by default, but due to instability in rare casesEnablePageFlip is disabled by default.

Turning on the option EnablePageFlip inxorg.conf reveals no flaws. I have not noticed any glitches with this option on my setup so I feel confident in recommending it. Then the obvious questionHow good is it? It is good!

glxgears gives us an indication. By enablingEnablePageFlip performance is increased from 2050 FPS to about 3270 FPS. A significant boost for tweaking one single option.

You only need to add one line to the Device section in the default xorg.conf to boost 3D performance:

Section "Device"

 

 

Identifier

"Videocard0"

 

Driver

"radeon"

 

Option

"EnablePageFlip"

"1"

EndSection

 

 

10.3.3 Other observations

During the optimization procedures a few interesting observations were made. Primarily the CPU speed does not seem to matter. Most tests were run with the CPU frequency first set to 800MHz, then repeated at 2000MHz. No significant difference related to the CPU speed was noticed.

Furthermore, the size of the configured virtual screen does not affect

20