SPONSORED LINKS

Introduction CPU/Memory details Power Management PCMCIA/Cardbus Sound Storage Peripheral Ports Video How I use my 500CDT and general opinions Files Contact

Introduction

The Tecra 500CDT is a Pentium notebook manufactured in 1996. It runs Debian GNU/Linux "sarge" excellently, except that the user needs to know some details to set up everything properly. This page will contain the necessary information for you to set up your 500CDT. My machine is a 500CDT/1.3, model PA1221U XCD, p/n PA1221U T2A.

CPU/Memory details

The 500CDT has a 120MHz Intel Pentium CPU. It is the VRT variant, so the core voltage is 2.9V instead of the usual 3.3V - this reduces power consumption and heat generation. It has the F00F hardware bug which Linux has a workaround for.

The P5 pipeline is strange in that for fastest execution speed, code must be compiled specifically for its dual pipeline; it has no out-of-order execution like P6 and later cores. Therefore, 386 and 486 compiled code is slower on P5 than on P6 of equivalent clock speed. Additionally, P5 code is slower on P6 than 386 or 486 optimized code. For best results, frequently used packages and libraries should be compiled with -mpentium optimization.

The new Debian installer automatically installs the appropriate (-586tsc) kernel for best kernel performance, and -586 packages of certain programs like mplayer are available. Unfortunately, no -586tsc versions of 2.6 kernels are available (yet).

It is possible to use the 'toshset' utility to enable/disable the L2 cache as well as set the CPU between a fast and slow setting. The system power management functionality must be in 'user' mode for this to work (toshset -bs user). The results of the different settings on UnixBench 4.10:

both cpu fast and cache on : 27.9
toshset -cpucache off : 27.4
toshset -cpu slow: 12.9
Strangely, when CPU is 'slow' and 100Hz scheduler of Linux is used, some strange noises come from the CPU power electronics.

The Pentium TSC (Time Stamp Counter) can be used for high precision timing by programs like mplayer and DOSEMU, but it has a significant disadvantage from later high resolution timers like ACPI/APIC timers: power management can cause it to dilate/compress time unexpectedly. Therefore, it is inappropriate to use when the system is changing the CPU speed or stopping the CPU in response to power management events, because the system state will become inconsistent. It is also a bad idea to use this on SMP machines, unless it is known that the motherboard keeps the TSC synchronized between the CPUs. Otherwise, a process's idea of time will jump around if it becomes scheduled on a different CPU. It appears that on the 500CDT, the SCI CPU speed setting does not affect the CPU MHz or the TSC rate, so using cpufreq should not pose a problem to user programs. FIXME: investigate APM.

The machine has an internal fan on the left side. It is sometimes too noisy, and can be disabled with toshset or toshutils if necessary. The only way to fix it is to re-lubricate the bearing. Use a heavy oil because light machine oil does not last, and be sure to seal the fan, otherwise the oil will just leak out. Since this is so much work to access the fan (whole motherboard must be removed, or else case modified), it might be better just to replace the fan. Don't bother replacing it with a used fan, all OEM fans will be close to failure soon. The OEM model number is NMB UDQFB2E02-PI which is a 5V 25mm (1 inch) fan with 15mm thickness. It can be replaced with any similar fan which should cost less than $10 shipped. The replacement fan will need to be modified with Dremel or similar tool to remove about 1/8 to 1/4 inch from the top on one side to match the OEM fan. Then just solder the wires together and wrap them in electrical tape. Don't forgot to make sure the fan is oriented in the correct direction to exhaust air outwards!

The machine comes with 16MB EDO memory onboard. It can be upgraded with 16MB, 32MB, 64MB, and 128MB memory cards, for a maximum of 144MB. I upgraded my machine with a 128MB memory card, Kingston model KTT500/128, and this works fine. Unfortunately, the L2 cache only has a 64MB cacheable region. The result is that if a physical page is located past 64MB of physical memory, access to that page will be very slow. A simple read benchmark shows the 0-64MB region of RAM at about 15MB/sec, while reads to the 64MB+ region of RAM come in at about 9MB/sec.

Better performance can be had by limiting Linux to using 64MB of memory, and using the rest of the memory for an in-memory swap device. As long as swap isn't being thrashed badly, this strategy will ensure that accesses to uncached regions are minimized because the kernel itself, the most frequently utilized program, will be loaded below that limit. Although, since swap access must go through the mtdblock layer, that also imposes a performance penalty.

