It's School time: Adventures in hacking an old Kindle

(samkhawase.com)

176 points | by FlyingSnake 2 months ago ago

50 comments

  • bigiain 2 months ago

    In case the author ever sees this...

    If you have that battery level available off the Kindle, you can use it to turn a wifi "smart plug" on and off, to automatically top the charge up only when required.

    (Or, more old-school, use a powerpoint timer set to only power up for a short time each day. I did this way back, when the place I worked decided they needed iPads stuck next to meeting room doors to stop arguments about who had it booked, but when they first installed them they left them plugged into the charger 24x7, and the batteries in them would puff up in 8-12 months and kill the iPads. Putting the charger in a timer so they only charged hour a day saved them about $6,000 a year in puffed up iPads.)

    • password4321 2 months ago

      Last week I xkcd#1053'd (aka lucky 10,000'd) https://chargie.org thanks to https://news.ycombinator.com/item?id=43766728#43767575 (additional anecdata: https://hn.algolia.com?query=chargie&type=comment)

      >an interposing dongle [$25 on sale!] which provides a Bluetooth receiver and app that lets you set arbitrary preferences on your phone and fast charge, slow charge, or turn off the charger at configurable state of charge setpoints or times

      Another option I learned about just now for Macbooks: https://github.com/AppHouseKitchen/AlDente-Charge-Limiter (macOS 11+; $25 Pro version)

      And I saw your recommendation elsewhere in the previous discussion I dug up (https://news.ycombinator.com/item?id=31841051#31842078) because someone mentioned that power cycling the battery on a timer would still eventually encounter the same problem.

      >Trades one problem for another. Now you are cycling the battery frequently which is going to do the same thing in the end.

      • Abishek_Muthian 2 months ago

        I’d add using those old 1A charger for slow charging the device overnight to reduce heat generated during charging especially during summer.

      • coderatlarge 2 months ago

        isn’t this what usb-pd is for?

    • FlyingSnake 2 months ago

      Author here: Thanks for the suggestion. I do have a wifi smart plug and I can take a look at this near trick. So far it's easier to charge it once a month as it runs fine for 2-3 weeks in one charge.

  • mtlynch 2 months ago

    >I designed a backend API that collected the data in real-time data and exported it as a PNG image.

    Does anyone know why in these Kindle modding dashboards, they always generate the dashbard image on an external server? Why isn't it possible to build all that functionality into an executable on the Kindle itself? You've got a Linux environment, so why can't you run all the logic locally?

    • kovac 2 months ago

      I built this dashboard. The price curves and text are rendered locally from the microcontroller and painted pixel by pixel. Letters use raster fonts stored locally, price curves are generated on the fly. It can be done, it takes a bit of care. Mine only has ~400KB memory. It must be a lot easier on the Kindle, I think it runs Java even.

      https://www.asciimx.com/projects/etlas/

      • FlyingSnake 2 months ago

        Thanks for sharing your project, it is very cool! I'll check it out and see if I can get it to work.

        Kindle is very hackable if you're ready to endure some weird quirks. E.g. You can install Python on kindle or do custom software using various tools like Gcc, clang, Perl etc.

        1: https://wiki.mobileread.com/wiki/Python_on_Kindle

        2: https://wiki.mobileread.com/wiki/Kindle_Hacks_Information#Ki...

        • kovac 2 months ago

          Sure, if you run into issues, feel free to drop me an email. My address is on the home page.

          Thanks for sharing the resources! Great to connect with fellow e-paper enthusiasts :)

        • seba_dos1 2 months ago

          ...and if you're not ready for enduring weird quirks, just launch stuff out of Debian chroot within Xephyr. I've used Pidgin this way many years ago.

    • FlyingSnake 2 months ago

      It is definitely possible to draw the images on the Kindle client, e.g. KoReader does that. I've mentioned 2 different ways in the article FBInk and Kindlet. I found it a bit cumbersome to use these tools and the tooling is bit iffy. It was easier for me to just download it from the server.

      [1]: https://github.com/NiLuJe/FBInk

      [2]: https://wiki.mobileread.com/wiki/Kindlet_Index

    • floren 2 months ago

      I'm just curious about the best way to generate a dashboard image locally without invoking a web browser -- I'm quite terrible at web programming and would be much more comfortable with ImageMagick or even troff.

    • dmitrygr 2 months ago

      Most people today do not know how to program in the confines of 256MB of RAM and are not aware that languages other than javascript exist.

      • supportengineer 2 months ago

        I expected the Kindle to do a few api calls and call ImageMagick but instead, in Cloudflare, it sets up a headless browser, and renders a web page to a PNG file on the server, and then only the final png image gets returned to the Kindle.

  • shlip 2 months ago

    A bit tengential to the subject here, but maybe someone can tell which kindle is the easiest to jailbreak without it having to be registered ? I see that Windbreak needs device registration and that's a bit of a show stopper for me...

    • myself248 2 months ago

      Same, same. I picked up a couple of used ones at an estate sale and I just want them as e-ink tablets. It's weird to me that there's no from-the-ground-up total firmware replacement for these.

  • dmitrygr 2 months ago

    4 significant figures on weather temperature is kind of funny to look at. Must be some very accurate forecasts

    • mobilemidget 2 months ago

      I was just here to write the same thing :) imagine it being 0.01 degrees too warm or cold

      • alnwlsn 2 months ago

        Reminds me of those times I work with temperature sensors which report in eighths of a degree. 3 decimal places to give less than one decimal place of precision. You can round, but somehow that doesn't feel right.

    • FlyingSnake 2 months ago

      I did that on purpose. My daughter is learning decimal place value system in school and I thought it would be a cool Easter Egg for her.

  • marcod 2 months ago

    I just realized I had a few Kindle Fires lying around in a box.

    I wanted to give one to a friend who didn't have a good phone so she could listen to audio books. Turns out those old Fires are no longer updated and Android is so old I can't even install anything current on it.

    I hope to change that with https://kindlemodding.org/ which was mentioned, so appreciate the writeup :)

    • theblazehen 2 months ago

      They don't cover the Kindle Fires, however you can get a _slightly_ newer Android from https://xdaforums.com/f/kindle-fire-android-development.1309...

      • marcod 2 months ago

        Darn, I checked XDA but must have been in the wrong forum because that's really what I was looking for - thanks!

    • wintermutestwin 2 months ago

      https://kindlemodding.org/

      I appreciate finding that site as well, but I thought it strange that I couldn't find a "why jailbreak" section. Does anyone here know?

      I don't want Amazon's spying on me so I have just kept it in Airplane mode since I bought it 9 years ago. It seems to work fine ¯\(ツ)/¯

  • megous 2 months ago

    Hacking here seems to have been done by others.

    Anyway, speaking of hacking... check out what pocketbook creators themselves did with some of the older pocketbook models. They managed to drive eInk display panel from a normal RGB LCD interface, because they used a SoC (A13) without eInk interface. One of the weirder things I saw during my reverse-engineering adventures. :D

  • ishanmahapatra 2 months ago

    Unfortunately, Winterbreak doesn’t work on Kindles with the latest firmware (5.18.1 or 2). And there’s no way to downgrade the firmware to an earlier one without having previously jailbroken your device.

    So now it’s a waiting game to see when the new method for the latest firmware will be ready for the public.

  • larodi 2 months ago

    Old kindles should be donated to engineering schools and academia to break it into pieces and do new hacks with them. Amazon produced so many of them there’s always one 7” lying around at a friend’s desk.

    • myself248 2 months ago

      Are you aware of a school that proactively declares that they accept such donations?

      Speaking in my volunteer post as the coordinator of a makerspace electronics lab, we were buried in e-waste "abandonations" (someone literally unloaded a pickup truck full of mouse-eaten boxes of plastic junk outside our door one morning, and it took us a week of volunteer hours to dispose of it all properly) until we got very aggressive about requiring advance approval by the appropriate coordinator.

      • larodi 2 months ago

        No, but I've been campaigning at university where I teach to do it. As you may expect - very few people at academia do bold moves just out of love for knowledge these days. So, perhaps, I'm going to have to do it myself sooner or later.

        I believe the tagline should be - "welcome to the hackaton. you live in a post-singularity world where only legacy chips are available, and the establishment controls all the silicon producing facilities. your job is to bring equipment back to live in order to help the resistance"

        Of course the entry exam is having students spend a day without mobiles, in order to get used to this reality :D

        • myself248 2 months ago

          Every syllabus should be part manifesto. I love this.

  • stavros 2 months ago

    Is there anything like this that can wake the Kindle up, get an image, and then sleep it again? I have an old Kindle that I want to show stuff on, but I don't want to keep it plugged in all the time.

    • FlyingSnake 2 months ago

      > wake the Kindle up, get an image, and then sleep it again

      This is basically what I'm doing with this project. I tested the client by getting a dummy image initially. This line in the code puts it to sleep for x-duration. The kindle runs for ~2-3 weeks on a single charge.

      [1^]: https://github.com/samkhawase/kindle-dash-client/blob/master...

      • stavros 2 months ago

        That's what I wanted, thank you!

        • FlyingSnake 2 months ago

          If you just want to test if your image works, I've created a handy script for testing. It downloads the image, displays it for 20 seconds, and reverts the Kindle back to its normal state.

          https://github.com/samkhawase/kindle-dash-client/blob/master...

          • stavros 2 months ago

            That will be useful, thanks. I'll try a proof of concept soon.

            • FlyingSnake 2 months ago

              Best of luck!

              Please feel free to ping me if you need any help.

              • stavros 2 months ago

                That's very kind, I will, thanks (though your scripts are really straightforward so I don't anticipate any trouble).

    • kovac 2 months ago

      I work on e-paper displays. Are you looking for something built with a Kindle?

      This project of mine is similar to what you described with a power down mode. The power down and wake up can be automated. I'm looking to build a small business around such projects. Not sure how viable it is.

      https://www.asciimx.com/projects/e-reader/

      • stavros 2 months ago

        It does seem pretty viable, TRMNL are pretty popular:

        https://usetrmnl.com

        I made some stuff of mine for that display too, but the easiest way is to just use TRMNL's firmware, as it supports autoupdates and a few other nice features.

        Here's mine:

        https://www.stavros.io/posts/making-a-trmnl-device/

        Plus this:

        https://www.stavros.io/posts/making-the-timeframe/

        And a few more things I never wrote about.

        The Kindle project is just because I have a few Kindles lying around, so I might as well use them!

        • kovac 2 months ago

          That's beautiful, thanks for sharing. I was wondering what may be the best way to do frames. Custom frames, here in Singapore, are a bit expensive relative to the rest of the parts.

          • stavros 2 months ago

            3D printing is one good way, the other way I used is just to get a frame from IKEA and 3D print the inside white bit to my exact dimensions, which worked beautifully.

            I should post that build too, with some photos, I really like it.

      • sciencesama 2 months ago

        Develop a 3d case and a finished pcb. Check out trmnl

    • seba_dos1 2 months ago

      bash, rtcwake, any X11 client

  • mahi_novice 2 months ago

    Love this! Always fun to do stuff like this.

  • butz 2 months ago

    It might be faster, and cheaper, to build SVG file and render it on server directly to correct format.

  • gitroom 2 months ago

    lol i get weirdly obsessed with decimal places on stuff like this too - makes me laugh every time.

  • badmonster 2 months ago

    highlights for me:cf-wasm for image transformation and the graceful handling of real-world issues like BVG strikes.

  • goodboyjojo 2 months ago

    cool read. its always good to breath life into an old device with hacking and modding

  • 2 months ago
    [deleted]