tpctl

Langue: en

Autres versions - même langue

Version: 113846 (mandriva - 01/05/08)

Section: 1 (Commandes utilisateur)

NAME

tpctl - a ThinkPad configuration tool for Linux

SYNOPSIS

tpctl [--h|--help ] [--V|--version ] [--device=<name> ] [--dull ] [--quiet ]
[--S|--standby|--Z|--suspend|--H|--hibernate ]
[--x|--all ]
[--ix|--info-all ]
[--ib|--info-bios ]
[--ic|--info-CMOS-RAM ]
[--id|--info-display ]
[--io|--info-docking ]
[--ip|--info-processor ]
[--ir|--info-refresh=<VGA-mode-#> ]
[--is|--info-sensor ]
[--iU|--info-UltraBay ]
[--sx|--setup-all ]
[--sdx|--setup-display-all ]
[--sdi|--setup-display-internal[=(disable|enable)] ]
[--sdc|--setup-display-CRT[=(disable|enable)] ]
[--sdt|--setup-display-TV[=(disable|enable)] ]
[--sdT|--setup-display-TV-select[=(disable|enable)] ]
[--sdm|--setup-display-monitor-detection-ignore[=(disable|enable)] ]
[--sd2|--setup-display-dual[=(disable|enable)] ]
[--sf |--setup-Fn-hotkey[=(nonsticky|sticky|locked)] ]
[--spx|--setup-pointing-device-all ]
[--spi|--setup-pointing-device-internal[=(disable|enable|auto)] ]
[--spe|--setup-pointing-device-external[=(disable|enable|auto)] ]
[--sst|--setup-daylight-saving-time ]
[--px|--pm-all ]
[--pmx|--pm-mode-all ]
[--pma|--pm-mode-AC[=(high|auto|manual)] ]
[--pmb|--pm-mode-battery[=(high|auto|manual)] ]
[--pmR|--pm-mode-RediSafe|--pm-mode-safe-suspend[=(disable|enable)] ]
[--prx|--pm-resume-all ]
[--pra|--pm-resume-appointment[=(enable|disable|(daily|<yy>:<mm>:<dd>):<hh>:<mm>:<ss>)] ]
[--prh|--pm-resume-hardware[=(disable|enable)] ]
[--prl|--pm-resume-lid[=(disable|enable)] ]
[--prs|--pm-resume-serial-RI[=(disable|enable)] ]
[--psx|--pm-sedation-all ]
[--psS|--pm-sedation-standby-timer[=(-|S|Z|R|H|O)] ]
[--psZ|--pm-sedation-suspend-or-hibernate-timer[=(-|S|Z|R|H|O)] ]
[--psH|--pm-sedation-hibernate-from-suspend-timer[=(-|S|Z|R|H|O)] ]
[--psb|--pm-sedation-battery-low[=(-|S|Z|R|H|O)] ]
[--pse|--pm-sedation-environment-exhausted[=(-|S|Z|R|H|O)] ]
[--psh|--pm-sedation-hardware-or-software[=(-|S|Z|R|H|O)] ]
[--psl|--pm-sedation-lid-closure[=(-|S|Z|R|H|O)] ]
[--psp|--pm-sedation-power-switch[=(-|S|Z|R|H|O)] ]
[--ptx|--pm-timer-mode-all ]
[--ptB|--pm-timer-mode-blank-display[=(disable|enable)] ]
[--ptS|--pm-timer-mode-standby[=(disable|enable)] ]
[--ptZ|--pm-timer-mode-suspend-or-hibernate[=(disable|enable)] ]
[--ptd|--pm-timer-mode-drive-powerdown[=(disable|enable)] ]
[--pdx|--pm-delay-all ]
[--pdH|--pm-delay-hibernate-from-suspend[=<minutes>] ]
[--pdZx|--pm-delay-suspend-or-hibernate-all ]
[--pdZa|--pm-delay-suspend-or-hibernate-AC-manual[=<minutes>] ]
[--pdZb|--pm-delay-suspend-or-hibernate-battery-manual[=<minutes>] ]
[--pdZh|--pm-delay-suspend-or-hibernate-high] ]
[--pdZu|--pm-delay-suspend-or-hibernate-auto] ]
[--rx|--resource-all ]
[--rf|--resource-floppy ]
[--rp|--resource-parallel[=(<port>|LPT<#>|IRQ<#>|enable|disable)] ]
[--rsx|--resource-serial-all ]
[--rs1|--resource-serial-1[=(<port>|COM<#>|IRQ<#>|enable|disable|on|off)] ]
[--rs2|--resource-serial-2[=(<port>|COM<#>|IRQ<#>|enable|disable)] ]

DESCRIPTION

tpctl is a configuration and control utility for the IBM ThinkPad series of laptops. tpctl requires device drivers for certain ThinkPad components in the form of loadable kernel modules. These are available in the separate thinkpad package. tpctl is a console interface to these drivers. (The ntpctl program offers a subset of tpctl functionality through an ncurses interface. See the ntpctl man page for details.)

OPTIONS

--help
(or --h) option outputs a usage listing which is designed to be largely self-explanatory.
--dull
option turns off highlighting in the printed output.
--quiet
makes tpctl a bit less verbose.
--device=special
allows setting the ThinkPad kernel device interface to special rather than the default /dev/thinkpad/thinkpad.

Entering standby, suspend, or hibernate states

--standby
(or --S) will make the machine stand by.
--suspend
(or --Z) will suspend the machine. Pressing the Function key will resume operation.
--hibernate
(or --H) will hibernate the machine. Pressing the power switch will resume operation.

Gaining information

--all
(or --x) will output all information and settings available.
--info-all
(or --ix) will output all information. More specific information can be requested with --info-bios (--ib), --info-CMOS-RAM (--ic), --info-display (--id), --info-docking (--io), --info-processor (--ip), --info-sensor (--is) and --info-UltraBay (--iU).
--info-refresh=VGA-mode-number
(or --ir=VGA-mode-number). Information about refresh rates capabilities for particular VGA modes requires that the VGA mode number be provided. Known modes include:
    0x100 :     640 x 400 x 8 (256)

    0x101 :     640 x 480 x 8 (256)

    0x102 :     800 x 600 x 4 (16)

    0x103 :     800 x 600 x 8 (256)

    0x104 :     1024 x 768 x 4 (16)

    0x105 :     1024 x 768 x 8 (256)

    0x106 :     1280 x 1024 x 4 (16)

    0x107 :     1280 x 1024 x 8 (256)

    0x108 :     (reserved)

    0x109 :     1056 x 350 x 4 (16)

    0x10A :     1056 x 473 x 4 (16)

    0x10B :     (reserved)

    0x10C :     1056 x 480 x 4 (16)

    0x10D : (reserved)
    0x10E : (reserved)
    0x10F : (reserved)
    0x110 :     640 x 480 x 15 (32K)

    0x111 :     640 x 480 x 16 (64K)

    0x112 :     640 x 480 x 24 (16M)

    0x113 :     800 x 600 x 15 (32K)

    0x114 :     800 x 600 x 16 (64K)

    0x115 :     800 x 600 x 24 (16M)

    0x116 :     1024 x 768 x 15 (32K)

    0x117 :     1024 x 768 x 16 (64K)

    0x118 :     1024 x 768 x 24 (16M)

    0x119 :     1280 x 1024 x 15 (32K)

    0x11A :     1280 x 1024 x 16 (64K)

    0x11B :     1280 x 1024 x 24 (16M)

    ...        (reserved)

    0xA00 :     1600 x 1200 x 4 (16)

    0xA01 :     1600 x 1200 x 8 (256)

    0xA02 :     1600 x 1200 x 15 (32K)

    0xA03 :     1600 x 1200 x 16 (64K)

    0xA04 :     1600 x 1200 x 24 (16M)

    ...        (reserved)
--pm-all
(or --px) will output all power management data. More specific information can be requested with: --pm-delay-all (--pdx), --pm-timer-mode-all (--ptx), --pm-resume-all (--prx), --pm-sedation-all (--psx) --pm-delay-suspend-or-hibernate-all (--pdZx) or --pm-mode-all (--pmx)
--setup-all
(or --sx) will output all setup data. More specific information can be requested with --setup-display-all (--sdx) or --setup-pointing-device-all (--spx)
--resource-all
or (--rx) will output all resource (floppy, parallel and serial port) settings. More specific information can be requested with: --resource-floppy (--rf), --resource-parallel (--rp) or --resource-serial-all (--rsx).

Controlling the general setup

--setup-display-internal[=(disable|enable)]
(or --sdi)
--setup-display-CRT[=(disable|enable)]
(or --sdc)
--setup-display-TV[=(disable|enable)]
(or --sdt)
--setup-display-TV-select[=(disable|enable)]
(or --sdT)
--setup-display-monitor-detection-ignore[=(disable|enable)]
(or --sdm)
--setup-display-dual[=(disable|enable)]
(or --sd2)
--setup-Fn-hotkey[=(nonsticky|sticky|locked)]
(or --sf )
--setup-daylight-saving-time
(or --sst)

Controlling the pointing devices

--setup-pointing-device-all
(or --spx) causes tpctl to output the current settings of the internal and external pointing devices.
--setup-pointing-device-internal
(or --spi) will restrict the output to just the internal pointing device.
--setup-pointing-device-external
or (--spe) will restrict the output to just the external pointing device.

These latter flags can be used to alter the settings, using e.g. --spi=keyword where keyword is one of enable, disable or auto.

If you boot with the internal pointing device in "auto-disable" mode then the TrackPoint will not work when you start X. However on my ThinkPad 600 I can "tpctl --spi=enable" prior to starting X windows and this allows use of both external and internal pointing devices.

You may want to stick with auto-disable mode if you have a wheel mouse, however: the wheels on some wheel mice work with X windows, but only if the TrackPoint is disabled. Please let me know if you manage to get a wheel-mouse wheel working simultaneously with the TrackPoint!

Controlling the power management functions

--pm-mode-AC=arg
(--pma=arg) where arg is high, auto or manual
--pm-mode-battery=arg
(--pmb=arg) where arg is high, auto or manual
--pm-mode-RediSafe|--pm-mode-safe-suspend=arg
(--pmR=arg) where arg is disable or enable
--pm-resume-appointment=arg
(--pra=arg) where arg is [=(enable|disable|(daily|<yy>:<mm>:<dd>):<hh>:<mm>:<ss>)]
--pm-resume-hardware=arg
(--prh=arg) where arg is disable or enable
--pm-resume-lid=arg
(--prl=arg) where arg is disable or enable
--pm-resume-serial-RI=arg
(--prs=arg) where arg is disable or enable
--pm-sedation-standby-timer=arg
(--psS=arg) where arg is is one of - S Z R H or O where these mean:
    -: disable
    S: standby
    Z: suspend
    R: safely suspend (RediSafe)
    H: hibernate
    O: power off
--pm-sedation-suspend-or-hibernate-timer=arg
(--psZ=arg)
--pm-sedation-hibernate-from-suspend-timer=arg
(--psH=arg)
--pm-sedation-battery-low=arg
(--psb=arg)
--pm-sedation-environment-exhausted=arg
(--pse=arg)
--pm-sedation-hardware-or-software=arg
(--psh=arg)
--pm-sedation-lid-closure=arg
(--psl=arg)
--pm-sedation-power-switch=arg
(--psp=arg)
--pm-timer-mode-blank-display=arg
(--ptB=arg) where arg is disable or enable
--pm-timer-mode-standby=arg
(--ptS=arg) where arg is disable or enable
--pm-timer-mode-suspend-or-hibernate=arg
(--ptZ=arg) where arg is disable or enable
--pm-timer-mode-drive-powerdown=arg
(--ptd=arg) where arg is disable or enable
--pm-delay-hibernate-from-suspend=arg
(--pdH=arg) where arg is <minutes>
--pm-delay-suspend-or-hibernate-AC-manual=arg
(--pdZa=arg) where arg <minutes>
--pm-delay-suspend-or-hibernate-battery-manual=arg
(--pdZb=arg) where arg <minutes>
--pm-delay-suspend-or-hibernate-high]
(--pdZh)
--pm-delay-suspend-or-hibernate-auto]
(--pdZu)

Controlling the resource settings

--resource-parallel=arg
(--rp=arg) where arg is one of <port> LPT<#> IRQ<#> enable or disable)

<port> is a hardware I/O address, e.g., '0x3f8'

--resource-serial-1=arg
(--rs1=arg where arg is one of <port> COM<#> IRQ<#> enable disable on or off))
--resource-serial-2=arg
(--rs2=arg where arg is one of <port> COM<#> IRQ<#> enable or disable

Note that the --r** options cause tpctl to talk directly to hardware. They do not change settings stored in nonvolatile RAM. Therefore your changes will be lost on power-off. To make nonvolatile changes, use the setpnp utility.

These options have not been tried out on every model of ThinkPad; but they work on many.

Here is an example of a session in which I first moved my serial port 1 from 0x3e8 irq4 to 0x2f8 irq3, and then enabled serial port 2 at 0x3e8 irq4. Please read the man page for the "setserial" command for more information. On my ThinkPad 600, serial port 1 is connected to the DB-9 on the back of the machine; serial port 2 is connected to the infrared interface.

[root@myhost]# setserial /dev/ttyS1 auto_irq autoconfig ; setserial /dev/ttyS2 auto_irq autoconfig ; setserial /dev/ttyS1 ; setserial /dev/ttyS2
ttyS1, UART: unknown, Port: 0x02f8, IRQ: 3
ttyS2, UART: 16550A, Port: 0x03e8, IRQ: 4

[root@myhost]# tpctl -rs1=0x2f8 -rs1=irq3
tpctl: serial port 1 interrupt has been set to IRQ3
tpctl: serial port 1 base address has been set to 0x2f8
resource current state:
serial port 1: enabled COM1 0x2f8 IRQ3

[root@myhost]# setserial /dev/ttyS1 auto_irq autoconfig ; setserial /dev/ttyS2 auto_irq autoconfig ; setserial /dev/ttyS1 ; setserial /dev/ttyS2
ttyS1, UART: 16550A, Port: 0x02f8, IRQ: 3
ttyS2, UART: unknown, Port: 0x03e8, IRQ: 4

[root@myhost]# tpctl -rs2=0x3e8 -rs2=irq4 -rs2=enable
tpctl: serial port 2 has been enabled
tpctl: serial port 2 interrupt has been set to IRQ4
tpctl: serial port 2 base address has been set to 0x3e8
resource current state:
serial port 2: enabled COM2 0x3e8 IRQ4

[root@myhost]# setserial /dev/ttyS1 auto_irq autoconfig ; setserial /dev/ttyS2 auto_irq autoconfig ; setserial /dev/ttyS1 ; setserial /dev/ttyS2
ttyS1, UART: 16550A, Port: 0x02f8, IRQ: 3
ttyS2, UART: 16550A, Port: 0x03e8, IRQ: 4

General

Note that at the present time all the options can be given with a single dash.

You can give as many different options as you like, including multiple instances of an option with different arguments: e.g.,
           tpctl --rs1=enable --rs1=irq5

SECURITY

The user requires write permission on the device file in order to change settings or to "sedate" the machine. This means that it is safe to allow a normal user to execute tpctl or ntpctl, so long as he or she doesn't have write permission on the device file.

FILES

/dev/thinkpad
This is a directory containing the following special device files:
/dev/thinkpad/thinkpad
Special device file (char, major 10, minor 170) through which ThinkPad devices are controlled
/dev/thinkpad/smapi
Special device file through which the SMAPI BIOS may be accessed
/dev/thinkpad/superio
Special device file through which the Super I/O chip may be controlled
/dev/thinkpad/rtcmosram
Special device file through which the RT CMOS RAM chip may be controlled
/dev/thinkpad/thinkpadpm
Special device file through which certain ThinkPad power management actions may be performed

BUGS

None known.

AUTHOR

tpctl was written by Thomas Hood and Bill Mair.
This man page was written by Adrian Bridgett and Thomas Hood.

SEE ALSO

ntpctl(1), thinkpad(4), setpnp(8), apmiser(8).