Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,733,198 Members 40,609 Now Online
XDA Developers Android and Mobile Development Forum

Screensave while in landscape mode

Tip us?
 
Renate NST
Old
#11  
Renate NST's Avatar
Recognized Contributor / Recognized Developer - OP
Thanks Meter 782
Posts: 1,951
Join Date: Feb 2012
Location: Boston
Oh, and if you're tired of dragging to unlock your NOOK™,
place the extracted files in /res/drawable-mdpi/ inside /system/framework/framework-res.apk

Just to be clear, this doesn't change the manner of unlocking, just the look.

(The folks at B&N made the graphics shorter by making the top 30 pixels transparent.
That was an unnecessary hack, as long as all four graphics are the same height it works fine.)
Attached Thumbnails
Click image for larger version

Name:	Slide.png
Views:	71
Size:	1.5 KB
ID:	1021406  
Attached Files
File Type: zip Slide.zip - [Click for QR Code] (2.2 KB, 17 views)
The Following User Says Thank You to Renate NST For This Useful Post: [ Click to Expand ]
 
ajislav
Old
#12  
Member
Thanks Meter 31
Posts: 76
Join Date: Apr 2011
Default signing / alternative to adb push

Renate,

thank you for the mods. The rotated screensaver has been irritating me for some time ;) And I intend to put my email instead of the "slide to unlock" text..

Just 2 questions, before I do so:

1) do I need to sign the modified .jar/.apk files?
2) As I do not have ADB installed, I intend to change the files from a command line over ssh (i.e. copy, chown, chmod). My understanding is that this should be equivalend to adb push. Is this so?

Cheers
 
Renate NST
Old
#13  
Renate NST's Avatar
Recognized Contributor / Recognized Developer - OP
Thanks Meter 782
Posts: 1,951
Join Date: Feb 2012
Location: Boston
Quote:
Originally Posted by ajislav View Post
1) do I need to sign the modified .jar/.apk files?
"Badges? Badges? We don't need no stinkin' badges."

No, if you copy in anything directly you bypass all the signing stuff.

How you get the files over is however you like.
 
ajislav
Old
#14  
Member
Thanks Meter 31
Posts: 76
Join Date: Apr 2011
Default Bootloop

Hi,

I tried to do both changes (screensaver, slider) but since the recompilation of services.jar and android.policy.jar was giving me errors (see below), I decided to go with replacing framework-res.apk

what I did was

ssh into my nook
Code:
cd /system/framework/
mount -o remount,rw /dev/block/mmcblk0p5 /system
#copy the new framework into target dir
cp /sdcard/download/framework-res.apk ./framework-res.apk.new
#fix permissions
chmod 644 framework-res.apk.new
#make a backup
cp framework-res.apk framework-res.apk.old
#replace the file
cp framework-res.apk.new framework-res.apk
now at that moment I got the bootloop screen.. however ssh was still working, so I run the following line to restore the framework:
Code:
cp framework-res.apk.old framework-res.apk
and rebooted.. I am getting bootloops ever since..

I can boot to CWM. so I tried both what I should have done in the first place, i.e. replace the file in CWM
I tried this
http://forum.xda-developers.com/show...2&postcount=22
(fixes permissions)
and this
http://forum.xda-developers.com/show...4&postcount=11
(restores the old framework and fixes permissions)

but none seem to work... still the same bootloop (nook by B&N and 5 dots going from Left to Right)..

any ideas? I'd rather not go all the way to factory restore

p.s. I also tried wiping cache and dalvik-cache in CWM.. could this cause any problems?

p.p.s. the errors I got with recompiling the jars are:
Code:
>apktool b .\Services2 services.jar
I: Checking whether sources has changed...
W: Could not find resources
I: Building apk file...
is the "Could not find resources" normal?
 
Renate NST
Old
#15  
Renate NST's Avatar
Recognized Contributor / Recognized Developer - OP
Thanks Meter 782
Posts: 1,951
Join Date: Feb 2012
Location: Boston
Let's take the easy one first.

