Loading...

Zufälliges Bild

thumbnail
Blumenherz

Menu [toggle]

Quick Edit a Wiki Page

Tikiwiki Assistant

Thank you for installing Tikiwiki!

LoginTo begin configuring Tiki, please login as the Admin.

The Tikiwiki CommunityTo learn more, visit: http://www.tikiwiki.org.

Tikiwiki DocumentationFor help, visit http://doc.tikiwiki.org.

Impressum [toggle]


CVitC Limited
the Computer Vitamin C
Wormser Str.45
D-67227 Frankenthal
Germany
phone: [+49|0]6233/3185454
fax: [+49|0]6233/3185456
mail: cvitc(at)global-social(dot)net
Director: Raphael Gradenwitz

Registered in England and Wales
Company No.: 6675582
Registered Office:
69 Great Hampton Street
B186EW Birmingham
Great Britain

Hauptniederlassung in Deutschland:
CVitC Limited
das Computer Vitamin C
Wormser Str.45
67227 Frankenthal (Pfalz)
Tel: 06233/3185454
Fax: 06233/3185456
Mail: cvitc(at)global-social(punkt)net
Vertretungsberechtigter Geschäftsführer:
Raphael Gradenwitz

Amtsgericht Ludwigshafen
HRB 61266
Ust.Id Nr.: DE262558412
Blog: sony-vaio-z-series
Description: Skripts and tips about how to run Linux on Sony Vaio Z-Series laptops
Created by ernolf1997 Punkte  on Thu 01 of Oct., 2009 00:11 CEST
Last post Sun 06 of Dec., 2009 18:41 CET
(2 Posts | 20791 Visits | Activity=2.00)
Find:

Setup the microphone under Ubuntu Karmic

Posted by admin on Thu 08 of Oct., 2009 02:40 CEST

 

Setup the microphone

Meanwhile this became obsolete since the microphone simply works out of the box with newest kernel and alsa/asound >=1.0.20.
If you encounter trouble with the microphone, you can try this:
check if amixer is on board and if not, apt-get install it:

which amixer >/dev/null || sudo apt-get install alsa-utils

Next, open gnome-session-properties (as normal user, not as root):

gnome-session-properties

and add this command to the autostart list:

Name:        Fix Microphone Input
Command:  amixer sset 'Input Source' 'Int DMic' >/dev/null 2>&1
Comment:   switch microphone to the right input

after the next boot, the microphone should work.

© Raphael Gradenwitz

Share this page:

 Digg  del.icio.us  Blinklist  Furl  Reddit  Blogmarks  Magnolia  Sphere  Yahoo!  Technorati  Blue Dot  Simpy  Newsvine  Stumble Upon  co.mments.com  Blinkbits  BlogMemes  Connotea  Mister Wong  Facebook  Google 


The content on this page is licensed under the terms of the CreativeCommons .


Permalink 0 comments Print Email This Post

Switching between intel and nvidia graphic chip with Debian or Ubuntu Linux

Posted by ernolf1997 Punkte  on Thu 01 of Oct., 2009 05:43 CEST

Switching Intel <=> nVidia

STAMINA-SPEED

The goal:

.. of this How-To is to setup a system where one only have to switch the  °STAMINA <=> SPEED°  slider before a (re)boot, without any other steps needed to be done. The System will boot with only one of both graphic chips activated (intel in stamina-, nvidia in speed-mode). The respectively other one will be powered off by acpi.
The scripts, specially developed to make this how-to easy to reconstruct, will do the detection during startup, and link the required shared libraries depending on what graphic chipset rather is activated.
There are different solutions for switching the hybrid graphics. One of them is the Sony-Solution for Windows Vista which needs a diferent initialized acpi as we need it for this solution used on Linux. That is the reason why this does not work 100% when prior to Linux, Windows Vista was booted and vice versa, Vista does not work 100% when prior to Vista, Linux was booted but the second boot on the same systems will result in a 100% working solution. Hot-switching like in Vista is not yet possible under Linux.

