MartinPham / kindle-calendar

Transform your Kindle into a Calendar
GNU General Public License v3.0
36 stars 0 forks source link

Inconsistent colours and broken quotes. #1

Open cautious-bread opened 1 year ago

cautious-bread commented 1 year ago

Firstly, thank you SO much for this! I've been wanting to attempt something like this for a while, but just didn't have the skills. I've been excitingly waiting for your guide.

I have it setup and it... kinda works. The layout looks OK, but the greys, blacks and whites will sometimes not render, leaving the text invisible or just... off. If I press the power button, it'll refresh to be correct, sometimes, but eventually crash the device, needing a forced reboot.

image

Also, the quotes are not rendering. I see the below message in the USBnetwork/SSH session before the connection drops out...

[FBInk] Detected a Kindle PaperWhite 2 (0x17 => Pinot on Wario)
[FBInk] Clock tick frequency appears to be 100 Hz
[FBInk] Screen density set to 212 dpi
[FBInk] Variable fb info: 758x1024, 8bpp @ rotation: 3 (Counter Clockwise, 270°)
[FBInk] Fixed fb info: ID is "mxc_epdc_fb", length of fb mem: 3145728 bytes & line length: 768 bytes
[FBInk] Fontsize set to 16x16 (IBM base glyph size: 8x8)
[FBInk] Line length: 47 cols, Page size: 64 rows
[FBInk] Pen colors set to #EEEEEE for the foreground and #FFFFFF for the background
Loading font '/mnt/us/extensions/calendar/AppleChancery.ttf' for the Regular style
[FBInk] Font `/mnt/us/extensions/calendar/AppleChancery.ttf` loaded for style 'Regular'
Printing string '' @ 20.0pt (or 0px), honoring the following margins { Top: 820px, Bottom: 5px, Left: 43px, Right: 43px } (default style: 0, formatted: Y, compute only: N, no truncation: N, overlay: N, no BG: Y, no FG: N, inverted: N, flashing: N, centered: Y, H align: 0, halfway: Y, V align: 0, clear screen: N, waveform: AUTO, dithering: PASSTHROUGH, nightmode: N, skip refresh: N)
[FBInk] [fbink_print_ot] Cannot print an empty string!
[CLI] Failed to print that string!
wakeup from "no" at Tue Dec 13 03:12:03 2022
rtcwake: write error: Invalid argument
client_loop: send disconnect: Connection reset

It thinks there is not string to print for the quotes.

Any ideas what I could be doing wrong? I have only updated the config.sh file so far to match the display resolution for my device

export SCREEN_WIDTH=758
export SCREEN_HEIGHT=1024
MartinPham commented 1 year ago

Thanks for your report, and sorry that you had problem. For saving battery, the script will put your device to sleep, not to crash it. Clicking the power button will wake it up & force re-render. May I have your quotes.txt file? Thanks

cautious-bread commented 1 year ago

No need to apologise - I'm just stoked this is even out in the wild. I can't expect it to work flawlessly on every device first time. The quotes.txt file is the same one in the repository - I wanted to check all works "as-is" before tweaking anything.

But by device definitely "crashes" at some point. If I leave it over night, the display will be iffy, as in some of the text will be the same colour as the background, or it'll be showing the background only. So it must try and update at some point and get itself in a twist.

Pressing the power button does force a refresh, but only about 3. After that the light stays on and nothing responds - I need to hold the power button for the forced reboot.

Maybe certain models don't play well with the scripting. Mine's a PW2 from 2013 (6th Generation according to the "about" info).

MartinPham commented 1 year ago

Thanks, could you check if you have the /mnt/us/extensions/calendar/output.log file? Or /extensions/calendar/output.log (if you're browsing from the Kindle via USB)

cautious-bread commented 1 year ago

Hi again. Sorry for the late reply - busy week. The output.log doesn't have anything useful I'm afraid...

2022-12-12_21:11:46: Calendar Enabled 2022-12-12_21:12:01: Battery level: 92 2022-12-12_21:12:02: Sleeping 2022-12-12_21:12:05: Battery level: 92 2022-12-12_21:12:07: Sleeping 2022-12-12_21:12:10: Battery level: 92 2022-12-12_21:12:22: Sleeping 2022-12-12_21:12:25: Battery level: 92 2022-12-12_21:12:32: Sleeping 2022-12-12_21:12:35: Battery level: 92 2022-12-12_21:14:18: Sleeping 2022-12-12_21:14:21: Battery level: 92 2022-12-12_21:14:30: Sleeping 2022-12-12_21:14:33: Battery level: 92 2022-12-12_21:24:43: Sleeping 2022-12-12_21:24:46: Battery level: 92 2022-12-13_03:24:47: Sleeping 2022-12-13_03:24:50: Battery level: 89

MartinPham commented 1 year ago

Sorry for late, I'm trying to figure out the crash. Probably differents between devices

cautious-bread commented 1 year ago

No worries at all. And this is a nice-to-have thing to play with. Not expecting miracles. If you told me it works fine on yours and to go away, no hard feelings :-)