olm3ca / Galaxy-Chromebook

Mac OS, Linux and other systems on the Samsung Galaxy Chromebook
65 stars 4 forks source link

Touchscreen doesn't work #3

Closed CabbageSong closed 3 years ago

CabbageSong commented 3 years ago

Hello:

Thank you for your tutorial for running linux on galaxy chromebook! I try to install ubuntu on this chromebook, but the touchscreen doesn't work (spen works). I try to install manjaro as you recomment which is no different. However, what surprises me is that it works after I close and reopen the laptop.

It confuses me a lot and I don't know why the screen works like this. BTW, the version of Ubuntu I installed is 21.10 and version of Manjaro (KDE) is 21.1.6, both of which own the kernel later than 5.10.

Thanks a lot!

olm3ca commented 3 years ago

Hi, glad you tried it out. I don't recommend Ubuntu actually, they don't have the audio driver working natively yet so you'll have to configure it. I recommend Manjaro (latest version) or Fedora 35. I use Fedora now and everything works really well, on first installation the sound and brightness work. For me the touchscreen doesn't work, but for another user it does. I haven't time to investigate it as I don't need that, the pen works just fine.

CabbageSong commented 3 years ago

Hi, thank you for your reply. The audio doesn't work in Manjaro (latest version) as well. I don't know if there is something wrong with the firmware or drivers. I'll try to install Fedora on it.

olm3ca commented 3 years ago

That's strange about Manjaro, audio should work. I think you'll be pleased with Fedora though, try it. It's quite easy to use.

mingming1222 commented 3 years ago

Hi, @CabbageSong I installed fedora on my galaxy chromebook, here are some of my experiences, hope they help you. I referenced this repository: https://github.com/jmontleon/pixelbook-fedora/tree/main/kernel, compiled my own linux kernel, modified filter-modules.sh.fedora, added a populated kernel-local with the chromeos / cros_ec modules enabled, and for the touch screen, disable atmel touch module, add enable elan touch module. This will make the touch screen work properly. But the accel sensor is still having problems and I haven't figured out how to get it to work correctly.

Here is my config file: https://github.com/mingming1222/galaxy-chromebook-linux

olm3ca commented 3 years ago

@mingming1222 that is really great. thanks for sharing. So does your audio work 100% with your own kernel and cros_ec? The headphone jack and everything?

mingming1222 commented 3 years ago

The audio is working, but the output device shows headphones, the headphone jack is not working. The audio input does not work either.

image

@mingming1222 that is really great. thanks for sharing. So does your audio work 100% with your own kernal and cros_ec? The headphone jack and everything?

olm3ca commented 3 years ago

Ok, so that's the same as what I have. It's fine with me though, I can use bluetooth headphones when I don't want to use the speakers.

Quick question about the touchscreen, please: when you say, "disable atmel touch module, add enable elan touch module." Can you detail the steps you took to do this?

mingming1222 commented 3 years ago

@olm3ca I mean that when compiling the kernel, the option CONFIG_TOUCHSCREENATMELMXT must be N and the option CONFIG_TOUCHSCREEN_ELAN must be Y

image image

CabbageSong commented 3 years ago

Hi, @mingming1222 @olm3ca thanks a lot for your helpful suggestions. Sorry for replying late because I'm not good at building kernel which takes lots of time. With tips from @mingming1222 on kernel part, I made some progress on kernel modules.

At the begining, I try to build the kernel without the driver of atmel. However, I checked the config file in /boot/ and found the drive of elan touchscreen is already built in vmlinuz. And then, here comes an idea to just disable the atmel driver.

I add _blacklist atmel_mxtts to /etc/modprobe.d/blacklist.conf and it works after reboot. Maybe it is driver module of atmel which hijacks the touch of chromebook.

olm3ca commented 3 years ago

@CabbageSong - that is the solution! Nice job, that is very simple. I'll add that to the instructions on the repo. Thanks!

olm3ca commented 3 years ago

Also, one last thing @CabbageSong - I realized why sound wasn't working for you on Manjaro. On the latest builds, it appears we now need to install sof-firmware for sound to work. Before it was configured automatically.

CabbageSong commented 3 years ago

Hi @olm3ca , thank you for reinstalling Manjaro for validation. I return to Ubuntu at last. After installing sof-firmware-signed, the sound works but doesn't work well. The mic and headphone are not detected. Honestly, it doesn't matter for me, but I'll try to find ways to get it work.

olm3ca commented 3 years ago

@mingming1222 @CabbageSong not sure if either of you use Windows, but driver support just improved quite a bit with the touchpad and touchscreen working. Still no audio, but this is a lot better now.

CabbageSong commented 3 years ago

@mingming1222 glad to see that the driver support improves. Recently, I find a method to get drivers from linux subsystem https://github.com/flantel/pixelbook-linux , which take advantage of alsa from google to drive audio. It seems to work for pixelbook, but I don't know how to make it for galaxy chromebook. Hope it helps for you.

BTW, there may be some bugs on GPU for linux. Cause 4k video in Ubuntu is not fluent, while it is fine in ChromeOS.

olm3ca commented 3 years ago

@CabbageSong - I used that method on the Pixelbook. It required using the ChromeOS kernel, so that the audio server would connect, that was the only way to make sound work on Ubuntu at the time. My thinking is sof-firmware will improve in time. But if you're up to the challenge, that would be interesting...