Prerequisites:

  • Either Ubuntu Jaunty Jackalope, Debian Lenny (5.0) or Squeeze (6.0) yet without upstart (sysv-rc init.d scripts).
  • or Ubuntu Karmic Koala or Lucid Lynx (development branch) with:
    "upstart" (replacement for-/ successor from "sysv-rc") and "grub2" (the successor from - for distinction now called - "grub-legacy").
  • Some of the newest BIOSes as needed for Windows 7 (e.g. R2170M3) is reported to make difficulties. I use an unlocked R2168M3 with installed Vista and no Windows 7. If you want to switch between Windows 7 and linux, please read this excellent blog from Peter Fern. You can additionally report your experiences in the vaio-z-series mailing list mailto:sony-vaio-z-series@lists.launchpad.net
  • The Vaio Z must be connected to the internet (port 80-http and 21-ftp).
  • No old switching scripts or mechanisms from other websites or 'solution designers'.
  • you should understand the Kernel Commandline and what it does - before you install the sony-VGN-Zseries-janitor script that than will install all the rest for you. So please read this part carefully:

The Kernel Commandline:

Deprecated (only Kernel <= 2.6.31-11-generic): to make the backlight Fn-keys (Fn-F5 and Fn-F6) as well as the Brightness Applet working (Intel only), try to add "acpi_backlight=vendor" to the kernel command line.

To make the acpi work like set with the  °STAMINA <=> SPEED°  switch, add acpi_osi="!Windows 2006" to the kernel command line. This will set the _OSI section of the DSDT table, (a file located in a hardware eeprom) and force the ACPI not to uninitialize it at shutdown (like acpi_osi="Windows 2006" (=Vista) or acpi_osi=Linux would do) to make it on next boot do its job.

If you use grub2, add to /etc/default/grub:

GRUB_CMDLINE_LINUX="acpi_osi=\\\"!Windows 2006\\\""

.. and run sudo update-grub to create a new /boot/grub/grub.cfg

Deprecated (Only if you still use grub (legacy) as bootmanager):

  • sudo gedit /boot/grub/menu.lst

  • search the kernel-command-line for your actual kernel, (line begins with 'kernel        /vmlinuz-...')
  • append:

    acpi_osi="!Windows 2006"

    with the quotes ("..") to protect the space between Windows and 2006.
  • To make this permanent, edit the line that begins "# defoptions=" (yes, it looks like a comment).

NOTE: before the nvidia driver from your distribution can be installed, acpi_osi="!Windows 2006" should not be added (you can simply remove it, press 'e' in the grub shell, see below next indention) since it will hide the nvidia hardware (makes it invisible for lspci) which makes driver installation with the jockey script impossible. If you want to install the driver directly from the nvidia ftp-server (the janitor script will give you that choice) the acpi_osi="!Windows 2006" can - no - should be active. In both cases you should run the janitor script in stamina mode when you want to install the nvidia driver.

Edit the Kernel Commandline in the Grub-Shell:

