Quantcast
Channel: MobileRead Forums - Kindle Developer's Corner
Viewing all articles
Browse latest Browse all 4430

"USB Connected" screen image replacement

$
0
0
Dear Mobileread Community,

I need your help in replacing screen image when Kindle Paperwhite 3 (5.9.7) is connected via USB.
I had no problem doing that on Kindle 4 Non-Touch.
However, it seems like besides the png file itself, their is also an eips (?) command to draw something else.
What I did:
1) Prepared an image. Just took my favorite one and after some tweaks in GIMP, I finally converted it to a proper eips-compatible format:
Code:

convert input.png -type GrayScale -depth 8 -colors 256 -resize 1072x1448! output.png
2) Replaced bg_usbconnect.png in /usr/share/blanket/usb and gave it the same permission chmod as it was of the original one. I attached my screen image to this post.
3) Now, when I connect to USB, my new screen image shows up very well, but on top of that there are two more things. One is a text 'If you want to read while still charging... blahblah', another is a small white square of a charging icon. I can see that it is ov_default_charging.png (I attached it too) in the same folder.
4) I returned to (1) and added a white circle approximately at location around that square.

Why approximately? Because I don't have exact coordinates or a combined pictures of them all.
Well, here come two problems:
1) I have no idea how to take screenshot of the screen while Kindle is connected via USB. I tried to:
— press the diagonally opposite corners of the screen (as for usual screenshot). Screen blinks, as if it took a screenshot, but I can't find it. I guess, because /mnt/us/ is now unmounted and presented to PC, there is no place to put screenshot to.
— access ssh during usb connection, but Kindle is inaccessible when connected, so I can't reach command line to invoke 'screenshot' command.
— connect to ssh first, then do 'sleep 20; screenshot' command, then connect to usb and wait for these 20 sec to pass. Screen again flashes as if it took the screenshot, but I can't find it anywhere.
2) I have no success in finding a script for USB connection event neither to see how these two extra things are drawn. I looked up in /etc/upstart/ using Total Commander's 'Search in files' feature trying to find anything related to 'usb'. There should be a daemon (or sort of 'listener') that catches the /mnt/us/ upon usb connection and manages its mount to PC and back to Kindle.

If I have at least coordinates of that little square, I could've replaced it by the same pixels of my new image at these coordinates, so that the square would seem 'transparent'.

Do you guys have any suggestions?
Thanks!

Attached Thumbnails
Click image for larger version

Name:	bg_usbconnect.png
Views:	N/A
Size:	646.6 KB
ID:	168457  
Attached Images
 

Viewing all articles
Browse latest Browse all 4430

Trending Articles