Make the following changes in order to swap over RAM:
Add to the GRUB_CMDLINE_LINUX_DEFAULT in

/etc/default/grub
:
'memmap=80M\$64M'

Be sure to observe the single quotes and the backslash. This creates an 80MB reserved area starting at 64MB.
Add to /etc/modutils/actions (or to a new file in /etc/modutils):
post-install slram mkswap /dev/mtdblock0 && swapon -p0 /dev/mtdblock0

and then run update-modules.
Add to /etc/modules
mtdblock
slram map=ram_uncached,64M,+80M

If /dev/mtdblock0 does not exist:
mknod /dev/mtdblock0 b 31 0

Then reboot. You should see messages saying that a swap-space was setup and added as part of the output.

Power Management

The Tecra 500CDT has only APM support, not ACPI, and only supports APM standby and sleep modes (with a NiMH 7.2V 110mAh refresh/resume battery that should provide 8-12 hours of sleep: Toshiba part number P71044001117). During sleep, the normal battery can be removed for charging or swapped out with another one. (FIXME: is there any wake up IRQ events besides RTC and modem?)

A RTC battery (3.6V NiMH 30mAh: Toshiba P/N P71007006036) keeps the system settings alive. The refresh/resume battery also helps keep the settings active. Removing both batteries or allowing them to fully discharge will clear the system settings to defaults. Note that both of these batteries are NiMH so it is expected that after a period of disuse, the laptop's system settings will be lost because of the battery self-drain.

APM includes several power-saving modes - standby, sleep, and suspend. Standby is a low-power, but still fully enabled system; the screen and perhaps the HDD and some chips are turned off to conserve power. Sleep is sometimes referred to as suspend-to-RAM - the BIOS saves all of device state to RAM and powers off the whole system except for a battery (either system battery, or separate refresh battery) that keeps the RAM refreshed and alive; when coming out of suspend, device states are restored by the BIOS and the system continues where it left off. (This is the same effect as ACPI S3) Suspend is sometimes referred to as suspend-to-disk or hibernation. It is identical to suspend-to-RAM, except that a disk partition big enough to hold a RAM snapshot and device states is required, and everything is stored to disk instead of RAM, allowing for essentially zero power use. Not all systems support suspend, and properly setting up the hibernation file or partition is dependent on the BIOS implementation. (This is the same effect as ACPI S4bios.) APM can also call swsusp instead to eliminate most of the reliance on the BIOS to do the right thing.

APM sleep works with kernel 2.6 but not with kernel 2.4; in 2.4 a resume attempt ends up in the BIOS with 'RESUME FAILURE'.

Wakeup events differ between APM suspend and software suspend. In APM, the BIOS predefines IRQs where traffic will cause a resume from standby or suspend. With software suspend, the machine must be powered back on by the user or a BIOS-defined IRQ event, and Linux boots and reloads the system state from swapfile. (FIXME: what IRQs are wakeup events? what about pcmcia cards? is this configurable?)

You can also use the program 'apmsleep' for a timed wakeup. This program programs the RTC to generate an interrupt after a period of time, at which point the system will resume from suspend. This requires that the RTC interrupt (IRQ 8) is defined as a wakeup event. I haven't tested this yet. (FIXME)

You can change all of the APM power settings with toshset. Toshset implements the CPU SMM (System Management Mode) to access its private interface. An unfortunate drawback is that SMM causes interrupts to be disabled while the command executes, so avoid using toshset while the system is doing anything time critical.

The laptop-mode-tools package is a good thing to install. On 2.4 and 2.6 kernels with laptop_mode support, they will do a pretty good job of conserving battery life when the machine is on battery by minimizing disk access and/or throttling the CPU speed. (Battery life can be monitored with apm q, or with xbattbar for example.) The hard drive spindown interval can be adjusted with hdparm.

The 500CDT has a Li-Ion battery that provides between 1.5 and 2 hours of battery life on my machine with laptop mode and with my toshapm script. A newer battery might be even better. You can use the battery-stats package to collect battery statistics and print a graph showing your battery's charge level over time.

The power supply is internal to the laptop so a standard two-prong appliance cable is all that is needed externally to run the laptop on AC. Time to charge the battery from nearly empty to full while the machine is running is around X hours. (FIXME)

