MenuMaster

Posted on the January 31st, 2012 under Gadged by

I was looking around for a way to launch Hulu Desktop using my Apple Remote instead of it always bringing up Front Row. I couldn’t find a simple, free app to do it – so I made my own. If you’re having this problem, go grab it and thank me later.

How I Write Code

Posted on the January 31st, 2012 under Gadged by

My approach is usually to stare out the window or at a wall or blankly at my desktop and “see” the code, in a sense. Almost as if projected onto the world – but not quite. I think I’m seeing packets of meaning rather than programming language text. It’s hard to say for certain. I [...]

Various Object-Oriented Design Dilemmas

Posted on the January 30th, 2012 under Gadged by

[ Concrete or Abstract or Tool ]
A concrete Box object may represent an actual on-screen box where if you adjust the x or y properties of the object, the on-screen box moves and if you remove or delete the Box object, the visible box goes away. An abstract Box object may simply be a container [...]

QuickOIB

Posted on the January 30th, 2012 under Gadged by

Hey, I would just like to tell you about a project pH is working on called QuickOIB. It is an installer for openiboot that works on Mac OS and Linux. He also tells me that he is working on a Windows version.

I’m sure it’ll be very useful to people wanting a quick way to get past the OpeniBoot stage and get directly to working with the Linux environment.

 QuickOIB

 QuickOIB

 QuickOIB

Still Alive

Posted on the January 30th, 2012 under Gadged by

Been busy lately, but we’ll be back at it soon. Stay tuned for updates!

 Still Alive

 Still Alive

 Still Alive

25 things about me

Posted on the January 30th, 2012 under Gadged by

3789 25 things about me(I’m going to start posting more things non-iPhone related. If you only subscribe for iPhone stuff, follow my iPhone tag. I’d love you to stick around though. )

There’s been this "25 things" trend on Facebook where people post 25 things about themselves and let all their friends learn a little more. I decided to post my 25 things here because not all of you follow me on Facebook.

I’ve been meaning to do my 25 things for a while. As a somewhat private person it’s generally quite difficult for me to open up. But here goes.

1. My full name is Nathaniel Paul True. Nathaniel means ?God has given? and Paul means ?small?.

2. As I was growing up I was fascinated with how my toys worked and would take them apart all the time. I soon became interested in assembling my own electronics and dove into that.

3. I also took up programming early on…

Read the rest of this post

Debian on iPhone Linux

Posted on the January 29th, 2012 under Gadged by

NAND writing is now semi-reliable (although one has to be VERY careful not to interrupt the device in the middle of a write operation), but it is enough to have something akin to a full-functional OS, backed by non-volatile storage.

People interested in the project should be familiar with the myriads of Linux “distributions” floating around. An operating system consists of two major domains: one is the kernel, which is what manages the hardware, and one is the userland which contains things like shells and other UIs, package managers, etc. Software that help users install and run useful programs. Ubuntu is a popular distribution that I run on my personal machine. Android could also be considered a distribution (though I believe it has some apparently messy kernel patches).

I decided that Debian would be an interesting thing to try, since we would then instantly have a userland and a pool of ready-compiled applications. Using a slightly dated root filesystem here: http://lists.debian.org/debian-arm/2007/01/msg00034.html, a initrd and further kernel configurations were sufficient to get it to run. Thus, we can now compile programs for iPhone Linux on iPhone Linux. The process is rather slow due to the processor and inefficient NAND device driver (pending a real FTL), but at least theoretically, iPhone Linux is now self-hosting.

This should be pretty much enough for those who are more into the userland development side of things to come in, possibly using Debian as a base to build anything else (as I believe it is standard enough).

I will be offering instructions on how to get this all to work soon. The (modified for gadget serial terminal) rootfs is fairly hefty (around 130 MB), so I’m not sure how we’ll handle distribution of that.

 Debian on iPhone Linux

 Debian on iPhone Linux

 Debian on iPhone Linux

Porting drivers to Linux

Posted on the January 29th, 2012 under Gadged by

We’ve made some progress on the USB gadget driver for Linux, and we’re now running a generic serial gadget for communication. This implementation is important because USB is now a lot less laggy and things like ethernet over USB, etc., can eventually be supported, easing access.

We’ve also got pretty far with porting the NAND driver to Linux. Most of the read support is now there, and we’ve isolated the routines in the iPhone kernel where the raw hardware write occurs. CPICH and c1de0x are working on reversing it. Hopefully, it will be analogous enough to reads that it won’t take a huge amount of time to work out.

This is different from reversing their FTL, however, which is a complicated slew of data structures, merge buffers and other exotic algorithms that take care of evenly distributing writes throughout the device and also making writes take less time.

I think reversing all of that would take too much time and effort. Instead, my proposal is to just reverse the hardware NAND writes. Instead of using a partition, we would have a loop-mounted root filesystem (similar to how Wubi is setup), with the root filesystem being a file on the Media partition. Since there’s a non-empty file at that location, the FTL system, whatever it is, must create a one-to-one mapping from logical sectors to physical NAND pages. We can already read the mapping it creates (we have already reversed the read-side FTL code), and so all we have to do to alter the data is to write to the same pages we would’ve read from. Of course, this means that wear-leveling and bad block handling is not performed. However, if we use a filesystem that’s aware of bad blocks and can wear-level (YAFFS or JFFS2), then it amounts to the same thing. The wear-leveling would then take place over the particular physical pages belonging to the rootfs image, rather than the entirety of the NAND. This would make the physical pages belonging to the rootfs image wear out a little faster than the rest of the NAND, but the actual effect of this should be inconsequential.

The additional benefit of this setup is that there’s no repartitioning required, so setup is cinch. See this wiki document for specific proposed implementation details.

 Porting drivers to Linux

 Porting drivers to Linux

 Porting drivers to Linux

Donations…

Posted on the January 29th, 2012 under Gadged by

A couple of people asked for a donate button of some sort. I hesitate because of the sudden complexity of things when money is involved. Here is what I think would be best:

  • Donate your time and skills if you can rather than money.
  • If you cannot do so, please consider sponsoring something we could directly use: Such as a USB serial cable (about $45 for parts from Sparkfun), or perhaps upgrading the Slicehost slice we’re borrowing from pumpkin ($60 per month, though it would only be useful if we could get enough money for at least six months), used or broken devices for testing, etc. Or something like a pizza for one of our contributors on a late night hacking binge (we will distribute food donations on a round-robin basis =P)
  • My paypal address is my gmail e-mail address (planetbeing). If you do make a donation, please specify exactly what it is for. A gigantic slush fund is something that I wish to avoid.

For the record, contrary to what was published by some media sources, the iphonelinux group is not associated with the group commonly known as the “iPhone Dev Team”. I’m a member of the Dev Team, and other members sometimes lends assistance or advice, but this is an entirely separate project. The Dev Team does not accept any donations whereas this project tentatively will.

 Donations...

 Donations...

 Donations...

Updating and uninstalling openiboot

Posted on the January 29th, 2012 under Gadged by

It’s actually slightly problematic to use the “Update Firmware” feature of iTunes with openiboot installed, so I updated openiboot with an uninstall facility.

I uploaded the binaries and instructions necessary to update openiboot (and then uninstall it if you wish) to: http://www.iphone-dev.org/planetbeing/openiboot-uninstall.tar.gz

 Updating and uninstalling openiboot

 Updating and uninstalling openiboot

 Updating and uninstalling openiboot