maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Alternatives (https://talk.maemo.org/forumdisplay.php?f=36)
-   -   [Android] Another Android port: NITdroid (https://talk.maemo.org/showthread.php?t=25410)

Bundyo 2009-01-04 22:39

Re: Another Android port: NITdroid
 
That's because there's no init in the latest rootfs. If you can find a previous one :)

stelleg151 2009-01-04 23:19

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by Bundyo (Post 254453)
That's because there's no init in the latest rootfs. If you can find a previous one :)

Thats what I figured, any idea where an older rootfs is? Or maybe I should just create a maemo one temporarily for testing. I assume your kernel is based off of 2.6.28?

Another thought: maybe I could do a diff of your kernel with the android kernel to figure what changes to make to boot from an init-less rootfs.

Edit: I see in Solca's earlier post what happened.

By the way, your sig is awesome.

stelleg151 2009-01-05 01:44

Re: Another Android port: NITdroid
 
@Solca: Your config file has a reference to a local file for CONFIG_INITRAMFS_SOURCE.

stelleg151 2009-01-05 02:22

Re: Another Android port: NITdroid
 
Ok so just for fun I pulled most of the emulator's rootfs out using adb and put it into my ext3 partition to be loaded by Bundyo's kernel. Doing this got me a new init error:

Code:

Kernel panic - not syncing; Attempted to kill init!
I also got this message with Solca's rootfs + init and init.rc from emulator.

Any ideas? I'm afraid I'm still pretty new at this stuff so I apologize if that was a useless idea.

solca 2009-01-05 06:13

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by cyrus (Post 254275)
Has the kernel patch not changed then? I have kept each file as you have updated and diffed the old one vs the new one and there are no differences.

The kernel patch it is the same, for the precompiled kernels I'm using now the pm branch of the omap tree plus my kernel patch.

Quote:

Originally Posted by stelleg151 (Post 254489)
Any ideas? I'm afraid I'm still pretty new at this stuff so I apologize if that was a useless idea.

The next release will include init again but you need Bundyo's kernel to run on N770.

Bundyo 2009-01-05 06:52

Re: Another Android port: NITdroid
 
Yes, I'll update it when i have the init though :) And release the patches/config.

solca 2009-01-05 10:37

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by Bundyo (Post 254527)
Yes, I'll update it when i have the init though :) And release the patches/config.

Well, you don't have too wait any longer as there is a new NITdroid release (0.3.1) :)

EDIT: There is a new #NITdroid IRC channel on freenode too if somebody wants to lurk or chat about it.

Barret 2009-01-05 17:08

Re: Another Android port: NITdroid
 
thanks for the update :) ...
Unfortunately the n810 tells me "Unable to start Wi-Fi" now :(... anyone else got the problem?
---------- edit ---------------
works after re-formatting and flashing again

gowen 2009-01-05 19:54

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by solca (Post 254553)
Well, you don't have too wait any longer as there is a new NITdroid release (0.3.1) :)

I have two issues on my N800.
1) I'm finding that setting the correct time and date (in 0.3.1) isn't surviving a shutdown and restart.
2) Buttons, including the soft keyboard, only work if I press the top left corner.

Thanks to you and bundyo for all your hard work.

solca 2009-01-05 22:53

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by gowen (Post 254667)
I have two issues on my N800.
1) I'm finding that setting the correct time and date (in 0.3.1) isn't surviving a shutdown and restart.

I get the time at init from retutime but I never set it on shutdown, good idea.
Quote:

2) Buttons, including the soft keyboard, only work if I press the top left corner.
Hmm that's not good, does this work before 0.3.1 or it is some new issue now? can you describe it in more datils?

stelleg151 2009-01-05 23:10

Re: Another Android port: NITdroid
 
Bundyo: any chance you could release the source to your miracle kernel?

Bundyo 2009-01-05 23:28

Re: Another Android port: NITdroid
 
Yep, soon, sorry, doing something else and doesn't have the time to clean it up.

gowen 2009-01-06 09:17

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by solca (Post 254735)
I get the time at init from retutime but I never set it on shutdown

My clock is always about 2 hours 15 minutes off after a power cycle. It's keeping time OK, but just needs an offset to local time.

Quote:

Originally Posted by solca (Post 254735)
Hmm that's not good, does this work before 0.3.1 or it is some new issue now? can you describe it in more datils?

