[HELP] Keylayout files are broken - Android Q&A, Help & Troubleshooting

Hi,
For few weeks I've been struggling with making my Xbox 360 gamepad to work with my ASUS Nexus 7 tablet. I bought an OTG cable and connected my wireless pad via Microsoft receiver. Everything seemed to work, except gamepad deadzones were not set right (I doubt Android devices consider gamepad deadzones at all), thus making all games unplayable: characters or camera kept turning left even when I wasn't touching an analog sticks at all.
I followed the thread http://forum.xda-developers.com/showthread.php?t=2492251, the guy who posted it seemed to have worked it out so I gave it a shot. I needed to root the device first, everything worked like a charm. I'm such an idiot I tried and edited Generic.kl file and made changes like the guy in mentioned thread.
Now I don't know what the heck is going on, beacuse hardware keys don't work at all, and I can't type numbers with on-screen keyboard. Which means I have to use my USB cable to even wake the screen, which is ridicilous enough. I found what seems to be an original Generic.kl file from here:
https://android.googlesource.com/platform/frameworks/base/+/cd92588/data/keyboards/Generic.kl
But no matter what I do, I cannot get it to work. My tablet seems to be ignoring any changes that are being made in /system/usr/keylayout.
Also, I don't know why, but I have an empty folder "keylayout" inside /system/usr/keylayout (which makes /system/usr/keylayout/keylayout) and another empty folder "keychars" in /system/usr/keychars.
Everytime I make change in keylayout dir I chmod the file to -rw-r--r-- and perform a mount operation in my Terminal Emulator, which goes:
Code:
> su
> mount -o remount,rw /system
I don't know what to do - currently I'm trying to restore a backup of my tablet's data I made before rooting the device, but I'm not too sure it'll help. I'm thinking about installing a custom ROM, but do ROMs affect keylayout files?

Related

[HOWTO] Droid-X multitouch keyboard