Pressing the power button does (FIXME) There is also a pen-tip reset button which is handy if the system gets into some strange state.

If APM suspend is problematic, it is recommended to disable network interfaces, mute sound cards, cardctl suspend PCMCIA cards, sync a few times, then sleep for a second or two. When coming back up, remember to cardctl restore them. For problematic cards, cardctl eject and cardctl insert may be necessary. (FIXME: this is required for the IBM ethernet card - why?) Suspending and resuming under kernel 2.6.11 and XFree86 4.3.0 currently works fine.

PCMCIA, Plug & Play (PNP) and Resouce Management

There are two PCMCIA slots. Either two Type II cards or one Type III card may be used. The controller is the ToPIC95-B Cardbus bridge. It can be used in "Cardbus/16-bit" mode, where it is a PCI bridge device and supports both Cardbus and 16-bit cards, or in "PCIC compatibility" mode, where it is a standard ISA PCIC controller and only supports 16-bit cards. Most of the time you will want it in Cardbus/16-bit mode. Unfortunately, bugs exist in the Linux 2.4 and 2.6 kernels regarding the Toshiba support. The result is that if the controller is set to Cardbus/16-bit mode, 16-bit cards will be unusable. (The pcmcia-cs drivers, a separate driver set for 2.4, do not have this problem, but they are not used during Debian installation and must be installed afterwards.) The specific issue is that according to Toshiba, ToPIC95 and ToPIC97 controllers ignore the Cardbus power register settings for 16-bit cards, and so the ExCA register must be used.

The result is that during installation of Debian, if you are using a 16-bit device like a network card, you will have to set the controller to PCIC Compatibility mode in the BIOS. The problem has been located and a fix made it into Linux 2.6.13.

The Cardbus controller has some compatibility issues. While older Cardbus cards, like 10/100 network cards, work fine, newer CardBus cards, like wireless ethernet cards, tend not to work, either locking up the system or otherwise misbehaving. 16-bit PCMCIA cards work fine, so just bear that in mind before you spend money on a 32-bit CardBus card. The only 16-bit cards that appear to support WPA are the Aironet and Orinoco cards, and the Aironet driver on Linux does not support WPA except with Aironet 350 and a very beta driver.

One solution to 32-bit Cardbus cards locking up the system is to disable the ToPIC95 controller's Write Buffer bit via the Bridge Control Register in the PCI configuration space. This setting seems to be battery-backed/non-volatile and will persist across power cycles, but it would be a good idea to set it on reboot (e.g. in /etc/rc.local) anyway if it is helpful. Example:

# setpci -v -s 00:02.0 3e.w=0:0400
# setpci -v -s 00:02.1 3e.w=0:0400

This setting solved system lockups using (following tested):

It did not solve system lockups under heavy network load using either of two Atheros AR5xxx cards that were tested, nor lockups and unreliablity with two VIA USB/Firewire cards.

For PCMCIA network card hotplug, install hotplug and ifplugd (configure ifplugd with -M option to avoid repeated modprobe attempts when the network card is removed). If you have a wireless card, additionally install wireless-tools, and wpasupplicant. (Note that udev and ifupdown/NetworkManager have superceded all of this advice in newer distributions.)

PCMCIA cardmgr support for 16-bit cards is being phased out in favor of a unified hotplug subsystem (hotplug already handles Cardbus devices as of this writing). Therefore, the following only applies to a system which still uses the PCMCIA cardmgr.

A snag regarding PCMCIA support is that the builtin devices in this machine do not report their resources through PnP on kernels which do not have PNPBIOS support. (Even on those that do, not all resources are reported, so you will need to reserve certain areas in all cases.) If you want to use the IRDA port, you will have to reserve IRQ 3; if you want to use the parallel port, you will have to reserve IRQ 7; and for the built in sound, you must reserve all of the following in /etc/pcmcia/config.opts:

########################
# control port
exclude port 0x120-0x127
# sb port
exclude port 0x220-0x22f
# mpu401 port
exclude port 0x330-0x331
# opl3 port
exclude port 0x388-0x38b
# wss port
exclude port 0x534-0x537
# DSP/SB IRQ
exclude irq 5
# MPU-401 IRQ
exclude irq 9
########################
Of course, if you have changed these resources from the defaults in the system setup, these exclusions must be changed to match.

Apparently this PCMCIA controller has ZV (Zoomed Video) support, but it is not yet observed working.