I had the problem since my first install of NITdroid (around 18th December). I'm thinking this may be a screen calibration problem. I found the pointer location app in DevTools and this shows that at the bottom of the screen the calibration is off by about 4mm. There is quite a bit of variation across screen with only the centre left edge having no error.

Is there a screen calibration app in Android?

Finally, I can't get 0.3.1 to return from screen blanking. Once it's gone blank pressing the keys or the screen has no effect. Eventually, it seems to power off as pressing the power key will produce a restart. Strangely, when adb is connected running logcat, it will recover. Here is the logcat trace, although I'm not sure it will be much use.

Code:

**** screen blanks ****
W/ActivityManager(  682): Unable to start service Intent { action=android.accounts.IAccountsService comp={com.google.android.googleapps/com.google.android.googleapps.GoogleLoginService} }: not found
E/LockPatternKeyguardView(  682): Failed to bind to GLS while checking for account
D/dalvikvm(  682): GC freed 15372 objects / 702696 bytes in 211ms

**** keys pressed ****

D/KeyguardViewMediator(  682): wakeWhenReadyLocked(26)
D/KeyguardViewMediator(  682): handleWakeWhenReady(26)
D/KeyguardViewMediator(  682): pokeWakelock(10000)
D/KeyguardViewMediator(  682): wakeWhenReadyLocked(82)
D/KeyguardViewMediator(  682): handleWakeWhenReady(82)
D/KeyguardViewMediator(  682): pokeWakelock(10000)
W/KeyCharacterMap(  682): Can't open keycharmap file
W/KeyCharacterMap(  682): Error loading keycharmap file '/system/usr/keychars/Internal_keypad.kcm.bin'. hw.keyboards.0.devname='Internal keypad'
W/KeyCharacterMap(  682): Using default keymap: /system/usr/keychars/qwerty.kcm.
bin
D/KeyguardViewMediator(  682): pokeWakelock(10000)
D/KeyguardViewMediator(  682): pokeWakelock(10000)

**** screen blanks ****

W/ActivityManager(  682): Unable to start service Intent { action=android.accounts.IAccountsService comp={com.google.android.googleapps/com.google.android.googleapps.GoogleLoginService} }: not found
E/LockPatternKeyguardView(  682): Failed to bind to GLS while checking for account


stelleg151 2009-01-06 18:39

Re: Another Android port: NITdroid
 
Hey Guys, got android up and running on my 770 (thanks solca, bundyo, rzr), but adb bridge no go. USB Debugging is checked in Settings->Application->Development, but I think not registering correctly.

dmesg in ubuntu lappy:

Code:

[402380.417159] usb 4-1: USB disconnect, address 25
[402384.725097] usb 4-1: new full speed USB device using uhci_hcd and address 26
[402384.889675] usb 4-1: configuration #1 chosen from 1 choice
[402384.894245] scsi129 : SCSI emulation for USB Mass Storage devices
[402384.895605] usb-storage: device found at 26
[402384.895622] usb-storage: waiting for device to settle before scanning
[402390.894515] usb-storage: device scan complete
[402391.008182] usb 4-1: reset full speed USB device using uhci_hcd and address 26
[402391.280203] usb 4-1: reset full speed USB device using uhci_hcd and address 26
[402391.544648] usb 4-1: reset full speed USB device using uhci_hcd and address 26

adb shell and adb ppp -d (w/ or without su) fail, device not found

edit: fixed by killing previous adb processes

Thesandlord 2009-01-07 02:16

Re: Another Android port: NITdroid
 
battery management is wacky. First, it drains. Then, the icon disappears. Then, it "charges" (without being plugged in). Then it drains. Then, the icon disappears...

Same time problem here as well...

meizirkki 2009-01-07 06:40

Re: Another Android port: NITdroid
 
The battery meter works as good as KDE 4:s battery applet in diablo, or gnome-power-manager in deblet, it shows only 0% - 25% - 50% -75% -100%

memson 2009-01-07 14:28

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by meizirkki (Post 255087)
The battery meter works as good as KDE 4:s battery applet in diablo, or gnome-power-manager in deblet, it shows only 0% - 25% - 50% -75% -100%