OK. I told someone I would go through this and come up with a quick HOWTO to get the Droid-X multitouch keyboard installed on the NC.
I really like this keyboard. It has predictive text and it also allows me to touch type when in landscape mode.
This HOWTO assumes that you have downloaded View attachment DroidX_Keyboard.apk <- [that is a link to the APK people!] to the same directory that your adb binary (adb on linux, adb.exe on Winblowz) is located in...
DO NOT CONTINUE UNLESS:
(1) You have at a minimum enabled non-market apps on your NC!!!
(2) You are willing to suffer through a single reboot to get the new keyboard loaded.
(3) In the unlikely event that something goes wrong, you're unable to go through the "revert to original keyboard" procedure listed in this post.
Note: If your computer is infected with the Bill Gates virus (you're running Winblowz), you will run adb.exe in the current directory instead of ./adb as I have in the HOWTO. My personal system is Ubuntu 10.04 LTS with android-sdk_r07-linux_x86.tgz installed.
OK... Here we go...
(1) Verify that View attachment DroidX_Keyboard.apk is in your adb binary directory:
$ ls -al DroidX_Keyboard.apk
-rw-r--r-- 1 tvo tvo 3256280 2010-12-08 22:07 DroidX_Keyboard.apk
(2) Verify that the MD5SUM for DroidX_Keyboard.apk is as follows:
$ md5sum DroidX_Keyboard.apk
c2ae341417585a2847765d9598575b20 DroidX_Keyboard.apk
If the MD5SUM doesn't match, DO NOT CONTINUE! (If you don't know what MD5SUM is, Google it. )
(3) Connect your NC to the USB port of your computer.
(4) Verify that you're in the correct directory and that ADB can see your NC. IE; Your ADB binary is in the same directory and things are OK with communications between the computer and the NC:
./adb devices
List of devices attached
xxxxxxxxxxxxxxxx device
Note: the x's will be the actual SN of your NC.
(5) If and ONLY if all of the above has worked as expected, continue with the following:
(6) Make a local (on your computer) backup of your original NC keyboard...
./adb pull /system/app/LatinIME.apk
You should see something like the following:
1408 KB/s (198321 bytes in 0.137s)
(7) Make another local copy of the original NC keyboard:
cp LatinIME.apk LatinIME.apk.nook.original.keyboard
(8) Run the following ADB commands:
./adb shell
# mount -o remount rw /system
# cd /system/app
# mv LatinIME.apk LatinIME.apk.bak
# exit
What we just did was mount the /system partion as RW and move the original keyboard to a backup file. Notice that we have three backups now. Two on your computer and one on your NC.
(9) Install the View attachment DroidX_Keyboard.apk with the following command:
./adb install DroidX_Keyboard.apk
You should see something like the following:
1782 KB/s (3256280 bytes in 1.783s)
pkg: /data/local/tmp/DroidX_Keyboard.apk
Success
(10) Reboot your NC:
./adb reboot
(11) WHILE the NC is rebooting, disconnect the USB cord.
When the NC boots up, you will now have the DroidX multitouch keyboard instead of the stock NC keyboard.
I know... I know... I could have written a script to do all of this for you. But, if you can't follow 11 very simple steps, um... Oh, nevermind.
How to REVERT TO ORIGINAL KEYBOARD...
If something doesn't work right or if you just want to go back to your stock keyboard, run the following commands from within your adb binary directory (the directory with adb or adb.exe in it):
./adb shell
# mount -o remount rw /system
# cd /system/app
# cat LatinIME.apk.bak > LatinIME.apk
# chmod 755 LatinIME.apk
# reboot
While the NC is rebooting, remove the USB cable.
When the NC reboots, your keyboard will be restored to the stock NC keyboard.
Simple, huh?
I've gone through this multiple times now trying to find any issues. It works flawlessly for me to switch back and forth between the two keyboards.
John - Your friendly neighborhood e-thug.
Worked for me without a hitch.
Has anyone figured out how to make the letters on the keys bigger? It's not a big deal but if possible it would be a 'good thing.'
I should add: Thanks for the instructions!
Any idea how to get the font/letters on the keys to display larger?
-CC
DyDx said:
Worked for me without a hitch.
Has anyone figured out how to make the letters on the keys bigger? It's not a big deal but if possible it would be a 'good thing.'
I should add: Thanks for the instructions!
Click to expand...
Click to collapse
Glad it worked out for you. I'm looking into making the keys bigger. Will post an update if I get it figured out.
Strapping on Flame Suit.
It didn't work for me. :-(.
Just kidding. It was simple enough. It's funny, I've been playing with Android for a while but never got into using adb. Partly because I never could get the SDK installed correctly, it was always a pain to use. I don't know which instructions worked, I tried a few, but this install of the SDK is working great and I can run adb anywhere. I've learned more about Android on the NC then my last 2 Android phones. I'm McLuvin it
If I could only get Swiftkey to work. This keyboard will do me fine till Switkey works.
Thanks.
You really made that complicated sarcasm boy.
Its really easy in Root Explorer. Thanks for the apk though.
Just curious, does this have swipe functionality?
Also, I haven't installed this yet, but as some of you are asking about getting the letters bigger, are these smaller than stock NC key letters?
Yes, the letters are quite small. The buttons themselves are larger, however.
Has anyone tried the Gingerbread keyboard?
EDIT, I guess it won't work on 2.1 roms.
Anyone know a keyboard that works but doesn't have the small letter problem the DROID X keyboard has?
donballz said:
You really made that complicated sarcasm boy.
Its really easy in Root Explorer. Thanks for the apk though.
Click to expand...
Click to collapse
If you think that typing a bunch of things on the NOOK keyboard compared to copy/paste to your computer is compliacted, sure.
Glad I could help you out. As for Boy... OK. Based on your moniker, I was in combat killing enemies YOUR AGE before you left your mommy's teet. That's OK though. You can call me boy if you must.
Figured out how to increase the font size on the keyboard.
I used apktool and decoded DroidX_Keyboard.apk posted by johnopsec. I took a peek at the xml in the LatinIME.apk and found that the NC keyboard has this setting android:keyTextSize="24.0sp" in /res/layout/input.xml.
It was as simple as copying that into DroidX_Keyboard's /res/layout/input.xml and rebuilding it. Obviously if you wanted a larger or smaller font-size it would be fairly easy to adjust. Anyway, I'm not much of a hacker but I figured I would share.
I also went ahead and removed the voice search buttons as they serve no purpose with our lack of a microphone.
I attached a screenshot as well as my apk, which installs(at least for me) just fine using johnopsec's method.
I take no responsibility if your NC explodes or bricks or turns into a unicorn.
rpollard00 said:
Figured out how to increase the font size on the keyboard.
Click to expand...
Click to collapse
Great work. Looks great on my NC. Thanks for your work!
Works great, thanks. One minor issue I'm having (using rpollard00's apk) is that in landscape, if I bring up the numeric keyboard, the "&" key shows as "&". Is this just me, or can you guys see it too?
ddenson said:
Works great, thanks. One minor issue I'm having (using rpollard00's apk) is that in landscape, if I bring up the numeric keyboard, the "&" key shows as "&". Is this just me, or can you guys see it too?
Click to expand...
Click to collapse
I see the same thing here. And it is very bold text. I'd actually like to see all of the letters this bold on the keyboards. Hey rpollard00, any chance of an updated APK?
Glad someone found a fix for the font size.
Now the next thing I'd like to see is someone getting the new SwiftKey 'HD' to work. It has a 31 day trial on the Market for anyone who wants to give it a shot. I'm eager to see it work because they just changed it to work better with higher res screens like the Galaxy Tab.
However, it's a keyboard that has it's own setup utility and requires you to turn it on in "Settings," which of course is hidden on the NC. So, I was unable to get it to work using the method applied to the DroidX keyboard.
johnopsec said:
I see the same thing here. And it is very bold text. I'd actually like to see all of the letters this bold on the keyboards. Hey rpollard00, any chance of an updated APK?
Click to expand...
Click to collapse
I fixed the &amp issue. I played around a bit to see if I could make all of the keys bold but I couldn't get anything working. I also restored the "<" symbol(anyone notice?), which I accidentally deleted when I fixed the &amp's in portrait mode. Oops!
I'll see if I can figure anything out with bolding the text after work, but no promises.
rpollard00 said:
I fixed the &amp issue. I played around a bit to see if I could make all of the keys bold but I couldn't get anything working. I also restored the "<" symbol(anyone notice?), which I accidentally deleted when I fixed the &amp's in portrait mode. Oops!
I'll see if I can figure anything out with bolding the text after work, but no promises.
Click to expand...
Click to collapse
Works great. Thanks!
Feel free to mock me, but I'm having problems. Here's the error I get:
$ adb install DroidX_Keyboard.apk
2385 KB/s (3256280 bytes in 1.333s)
pkg: /data/local/tmp/DroidX_Keyboard.apk
Failure [INSTALL_FAILED_ALREADY_EXISTS]
I'd already installed SoftKeys_2.00.apk before attempting this, which may be the source of the issue. Any idea how to get my Nook to a state where I can successfully install the Droid X keyboard?
EDIT: Got it! You need to revert to the stock keyboard before you can install a new custom one.
I used root explorer, because I don't have ADB installed at work.
I made a copy of the stock keyboard file, and pasted it to my SD card. I then renamed the stock keyboard to LatinIm.apk.bak.
I then installed the new multitouch keyboard as a regular APK, it installed, and I rebooted. Voila, everything worked well.
(I figured I'd throw this in here in case anyone was wondering how to do it with root explorer...I know adb can sometimes be a little intimidating)
Is there a way to revert to NC original keyboard if i got the droid-x's with the Auto-nooter batch installation? I dont think it made any backup copies... Now im stuck with Droid-x i dont want at all...

[HOW TO] Calibrate your Touch Screen on Newer Kernels in GBX0C/GBX0*

I take no credit for any of this, I have just put together things I have found on various threads.
As you all know the touch screen calibration that runs at boot does not work with any of the newer kernels as you cannot see some of the cross hairs to tap. I have personally NEVER been able to produce my own accurate ts-calibration file and have been using an ancient one that I downloaded back in the early days of FRX (thank you arrrghhh). Hopefully you have a somewhat functional ts-calibration file as you need to carry out this procedure from within Android. Here we go... (it's easy)
1. Download HtcCalibrate_WVGA.apk, thanks to lukas.pce, attached to first post here http://forum.xda-developers.com/showthread.php?t=1457343 to your device.
2. Install HtcCalibrate_WVGA.apk
3. Run HTC Calibrate and follow the instructions, tapping all the points (I used a toothpick for added accuracy)
4. When complete the app will report 'Calibration complete', tap 'Done'. Your screen should now be accurately calibrated for this session. Test to make sure it is working correctly before proceding to next step.
5. Now to get the calibration data to stick after reboot: Open your file explorer (MUST HAVE ROOT ACCESS; I use ES File Explorer with Menu>Settings>'Up to Root' checked) and navigate to /sys/devices/virtual/input/input3/ there you should see a file named calibration_points.
**It seems that in some builds (perhaps depending on kernel version?) that the devices get defined differently and I have found the file calibration_points in /sys/devices/virtual/input/input2/.
**So if you can't find it in input3/ then check input2/ (I haven't seen it anywhere else, but it probably could be in input1/, 4/, or 5/ as well, if not in the first two).​6. Finally copy calibration_points to /sdcard/ (the root of your SD card), delete your existing ts-calibration file (or backup somewhere if you want) and rename calibration_points to ts-calibration.
**Nand users see this (thanks wizardnight!):
wizardknight said:
BTW on the nand version (GBX0* + 3.3.x kernel) it needs to be placed in /data/
Click to expand...
Click to collapse
Done. Your phone should now boot with the calibration data you created.
So that is where it sticks the file. I have been trying to find that out forever. Cool beans.
I had been using an old version of GBX0B on an sd card to make a decent ts-calibration file. Kind of a pain as you have to load up WM, then GBX0B to make the file at boot time (and it wasn't as accurate as the HTC one), copy it , and then reload the GBX and paste it.
BTW on the nand version (GBX0* + 3.3.x kernel) it needs to be placed in /data/
Why couldn't you have posted this sooner When I was using GBX0C I couldn't find the file anywhere
Ha! Sorry, I just found it today. Your problem was prbably that you looked virtually everywhere! It does seem an odd place for the file to be.
Would it work to bind-mount that file to /data/ts-calibration in the boot script, so that running HTC Calibrate will automatically write it?
That I do not know. I have never looked at the boot script or bind mounted anything. But automating this does sound like a great idea!
It would be amazing if a dev could do a reverse compile on this app, and put in an option to select the save location. One can dream.
I was taking a look at the data and time stamps on calibration_points, and it seems that there is a script somewhere that takes ts-calibration and overwrites calibration_points at boot time. If that is correct disabling that overwrite would mean the app could work fine as-is.
Unfortunately just renaming the ts-calibration is not enough. During the boot process it creates a new one with a set of values.
I found this bit of code that might explain why we are seeing this overwriting.
http://gitorious.org/xdandroid/rootfs/merge_requests/4
Part 1 locates the touch screen manager directory
Part 2 looks for ts-calibration in /data/ and if it finds it overwrites calibration_points
otherwise it creates a new ts-calibration using a default set of values and then overwrites calibration_points
So what we want to do is have it overwrite /data/ts-calibration with $touchscreendir/calibration_points as long as calibration has been completed previously within android.
Now I haven't really written code/scripts in a decade and am not yet too familiar with linux but something like:
(tiad8's commit, edited poorly by me)
## Ts Calibration
for i in /sys/class/input/input* ; do
if [ "`cat $i/name`" = "tssc-manager" ] ; then
touchscreendir=$i
echo "Touchscreen device directory is $i"
fi
done
if [ -f /data/ts-calibration ] ; then
echo "Using Saved Touchscreen Calibration"
echo 128,128,1903,128,128,1907,1903,1907,1024,1024 > $touchscreendir/calibration_screen
cat /data/ts-calibration > $touchscreendir/calibration_points
else
if [ -f "$touchscreendir/calibration_points"="0,0,0,0,0,0,0,0,0,0" ] ; then
echo "Using Default Calibration Values"
echo 821,860,197,868,500,517,829,172,191,171 > /data/ts-calibration
cat /data/ts-calibration > $touchscreendir/calibration_points
else
echo "Using Last Calibration Values"
echo 128,128,1903,128,128,1907,1903,1907,1024,1024 > $touchscreendir/calibration_screen
cat $touchscreendir/calibration_points > /data/ts-calibration
fi​fi
​I am sure that my commands and syntax above are wrong, it's the concept that I am trying to convey.
I want to look to see if there is a ts-calibration and if not then look to see if there is valid calibration data in calibration_screen and if there is then write that value to ts-calibration. Thus to update calibration all you need to do is run HTC Calibration, and delete ts-calibration.
I guess you could also compare calibration_screen to ts-calibration and if there are differences (and calibration_screen is valid) have ts-calibration overwritten, removing the need to delete it!
I am assuming that before calibration or having ts-calibration written to it that calibration_screen has the value 0,0,0,0,0,0,0,0,0,0 but it could also be 0 or empty i don't know really and am probably wrong!
Also for GBX0C /data/ would have to be /sdcard/
One major problem with that plan:
/sys/ isn't a real filesystem.
It's a virtual file system, like /proc/, created programmatically by kernel drivers. It's not stored anywhere.
That boot script is writing the node because that's the only way to get the data into the kernel. If you don't do that, the calibration gets purged (or more accurately, not initialized) every boot.
That's why I proposed a bind-mount: make an access to one place in the filesystem affect another place. Though I realize another problem with that... The driver doesn't read from the filesystem! You have to actually write to the node to get the data into the driver. So that busts that plan.
It might be theoretically possible to modify the kernel driver to signal a userspace process to copy that data out, but... I don't know what would go into that, or even if it's ideal.
I have been using the latest kernel, 3.4 with a new build of GBX0C and decided to re-calibrate my screen:
Strange.... When I went looking for calibration_points in /sys/devices/virtual/input/input3/ it wasn't there, it had moved to /sys/devices/virtual/input/input2/
Before I edit the first post can anyone who is using the 3.4 linux kernel confirm this, please?
I can confirm that with the 3.3 kernel, mine is in input2, not input3
where to copy? does not have memory card
karelkopp said:
where to copy? does not have memory card
Click to expand...
Click to collapse
What does not have a memory card? The RHOD certainly has a slot for one...
Edit - I just realized why your question is so poorly worded. You're running NAND, and this thread assumes you're on a SD build.
I responded to you here.
I recently started working on a Android based Car solution and decided to buy the MK802 units. My car used to have a Windows based PC, so I already have VGA touchscreens installed. I didnt want to replace the screens, so I bought a HDMI to VGA converter and the MK802.
I plugged the touchscreen into the MK802, assuming it wouldnt do anything. But sure enough, it works. Problem is the calibration is off and up and down are reversed. So say I tap the bottom of the screen, the mouse pointer appears on the top of the screen and vis versa. My understanding (Im very new to this) is that you have to be rooted, which is the way these devices come.
So my question is, will this calibration tool work? I know most Androids use a multi-touch screen. Mine are 4-wire touch panels. Also, what do I have to look for and edit to get Up to Up and Down to Down?
Thanks in advance!
hijackzx1 said:
I recently started working on a Android based Car solution and decided to buy the MK802 units. My car used to have a Windows based PC, so I already have VGA touchscreens installed. I didnt want to replace the screens, so I bought a HDMI to VGA converter and the MK802.
I plugged the touchscreen into the MK802, assuming it wouldnt do anything. But sure enough, it works. Problem is the calibration is off and up and down are reversed. So say I tap the bottom of the screen, the mouse pointer appears on the top of the screen and vis versa. My understanding (Im very new to this) is that you have to be rooted, which is the way these devices come.
So my question is, will this calibration tool work? I know most Androids use a multi-touch screen. Mine are 4-wire touch panels. Also, what do I have to look for and edit to get Up to Up and Down to Down?
Thanks in advance!
Click to expand...
Click to collapse
This tool was made for HTC phones. You will need to find the group for your device to get support for it.
Calibration problem
Hello,
I am not able to calibrate screen on htc touch pro2 sprint modem (T7380) PocketPC
there is a software problem due to which i had to reset factory restore button inside handset ,and restarted device
but it stuck on calibrate option ,continuous prompt to press all 4 side and centre ,even though i had done multiple time
but no further progress ,would like to know how to come out from this problem
now the handset is completely not starting ...i am on calibrate mode screen.
please suggest any solution .
syedwasi said:
Hello,
I am not able to calibrate screen on htc touch pro2 sprint modem (T7380) PocketPC
there is a software problem due to which i had to reset factory restore button inside handset ,and restarted device
but it stuck on calibrate option ,continuous prompt to press all 4 side and centre ,even though i had done multiple time
but no further progress ,would like to know how to come out from this problem
now the handset is completely not starting ...i am on calibrate mode screen.
please suggest any solution .
Click to expand...
Click to collapse
It sounds like you are having this issue with a Windows Mobile ROM and this thread is dedicated to Android on the Touch Pro2. However...
OFF TOPIC:
I had a similar problem with my old Acer M900 and the solution was to put an empty text file in the root (no folders) of your SD card and rename it welcome.not and this will bypass the screen calibration on your first boot. I was then able to successfully run the calibration afterwards from the settings menu. Here, to make it easy I attached the file here:View attachment welcome.zip. Simply unzip the file and place the file welcome.not on your storage card.​
Caldair said:
I take no credit for any of this, I have just put together things I have found on various threads.
As you all know the touch screen calibration that runs at boot does not work with any of the newer kernels as you cannot see some of the cross hairs to tap. I have personally NEVER been able to produce my own accurate ts-calibration file and have been using an ancient one that I downloaded back in the early days of FRX (thank you arrrghhh). Hopefully you have a somewhat functional ts-calibration file as you need to carry out this procedure from within Android. Here we go... (it's easy)
1. Download HtcCalibrate_WVGA.apk, thanks to lukas.pce, attached to first post here http://forum.xda-developers.com/showthread.php?t=1457343 to your device.
2. Install HtcCalibrate_WVGA.apk
3. Run HTC Calibrate and follow the instructions, tapping all the points (I used a toothpick for added accuracy)
4. When complete the app will report 'Calibration complete', tap 'Done'. Your screen should now be accurately calibrated for this session. Test to make sure it is working correctly before proceding to next step.
5. Now to get the calibration data to stick after reboot: Open your file explorer (MUST HAVE ROOT ACCESS; I use ES File Explorer with Menu>Settings>'Up to Root' checked) and navigate to /sys/devices/virtual/input/input3/ there you should see a file named calibration_points.
...
..
**Nand users see this (thanks wizardnight!):
Done. Your phone should now boot with the calibration data you created.
Click to expand...
Click to collapse
I have had a little bit of an alingment problem with my screen on my TP2. The NAND GBX works great so far. The only small but nevertheless important issue is finding a way to calibrate the screen and all Google searches lead back to the same forum post here , which has many files in the zip but NO apk inside.
Anyway, if anybody has any information of where to find an apk that will work, or maybe information on how to use the included files in the above mentioned link would be much appreciated.
My sincere thanks to all the developers that make all this modding possible, thank you all.
isruco said:
I have had a little bit of an alingment problem with my screen on my TP2. The NAND GBX works great so far. The only small but nevertheless important issue is finding a way to calibrate the screen and all Google searches lead back to the same forum post here , which has many files in the zip but NO apk inside.
Anyway, if anybody has any information of where to find an apk that will work, or maybe information on how to use the included files in the above mentioned link would be much appreciated.
My sincere thanks to all the developers that make all this modding possible, thank you all.
Click to expand...
Click to collapse
I just redownloaded the WVGA calibration from the link you refered to here:
[URL="http://forum.xda-developers.com/showthread.php?t=1457343"]http://forum.xda-developers.com/showthread.php?t=1457343
And the file seems to be intact and unchanged.
Those attached files on said thread ARE apk's already, they don't need to be extracted, just installed on your TP2.:good: Hope that helps!

Best USB Keyboard?

I'm looking for a good keyboard for the NST. I got a (Link disabled due to xda-dev restrictions on new users, search amazon.com for "DIAOTEC (TM) Synthetic Leather Keyboard Case with micro-USB plug for 7 inch Tablet Computers") off amazon and while I liked the form factor, the physical keys were just a smidge too small vertically and the spacebar hardly ever responded, meaningeverythingItypedlookedkindalikethis.
The reason I picked up a cheap nook used was to make an e-ink writing device. I'd love to have something integrated into a portable case the way that last product was, but everything I've seen appears to be different Chinese companies selling the same thing (if the images are anything to go by). The size wouldn't be a problem if they didn't insist on cramming F1-F12 keys into a keyboard designed for a tablet. I use an eeepc 701 with a similar size keyboard and love that.
Anyone with usb-host activated find anything they like? Thanks!
Not a specific recommendation, but I'm using this: http://www.microcenter.com/product/310127/Pro_Mini_USB_Multimedia_Keyboard
It has full-sized keys, which is important for touch typing.
Keyboard Testing
I'm testing a Sanoxy 7" keyboard/case with what was shipped to me as an OTG cable. Keyboard seems nice enough and Nook is held securely by spring clip. Keyboard likely not so good for extended touch typing as Renate's but all would be well if keyboard were recognized (no green light yet.) Are drivers needed -- or only Renate's USB application to put Nook in host mode?
Actually, I can get the keyboard working with the stock kernel in 1.2.1
If you don't have the correct init in your uRamdisk you won't get far, but at least you can tell that init is the problem.
With just my UsbMode:
Hit "Off"
Hit "Peripheral"
Connect just the OTG adapter (no keyboard)
Hit "Host", does the green light go on? If not, try again.
Connect the keyboard to the OTG adapter
Does the status read "Qwerty, Kbd:2" (or 1)?
If you just get "None, Kbd:2" (or 1), then you need to fix init in uRamdisk.
testing keyboard
Many thanks, Renate. Will try later today. Meanwhile, how does one put the right init in uRamdisk? I used Nook Root Manager to root my 1.2.1 NST and browsed for init but am not sure where it would be or if I have the uRamdisk that is needed.
BTW, the 7" Saxony keyboard/case works quite well when connected to the USB drive of a netbook. Small enough to easily stick in a briefcase or bag. Should work well with Nook for occasional typing.
testing keyboard
Renate NST said:
Actually, I can get the keyboard working with the stock kernel in 1.2.1
If you don't have the correct init in your uRamdisk you won't get far, but at least you can tell that init is the problem.
With just my UsbMode:
Hit "Off"
Hit "Peripheral"
Connect just the OTG adapter (no keyboard)
Hit "Host", does the green light go on? If not, try again.
Connect the keyboard to the OTG adapter
Does the status read "Qwerty, Kbd:2" (or 1)?
If you just get "None, Kbd:2" (or 1), then you need to fix init in uRamdisk.
Click to expand...
Click to collapse
I just get "None" without any ref to KBd:2 so I suppose I must fix init in uRamdisk. I found one init file that seems to be empty, but not sure it is the right one.
I do like the Saxony Keyboard, although keys are not full sized.
You do have superuser installed?
You don't get any <write error> from UsbMode?
You do get a steady green light with just the adapter plugged in?
Are you sure that your adapter is an OTG one?
Don't worry about init for now.
testing keyboard
"You do have superuser installed?"
Yes. Confirmed when use UsbMode.
"You don't get any <write error> from UsbMode?"
No.
"You do get a steady green light with just the adapter plugged in?"
No. Not even a flicker.
"Are you sure that your adapter is an OTG one?"
Invoice says so. Looks like photo at Amazon, but no label on adapter.
"Don't worry about init for now."
OK. Thanks!
Well, that's screwy.
The first thing is to get that light on.
Do you have the "big" kernel installed? (2,727,540 uImage)
With nothing connected and just hitting the "Host" button you should be able to get the LED to flash for 1/10 or a second.
Start with a new power on boot, keep hitting "Host".
It might flash red, you want green.
Hit the "Off" button to keep the charging circuit offline.
Once you get a green flash, plug in just the OTG adapter.
You should be able to get a solid green when you hit host.
When you are that far, try a powered hub too.
testing keyboard
"Do you have the "big" kernel installed? (2,727,540 uImage)"
My NST was updated to fw 1.2.1 and then rooted with Nook Root Manager. No changes to kernel after that. Not sure of kernel location.
"With nothing connected and just hitting the "Host" button you should be able to get the LED to flash for 1/10 of a second.
Start with a new power on boot, keep hitting "Host".
It might flash red, you want green.
Hit the "Off" button to keep the charging circuit offline."
No flash of any color!
Thanks for the help.
testing keyboard
Here's what I get from doing cat /proc/version in the terminal emulator on my Nook:
Linux version is 2.6.29-omap1 ([email protected]) (gcc version 4.3.2 (Sorcery G++ Lite 2008q3-72)) #1 PREEMPT Fri Dec 7 14:35:04 PST 2012
Here's the link for the keyboard, which I like and am trying to get going:
http://www.amazon.com/SANOXY-Leather-Keyboard-Tabletpc-Notebook/dp/B004TJJPG8
Thanks!
Oops, sorry, you need the right uImage to get USB working without a back-powering hub.
I always forget that I'm using one.
You need a better uImage in the boot directory.
You can use noogie to replace it or else ADB under Nook or CWR if you mount boot.
Code:
mount -o rw,remount rootfs /
mkdir /boot
mount -t vfat /dev/block/mmcblk0p1 /boot
I'm not even sure where this kernel that I'm using comes from, but here is a good one:
http://nst-recovery.googlecode.com/files/NST-kernel_0.1_uImage.zip
testing keyboard
"I'm not even sure where this kernel that I'm using comes from, but here is a good one:
http://nst-recovery.googlecode.com/files/NST-kernel_0.1_uImage.zip"
Renate, is this kernel compatible with fw 1.2.1? Also, with what the Nook Root Manager has changed?
Wonder if anyone has a keyboard working with 1.2.1 and Nook Root Manager.
Maybe I should make a back-powered hub for keyboard, audio etc.
Many thanks!
Try that kernel, it should work fine.
testing keyboard
"You need a better uImage in the boot directory.
You can use noogie to replace it or else ADB under Nook or CWR if you mount boot."
I had no boot directory but made one as per instructions a couple of messages above. There's no ulmage to replace that I could find. Do I just put the new one in boot? If so, zipped or unzipped? (B&N says zipped for their manual updates.)
dnordquest said:
I had no boot directory ...
Click to expand...
Click to collapse
You most certainly did!.
The "/boot" directory that you created was just a place to put a mount.
The mount command should have worked fine.
If you do an ls - l /boot command you should see all your boot files.
If you are not seeing uImage, uRamdisk, u-boot.bin, MLO, then you are looking in the wrong place.
Once you get your bearings sorted out (and you're sure), you can copy over uImage.
The zip and all that is part of the automatic update, not what you want.
testing keyboard
OK! New ulmage did the trick. Green light goes on when cable attached. Many thanks!
"If you just get "None, Kbd:2" (or 1), then you need to fix init in uRamdisk."
This is what I'm getting now (with 2). How does one fix init in uRamdisk?
Thanks!
The best way is to keep most of your uRamdisk and replace init in it.
You get init from here, in binaries.zip: http://forum.xda-developers.com/showpost.php?p=21669750&postcount=1
Code:
C:\>bootutil /v /r uRamdisk init
Read image, 13 files
Replaced init
Wrote image
You get bootutil from the signature.
I'm basically having the same problem, only a bit worse.
I've looked into adb but it seems to be windows only from what I can tell.
I seem to remember Nook Manager saying something about ssh?
Perhaps I can secure shell into the Nook somehow?
I have nook simple touch and I've rooted it with Nook Manager.
I tried to replace the kernel image by copying over the one on the Nook Manager card but I now have a feeling that might only get used when the memory card is booted.
I really want to get the keyboard working on my nook.
The trouble is I'm not sure how I can go about adding the kernel or modifying files without a keyboard
...and unless I can get the kernel on there etc then I won't have a working keyboard...
I seem to be trapped in the egg... or the chicken...I'm not sure which.
I'm running Linux here too, I hope that isn't a problem. I notice that everyone here seems to be talking about windows based tools a lot ironically.
Can anyone help me?
I'm going to keep reading and maybe I will stumble on the basic stuff I need to know somewhere!
Freya

FIX Need help with a kernel

Posted this in the wrong place, i guess this is the right
Hi everyone,
I have a 10.1'' chinese tablet with a rk3066 chip, suddenly the firmware got damagend, there is no way to find the original, i've tried with over 100 different firmwares from here or rockchipfirmware, nothing worked, but there is 1 version that barely works (PlayerMomo12 release 3) but the screen is inverted in both axis (X and Y), i've tried different methods to fix it, with apks, with usb debugging, and nothing worked, the apps just doesn't works, even one of them dissapeared and i was unable to install it again, using my laptop doesnt works because the directory that should mount doesn't exist, i don't know why but i've tried all the methods, even mounting with a terminal inside the tablet (you can imagine how hard was writting with the screen like a mirror), then i thought the only solution was using the kitchen to modify the file script.bin, but again, a lot of problems, i couldn't open the image, found this thread:
http://forum.xda-developers.com/show...33246&page=555
-------------------------------------
Originally Posted by biglcny
just running sysrw and sysro would return this:
Usage: mount [-r] [-w] [-o options] [-t type] device directory
rather than no output as usual. I believe there may be another version of mount that takes different parameters. When a rom is flashed and you connect to it with adb shell there is a version of mount in /system/bin that is different and accepts options in a different format.
simply typing running mount at the command line or in a shell script uses that one instead of the busybox one.
dr.notor replied:
Well, the above is an example of totally screwed up mount binary, dunno which phone and ROM you are using but the guy who produced the above would deserve a bit hit with a cluebat into their head.
If you have similar broken crap, simply edit the scripts to call busybox mount and not mount.
-------------------------------------
well, this is the point (after a lot of days working on this) when i give up, this tablet was bought in China and the company (scope) doesn't sell it anymore, and they don't reply the emails, even the webpage is half empty, this is the point when i ask, if someone can help me sending a working kernel based on this rom (PlayerMomo12 release 3) or the firmware with the script.bin modified to invert both axis, if no one can, then it's the moment to smash the tablet with a giant hammer and send it back to China
i could bought 2 galaxy tab 4 if i wasn't wasted so much time on this
here is the firmware if someone wanna to try
http://www.rockchipfirmware.com/cont...-tnt-release-3

Help needed in autobooting samsung android when charger is connected - playlpm

Hi guys.
I've been registered here or a long while, but I've run into a brick wall with a customisation I'm trying to do with an old phone and I though that, if someone could help then it may also help someone else that will (no doubt) have the same issue in the future.
I'm comfortable with the basics - rooting and automation (tasker etc), but I'd still consider myself a noob compared to most on this forum.
So here's what I'm doing.
My last phone (Samsung S3) was only worth £20 on the "trade in" sites, so I decided to re-purpose it as a dedicated bluetooth media device that'll live permanently in my motorbike.
I already have a USB connector in there which is spliced into the tail light so it'll only have power when the ignition is on.
So far the build has been straightforward:
Remove SIM
Clear partition
Factory reset
Rooted with ChainFire's AutoRoot (CF-Auto-Root-m0-m0xx-gti9300)
Installed nice to haves (Secure Settings, Greenify, Xposed Installer Modules...)
Setup tasker with 4 simple profiles:
(Power Connected: Lock Screen)
(Power Disconnected: Lock Screen, wait 4 minutes then enter "disconnect" into calendar In/For: -1/2)
(Monitoring calendar for "Disconnect". When found wait 1 minute and if Power is still disconnected then shutdown)
(When BT connected, every 5 minutes max the media volume) [optional] useful if the volume buttons get nudged
So far so good. I also got my BT headset set up so it'll seamlessly switch between my main phone (S6 Calls and GPS) and the "media" S3 phone.
But ... it's this last bit where I'm struggling
The phone will be kept either under the seat or in the bike's trunk, so it's not the same as a car setup where you can easily start it up manually, so I'm trying to get the phone to power on when the phone detects power through the charge socket.
I saw there were 2 apps in the play store that claim to be able to do this, but they're rated pretty badly and cost money just to try out.
After a short dig around here I found posts explaining how you can modify an lpm or playlpm file (which is to my understanding the battery power/charge screen) in the /system/bin directory and overwrite it with a reboot command.
And that's where I'm stuck.
I have 2 issues:
1) I have tried to overwrite it ... but it's really awkward to do. Even though I'm rooted, the tools I've used don't seem to be able to truly edit the system folder content as r/w
In the end, I had to use a combination of Root Explorer and ES File explorer to create a new playlpm (ES) in /storage/emulated/0/Downloads, then rename the current /system/bin/playlpm to /system/bin/playlpm.ori (RE)
Then move the file I created in Downloads to the bin folder (ES) and reset the permissions to allow execute all (RE)
Aaaand .... nothing
The only difference now is that when the phone is on charge, the charging screen stays as the grey 'loading' battery and doesn't switch to the green power level battery.
2) All the advise I've seen on here and in StackOverflow is to overwrite or replace the file with ascii code, but the content of my playlpm file looks like it's compiled and if I was to overwrite it then I'm sure it would ... not be happy
Code:
#!/system/bin/sh
sleep 5
/system/bin/reboot
Question: Do I need to recompile or generate the file in some way so that the S3 will read it (e.g. android-studio-bundle sdk)?
Another way I tried did involve installing the android SDK studio-bundle and running some commands through a command prompt (e.g. fastboot oem-off-mode charge 0) but the Samsung doesn't have a fastboot option afaik and the SDK couldn't connect to the phone ("waiting for devices" after issuing the command) .... and at 5 am I was beginning to see double so had to gave up.
(Source: https://www.youtube.com/watch?v=Zp9G6A6EFlA )
One last way I saw (Source: http://stackoverflow.com/questions/26294258/auto-boot-when-wall-charger-is-plugged) was to remove the /system/bin/charge_only_mode file, but that doesn't exist on my phone.
So that's where I am...
Any advise welcome on how to get this reboot on connection thing working would be greatly appreciated.
Cheers
CW
Anyone ... Bueller ... Bueller?
Ok, so I came back to this and got it working.
So simple, but they do say hindsight is 20/20
The reason it wasn't working for me was because I was using Notepad++ to create the file.
Even though I was telling it to save the file as UNIX, it was still writing it out in DOS
It was only when I switched to the trusty old Ultraedit and viewed it in HEX that I saw it.
So I did a FILE | Conversions | DOS to UNIX and then saved it.
Write to file, copy to /system/bin, change permissions and *boom* , it worked.
Hopefully if someone else has the same issue then this may help. :good:
In the end I used this code for no other reason than I was trying stuff.
I doubt it made any contributing difference, but for the sake of complete disclosure on my solution:
Code:
#!/system/bin/sh
su
/system/bin/reboot
I just did the following and it also worked without any problem, so the "su" in the previous post was purely coincidence
Code:
#!/system/bin/sh
sleep 15
/system/bin/reboot

Categories

Resources