Author Topic: Htc Universal  (Read 595810 times)

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #45 on: April 17, 2008, 06:54:33 am »
OK, intermediate report, going quite well...

I've booted the Zdevil's clean and configured tarball, started x, obviously the display doesn't work. Will try to see if it's just the pointercal, copied one over from the OpenMoko image, which worked, so will try to see if it works with that.

Otherwise, it would be using another device for the input. If this is so, which one?
[span style=\'font-size:8pt;line-height:100%\']Das ganze tschechische Volk ist eine Simulantenbande.[/font][/span]
Militäroberarzt Bautze

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #46 on: April 17, 2008, 07:08:24 am »
Update, this doesn't solve it, so it's (probably logically) another device than on the Z. I've also noted no modules are loaded after starting.

datathief, do you have a base rootfs which maybe I should start from and disregard the Z rootfs, if that would be a better solution?
[span style=\'font-size:8pt;line-height:100%\']Das ganze tschechische Volk ist eine Simulantenbande.[/font][/span]
Militäroberarzt Bautze

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #47 on: April 17, 2008, 07:25:48 am »
Quote from: ShiroiKuma
OK, intermediate report, going quite well...

I've booted the Zdevil's clean and configured tarball, started x, obviously the display doesn't work. Will try to see if it's just the pointercal, copied one over from the OpenMoko image, which worked, so will try to see if it works with that.

Otherwise, it would be using another device for the input. If this is so, which one?
I don't remember having difficulty getting X running, but it's been a while.  Try setting TS_DEVICE=/dev/input/event0.

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #48 on: April 17, 2008, 08:03:02 am »
Quote from: datathief
I don't remember having difficulty getting X running, but it's been a while.  Try setting TS_DEVICE=/dev/input/event0.
Will try... You wouldn't remember which rootfs you used then, when you got started, would you?
[span style=\'font-size:8pt;line-height:100%\']Das ganze tschechische Volk ist eine Simulantenbande.[/font][/span]
Militäroberarzt Bautze

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #49 on: April 17, 2008, 08:40:05 am »
Quote from: datathief
I don't remember having difficulty getting X running, but it's been a while.  Try setting TS_DEVICE=/dev/input/event0.
This had no effect apparently, perhaps I'll try ts_calibrate before X, to see if it makes any difference.
[span style=\'font-size:8pt;line-height:100%\']Das ganze tschechische Volk ist eine Simulantenbande.[/font][/span]
Militäroberarzt Bautze

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #50 on: April 17, 2008, 09:11:37 am »
Quote from: ShiroiKuma
You wouldn't remember which rootfs you used then, when you got started, would you?
I used debootstrap to build the rootfs, and the packages at http://yonggun.tistory.com/54 to get X working.

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #51 on: April 17, 2008, 09:14:47 am »
Quote from: ShiroiKuma
Quote from: datathief
I don't remember having difficulty getting X running, but it's been a while.  Try setting TS_DEVICE=/dev/input/event0.
This had no effect apparently, perhaps I'll try ts_calibrate before X, to see if it makes any difference.
Is there any helpful output from the X server?  Can you start Xfbdev from the command line?
Code: [Select]
TS_DEVICE=/dev/input/event0 Xfbdev & pid=$!; sleep 10s; pkill $pid
EDIT: I think it's TSLIB_TSDEVICE, not TS_DEVICE.  Oops.
« Last Edit: April 17, 2008, 09:30:46 am by datathief »

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #52 on: April 17, 2008, 09:25:34 am »
Quote from: datathief
Quote from: ShiroiKuma
Quote from: datathief
I don't remember having difficulty getting X running, but it's been a while.  Try setting TS_DEVICE=/dev/input/event0.
This had no effect apparently, perhaps I'll try ts_calibrate before X, to see if it makes any difference.
Is there any helpful output from the X server?  Can you start Xfbdev from the command line?
Code: [Select]
TS_DEVICE=/dev/input/event0 Xfbdev & pid=$!; sleep 10s; pkill $pid
Hang on...  I've taken a look in the packages from http://yonggun.tistory.com/54 and found where the touchscreen device is configured.  This may not apply to the packages you're using, but anyway...
  • Edit /etc/profile.d/tslib.sh, and change /dev/input/ts0 to /dev/input/event0
  • Log out or reboot
  • Start X
I think event0 is correct  -  if I do cat -v /dev/input/event0, I get output when I touch the screen.

desertrat

  • Hero Member
  • *****
  • Posts: 743
    • View Profile
    • http://
Htc Universal
« Reply #53 on: April 17, 2008, 10:44:39 am »
Quote from: datathief
The SD card slot is occupied when running Linux (there's no way to install to the internal flash yet).
Does it do SDHC?
« Last Edit: April 17, 2008, 10:47:11 am by desertrat »
SL-C3100 / Ambicon WL1100C-CF / pdaXrom 1.1.0beta3 / IceWM

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #54 on: April 17, 2008, 11:04:09 am »
Quote from: datathief
  • Edit /etc/profile.d/tslib.sh, and change /dev/input/ts0 to /dev/input/event0
  • Log out or reboot
  • Start X
I think event0 is correct  -  if I do cat -v /dev/input/event0, I get output when I touch the screen.
Allright, didn't get as far as tslib.sh, but I copied /etc/ts.conf from the OpenMoko rootfs and then could run ts_calibrate and now the touchscreen works in X.

Now I'm trying to start X as a normal user, not as root.

When I run from a normal account created, I keep getting[div class=\'codetop\']CODE[/div][div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']$ startx
X: cannot stat /etc/X11/X (No such file or directory), aborting.
xinit:  Server error.[/div]

So far haven't been able to fix this. Am searching on the web for pointers, but other than saying dpkg-reconfigure xorg or whatever not much. Any hints?
« Last Edit: April 17, 2008, 11:04:36 am by ShiroiKuma »
[span style=\'font-size:8pt;line-height:100%\']Das ganze tschechische Volk ist eine Simulantenbande.[/font][/span]
Militäroberarzt Bautze

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #55 on: April 17, 2008, 12:06:10 pm »
Quote from: ShiroiKuma
[div class=\'codetop\']CODE[/div][div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']$ startx
X: cannot stat /etc/X11/X (No such file or directory), aborting.
xinit:  Server error.[/div]

So far haven't been able to fix this. Am searching on the web for pointers, but other than saying dpkg-reconfigure xorg or whatever not much. Any hints?
Try making a link to Xfbdev:
Code: [Select]
ln -s `which Xfbdev` /etc/X11/X

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #56 on: April 17, 2008, 12:21:50 pm »
FYI, I've fixed a bug in htcunid (it crashed if the phone was suspended while GPRS was in use), and uploaded a proper htcunid.deb.  I'll try to put together a deb of the other stuff (keymap, sound, and keyboard and power hacks).

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #57 on: April 17, 2008, 04:17:03 pm »
Quote from: datathief
Try making a link to Xfbdev:
Code: [Select]
ln -s `which Xfbdev` /etc/X11/X
I kept thinking why it would require a symlink that root doesn't require when starting X. Of course, the answer is simple. Since the simple user didn't have the same path definitions as rot etc. So I copied over .profile and .xserverrc from /root directory.

However now there is again something that beats me. I get:
Code: [Select]
$ startx


Fatal server error:
LinuxInit: Server must be suid root

giving up.

And this though
Code: [Select]
# chmod u+s `which X` went through with no problem.

What the? Currently cannot move on this.
[span style=\'font-size:8pt;line-height:100%\']Das ganze tschechische Volk ist eine Simulantenbande.[/font][/span]
Militäroberarzt Bautze

ZDevil

  • Hero Member
  • *****
  • Posts: 1998
    • View Profile
    • http://
Htc Universal
« Reply #58 on: April 18, 2008, 04:03:24 am »
So ShiroiKuma did you manage to get X running as root?

Life is too precious for hacking *too much*
Visit my Z screencap gallery[/color]
My EeePC 701 Black = Debian (Lenny) on IceRocks + Transcend SDHC Class6 8GB + 2GB RAM
My Zaurus SL-C3200 = Debian EABI (kernel 2.6.24.3-yonggun) on a swapped internal Sandisk Extreme III CF 16gb
My Debian EABI feed: http://matrixmen.free.fr/zaurus/debian/
My OpenBSD/Zaurus feeds:  Link1, Link2
[/i][/font][/color][/size]

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #59 on: April 18, 2008, 06:32:09 am »
Quote from: ZDevil
So ShiroiKuma did you manage to get X running as root?
As root it runs no prob.

But I'd like to get it to run as a regular user. Now, the problem seems to be centered around /usr/bin/Xfbdev

If I suid it, then even trying to start X as root gives me the above error that Server has to be suid... What the...?

If I chmod it 755 again, then as root I can start and run no prob, sudo startx starts it, but the touchscreen doesn't work, starting as regular user gives me the above error?

I'm just about to check your thread on the clean configured tarball. Did you encounter problems there creating and running as normal user? Or did nobody do that? Doesn't seem smart to me to run the environment as root.
[span style=\'font-size:8pt;line-height:100%\']Das ganze tschechische Volk ist eine Simulantenbande.[/font][/span]
Militäroberarzt Bautze