Sounds like it works about as well as the meter did in Qtopia on the Sl5500. The biggest issue with the Sharp devices was the poor battery life and poorer battery indicator (full, 3/4 full, half full, empty).

memson 2009-01-07 14:29

Re: Another Android port: NITdroid
 
My manager tried the Android port for his HTC phone yesterday - OMFG!! NITdroid is "fully" working in comparison. You guys are doing an amazing job ;) Thanks!

solca 2009-01-07 16:38

Re: Another Android port: NITdroid
 
[QUOTE=gowen;254864]My clock is always about 2 hours 15 minutes off after a power cycle. It's keeping time OK, but just needs an offset to local time.[\QUOTE]

Most devices have 2 clocks, the real time clock (RTC) which is hardware and the internal system time "clock" which is just software. The hardware RTC keeps time even when the device is powered off, the internal is just a software clock that normally deviates slowly from the real time, so it needs to keep in sync normally in startup and shutdown, NITdroid misses the shutdown part as Android just shuts the hardware without running any scripts. My plan to solve this is to set the RTC clock when the user set it in the GUI.

Quote:

Originally Posted by gowen (Post 254864)
I had the problem since my first install of NITdroid (around 18th December). I'm thinking this may be a screen calibration problem. I found the pointer location app in DevTools and this shows that at the bottom of the screen the calibration is off by about 4mm. There is quite a bit of variation across screen with only the centre left edge having no error.

Yes, it is a calibration problem, Maemo solve it using tslib and shipping "default" calibration data for different touchscreen panels. Android doesn't use tslib nor calibration data as it is expected all shipping devices with Android will use capacitive touchscreen hardware which doesn't require calibration. My plan is to teach Android tslib and reuse the calibration data on Maemo partition, I'm working on it.

Quote:

Originally Posted by gowen (Post 254864)
Is there a screen calibration app in Android?

I don't think so.

Quote:

Originally Posted by gowen (Post 254864)
Finally, I can't get 0.3.1 to return from screen blanking. Once it's gone blank pressing the keys or the screen has no effect. Eventually, it seems to power off as pressing the power key will produce a restart. Strangely, when adb is connected running logcat, it will recover.

Other people with N800 reported the same problem, this works nicely on N810 and it seems to be a problem when the device entering retention mode but it can't get out of it. It's a kernel problem and there is no fix yet, other than disabling power management, for the next release I'll provide a kernel without pm for N800 users until a fix get's done.

Quote:

Originally Posted by Thesandlord (Post 255044)
battery management is wacky. First, it drains. Then, the icon disappears. Then, it "charges" (without being plugged in). Then it drains. Then, the icon disappears...

Battery metering is implemented in NITdroid (and I belive in Maemo too) by reading from the RETU ASIC. NITdroid uses the nice kcbatt tool to read the raw value of the current charge and speculatively knows if it's charging or discharing. Maemo uses other method to know if it's charging or discharging but the current charge I'm pretty sure it's read too from RETU.

The problem, is the value reported by RETU which deviates depending on which hardware is turned on (WiFi, LCD, backlights), so this value it's reported 'weirdly', I'm pretty sure that's the reason why Maemo doesn't show you the real charge in their battery applet.

If you don't belive me try this on NITdroid 'kcbatt -r -l 1' then connect/disconnect AC power, turn on/off LCD, WiFi, backlights, and you will see what I mean.

The only way to improve it is by observing and adding that logic to NITdroid so a better value is reported in the GUI or in the Settings/About section. Shame NITs doesn't use standard power class drivers and the hardware doesn't report a single absolute _real_ value.

BTW does somebody knows something about the RETU ASIC? it seems the kernel drivers just read/set registers, the real thing is obfuscated in the proprietary daemons.

I recently (Oct/2008) buy my N810 because Nokia say it was open, they even have great publicity on this, for their next tablet Nokia should put clearly which drivers are following standard Linux APIs and which don't and are implemented by binary only daemons in userspace as belive me this is _very_very_ important.

Anyway I'm happy how NITdroid is progressing thanks too you. :)

cyrus 2009-01-07 18:11

Re: Another Android port: NITdroid
 
solca:

What are the plans for audio? I know you have it turned off for now. Is there any way any of us can help you out with implementing sound? Maybe doing some research for you, etc?

Thanks

solca 2009-01-10 19:32

Re: Another Android port: NITdroid
 
