Sunday, November 24, 2019

DIY Laptop: LCD, part 2

Before starting on the messier parts of the project (heatsink, case etc.) I wanted to be sure that the LCD could actually be made to work: could I get the A1707/A190x LCD to display an image? For that, I would need to connect DisplayPort data lanes to motherboard eDP output in addition to power, AUX and control signals. In early summer, I made several attempts to solder the wires of Quadrangle's unterminated ACES connector to the flexible connector I used to check AUX (see previous post). These were not successful: the wire gauge was a little too large to fit the tiny solder pads, and even when I somehow squeezed them in, Linux kernel's i915 driver showed me that the DisplayPort main link was not going up. It did show that the first stages (clock recovery and equalization) were succeeding, which was peculiar because, as I'd belatedly realized, there was no way ~8Gbps DisplayPort signal could be transmitted through 0.5m of unshielded spaghetti wires of unknown impedance. I obtained a dmesg boot log from a live A190x, and learned that Retina's TCon (LCD controller) is set up to skip DisplayPort clock recovery and equalization stages, probably because the native connector is so short. These observations forced me to rethink my approach: I decided to ditch the wires and make a interposer PCB. Instead of a separate ACES connector part, I could make a DIY card-edge connector by printing the contacts on one side and filing away the other. (Cue Russian "file to fit" joke.) The I-PEX receptacle I could lift from a dead LCD. aces2retina PCB This took a while to design because I was worried about screwing up the impedance again and went as far as simulating it in an EM simulator, and a few weeks more until the PCB came back from OSHPark. In the interval I bought myself a starter SMD rework station and gave it a whirl, but it was obvious that I couldn't hope to resolder the delicate 0.35mm pitch I-PEX connector with my basic equipment and even more basic skills. A friend's repairman friend, M. Grekhov of НоутбукOFF, graciously agreed to help me out with the I-PEX, though, and the rest of the parts (a couple of LEDs to indicate LCD power and HPD) I could manage myself. The complete item worked perfectly the first time I tried it, which was most gratifying. I could see the cloned Windows desktop on the Retina if I shone a flashlight behind it. Besides the DisplayPort data and AUX, this PCB breaks out the backlight and I2C connections, so I'll be able to use it to design a backlight power supply and control circuit.

Saturday, April 13, 2019

DIY laptop: LCD

To pick up on the DIY laptop project post from a year ago. Since then, I gradually developed an aversion to the idea of buying a p5x. Besides, it would be fun to build a piece of hardware for a change from software. My standard was still 15" Thinkpad T61/T500. Coffee Lake and 300-series chipsets having come out, I searched for Thin Mini-ITX motherboards with a 300-series chipset and an embedded DisplayPort output. There aren't many, and there are no consumer-oriented ones so far, but some AsRock and MiTAC industrial motherboards fit the bill. I bought a MiTAC PH12FEI through their German distributor, an unterminated ACES 88441-040 cable from Quadrangle, and the standard Thin Mini-ITX cooler, HTS1155LP, to use until I get around to making a thinner one (HTS1155LP is 26mm thick and the keyboard would have to go on top of it, making the body too thick for my taste). I decided on reusing stock parts as much as possible, so I bought a dead T500 (minus LCD screen) for $20. It would also provide the keyboard and trackpad connectors, which aren't otherwise readily available.

As it happens, A1398's Retina LCD is a centimeter too big to fit into T500's LCD housing. I briefly considered a completely custom lid, which would also save about 5mm in height, but hinges and hinge mounting would be a problem. Also that LCD model is now quite old. On the other hand, A1707 is narrower and there were indications that its LCD would possibly fit. Therefore, I obtained a cracked but functional A1707 LCD, p/n LSN154YL03, from a repair shop for $15, and it fits perfectly - there is not even 0.5mm of space anywhere. The crucial question for the whole project was whether I could get it to work with the motherboard. Panelook shows that this LCD, like the older one, has a 40-pin eDP interface. Mike of Mike's Mods had already shown that the older LCD does not need any special initialization, and I could reasonably expect that this would be the case with the newer one.

This was absolutely no fun to solder.

I could figure out most of the pinout from labeled test points on the controller board and from the pattern of ground lines. I was saved the trouble of figuring out which pair of differential wires was AUX, and the polarity, because schematics are now easily found on the global garbage dump internet. The LCD connector is, however, different from the older model, probably due to space restrictions in the smaller and thinner A1707. It is quite distinctive, and a search by pin pitch and count quickly turned up the part - it is I-PEX NOVASTACK 35-HDP 42p+4p, p/n 20698-042E-01, or an equivalent. It goes without saying that this part is not carried by the usual distributors. I resorted to scavenging them from replacement LCD "cables" (actually a small flexible PCB with two of these I-PEX plugs on opposite sides) sold on eBay. I figured that at the minimum I had to connect power, HPD, AUX and EDP_PWR_EN lines to get the LCD up and running. The controller apparently needs +5V and +3.3V, but I could take both from the motherboard's LCD power voltage jumper. As for EDP_PWR_EN, I connected it to one of the CABLE_ID pins of the motherboard's eDP connector which always has +3.3V on it.

First I carefully removed one of the plugs with a hot plate and tried soldering wires directly to the plug's pins, but the plugs' plastic is very weak mechanically and instantly melts if accidentally touched by the soldering iron. I had better luck with soldering wires to the flexible PCB with the remaining plug. I had to use superglue to hold down the three AUX wires after they were soldered, because (another lesson learned) a careless swipe can easily tear off a contact pad off the flexible PCB. It took a few hours, but the connector worked and Windows detected the LCD as 2880x1800, device name APPA031, meaning I can proceed with the project. The next big hurdle is the heatsink mod.