In the Grub Shell, directly after booting the Vaio-Z, you can edit the highlighted Kernel by pressing 'e', then you can manually remove the acpi_osi="!Windows 2006" (there the quotes are escaped like this: acpi_osi=\"!Windows 2006\"). That will change the acpi in the Session after the next boot.

YOU MUST REBOOT TWICE FOR acpi_osi="!Windows 2006" (or its removal) TO TAKE EFFECT.

Install and maintain with the sony-VGN-Zseries-janitor browse source script:

If you meet the above eligibility, this script can/will do an almost complete installation:

Install the file sony-VGN-Zseries-janitor browse source :

sudo wget -NP /usr/local/bin/ http://global-social.net/files/sony-VGN-Zseries-janitor

.. make it executable:

sudo chmod 0755 /usr/local/bin/sony-VGN-Zseries-janitor

.. and run it (as normal User):

sony-VGN-Zseries-janitor

..this will popup for gksudo and run verbose in an xterm-window, providing information about what it exactly does.

That will ascertain that everything is on its right place. It installs/upgrades:

  • launcher in application-menu and on desktop
  • the sony-laptop kernel module from Norbert Preining or (for Kernel < 2.6.31) from Eva Brucherseifer
  • the rfkill-applet from Norbert Preining
  • the nvidia driver (you can choose: using the jockey-gtk or jockey-kde script or install from the nvidia ftp-server)
  • creates the right xorg.conf backups which are used in later switch mechanism.
  • the symlink /usr/local/sbin/switch-x-to pointing to /usr/share/sony-laptop/switch-x-to script browse source that switches the xorg.conf and GL-Libraries depending to the connected graphic-chipset.
  • the required upstart-jobs /etc/init/switch-x-to.conf and /etc/init/nvidia-settings.conf (if your system does not yet use upstart - the init.d scripts /etc/init.d/switch-x-to and /etc/init.d/nvidia-settings) with the "what-graphic-chip-is-active" detection code to invoke the switch-x-to with the right arguments.
  • the default-file /etc/default/switch-x-to (see below).
  • the symlink /usr/local/bin/acpi_create_nv_event pointing to /usr/share/sony-laptop/acpi_create_nv_event script browse source to assign the Fn-F5/Fn-F6 key-combinations to the LCD-backlight under nVidida GPU
  • sanitize old unused files.

To make a complicated xorg.conf-file unnecessary (after nvidia installation is ready and everything is running well) one can use nvidia-settings as root (sudo nvidia-settings) or as normal user, make the settings you want and then save them in an rc-file. Now enter the path to this rc-file into /etc/default/switch-x-to

Special sony-laptop kernel module:

NOTE: this step (kernel-module installation and upgrading) is automated with the sony-VGN-Zseries-janitor script.

We need a 'sony_laptop' module that is a little bit different from the vanilla module shipped with the distribution:

sony-laptop-zseries-0.9np5.tar.gz     thanks to Norbert Preining for maintaining this: Norbert Preining's Software projects
If you use a Kernel < 2.6.31 you need the previous module from Eva Brucherseifer build it like described in the shipped README)

build it with dkms which auto-build the module after each kernel update. If you don't use the sony-VGN-Zseries-janitor script, here the steps to be done:

sony-laptop module installation with dkms


  • First create (as root: sudo -i) a directory mkdir -p /usr/share/sony-laptop and unpack the source into there. It should look like:

/usr/share/sony-laptop/sony-laptop-zseries-0.9np5

  • uninstall eventually previously installed builds. You can test if it was already build with dkms before with
          dkms status | grep sony-laptop-zseries
    If that echoes you some output, then it was previously build already with dkms and must be completely removed from the dkms build-tree, (in this example the before installed version was 0.9np2):
    • in case it was already build and installed with dkms, (as root):
    • dkms remove -m sony-laptop-zseries -v 0.9np2 --all

      it should echo something like this:

      -------- Uninstall Beginning --------
      Module:  sony-laptop-zseries
      Version: 0.9np2
      Kernel:  $kernel-version
      -------------------------------------

      Status: Before uninstall, this module version was ACTIVE on this kernel.

      sony-laptop.ko:
       - Uninstallation
         - Deleting from: /lib/modules/$kernel-version/updates/dkms/
       - Original module
         - No original module was found for this module on this kernel.
         - Use the dkms install command to reinstall any previous module version.
      depmod........

      DKMS: uninstall Completed.

      ------------------------------
      Deleting module version: 0.9np2
      completely from the DKMS tree.
      ------------------------------
      Done.

    • only in case it was installed but not yet with dkms, (as root):
    • cd /usr/share/sony-laptop/sony-laptop-zseries-0.9np2/
      make uninstall


      ..your path may differ from the one in this example.

  • next create a symlink (still root):

ln -sf ../share/sony-laptop/sony-laptop-zseries-0.9np5 /usr/src/sony-laptop-zseries-0.9np5