New release 0.3.2:

Quote:

Originally Posted by jogorman (Post 251860)
Just an update. I am still having issues with cookies not working. I got a chance to hook up logcat while trying to log into various web services. No output is captured. I also tried to disable then re-enable cookies while attached to logcat, and nothing was reported there either, which I found curious with how verbose this can be.

Quote:

Originally Posted by Thesandlord (Post 254152)
... the cookies don't work for some reason.

Fixed. Thx to BrentDC for pointing me to the HTC-Vogue Android port, they don't post sources but with some directions I found the problem, it seems an accidental bug by Google.

Quote:

Originally Posted by rasmithuk (Post 252465)
I'm not sure if this is the right place to report this but I think the touch screen pressure code is backwards (or google picked an odd way to represent it).
If you go to 'Dev Tools' > 'Pointer Location' the current pressure is displayed at the top of the screen. Now I'm assuming that this is scaled from 0 to 1 with 1 being as higher force as possible. However on my n800 the harder I push the closer to 0 the value goes.
This does explain why the on-screen keyboard is a bit odd to use with multiple key presses being detected for no reason. I'm guessing the pressure calibration code still needs tweaking.

Fixed. The touchscreen driver reports the pressure value backwards. Thx to stelleg151 for helping me with the math. This change requires a kernel upgrade (zImage-nitdroid-2.6.28_n8x0-3).

Quote:

Originally Posted by cyrus (Post 255188)
What are the plans for audio? I know you have it turned off for now. Is there any way any of us can help you out with implementing sound? Maybe doing some research for you, etc?

Yes, audio is turned off for now as for N800 is b0rked in latest kernels, I'm working in the IRC channel with some N800 owners testing driver fixes for latest kernels but no luck so far. N810 driver is ok but I can't get any sound output from within Android. For this release I put alsa-utils so ppl who want to help with sound could try from the command line with aplay, amixer, alsactl and alsacap. Too there is a /system/etc/asound.conf file that it's used by Android, I build it with help of alsactl output but probably it needs some mods to work.

For bluetooth I need a small kernel patch required by Android that I'm working though I have to test it well.

Thx to all ppl in the #NITdroid channel that have helped me testing stuff!

jakemaheu 2009-01-10 19:40

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by solca (Post 256212)
I'm working in the IRC channel with some N800 owners testing driver fixes for latest kernels but no luck so far

Oh hai, lol

Chinpokomon 2009-01-11 05:19

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by solca (Post 256212)
Fixed. The touchscreen driver reports the pressure value backwards. Thx to stelleg151 for helping me with the math. This change requires a kernel upgrade (zImage-nitdroid-2.6.28_n8x0-3).

Last I checked the touch screen doesn't quite map to stylus correctly. It's close, but there the precision gets off closer to the edges of the screen.

jogorman 2009-01-11 22:18

Re: Another Android port: NITdroid
 
Applied the latest version, and I have to say it is working like a chap now. Web browser cookie issue is gone, and I have to say that is a big help for me. Thanks!

I was able to boot it up, hop online and start screwing around with no problem at all.

Only issue I am noticing now is the calibration issue.

With the state it is in now, I will be attempting to use this on a daily basis to see if anything big shakes out. Of course I notice little things here and there that would be nice, but overall this is very very nice.

Thanks
Jim

stelleg151 2009-01-13 00:18

Re: Another Android port: NITdroid
 
Just out of curiosity, I ran the emulator with only 64mb of ram and no swap, and it ran just fine, so I'm wondering if the instability on the n770 isn't for other reasons?

macit 2009-01-14 16:17

Re: Another Android port: NITdroid
 
Newbie question... I used the nitdroid_complete.sh script (thanks jakemaheu). It went fine all the way to "cleanup complete". I got the R&D mode screen, unplugged the USB, got the black screen and then got the NITDROID logo, but it got stuck there.

I tried doing the whole thing over again but still - no luck.

Any ideas?

whouweling 2009-01-14 17:52

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by macit (Post 257531)
Newbie question... I used the nitdroid_complete.sh script (thanks jakemaheu). It went fine all the way to "cleanup complete". I got the R&D mode screen, unplugged the USB, got the black screen and then got the NITDROID logo, but it got stuck there.

I tried doing the whole thing over again but still - no luck.

Any ideas?

