View Single Post
Old 06-09-2011, 04:48 AM   #25
hawhill
Wizard
hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.hawhill ought to be getting tired of karma fortunes by now.
 
hawhill's Avatar
 
Posts: 1,379
Karma: 2155307
Join Date: Nov 2010
Location: Goettingen, Germany
Device: Kindle Paperwhite, Kobo Mini
I think it was a simple shell script (or similar) that just wrote in regular intervals to the /proc pseudo-file (it's /proc, not /sys, I think) in order to refresh, so it was constantly refreshing. (Think: "while sleep 3; do echo 1 > /proc/.../refresh; done")
That's a simple trick to get any app to do output that at least does the memory part well. There's another thing I forgot to mention: The Kindle's memory layout for the framebuffer. It's 4bit, and this hits some applications very unprepared :-)

The /proc pseudo-files are one way to trigger refreshes, yes. I don't like them, however, since using this API means unnecessary string operations. But probably this overhead is negligible. The other way to do it is using private ioctls on the framebuffer device.

All of e-ink framebuffer is "custom" (but it builds upon the "mainline" framebuffer API). However, its code comes with the sources that Amazon provides. That way you can also get the C header file defining the ioctls for refreshing.
hawhill is offline   Reply With Quote