(of course, unpacking directly in /usr/src is possible too)

  • Now add the new module-source to the dkms watchlist (as root):

dkms add -m sony-laptop-zseries -v 0.9np5

it should echo:

Creating symlink /var/lib/dkms/sony-laptop-zseries/0.9np5/source ->
                 /usr/src/sony-laptop-zseries-0.9np5

DKMS: add Completed.

  • run the autobuild-script to do the rest:

/etc/init.d/dkms_autoinstaller start

Now, if you followed these steps, the new module should be build and installed for the actual kernel and will be auto-buildt after each kernel update!

It must be loaded with "options sony-laptop speed_stamina=3". The following lines will ensure this option is added at the right place if not yet done before. NOTE: this step is automated with the sony-VGN-Zseries-janitor script. If you don't use the sony-VGN-Zseries-janitor script, here the steps to be done:

First run sudo -i to get root:

sudo -i

Now copy and paste this 4 lines of code in the root-shell:

oi='false'; o='options sony-laptop speed_stamina=3'
for cf in ${m:=/etc/modprobe.d}/*.conf; do
grep -q "^$o$" $cf && oi='true'; done
$oi || echo "$o">>$m/sony-laptop.conf

Exit from root-shell:

exit

Tuning the intel driver acceleration (optional):

The intel-driver is extremely fast since Kernel-Mode-Setting is enabled by default (which is since kernel 2.6.30-10.12). You can try additional the new uxa acceleration (the successor from the exa- and even older xaa-acceleration):

  • The file /etc/X11/xorg.conf needs a line with

    Option        "AccelMethod" "uxa"

    in the Device section. Here my xorg.conf for the intel graphics-chipset:

Section "Device"
    Identifier    "Configured Video Device"
    Option        "AccelMethod" "uxa"
EndSection

Section "Monitor"
    Identifier    "Configured Monitor"
EndSection

Section "Screen"
    Identifier    "Default Screen"
    Monitor       "Configured Monitor"
    Device        "Configured Video Device"
EndSection

Note:

The new X server on Karmic doesn't need an xorg.conf file anymore rather gathering the devices with dbus. It may be (still) installed if your Karmic is an upgrade from Jaunty. You can build your own though if you need it or want to add something like these acceleration experiments. If it is present, it wil be parsed.

Make sure everything is running well. The acceleration should be enough to activate all visual effects like Compiz-Fusion. You can mesure the speed (in frames per ± 5,0 seconds) for 2D/3D-Animation with glxgears and gather informations about OpenGL with sudo glxinfo.
If you want to delve deeper into the matter: the intel-gpu-tools is a package of tools for debugging the Intel graphics driver including a GPU hang dumping program, performance monitor, and performance microbenchmarks for regression testing the DRM.: sudo apt-get install intel-gpu-tools

Rename xorg.conf for intel:

If you want to use an xorg.conf for the intel graphics chip, then you now have to rename it xorg.conf.INTEL, simply run:

sudo mv /etc/X11/xorg.conf /etc/X11/xorg.conf.INTEL

If you install fresh with or without the sony-VGN-Zseries-janitor script, you should NOT (yet) create an xorg.conf.INTEL file. That ensures that the intel chip can run without (eventually wrong) xorg.conf since intel does not nead an xorg.conf. A wrong xorg.conf.INTEL is a usual reason for a black screen after booting. Some people don't understand this mechanism and think, they have started the 'Z' in speed mode but it is in truth not in speed mode. In this case it is important to NOT have an xorg.conf.INTEL file.

Install the nvidia driver:

NOTE: this step (nvidia driver installation) is done automated with the sony-VGN-Zseries-janitor script.

If you don't use the sony-VGN-Zseries-janitor script, here the steps to be done:

Install the packages nvidia-common jockey-gtk and nvidia-settings:

sudo apt-get install nvidia-common jockey-gtk nvidia-settings

.. run /usr/bin/jockey-gtk, 'activate' the newest available nvidia driver and .. 

backup xorg.conf for nvidia:

NOTE: this step (nvidia xorg.conf maintainance) is completely automated with the sony-VGN-Zseries-janitor script.

If you don't use the sony-VGN-Zseries-janitor script or wants to understand what it does, here the steps to be done:

For the nvidia driver an xorg.conf file is needed. The jockey (jockey-gtk) script will create and install it without need to interact from your side.
If you like to see if the nvidia was loaded right while booting in speed-mode, you may want to edit this automatically created xorg.conf. Search for the line:

     Option          "NoLogo"     "True"

.. and comment it out with a '#':

#    Option          "NoLogo"     "True"

.. that makes the nvidia logo appear for a couple of seconds on startup if everything was loaded right.

The last step is to rename this xorg.conf into xorg.conf.NVIDIA:

sudo mv /etc/X11/xorg.conf /etc/X11/xorg.conf.NVIDIA

LCD brightness controll with the acpi_create_nv_event script browse source :

NOTE: this script will be installed, maintained and executed by the sony-VGN-Zseries-janitor script (see above).

Finally, for the intel gpu the Fn-F5 and Fn-F6 key combinations to increase or decrease the brightness work out of the box. For the nvidia gpu a different acpi-method is used. To make these keys do this under nvidia as well and if you don't use the sony-VGN-Zseries-janitor script or wants to understand what it does, here the steps to be done:

Install 'smartdimmer' and 'nvclock':

sudo apt-get install nvclock

create the sony-lapto share dir (if not yet exists):

sudo mkdir -p /usr/share/sony-laptop/

and download the script /usr/share/sony-laptop/acpi_create_nv_event browse source :

sudo wget -NP /usr/share/sony-laptop/ http://global-social.net/files/acpi_create_nv_event

.. create symlink /usr/local/bin/acpi_create_nv_event:

sudo ln -sf ../../share/sony-laptop/acpi_create_nv_event /usr/local/bin/acpi_create_nv_event

.. make it executable:

sudo chmod +x /usr/share/sony-laptop/acpi_create_nv_event

.. and run it:

sudo acpi_create_nv_event

that script will find out interactively on what acpi-event the brightness-up respectively brightness-down should be assigned and do everything for you. After running that script, you will be able to change nvidia brightness with the Fn-Key combinations.

© Raphael Gradenwitz


PS: I am Dutch, living in Germany; for me English is a foreign language. If you get disturbed by my spelling mistakes or literal errors, please feel free to send me your corrections. Thanks!

Share this page:

 Digg  del.icio.us  Blinklist  Furl  Reddit  Blogmarks  Magnolia  Sphere  Yahoo!  Technorati  Blue Dot  Simpy  Newsvine  Stumble Upon  co.mments.com  Blinkbits  BlogMemes  Connotea  Mister Wong  Facebook  Google 


The content on this page is licensed under the terms of the CreativeCommons .


Permalink 2 comments Print Email This Post
Page: 1/1
1

Google Search

 
global-social.net
WWW

Query Whois

Whois

Shoutbox

Anti-Bot verification code: Random Image
Enter the code you see above:

tester11 Punkte , 19:55 CEST, Tue 25 of May, 2010: Read comments please :)
xawer1268 Punkte , 23:09 CEST, Mon 01 of June, 2009: immo links ? :) moin ernolf und sehende
xawer1268 Punkte , 22:30 CEST, Sun 19 of Oct., 2008: Shoutbox IST GRATIS ;)
Anonymous, 16:36 CEST, Fri 03 of Oct., 2008: wundervolle Bilder,xawer!!!HUT ab!!
xawer1268 Punkte , 14:52 CEST, Thu 02 of Oct., 2008: ....dem Herbst sei dank ... farben wo man hinsieht :-)
ernolf1997 Punkte , 02:13 CEST, Thu 02 of Oct., 2008: Hallo Leute! Schon auf meinem Twitter account geschaut? http://twitter.com/ernolf

Google AdSense

Page generated in 1.44s
by Tikiwiki