Are you sure you're waiting long enough? It takes quite a bit of time for the first startup to complete.

Tried android myself on a N800, I have to say: impressive! Gives the N8*0 a whole new future.

Thanks to everyone who worked on this, great work!

cyrus 2009-01-14 18:38

Re: Another Android port: NITdroid
 
Anyone have issues with charging? Mine doesn't seem to work. It just heats up but the battery never seems to re-charge.

macit 2009-01-14 20:49

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by whouweling (Post 257558)
Are you sure you're waiting long enough? It takes quite a bit of time for the first startup to complete.

I waited about 10 minutes or so.
I will give it some more time...

Thanks!

macit 2009-01-14 22:10

Re: Another Android port: NITdroid
 
Waiting more than hour now... I guess there is something wrong with it.
Please help as I'm really anxious to see it working.

Thanks.

EasternPA 2009-01-15 01:42

Re: Another Android port: NITdroid
 
After the initial install (which turned out be 0.3.1), I was able to flash the 0.3.2 kernel but I can no longer mount the N810 partitions on the Linux host.

fdisk /dev/sda results in "unable to open /dev/sda"

/var/log/messages is filled with "Buffer I/O error on device sda, logical block 0" and "scsi 11:0:0:0: rejecting I/O to dead device"

dmesg shows

usb-storage: Vendor <NULL> Model: <NULL>

and

sd 15:0:0:0:Attached scsi removable disk sda

./adb shell shows "error: device not found"

Anyone face this? I'm in a half-loaded state with the 0.3.2 kernel but the 0.3.1 rootfs. The tablet and Internet both work, but I'd like to know how to get fully updated.

Any ideas? How do I mount /dev/sda3 on my linux host again now that Android is running?

N810 on a CentOS 5 host.

Thanks!

EDIT: I needed to reflash to the Maemo kernel, push the new rootfs, and then reflash to the latest nitdroid kernel. Nitdroid doesn't export the partitions in the same way the maemo kernel does

neatojones 2009-01-15 01:43

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by macit (Post 257650)
Waiting more than hour now... I guess there is something wrong with it.
Please help as I'm really anxious to see it working.

Thanks.

That would definitely be abnormal. Mine takes 5 min at most the first time I boot NITdroid.

Thesandlord 2009-01-15 01:46

Re: Another Android port: NITdroid
 
EasternPA, flash back to maemo kernel, upload the new rootfs, then flash back to Android.

Takes about 10 minutes max.

EasternPA 2009-01-15 02:57

Re: Another Android port: NITdroid
 
Quote:

Originally Posted by Thesandlord (Post 257707)
EasternPA, flash back to maemo kernel, upload the new rootfs, then flash back to Android.

Takes about 10 minutes max.

Thanks, TSL. Worked fine.

I see a dialog

Sorry!

Application Settings (in process com.android.settings) is not responding.

Force close | Wait

on every cold boot. Saw it under 0.3.1 and 0.3.2.

Thesandlord 2009-01-15 03:01

Re: Another Android port: NITdroid
 
Yeah, its beta software, so weird things pop up. I get the same sometimes, don't worry about it...

EasternPA 2009-01-15 03:06

Re: Another Android port: NITdroid
 
Just thought I'd mention it :) I'm good to go now. Thanks again.

memson 2009-01-15 09:39

Re: Another Android port: NITdroid
 
Does the current version allow you to boot to Maemo from Android yet? I haven't been following the development for a few weeks. That was the part that was stopping me install it and keep it around more than a day.

EasternPA 2009-01-15 14:48

Re: Another Android port: NITdroid
 
Memson - We still have to reflash to maemo in order to update the installed android filesystem, so while Maemo is an option on the shutdown menu, no is not a seamless reboot at this time. As I understand it a boot selector is under development.

maxkilla 2009-01-15 15:17

Re: Another Android port: NITdroid
 
ive been collecting software for android if anyone has any that's not in here please let me know -> http://www.4shared.com/dir/11234070/...0/sharing.html
i think all android software is still free they haven't started charging yet have they?

EasternPA 2009-01-15 15:19

Re: Another Android port: NITdroid
 
maxkilla check out this thread for the app discussion

http://www.internettablettalk.com/fo...ad.php?t=25682


All times are GMT. The time now is 23:20.

vBulletin® Version 3.8.8