The Lenovo Thinkpad X230, T430 & T530 generation have a battery authenticity check built in the embedded controller. This prevents aftermarket batteries from being charged. Luckily the EC can be patched.

1. Update firmware

Lenovo has updated their firmware which prevents this patch. It’s best to update the Thinkpad’s firmware, which includes BIOS and Embedded Controller, to the version listed below, but not newer. You can download the firmware updates on the Lenovo driver page. To find out your current BIOS version, boot into the BIOS setup.

laptop last good
t430 BIOS 2.81 (G1ETC1WW) EC 1.13 (G1HT35WW)
t430s BIOS 2.75 (G7ETB5WW) EC 1.16 (G7HT39WW)
t530, t530i BIOS 2.76 (G4ETB6WW) EC 1.13 (G4HT39WW)
w530 BIOS 2.75 (G5ETB5WW) EC 1.13 (G4HT39WW)
x230 BIOS 2.75 (G2ETB5WW) EC 1.14 (G2HT35WW)
x230t BIOS 2.73 (GCETB3WW) EC 1.14 (GCHT25WW

You can download the image I created to update my Thinkpad X230t to BIOS 2.73.

Copy the firmware to a USB drive

sudo dd if=gcuj32us.img of=/dev/sdx bs=4M status=progress conv=fsync

Boot from this USB drive and apply the update.

There is a caveat: the update mechanism requires a fully charged battery to be present. This was a problem since my original battery was dead and the aftermarket battery hardly had a charge. This cancelled the update. However when I rebooted, a message appeared saying the EC was being updated! So the BIOS wasn’t updated, but the EC was! This can be checked in the BIOS setup.

Now we can create our patched firmware.

2. Patch the firmware

Clone the repository

git clone
cd thinkpad-ec

Check if your laptop model is included in the patch

make list_laptops

Configure the patch

This patch was originally made to allow the use of old style thinkpad keyboards (like in the X220. Best keyboards ever!) by modifying the EC. This keyboard patch is enabled by default. The battery patch is disabled by default. Change this to the use case.

make patch_disable_keyboard clean && make patch_enable_battery clean

Build the patched firmware

Now we will build the firmware image for the thinkpad X230t

make patched.x230t.img

Make sure you have all the needed built tools installed. This will take a couple of minutes.

My image only had the battery patch enabled.

Write patched firmware to USB drive

sudo dd if=patched.x230t.img of=/dev/sdx bs=4M status=progress conv=fsync

Boot from the USB drive to apply the patch

Follow the on screen instructions.

Reboot and check if the battery can be charged.