Author Topic: Htc Universal  (Read 718137 times)

ArchiMark

  • Administrator
  • Hero Member
  • *****
  • Posts: 1830
    • View Profile
Htc Universal
« Reply #105 on: April 23, 2008, 06:17:24 pm »
Quote from: ArchiMark
USB Ethernet?

Trying to use ethernet through my Linksys USB200M v.2.1 device....at first I got message that there wasn't enough power, so connected up my lil' HP mini-hub and then there's enough power....

Now, to get connected to internet, do I need to do the 2nd section of the Titchy Mobile instructions titled 'Setting Up a USB Network' ?

If that is not what I should do, what should I do to get ethernet working?

Quote from: datathief
I don't think the phone even supports USB peripherals (I don't have an adaptor to try).  The USB network instructions are for connecting via a USB cable to a PC.

OK, I get it now....however, I do think that it recognizes that I've plugged something in...at least I think so..

Quote
Keyboard - Symbols??

If so, how do I type the '>' symbol??? I don't see it on the keyboard....I tried the 'sym' key but I get the '|' symbol when I click that key....
Quote
Shift-: = >
Shift-; = <
SYM = |
Fn-SYM = `

Got it, THANKS!


Quote
WiFi - UPDATE

As for WiFi, I just re-read instructions and realized that I needed to install 'firmware.tar.gz' and then per instructions:

Code: [Select]
modprobe htcuniversal-acx  (message says "forcing power off...is that OK??)
modprobe acx

....did that and now I see that wlan0 interface recognized in 'ifconfig -a'

I tried 'iwconfig wlan0 rate 1M per instructions, but get message that this is unknown command or something like that....

If I do 'ifup wlan0', console 'goes crazy' with continual scrolling of text.....no way to stop it....have force shutdown by resetting HTC Universal.....text refers to acx and has lots of numbers on each line as it scrolls by...

Any ideas as to get WiFi working properly??

Quote
Try dmesg -n1 to stop the messages appearing on the console.  Don't do iwconfig wlan0 rate 1M until after you've connected  to the access point.  You could try adding these to your /network/interfaces, e.g.:
Code: [Select]
wlan0 inet dhcp
  pre-up iwconfig wlan0 rate 11M
  post-up iwconfig wlan0 rate 1M

Added lines to interfaces file....

Then I try 'dhclient wlan0' ..... it looks for DHCPOFFERS but says:

Code: [Select]

No DHCPOFFERS received.
No working leases in persistent database - sleeping.

Also, what about 'iwconfig', why isn't it found??? Was it supposed to have been installed during original installation???

Any suggestions?

Quote
AC Power & USB Hub at Sametime?

Also, Is there anyway to connect the AC power to the Uni AND have the USB hub/ethernet device connected at the same time??? Would be nice to be able to do this since I will usually be near an AC power outlet either at home or at work....
Quote
The phone should charge via any powered USB connection, although not as quickly as when connected to AC.  Plug it in and type apm to see if it's charging.

Yes, it says charging....

Thanks!
« Last Edit: April 23, 2008, 07:26:53 pm by ArchiMark »
Silicon Valley Digerati - * Please see my Mini Laptops For Sale Listing *
Cosmo Communicator / One-Netbook One Mix Yoga 3S (Win 10/Manjaro 18)
Banana Pi Zero UMPC/Armbian
MacBookPro
Sold: C3200/N900/OQO/N5/Dell Mini9/Netwalker/UMID M1/

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #106 on: April 23, 2008, 08:49:09 pm »
Quote from: datathief
I had some apm problems when I installed a 3800mAh battery, but once I charged and discharged it completely (to re-calibrate the charging controller) it works fine.
My /proc/apm keeps showing -1% no matter what, which is strange. Do you get normal readings? Did you let it charge and discharge in a specific fashion, or just charged overnight and then left running something?
[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 #107 on: April 24, 2008, 03:40:58 am »
Quote from: ShiroiKuma
My /proc/apm keeps showing -1% no matter what, which is strange. Do you get normal readings? Did you let it charge and discharge in a specific fashion, or just charged overnight and then left running something?
Code: [Select]
# cat /proc/apm
1.13 1.2 0x02 0x00 0x00 0x00 97% 744 min
I didn't do anything special, just charged it fully then let it discharge completely.

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #108 on: April 24, 2008, 03:52:32 am »
Quote from: ArchiMark
OK, I get it now....however, I do think that it recognizes that I've plugged something in...at least I think so..
If you
Code: [Select]
dmesg | tailafter plugging it in, do you see anything that indicates it's recognised it?

Quote
Also, what about 'iwconfig', why isn't it found??? Was it supposed to have been installed during original installation???
Ohhhh... wireless-tools isn't installed.  My fault.  Are you able to connect to the internet using a USB cable and the instructions on the wiki, so you can install wireless-tools?

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #109 on: April 24, 2008, 07:20:48 am »
Quote from: datathief
Quote from: ShiroiKuma
My /proc/apm keeps showing -1% no matter what, which is strange. Do you get normal readings? Did you let it charge and discharge in a specific fashion, or just charged overnight and then left running something?
Code: [Select]
# cat /proc/apm
1.13 1.2 0x02 0x00 0x00 0x00 97% 744 min
I didn't do anything special, just charged it fully then let it discharge completely.
Mine:
[div class=\'codetop\']CODE[/div][div class=\'codemain\' style=\'height:200px;white-space:pre;overflow:auto\']$ apm

$ cat /proc/apm
1.13 1.2 0x02 0xff 0xff 0xff -1% -1 ?[/div]

What the?...
[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 #110 on: April 24, 2008, 07:24:00 am »
Quote from: datathief
Quote from: ShiroiKuma
I think the script needs to check if it's beyond the maximum SMS length and if so, then split into a number of messages and send those in succession.
It's even worse for incoming muiti-part messages:  they get completely mangled.  They seem to have some sort of extra header.  I think this is the last major missing feature  -  I'll see what I can do.
Great.

Regarding missing I'm currently implementing caller ID based on your script which queries a vcard vcf contacts file and displays the caller's name etc. in the whiptail dialog, almost finished, will be done later today probably. Will post.

Furthermore, today I also wanna get dialing from emacs working, i.e. use addressbook-el, with the same vcf file to work with contacts - add, edit, etc. and put in a keybinding that will dial the selected contact. Let's see if I can get that done today too.
[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 #111 on: April 24, 2008, 08:15:12 am »
I'm going to attempt to converge Titchy (for the Zaurus) and Titchy Mobile (for the Uni) into one Debian repository.  For the first step I've got the Titchy X server working on the Uni.  It's a bit of a hack (because it uses EABI packages from Angstrom even though Titchy was OABI) but it's working.

I'll upload it to the wiki (here).

(Has anyone else attempted to install XFCE?  Was it always so huge?  It won't fit on my 512MB SD card.)

ArchiMark

  • Administrator
  • Hero Member
  • *****
  • Posts: 1830
    • View Profile
Htc Universal
« Reply #112 on: April 24, 2008, 11:58:12 am »
Quote from: datathief
Quote from: ArchiMark
OK, I get it now....however, I do think that it recognizes that I've plugged something in...at least I think so..
If you
Code: [Select]
dmesg | tailafter plugging it in, do you see anything that indicates it's recognised it?

OK, I used my USB host cable that I use with my Zaurus and connected it to HTC and my HP USB Mini-hub with HP AC adapter to power it. Then connected up my Linksys 200M v.2.1 USB Ethernet stick to hub.

Here's what I get:

Code: [Select]
#dmesg | tail
[    64.530000] usbcore:  registered new interface driver usbserial
[    64.550000] drivers/usb/serial/usb-serial.c: USB Serial support registered for generic
[    64.570000] usbserial_generic 1-1:1.0: generic converter detected
[    64.590000] usb 1-1: generic converter now attached to ttyUSB0
[    64.590000] usbserial_generic 1-1:1.0: generic converter detected
[    64.610000] usb 1-1: generic converter now attached to ttyUSB1
[    64.610000] usbcore: registered new interface driver usbserial_generic
[    64.620000] drivers/usb/serial/usb-serial.c: USB Serial Driver core
[ 1533.420000] udc: USB reset
[ 1534.530000] ds2760-battery ds2760-battery.0: not enough power to charge

How does that look?

UPDATE

Hmmm...did 'ifconfig -a' and see 'lo' and 'usb0' listed.....

Then I unplugged host cable and plugged in regular USB cable to use to connect to my laptop...when I did that (and before connecting other end to laptop I got the following in console:

Code: [Select]
[  3077.570000] udc: USB reset
[  3078.020000] udc: USB reset
[  3078.210000] usb0: full speed config #1: 100mA, Ethernet Gadget, using CDC Ethernet Subset

So, is there any hope to get ethernet working???


Quote
Also, what about 'iwconfig', why isn't it found??? Was it supposed to have been installed during original installation???

Quote
Ohhhh... wireless-tools isn't installed.  My fault.  Are you able to connect to the internet using a USB cable and the instructions on the wiki, so you can install wireless-tools?

Had a feeling that was problem....just tried downloading wireless-tools from the yonggun webpage to my SD card inserted in my Fujitsu U810 and then installing it using dpkg on my HTC....it complained about dependency with 'libiw28', so wouldn't install it.....

Will try to get it installed using USB cable and your wiki instructions....


Thanks!
« Last Edit: April 24, 2008, 12:06:36 pm by ArchiMark »
Silicon Valley Digerati - * Please see my Mini Laptops For Sale Listing *
Cosmo Communicator / One-Netbook One Mix Yoga 3S (Win 10/Manjaro 18)
Banana Pi Zero UMPC/Armbian
MacBookPro
Sold: C3200/N900/OQO/N5/Dell Mini9/Netwalker/UMID M1/

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #113 on: April 24, 2008, 03:04:15 pm »
Quote from: ShiroiKuma
Quote
It's even worse for incoming muiti-part messages:  they get completely mangled.  They seem to have some sort of extra header.  I think this is the last major missing feature  -  I'll see what I can do.
Great.
I have multi-part messages working  -  but I've only tested with my own phone.  To try to keep the code manageable, I've taken some shortcuts  -  specifically:
  • Unicode messages are split at 63 characters (instead of 70)
  • 7-bit ASCII messages are split at 144 characters (instead of 160)
I think that's a reasonable trade-off for getting multi-part messages working...

Uploading now.

(Are there any important features still missing from htcunid?  What's standing in the way of a 1.0 release now?)
« Last Edit: April 24, 2008, 03:10:30 pm by datathief »

ArchiMark

  • Administrator
  • Hero Member
  • *****
  • Posts: 1830
    • View Profile
Htc Universal
« Reply #114 on: April 24, 2008, 03:10:39 pm »
OK, have setup USB Networking per wiki instructions using eth1 instead of eth0.....as that is my working ethernet connection on my laptop....

I've now got HTC connected to USB hub and USB hub connected to laptop and has USB ethernet device attached. I can get online OK with laptop, using eth1.

It seems like it is working OK from what I can tell....looked at info in 'ifconfig' and 'netstat' on both laptop and HTC....although only see 'lo' and 'usb0' listed on HTC.....

However, when I do 'apt-get update' after updating 'sources.list' I always get the error message below. I have tried several other sources too, so, don't think it's related to sources list....

Code: [Select]

Err http://http.debian.osuosl.org/debian lenny Release.gpg
   Temporary failure resolving 'http.debian.osuosl.org'
Reading package lists.... Done
W: Failed to fetch http://http.debian.osuosl.org/debian lenny Release.gpg
   Temporary failure resolving 'http.debian.osuosl.org'

W: Some index files failed to download, they have been ignored, or old ones used instead.
W: You may want to run apt-get update to correct these problems


From past experience, this usually means that I'm not really connected to net, right?

Just tried pinging my laptop from HTC and I get:

Code: [Select]
#ping -c 5 192.168.3.1
connect: network is unreachable

I do see on my laptop in ifconfig; lo, eth0, eth1, sit0, usb0 interfaces....

Any suggestions?

Thanks!
Silicon Valley Digerati - * Please see my Mini Laptops For Sale Listing *
Cosmo Communicator / One-Netbook One Mix Yoga 3S (Win 10/Manjaro 18)
Banana Pi Zero UMPC/Armbian
MacBookPro
Sold: C3200/N900/OQO/N5/Dell Mini9/Netwalker/UMID M1/

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #115 on: April 24, 2008, 03:40:00 pm »
Quote from: ArchiMark
Just tried pinging my laptop from HTC and I get:

Code: [Select]
#ping -c 5 192.168.3.1
connect: network is unreachable

I do see on my laptop in ifconfig; lo, eth0, eth1, sit0, usb0 interfaces....

Any suggestions?

Thanks!
I just followed the USB network instructions (for the first time ever!) and they worked.  So I'm not sure how to help.

Check that you get the same results as me for these commands:

On the laptop:
Code: [Select]
# ifconfig usb0
usb0      Link encap:Ethernet  HWaddr   
          inet addr:192.168.3.1  Bcast:192.168.3.255  Mask:255.255.255.0


# cat /proc/sys/net/ipv4/ip_forward
1

# iptables -L FORWARD
Chain FORWARD (policy ACCEPT)
target     prot opt source               destination        
ACCEPT     0    --  anywhere             anywhere

# iptables -t nat -L POSTROUTING
Chain POSTROUTING (policy ACCEPT)
target     prot opt source               destination        
MASQUERADE  0    --  192.168.3.0/24       anywhere

On the phone:
# ifconfig usb0
usb0      Link encap:Ethernet  HWaddr   
          inet addr:192.168.3.3  Bcast:192.168.3.255  Mask:255.255.255.0


# route -n
Kernel IP routeing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.3.0     0.0.0.0         255.255.255.0   U     0      0        0 usb0
0.0.0.0         192.168.3.1     0.0.0.0         UG    0      0        0 usb0
« Last Edit: April 24, 2008, 03:43:54 pm by datathief »

ShiroiKuma

  • Hero Member
  • *****
  • Posts: 900
    • View Profile
Htc Universal
« Reply #116 on: April 24, 2008, 03:51:44 pm »
Quote
  • Unicode messages are split at 63 characters (instead of 70)
  • 7-bit ASCII messages are split at 144 characters (instead of 160)
I think that's a reasonable trade-off for getting multi-part messages working...
Probably not a significant drawback now...

I'll test shortly and report.

Quote
(Are there any important features still missing from htcunid?  What's standing in the way of a 1.0 release now?)
I think the caller ID which brings up the callers name, if you have a vcard database. I'm almost finished, just two final bugs with getting it to display properly in your whiptail script.

Should be posted shortly - today.

That's what I think is missing from 1.0.

Also the reverse one, i.e. dialing from a vcard. I'm gonna implement this to work with emacs and addressbook-el, since that's what I care about. Generally though you could reword the script to let's say when "htcunid dial" is called without a number, whiptail would query the vcard database in the same logic that my script for caller ID does, and bring you a pop up menu of all names to call, you'd then enter the one to call, it'd query again for numbers in his vcard and then you'd select the number and call.

This is the last missing part I think to make it really phone like useable.
[span style=\'font-size:8pt;line-height:100%\']Das ganze tschechische Volk ist eine Simulantenbande.[/font][/span]
Militäroberarzt Bautze

ArchiMark

  • Administrator
  • Hero Member
  • *****
  • Posts: 1830
    • View Profile
Htc Universal
« Reply #117 on: April 24, 2008, 04:07:06 pm »
Quote from: datathief
I just followed the USB network instructions (for the first time ever!) and they worked.  So I'm not sure how to help.

Check that you get the same results as me for these commands:

On the laptop:
Code: [Select]
# ifconfig usb0
usb0      Link encap:Ethernet  HWaddr   
          inet addr:192.168.3.1  Bcast:192.168.3.255  Mask:255.255.255.0


# cat /proc/sys/net/ipv4/ip_forward
1

# iptables -L FORWARD
Chain FORWARD (policy ACCEPT)
target     prot opt source               destination        
ACCEPT     0    --  anywhere             anywhere

# iptables -t nat -L POSTROUTING
Chain POSTROUTING (policy ACCEPT)
target     prot opt source               destination        
MASQUERADE  0    --  192.168.3.0/24       anywhere

On the phone:
# ifconfig usb0
usb0      Link encap:Ethernet  HWaddr   
          inet addr:192.168.3.3  Bcast:192.168.3.255  Mask:255.255.255.0


# route -n
Kernel IP routeing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.3.0     0.0.0.0         255.255.255.0   U     0      0        0 usb0
0.0.0.0         192.168.3.1     0.0.0.0         UG    0      0        0 usb0


Thanks, datathief....here's what I see on my equipment, some differences, have also included eth1 since that's what I used in USB Networking setup and seems to me to be active.

Note differences in address in 'ifconfig' listing and nothing listing on HTC for 'route -n' for example....

On the laptop:
# ifconfig usb0
usb0      Link encap:Ethernet  HWaddr
                  BROADCAST MULTICAST  MTU:1500 Metric:1
                  RX Packets:0 errors:0 dropped:0 overruns:0 frame:0
                  TX Packets:0 errors:0 dropped:0 overruns:0 carrier:0
                  collisions:0 rxqueuelen:1000
                  RX bytes:0 (0.0b)  TX bytes:0 (0.0b)

eth1      Link encap:Ethernet  HWaddr

                  inet addr:10.xxx.xx.74 Bcast:10.241.xx.255  Mask: 255.255.255.0
                  inet6 addr: fe80::21d:7eff:fe00:6857/64 Scope:Link
                  UP BROADCAST RUNNING MULTICAST  MTU:1500 Metric:1
                  RX Packets:6095 errors:0 dropped:0 overruns:0 frame:0
                  TX Packets:476 errors:0 dropped:0 overruns:0 carrier:0
                  collisions:0 rxqueuelen:1000
                  RX bytes:1649656 (1.5 Mib)  TX bytes:33771 (32.9 Kib)



# cat /proc/sys/net/ipv4/ip_forward
1

# iptables -L FORWARD
Chain FORWARD (policy ACCEPT)
target     prot opt source               destination        
ACCEPT     0    --  anywhere             anywhere

# iptables -t nat -L POSTROUTING
Chain POSTROUTING (policy ACCEPT)
target     prot opt source               destination        
MASQUERADE  0    --  192.168.3.0/24       anywhere


On the phone:
# ifconfig usb0
usb0      Link encap:Ethernet  HWaddr   
                  UP BROADCAST RUNNING MULTICAST  MTU:1500 Metric:1
                  RX Packets:74 errors:0 dropped:0 overruns:0 frame:0
                  TX Packets:256 errors:0 dropped:0 overruns:0 carrier:0
                  collisions:0 rxqueuelen:1000
                  RX bytes:5448 (5.3 Kib)  TX bytes:67984 (66.3 Kib)

        
# route -n
Kernel IP routeing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
Silicon Valley Digerati - * Please see my Mini Laptops For Sale Listing *
Cosmo Communicator / One-Netbook One Mix Yoga 3S (Win 10/Manjaro 18)
Banana Pi Zero UMPC/Armbian
MacBookPro
Sold: C3200/N900/OQO/N5/Dell Mini9/Netwalker/UMID M1/

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #118 on: April 24, 2008, 04:12:02 pm »
Quote from: ShiroiKuma
Also the reverse one, i.e. dialing from a vcard. I'm gonna implement this to work with emacs and addressbook-el, since that's what I care about. Generally though you could reword the script to let's say when "htcunid dial" is called without a number, whiptail would query the vcard database in the same logic that my script for caller ID does, and bring you a pop up menu of all names to call, you'd then enter the one to call, it'd query again for numbers in his vcard and then you'd select the number and call.
I'll have a go once your caller-ID script is done.

When I have the time, I'll tidy up a few things (outputting "0" for a successful operation isn't very user-friendly), and call it 1.0.  Then I can start on the new and innovative stuff:
  • Different ringtones for different times of day.
  • Check my e-mail for invitations, and be silent if I'm in a meeting.
  • ...
That's all I can think of at the moment

datathief

  • Full Member
  • ***
  • Posts: 205
    • View Profile
Htc Universal
« Reply #119 on: April 24, 2008, 04:16:18 pm »