The system's Plug & Play BIOS configures all onboard devices and provides their resources via the PnPBIOS structure. If add-on ISA devices exist in the Deskstation, their resources may need to be configured separately via isapnp. The MPU-401 and gameport devices of the CS4232 are not enumerated by the BIOS unless the port replicator or docking station was attached at boot.

FIXME: Need to add support in Linux for docking station PnP, and resource allocation of docking station devices, and PnP rescan after status change. This would make Linux more functional since the BIOS would not be necessary to reconfigure the system (thus necessitating a reboot) after connecting the docking stations.

PCI devices in the docking station all share the same interrupt line.

USB / Firewire (IEEE 1394)

An easy way to add USB and Firewire ports is to obtain a Cardbus card that contains both. Note that any card containing both USB and Firewire ports, or any card with more than two USB ports, will block the slot above it (and thus should be inserted in the top PCMCIA slot).

Combo USB/Firewire cards will usually come in a form factor with 2 USB ports, a Firewire port, a i.Link (mini Firewire) connector, and a DC power plug. These are almost all with a VIA controller chip and are quite poor quality in general. Frequently it is difficult to get the power plugged in without wiggling, but if the power is added after the card is plugged into the computer it will most likely hang the computer.

USB cards with a power jack take a center-positive 3.5mm, 5V, 2000mA supply. This can be supplied either from a wall wart supply, or from a powered USB hub using the usually-supplied USB power converter. When the USB card is powered, you should use

pccardctl eject
to stop the card before removing it or system hangs will likely result.

I have tried several USB / Firewire cards with the following result:
NameMarkingsChipsetResult
USB2.0 / IEEE 1394 COMBO CARDBUS (red/orange plasma logo) Made in Taiwan VIA VT6212L (rev 63), VIA VT6306L (rev 46) RT2800USB insertion locks up system
USB storage stick insertion locks up system
Windows installs driver but doesn't recognize plugged devices
USB2.0+IEEE 1394 COMBO CARDBUS (black/purple triangle logo) PCMCIA COMBO CARD (VIA), S/N 2006041100034, comes with "The Expert Of USB" CD VIA (USB rev 61, FW rev 46) RT2800USB does not work (error -110 on insert)
USB storage stick does work (error -110 on insert)
Poor power connection
USB 2.0 Notebook Adapter Hi-Speed Card HT Technology, Made in China NEC, 4 ports USB RT2800USB works (self-power)
USB storage stick works (self-power)
Recommended for USB 2.0; room for two wide dongles simultaneously
32bit CardBus 1394a & USB2.0 4 Ports 5-PC103-01A, Made in Taiwan NEC USB, TI Firewire RT2800USB works (needs external power)
USB storage stick works (self-power)
Poor power connection

Sound

The sound chip is a Crystal CS4232, which is essentially a combination of a CS4231 WSS codec (improved CS4248/AD1848) and a SBProII. It has Sound Blaster Pro II, Windows Sound System, Adlib/OPL3, and MPU-401 UART compatilibity in hardware. It does not have hardware mixing and this system is too slow to utilize dmix, so only one application can play digital audio at once.

The resources used on my system are as follows:

/proc/ioports:
0120-0127 : CS4232 Control
0220-022f : CS4232 SB
0330-0331 : MPU401 UART
0388-0389 : OPL2/3 (left)
038a-038b : OPL2/3 (right)
0534-0537 : CS4231
/proc/interrupts:
5:          2          XT-PIC  CS4231
9:      34109          XT-PIC  MPU401 UART
/proc/dma
0: CS4231 - 2
1: CS4231 - 1
Therefore, the following line in /etc/modules loads the ALSA sound driver:
snd-cs4232 port=0x534 cport=0x120 mpu_port=0x330 fm_port=0x388 sb_port=0x220 irq=5 mpu_irq=9 dma1=1 dma2=0 isapnp=0
The isapnp=0 is important, because otherwise the driver will use PnP to probe the resources, which does not work on this machine.

In kernel 2.6, PnPBIOS and hotplug will automatically load the driver, but unfortunately it attempts to load cs4232 instead of snd-cs4232, and a blacklist prevents it. (FIXME) For some reason, specifying module options on the command line or in /etc/modules no longer works with the 2.6 module-init-tools, so you need to add something like this to some file in /etc/modprobe.d:

options snd-cs4232 port=0x534 cport=0x120 mpu_port=0x330 fm_port=0x388 sb_port=0x220 irq=5 mpu_irq=9 dma1=1 dma2=0 isapnp=0

MPU401 and game-port resources are not reported by PnP unless the port replicator or docking station is attached.

FIXME: A SB device should be a secondary DSP since it is an independent subsystem apart from sharing the IRQ. This would help in case the CS4231 component mysteriously fails.

Other things you probably want in /etc/modules:

snd-opl3-synth	# For OPL3 MIDI support
snd-seq-oss	# For OSS compatibility /dev/sequencer* support
snd-mixer-oss	# For OSS compatibility /dev/mixer support
snd-pcm-oss	# For OSS compatibility /dev/audio and /dev/dsp support

Note that ALSA is not 100% OSS compatible at the kernel level, so some applications may still give trouble. (Also, software mixing with the OSS compatibility devices is not possible, though it is too slow on this machine that it doesn't even matter.) The alsa-oss package also provides 'aoss' program loader for OSS applications, that redirects OSS device driver manipulation to ALSA libraries, where almost everything can be emulated.

Since there is a hardware OPL3 FM cell (equivalent to YMF262 OPL3 and YAC512 DAC), it can be used to play MIDI files with the utility pmidi. First, use sbiload (from alsa-tools currently in experimental) to load the *.sb (OPL2) or *.o3 (OPL3) instrument patches to the chip. The instrument patches can be found in the playmidi package or alongside sbiload. The ones included with playmidi seem to sound better. (I can't seem to get percussion sounds from the .o3 patches included with sbiload.) Then use pmidi to play your MIDI file. There is an option use_internal_drums to snd-opl3-synth that provides different drum sounds than the MIDI drum patches, but when using this I can't seem to get any MIDI voices at all. (FIXME) Also, DOSEMU should be able to take advantage of this hardware soon for that old school game and demos that directly program the hardware. Remember that if you use another application that programs instruments on the FM synthesizer or resets it, you will need to run sbiload again to load the MIDI instrument patches.

There is a joystick/MIDI port on the docking station that could be used to connect an external MIDI synthesizer (FIXME: test). Unfortunately this machine is too slow to run TiMidity++ for software MIDI synthesis. However, it is fast enough to emulate SID/NES sound chips in realtime. (xmms-sid must use libsidplay1 because libsidplay2 is too slow on this machine.)

External connectors are microphone, speaker, line-in, and line-out. There are two internal speakers with a dial for volume control. An internal connection exists for CD audio, so a simple application like cdcd can be used to play an audio CD through the speakers. The line-out output works independently of the internal speaker and its volume control. On the speaker output, when something is plugged in, the internal speakers are disabled, and the volume control then controls the speaker jack instead. The system speaker sound/beep appears on both the line-out, internal speakers, and speaker output.

Linux 2.6 includes a PC Speaker driver which can be used for a second sound channel if necessary.

I'm still investigating how to place the sound hardware into the power saving mode (through CS4232 control port). I can power off the chip, but then the system must be rebooted to power it back on. I am fairly certain it is possible to do through software since the BIOS seems to take care of re-enabling it.

Another strange problem is that under the ALSA driver, the CS4231 cell eventually gets into a state where it seems to be locked up. Strangely, the SB/OPL3 still works. I'm not sure if this is a driver bug or a hardware problem. I measured the ESR on the five electrolytic "chip" type capacitors on the sound board and found several divergent values up to 3 ohms. Aging capacitors may be the problem...

But it may be a driver bug because when it happens, SBPro/OPL3 still works if the SBPro driver is used instead:

modprobe snd-sb8 enable=1 port=0x220 irq=5 dma8=1
modprobe snd-mpu401 port=0x330 irq=9
Although with this approach, one loses the capability of playing 44.1/48KHz stereo audio (only 22KHz stereo or 44.1KHz mono is possible). XMMS seems to deal with this with the OSS plugin by automatically falling back to mono on sources greater than 22KHz, but not with the ALSA plugin (FIXME). Also full-duplex recording (simultaneous with playback) is not possible, since only one DMA channel is allocated. But even after loading the SBPro driver, playing sound, and unloading it, the CS4232 (or CS4231, or AD1848) drivers no longer work. I guess the SBPro DSP and WSS codecs are separate hardware, and only one of them is locking up. The question is can the software recover from this state somehow, and is my machine the only one that does this? Worse, APM sleep/resume fails when the chip gets into this state.

UPDATE: Replacing the SMD electrolytic capacitors on the sound board with tantalum equivalents fixed the 500CDT's sound lockup problem. The capacitors aged and no longer function correctly so they must be replaced.

Storage devices

The 500CDT was shipped with a 1.26GB Toshiba hard drive MK2720FC. It has 128KB cache, and 5 platters, with no parking latch, and is 1" high in an internal enclosure. My drive recently failed and was replaced with a 4.8GB Fujitsu drive (2 3.2GB platters), so I'm uncertain about the long-term reliability of this model. The MK2720FC does not support SMART. Unfortunately, the internal enclosure is not suitable for thinner drives, so I stuck a wad of paper towel into there as a spacer.

The Toshiba IDE controller is a plain ISA EIDE controller. It is not PCI so it cannot take advantage of DMA, PCI buffering, etc, and seems rather slow. Fortunately the HDD and CDROM are on separate channels so they are not fighting on the IDE bus. A faster hard drive significantly improves performance over the original drive. On my system, the optimal hdparm settings seem to be -u1 (Unmask IRQ), -c1 (32-bit I/O), and -m16 (16 sector multi I/O). Unfortunately, multi sector I/O causes APM resume to fail (FIXME). These settings worked with both the original drive and the replacement. They can be added to /etc/hdparm.conf to be applied at each system startup.

An internal bay exists where either a CD drive or a floppy drive (?) can be inserted. The CDROM drive that ships with the machine is a XM-1502BN ATAPI 10X CDROM. It seems that it can be safely removed and reinserted while the system is running. PnP takes care of disabling and re-enabling the IDE controller it is connected to. A program included with toshutils called 'thotswap' assists with scanning for devices. An external floppy drive connector is on the left side of the machine and seems to be safe to plug in/remove while the machine is running. A complication of Linux 2.4 is that a floppy access will cause the accessing process to hang if the drive is not attached and the floppy driver is loaded. Linux 2.6 is much better with this issue.

The XM-1502BN CDROM drive has a poorly engineered latch mechanism which is prone to failure. The symptom is that the drive will not stay closed when it is pushed shut. I was able to disassemble the drive and locate the problem. A small metal latch is connected to the mechanism which opens the drive when the button is pushed. Over time, this latch recedes too far upwards to latch onto the small metal notch which pokes up from the bottom plate of the drive. The fix is to bend the latch so that it hooks onto that notch more reliably. This fix is not likely to last forever, due to the flimsy metal used. The problem is exacerbated when the drive attempts to eject the sled while it is obstructed, so don't obstruct it.

Is it possible to install a DVD drive adapting it into the bracket? (FIXME)

Since the system has no onboard USB or Ethernet port, and the BIOS does not support 'El Torito' booting from the internal CD-ROM drive or booting from a PCMCIA card, the only options to boot the system are either from the floppy or the internal hard disk drive. However, using a program like Smart Boot Manager or Plop Boot Manager, it is possible to chain-boot from the floppy or hard disk to the CD-ROM drive or a PCMCIA card if this becomes necessary.

Peripheral Ports

The 500CDT has an external docking station connector which I am unable to test because I don't own one yet. (FIXME) Supposedly both a port replicator and a full docking station are available for use. List all available docking stations and test for Linux hot/coldplug and suspend/resume compatibility.

Ports that are built into the laptop are an external DB25 parallel (ECP) port, a DB9 serial (16550A) port, a PS2 connector for external keyboard/mouse, and a DB15 VGA connector. It appears that the machine must be rebooted to enable the external PS/2 port (probably the BIOS does the job, or can 2.6 kernel does this - FIXME). The internal mouse is an eraser head pointer with 2 buttons, and works well with the console mouse server gpm in 'autops2' mode, as well as the X server with 3-button emulation mode. If you need replacement "eraser head" nipples for the Accupoint, the Toshiba part number is P000203220 for a pack of five. The external mouse is multiplexed with the internal mouse, and they are mutually exclusive by default: You can change between the two transparently, but while one mouse is moved incoming data from the other mouse is ignored. This setting can be changed in the BIOS. The external mouse can be unplugged and plugged back in freely once the machine has booted with it plugged in (and enabled the external mouse port). FIXME: external keyboard?

If you have problems with the keyboard such as keys working intermittently or only working in combination with other keys, check the ribbon cable connection at the motherboard that it is fully inserted and seated straight across.

An IRDA port is on the front and rear of the laptop. This is a Sharp UIRCC IRDA 1.1 compliant device which behaves as a second serial port (SIR, 115.2Kbps) or as a FIR (4mbps) device. Unfortunately, there seems to exist no complete support for this device in Linux IRDA stack. I am attempting to obtain the appropriate documents from Toshiba to complete this support. (FIXME)

Enabling the IRDA port usually requires a special Windows utility, but actually can be done using the PNPBIOS support of Linux. If you use the

lspnp
command and look for the TOS7009 device, and no resources are assigned to it, note its device node number. Then do the following (example is for device node number 16):
echo auto > /sys/bus/pnp/devices/00:16/resources
echo activate > /sys/bus/pnp/devices/00:16/resources

If you look back in lspnp, you should see now that resources are assigned to it. This setting should be sticky (but will be reset if you upgrade the BIOS or lose battery power).

TODO: verify receives from remotes, wireless n64 controller, other laptop, wireless kb/mouse, HP48, etc

Unfortunately, since only three devices in this machine are PCI devices (PCI bridge, Cardbus bridge, and video controller), no IRQ sharing is possible except for on a multifunction PCMCIA card. This provides an interesting situation in /proc/interrupts and /proc/dma:

0:    5954822          XT-PIC  timer
  1:      72568          XT-PIC  keyboard
  2:          0          XT-PIC  cascade
  3:          0          XT-PIC  serial
  4:          0          XT-PIC  serial
  5:          0          XT-PIC  CS4231
  6:         39          XT-PIC  floppy
  7:         66          XT-PIC  parport0
  8:          4          XT-PIC  rtc
  9:          0          XT-PIC  MPU401 UART
 10:     256846          XT-PIC  pcnet_cs, serial
 12:     122339          XT-PIC  PS/2 Mouse
 14:     506728          XT-PIC  ide0
 15:         20          XT-PIC  ide1
NMI:          0 
LOC:          0 
ERR:          0
MIS:          0
 0: CS4231 - 2
 1: CS4231 - 1
 2: floppy
 3: parport0
 4: cascade
As you can see, only IRQ 11 is available for a second PCMCIA card, and after that, all IRQ levels have been consumed; also, only high DMA channels (5-7) are available. IRQ 10 in this situation houses a combination 14.4 modem/NE2000 Ethernet card that I have plugged in. This is from a setup where the machine is in PCIC compatibility mode; the Cardbus controller yenta_socket can share an interrupt with a card, so the availability doesn't change.

The internal hardware-based modem is /dev/ttyS1 and reports the following ID:

TOSHIBA 28.8 Data/14.4 Fax Modem Version 4.15(MA)
This modem seems to work fine as a data/fax modem, without voice features. It uses a Lucent 1634 chipset. I ran across some information which seemed to claim that this modem can be operated in controller-less mode, so perhaps there is an upgrade somewhere that turns it into a 33.6K or 56K modem, at the expense of making it a software-driven modem. (The 288modem.exe driver set from Toshiba certainly seems to include a Winmodem driver for the TOS7007 device.) If the modem is not responding to the system or not detected, remove the front cover and re-seat the modem into its mainboard connector.

The rear DB9 serial port is /dev/ttyS0 by default. The IRDA port is disabled by default. It can be enabled through Linux PnP or through the Windows utility.

Video Display

The 500CDT display is a 12.1 inch active matrix backlit TFT LCD screen (DDC reports a TOS 5081) with a size of 968x726 pixels. The display controller is a CHIPS (C&T) CT65550 which contains the CHIPS HiQV32 PCI core. The ToPIC95 Cardbus controller supposedly has support for the ZV (Zoomed Video) feature according to Byte review of the 500CDT; the Linux driver seems to think only ToPIC97 and later has this feature. It appears that the CT chip can be put into ZV mode with a single register. Obviously the optional LCD controller module mentioned in the CHIPS documentation is included, and drives the laptop's screen. There is 2MB of EDO memory and linear memory-mapped framebuffer access is provided. This provides a sufficient dotclock and framebuffer for 800x600x16bpp on the LCD screen. I haven't been able to get a working modeline for the maximum resolution, if it is possible even. (FIXME) Some nice modeline generators for you to try this out are AMLC and a GTF generator. It might be necessary to overclock the memory (default MCLK: 38MHz) and/or the video chip to accomplish this.

A VBE 2.0 BIOS is provided, which allows vesafb to be used, and furthermore DOSEMU's VESA console support to be utilized.

VGA text looks very nice thanks to the CHIPS VGA text stretch feature (which can be enabled/disabled in the BIOS). It only seems to work on the 80x25 text mode though. Other modes are 80x28, 80x30, 80x34, 80x43, 80x50, and 80x60. There is a VEXP utility that controls the text stretch feature under DOS, so I'll have to explore more to see if I can't get these other text modes to stretch.

SVGAlib supports this chip well A useful utility is provided in the svgalib-bin package: an init script which saves the VGA state and restores it with 'textmode' at the user's demand. So if your font becomes screwed up or you lose stretching because of X server or svgalib, or your console is corrupted, etc, it can be easily restored with this utility.

To get nice looking fonts in all X programs, install the following packages:

defoma x-ttcidfont-conf msttcorefonts xfonts-base xfonts-misc xfonts-100dpi fontconfig bitstream-vera-ttf gsfonts dfontmgr psfontmgr
In fontconfig configuration, choose the sub-pixel hinter for best LCD performance. Unfortunately, if you have both a CRT+LCD connected, there is no best choice here.

The CRT can do 1024x768x16bpp standalone. When ganged with the LCD it is limited to 800x600. When an external monitor is connected, you can cycle through LCD, CRT+LCD, CRT using Fn+F5.

YUV acceleration is available through Xv so the CPU usage for video playing is lower. However, I find that many of the mplayer win32 codecs are compiled for P6 architecture and result in an illegal instruction signal on this machine.

The maximum dot clocks for the various CHIPS units are provided here (from XFree86 4.x manual):

                             ------CRT/TFT-------    --------DSTN--------
                             8bpp    16bpp   24bpp   8bpp    16bpp   24bpp
     65550 rev A 3.3v        80      53.2    35.47   53.2    35.47   26.6
     65550 rev A 5v          106.2   53.2    35.47   53.2    35.47   26.6
     65550 rev B             95      70      46.67   70      46.67   35.0
     65554                   94.5    77      51.33   77      51.33   38.5
     65555                   110     77      51.33   77      51.33   38.5
This is a 3.3V 65550 rev A, I believe (need to check).

How I use my Tecra 500CDT and general opinions

I sit on the couch and work on this machine, away from my workstation. Vim and ssh sessions are snappy, and with a lightweight window manager like icewm and a lightweight GUI browser like Opera in tandem with a text-based browser such as Links, I can get a lot of work done. The screen is nice and bright and the hardware is reliable (aside from the failed hard drive in which I lost my entire original setup, code under development, documentation, etc). The OpenAFS client is installed so I can access my file server and also for an automated script scheduled with anacron to backup this machine to the file server so that a future HDD failure is not a catastrophe. I can listen to tracker music with minimal CPU impact, and stream music with XMMS from e.g. Nectarine and Kohina, and under Linux 2.6 sound is rarely if ever skipping. DOSEMU runs well and I can play most classic DOS games at the console with excellent performance. I use a Jabber client (Psi or imcom) as a lightweight instant messenger. Setting up the machine and learning everything about it took a while, but that is why I wrote this document, to save other people time. Here is a list of the packages I have installed on this machine. Currently the drive is about 60% used including the swap and hibernation partitions.

Compiling software is slow and uses memory. If you have a beefier workstation on the network, distcc improves this a lot. Use it.

Games are possible. SVGA Quake is very playable at 320x200. SVGA Quake II is playable at 320x240, but only if the display size is reduced. Higher resolutions are possible, but far too slow. (Set 'VertRefresh 60 60' in libvga.config or higher resolutions will also be completely scrambled.) In general, SVGAlib graphics gives much better performance than any graphics under X, but at the expense of some extra configuration and no way to run the program in a window or in the background. (Performance under X could probably be improved by reducing the display depth to 8bpp, but who wants to do that?) Also, I'm not sure how SVGAlib behaves with power management (FIXME).

Files

Links

Contact

I can be contacted at nemesis@icequake.net. Toshiba's Linux support pages can be found here which includes a useful mailing list for Toshiba Linux users. Information about the SMM/SCI interface used by toshset can be found at Jonathan's pages. General Toshiba Linux laptop stuff can be found at the upper level directory