Compiling the jars will return "No resources found", because they are just jars.
You should always check to make sure that the output is about the same size as the original.
It may be a bit bigger or smaller depending on the vagaries of compression.

Now the toughie.

Hot-swapping jars is a bit risky.
In the best of all worlds, you'd like to swap them when they are not being used.

Swapping framework-res.apk could make it crash when something can't find a resource,
but it's not code and generally if you leave the Nook sitting it won't try to access anything.

If all you did was replace one file and now you replaced it back it should be working.

I don't know how you are getting a ssh into the Nook.
I've got no port 22 or 23 open.
 
ajislav
Old
#16  
Member
Thanks Meter 31
Posts: 76
Join Date: Apr 2011
Hi Renate,

Quote:
Compiling the jars will return "No resources found", because they are just jars.
You should always check to make sure that the output is about the same size as the original.
It may be a bit bigger or smaller depending on the vagaries of compression.
I did this, of course. The files are generally sightly smaller, in the case of framework-res.apk the change is relatively big: from 2,897,726 to 2,381,970 (but I am not worried about this as I get a similar size decrease even during simple decompile/recompile)

Quote:
Swapping framework-res.apk could make it crash when something can't find a resource,
but it's not code and generally if you leave the Nook sitting it won't try to access anything.
If all you did was replace one file and now you replaced it back it should be working.
I know, and I totally agree with you!

My conclusion is that something got corrupted..
I tried removing the apk.old and apk.new files via CWM (to make sure they are not in the way)
I also tried running e2fsck -p /dev/block/mmcblk0p5 via CMW (from http://forum.xda-developers.com/show...5&postcount=59 )
.. but still the same bootloop.

Is there any way to see some logs of the failed boots?

Since I did not make a backup just before doing this change (and I know you had adviced to do so ), the only thing which I can think of now is
a) create a backup with noogie
b) mount the image and check what is actually in /system
unfortunately, I do not have access to linux so this would be kind of pain (my old laptop with WinXPSP3 is the main reason, why I dont have ADB..)

And I am not sure if this is not more complicated than reinstalling everything from scratch..

Thanks for your help, I'll probably give it a day's rest and then do the factory reset..

Quote:
I don't know how you are getting a ssh into the Nook.
I've got no port 22 or 23 open.
I have droidSSHd installed and am able to connect easily with Putty.
 
Renate NST
Old
#17  
Renate NST's Avatar
Recognized Contributor / Recognized Developer - OP
Thanks Meter 782
Posts: 1,951
Join Date: Feb 2012
Location: Boston
Have you already tried to look at dmesg? logcat?
 
ajislav
Old
#18  
Member
Thanks Meter 31
Posts: 76
Join Date: Apr 2011
I am not sure how to do this (dmesg, logcat)

I was probably unclear about the ssh - I WAS able to ssh in when Nook was booting normally. Now I cannot.

Is there any way to do this from CWM? (I mean dmesg, logcat)
 
Renate NST
Old
#19  
Renate NST's Avatar
Recognized Contributor / Recognized Developer - OP
Thanks Meter 782
Posts: 1,951
Join Date: Feb 2012
Location: Boston
I was wondering how you were in a boot loop and managed to ssh.

Code:
# dmesg
.....
# logcat
.....
If you don't have a shell this is not going to do you any good.
 
ajislav
Old
#20  
Member
Thanks Meter 31
Posts: 76
Join Date: Apr 2011
I used noogie to get an img which I then mounted (using OSFMount and Ext2IFS) under windows..

looking at the /system partition, I see that
- my .old and .new files are gone
- the correct framework-res.apk is in place
i.e. the CWM scripts I have run did their job correctly.. so they have effectively undone any changes that I have made.. so the nook should boot up without any problems

weird....

so I guess my only options are
- restore my pre-root backup
- factory reset

Tags
landscape, screensaver
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes