x330

Published on 2019-10-26 by Mohd

I ordered an x330, which is a modified x230 with a few goodies:

I bought it from an independent Chinese seller who goes by the name xueyao on the internet.

The laptop came with a Chinese version of Windows pre-installed, which I got rid of right away.

Getting it up and running took close to a complete day.

From playing around with the keys I discovered that I can get rid of the black screen by pressing the escape key on the grub menu. Pressing escape brings up the option to either install or try the live environment.

Executing xrandr on the terminal had this output:

Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 8192 x 8192
VGA-1 disconnected (normal left inverted right x axis y axis)
HDMI-1 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
HDMI-2 disconnected (normal left inverted right x axis y axis)
HDMI-3 disconnected (normal left inverted right x axis y axis)
DP-2 disconnected (normal left inverted right x axis y axis)
DP-3 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 294mm x 165mm
   1920x1080     59.93*+

Through research I amended my /etc/default/grub file with the following:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash video=LVDS-1:d video=DP-1:d video=VGA-1:d video=DP-2:d video=DP-3:e"

And voila, no more black screen on boot.

On the thinkpad touchpad the middle area is mapped to the middle mouse button. This is very annoying because the touchpad is small, and I often accidentally click the middle mouse button area when I want to left click. Here's how to disable the middle mouse button area and map the touchpad to the left and right clicks.

xinput command lists the input devices:

⎡ Virtual core pointer                    		id=2	[master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer              	id=4	[slave  pointer  (2)]
⎜   ↳ SynPS/2 Synaptics TouchPad              	id=11	[slave  pointer  (2)]
⎜   ↳ TPPS/2 IBM TrackPoint                   	id=12	[slave  pointer  (2)]
⎣ Virtual core keyboard                   		id=3	[master keyboard (2)]
    ↳ Virtual core XTEST keyboard             	id=5	[slave  keyboard (3)]
    ↳ Power Button                            	id=6	[slave  keyboard (3)]
    ↳ Video Bus                               	id=7	[slave  keyboard (3)]
    ↳ Sleep Button                            	id=8	[slave  keyboard (3)]
    ↳ Integrated Camera: Integrated C         	id=9	[slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard            	id=10	[slave  keyboard (3)]
    ↳ ThinkPad Extra Buttons                  	id=13	[slave  keyboard (3)]

We are interested in the SynPS/2 Synaptics TouchPad device, which has an id of 11.

xinput get-button-map 11
1 2 3 4 5 6 7

Here the 2 stands for our middle mouse button. We can get rid of it like so:

id=$(xinput | grep TouchPad | cut -d '=' -f 2 | cut -f 1)
xinput set-button-map $id 1 1 3 4 5 6 7

I discovered that the laptop would sometimes die when I closed the lid instead of sleeping. I disabled sleeping on lid close like so:

echo "LID " > /proc/acpi/wakeup

I invoked the mouse fix and lid fix from a start up script:

sudo sh ~/.local/bin/lid.sh
sudo sh ~/.local/bin/mouse.sh
sudo powertop --auto-tune
xmodmap -e "keysym Caps_Lock = Mode_switch Mode_switch"

Along with invoking the mouse fix and lid fix, this script also uses powertop to optimize power management and maps the capslock key to Mode_swtch.

installing new linux distros

The LVDS issues can make it annoying to install a new linux distro. You have to launch the live cd installer with the video=LVDS-1:d video=DP-3:e kernel CMD modifiers. Then once the system is installed, you have to use the live cd to update the /etc/default/grub file and then rebuild grub configs with update-grub. See run update-grub from live-cd for more details.

x330